Sharpei icon

Sharpei

Consume Sharpei Api

Overview

The "Update Customer" operation in the Sharpei node allows users to modify existing customer information by sending updated data to the Sharpei API. This is useful in scenarios where customer details such as name, email, phone number, or identification need to be corrected or changed after initial creation. For example, if a customer's contact information changes or additional identification details become available, this operation can update those records seamlessly.

Properties

Name Meaning
Customer Data (JSON) JSON object containing the fields and values to update for the customer. Typical fields include first name, last name, email, customer type, currency, phone, user ID, and identification number.
Customer PID The unique identifier (PID) of the customer to update. This is required to specify which customer record should be modified.

Output

The node outputs JSON data representing the response from the Sharpei API after attempting to update the customer. This typically includes the updated customer details or confirmation of the update operation. There is no indication that binary data is output by this node.

Dependencies

  • Requires an active connection to the Sharpei API.
  • Requires an API authentication token or key configured in n8n credentials to authorize requests.
  • The base URL for API requests is https://api.prod.gosharpei.com/api.
  • The node expects JSON content-type headers for communication.

Troubleshooting

  • Missing or invalid Customer PID: If the customer identifier is not provided or incorrect, the API will likely return an error indicating the customer was not found. Ensure the correct PID is supplied.
  • Malformed JSON in Customer Data: Invalid JSON syntax or unsupported fields may cause the API to reject the request. Validate the JSON structure before sending.
  • Authentication errors: If the API key or token is missing or invalid, the node will fail to authenticate. Verify that the credential is correctly set up in n8n.
  • Network issues or API downtime: Connectivity problems or server errors from the Sharpei API will result in failed requests. Check network status and API availability.
  • Field validation errors: The API might enforce specific formats or required fields; ensure all mandatory fields are included and properly formatted.

Links and References

Discussion