Skip to main content
POST
Create customer

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Body

application/json

Names, email, phone, country code, group and tier IDs, status, and tag items, where supported, are trimmed of surrounding whitespace and reject blank or whitespace-only strings.

first_name
string
required
Required string length: 1 - 255
last_name
string
required
Required string length: 1 - 255
loyalty_tier_id
string | null
required

Loyalty tier ULID to enroll the new customer into, or null for none. The key must be present.

Required string length: 1 - 255
loyalty_tier_starting_point
integer | null
required

Initial loyalty points when a tier is assigned, or null. The key must be present.

email
string<email> | null

Customer email. At least one of email or phone is required.

Minimum string length: 1
phone
string | null

10 ASCII digits without country code. At least one of email or phone is required.

Minimum string length: 1
Pattern: ^[0-9]{10}$
country_code
string

Country code, e.g. +91. Defaults to +91 when omitted, including email-only creation.

Required string length: 1 - 5
Pattern: ^\+?\d{1,4}$
customer_group_id
string | null

Assigns the customer to a Customer Group for group-specific pricing and promotions. Required and non-null when the store has customer groups enabled; otherwise optional. Null leaves the customer without a group when customer groups are disabled. A non-null ID must belong to the store's configured groups.

Required string length: 1 - 255
business
object | null
status
string
default:active

Customer status; defaults to active. Free text — not restricted to a fixed set by this endpoint.

Minimum string length: 1
tags
string[]
Minimum string length: 1
attributes
CustomerAttributePayload · object[]

Attribute values to set on the new customer. Each entry targets an existing store attribute by key (its ULID or slug); no new attribute definitions are created here.

metadata
object | null

The customer's own data as key-value pairs. Merged into what the customer has: each key sent is set, a key sent as null is removed, keys not sent are kept; null or {} changes nothing. At most 50 keys and 16 KB as JSON.

Response

OK

message
string
success
boolean
content
object