POST {{baseURL}}/v2/customers
This endpoint creates a customer.
See Also:
To list customers, see GET /v2/customers.
To retrieve a customer by ID, see GET /v2/customers/{customerId}.
To update a customer, see PATCH /v2/customers/{customerId}.
To delete a customer, see DELETE /v2/customers/{customerId}.
Specifies the customer's first name.
Example: Alexandro
Specifies the customer's last name.
Example: Peppared
Specifies the name of the customer's company or organization.
Example: Peppared Street Cafe
Specifies the customer's email.
Example: peppared@example.com
Specifies the customer's mobile phone number.
Example: +14155552309
Specifies the customer has consented to receiving the SMS.
If true, the customer has consented to receiving the SMS.
If false, the customer has not consented to receiving the SMS.
Example: true
Specifies to use the billing address as shipping address.
If true, use the billing address as shipping address.
If false, do not use the billing address as shipping address.
Example: true
Specifies accepted cards (credit or debit) payment methods.
- Sandbox environmenthttps://sandbox.api.flute.com/v2/customers
- Production environmenthttps://api.flute.com/v2/customers
curl -i -X POST \
https://sandbox.api.flute.com/v2/customers \
-H 'Authorization: Bearer <YOUR_JWT_HERE>' \
-H 'Content-Type: application/json' \
-d '{
"firstName": "John",
"lastName": "Peppared",
"companyName": "Acme Corp",
"email": "john.doe@acme.com",
"mobilePhoneNumber": "+14125553845",
"hasSmsConsent": true,
"shouldUseBillingAsShippingAddress": false,
"billingAddress": {
"city": "New York",
"countryCode": "US",
"addressLine1": "123 Main Street",
"addressLine2": "Suite 100",
"postalCode": "10001",
"stateCode": "NY"
},
"shippingAddress": {
"city": "Brooklyn",
"countryCode": "US",
"addressLine1": "456 Market Street",
"addressLine2": "Suite 7B",
"postalCode": "11201",
"stateCode": "NY"
},
"paymentMethodsCreditCards": [
{
"paymentName": "My Visa Card",
"cardNumber": "4111111111111111",
"securityCode": "123",
"expirationMonth": 12,
"expirationYear": 2032
}
],
"paymentMethodsAchAccounts": [
{
"paymentName": "Business Checking",
"routingNumber": "021000021",
"accountNumber": "123456789",
"taxId": "12-3456789",
"accountHolderType": "Personal",
"accountType": "Checking"
}
]
}'OK
Identifies the customer to link this payment method to.
This value may be null when this payment method is an orphan owned by the merchant directly. An orphan payment method is a payment method in the merchant's vault but has no customer record associated with it.
Example: 8fa8e727-73c6-436e-b56f-6f55aabf3b1c
{ "customerId": "e0bfe4be-c02a-4ded-bbdf-07a8bf8544c8" }