Create a customer for a merchant with a first name, last name, and optional merchant customer reference ID.
Upon success, a status code of 201 (Created) will be returned. If a customer cannot be created with the provided data, a status code of 400 (Bad Request) will be returned.
Additionally, subscriptions can be created simultaneously with the customer. If there are one of more subscription failed during the creation, a status code of 207 (Multi-Status) will be returned. A 207 status code response is an array of success (201) and failure (400) responses. The response field can be either Customer (Create Customer 201 response), Subscription (Create Subscription 201 response) or CreateSubscriptionFailure type. CreateSubscriptionFailure response type has a MerchantSubscriptionRefId field for the failure subscription, and an ErrorMessage field for the error description. For a sample of each response type, refer to the 207 response sample below.
For additional details on how to create subscriptions, refer to the specifications at Create Subscription.
Name | Description |
---|---|
FirstName | Customer's first name |
LastName | Customer's last name |
Name | Description | Default value |
---|---|---|
EntityUseCode | Avalara tax exemption code | null |
MerchantCustomerRefId | Merchant's identifier for the customer | null |
BillingAddresses | Customer's associated address(es) for billing purposes. A required set of Address details: AddressLine1, City and State or AddressLine1 and PostalCode or State and PostalCode | [] |
ShippingAddresses | Customer's associated address(es) for shipping purposes | [] |