Create
Creates a customer and returns it with 201.
This endpoint accepts the Application API Scope only. Storefront API Scope signatures are rejected. merchant must be your merchant public ID, or the request returns 403.
Only merchant is always required. Your merchant account’s required-field settings can also require merchant_user_id, first_name, last_name, email, or other fields, and a missing one returns 400.
If a customer with this merchant_user_id already exists, nothing is created or changed. A request with the same merchant_user_id, email, and user_token_id as that customer returns 400; any other request returns 201 with the existing customer as it was.
Authentication
Application API Scope — server-to-server, sent in the x-api-key header. See Authentication.
Request
Your merchant public ID. It must match the merchant you authenticate as, or the request returns 403.
Session ID, from the og_session_id cookie. Ordergroove generates one if you leave it out.
Customer phone type: 0 (invalid), 1 (landline), 2 (mobile), or 3 (VoIP)
Whether the customer account is active. Defaults to true.
Extra information to store on the customer, as a JSON-encoded string of key/value pairs, up to 1,024 characters.
The customer’s locale, as a locale code such as en-us or a numeric locale ID. Codes are case-insensitive, and hyphens and underscores are interchangeable. Responses always return the numeric ID.
Experiences to check the customer against, keyed by experience name, for example {"reorder": true}. For each key, Ordergroove checks that the request includes every field your merchant account’s settings require for that experience, and returns 400 if any is missing. The values are ignored, and experiences aren’t saved on the customer.
Response
Customer phone type: 0 (invalid), 1 (landline), 2 (mobile), or 3 (VoIP)
When the customer last logged in. null until they do.
Extra information stored on the customer, as a JSON-encoded string.
The customer’s locale as a numeric ID, for example 1 for en-us, even if the request sent a locale code.