Add a Contact
Add a new contact for the merchant. Either contactemail or contactmobile must be provided. The service will check for existing contacts with the same ID, email, or mobile number and raise a conflict error if any duplicates are found.
external_id
string
Optional. The external ID for the contact. Optional but must be unique if provided.
contact_email
string
Optional. The email address for the contact. Either contact_email or contact_mobile must be provided.
contact_mobile
string
Optional. The mobile number for the contact. Either contact_email or contact_mobile must be provided.
contact_name
string
Optional. The name of the contact.
favorite
boolean
Optional. Whether the contact is a favorite. Optional, defaults to false.
CONFLICT
A contact with the same ID, email, or mobile number already exists. Each contact must have unique values for these fields.
VALIDATION_ERROR
Validation failed. Either contactemail or contactmobile must be provided. If contact_email is provided, it must be a valid email format.
UNHANDLED_ERROR
This error occurs when the server encounters an unexpected internal error that it cannot handle gracefully. This typically happens due to bugs, infrastructure issues, or edge cases that weren't anticipated during development.
INVALID_ARGUMENTS
This error occurs when the request contains invalid or missing parameters. Common cases include missing required fields, or values that don't match the expected format or type.
BAD_VERSION
This error occurs when making requests to an API version that does not exist. This commonly happens when using an outdated SDK or when the API version specified in the request URL is incorrect.
