Actions7
- Agenda Actions
- Contact Actions
Overview
This node integrates with the MedX65 medical system API to manage various resources such as agenda entries, contacts, patients, users, and sectors. Specifically, for the Contact - Create operation, it allows you to create a new contact record in the MedX65 system by providing personal details like name, email, phone number, CPF/CGC (Brazilian tax ID), birth date, and gender.
Common scenarios where this node is beneficial include:
- Automating the addition of new patient or client contacts into the MedX65 system from external sources.
- Synchronizing contact data collected from forms or other applications directly into the medical system.
- Streamlining workflows that require creating contacts before scheduling appointments or linking them to other records.
Practical example:
- A healthcare provider collects patient information via an online form and uses this node to automatically create a contact in MedX65, ensuring the patient's details are immediately available for appointment scheduling and medical records.
Properties
| Name | Meaning |
|---|---|
| Name | Contact's full name (required). |
| Contact's email address. | |
| Mobile Phone | Contact's mobile phone number. |
| CPF/CGC | Contact's CPF or CGC number (Brazilian individual or company tax identification). |
| Birth Date | Contact's birth date and time. |
| Gender | Contact's gender; options are "Male" (M) or "Female" (F). |
Output
The node outputs JSON data representing the response from the MedX65 API after attempting to create the contact. This typically includes confirmation of the created contact's details or any error messages returned by the API.
No binary data output is produced by this operation.
Example output structure (simplified):
{
"Id": 123,
"Nome": "John Doe",
"Email": "john.doe@example.com",
"Celular": "+5511999999999",
"CPF_CGC": "123.456.789-00",
"Nascimento": "1980-01-01T00:00:00",
"Sexo": "M",
...
}
If an error occurs and the node is configured to continue on failure, the output will contain an error field with the error message.
Dependencies
- Requires an API authentication token credential to access the MedX65 integration API.
- The node communicates with the MedX65 API endpoint at
https://medx65-v65teste.azurewebsites.net. - The integration token is used to request an authorized bearer token before making API calls.
- Proper configuration of the API credentials within n8n is necessary for successful requests.
Troubleshooting
- Authentication errors: If the API token is invalid or expired, the node will fail to authenticate. Ensure the API key credential is correctly set and valid.
- Missing required fields: The "Name" property is mandatory. Omitting it will likely cause the API to reject the request.
- Network issues: Connectivity problems to the MedX65 API endpoint can cause request failures.
- API errors: The MedX65 API may return errors if data formats are incorrect or business rules are violated (e.g., invalid CPF format).
- To handle errors gracefully, enable the node’s "Continue On Fail" option to capture error messages in the output for debugging.
Links and References
- MedX65 API Documentation (Not provided in source; check official MedX65 resources)
- n8n Documentation - Creating Custom Nodes
- Brazilian CPF Information