Actions14
Overview
This node interacts with the Nookal practice management system via its GraphQL API. Specifically, the Patient - Update operation allows you to update an existing patient's information by specifying their unique ID and the fields to change.
Common scenarios where this node is beneficial include:
- Keeping patient records up-to-date with new contact details or demographic information.
- Correcting errors in patient data after initial entry.
- Automating updates from external systems or forms into Nookal.
For example, you could use this node to update a patient's phone number and email address after they provide new contact info during a call or appointment.
Properties
| Name | Meaning |
|---|---|
| ID | The unique identifier of the patient record to update. |
| Patient Data | A collection of fields to update for the patient. Options include: |
| - First Name: Patient's first name (string) | |
| - Last Name: Patient's last name (string) | |
| - Email: Patient's email address (string) | |
| - Phone: Patient's phone number (string) | |
| - Date of Birth: Patient's date of birth (date/time) | |
| - Gender: Patient's gender, selectable options are Male, Female, Other |
Output
The output JSON contains the updated patient object along with any errors returned by the API. The structure includes:
patient: An object with updated patient details such as:idfirstNamelastNameemailphonedateOfBirthgenderupdatedAt(timestamp of last update)
errors: An array of error objects if any occurred during the update, each containing:field: The field related to the errormessage: Description of the error
Example output snippet:
{
"updatePatient": {
"patient": {
"id": "123",
"firstName": "John",
"lastName": "Doe",
"email": "john.doe@example.com",
"phone": "555-1234",
"dateOfBirth": "1980-01-01T00:00:00Z",
"gender": "MALE",
"updatedAt": "2024-06-01T12:00:00Z"
},
"errors": []
}
}
No binary data output is produced by this operation.
Dependencies
- Requires an active connection to the Nookal practice management system via its GraphQL API.
- Needs an API authentication token configured in n8n credentials (an OAuth2 or API key credential).
- The node uses a helper function to send GraphQL requests to Nookal's API endpoint.
Troubleshooting
- Invalid ID Error: If the provided patient ID does not exist or is malformed, the API will return an error. Verify the ID is correct.
- Validation Errors: If any patient data fields are invalid (e.g., incorrect email format), the
errorsarray will contain details. Adjust input accordingly. - Authentication Failures: Ensure the API credentials are valid and have sufficient permissions to update patient records.
- JSON Parsing Issues: Input properties must be correctly formatted; otherwise, the node may throw errors before sending the request.
- Network Issues: Connectivity problems with the Nookal API endpoint can cause failures. Check network access and API availability.
Links and References
- Nookal API Documentation (for detailed API schema and mutation examples)
- GraphQL Basics (to understand query and mutation structure)
- n8n Documentation (for general usage of custom nodes and credentials setup)