Skip to main content
POST
Create a customer

Authorizations

X-API-Key
string
header
required

API Key for authentication (format: sk_...)

Headers

X-Organization-Id
string

Required for Supabase session auth. Ignored when authenticating with an API key (the organization resolves from the key).

Body

application/json

Customer legal name (Razón Social)

Example:

"Dunder Mifflin"

taxId
string
required

Mexican RFC (tax identifier)

Example:

"ABC101010111"

taxSystem
string
required

SAT tax system code (Régimen Fiscal)

Example:

"601"

email
string
required

Customer email

Example:

"email@example.com"

defaultInvoiceUse
string
required

Default CFDI use code

Example:

"G01"

addressStreet
string
required

Street name

Example:

"Blvd. Atardecer"

addressExterior
string
required

Exterior number

Example:

"142"

addressNeighborhood
string
required

Neighborhood (Colonia)

Example:

"Centro"

addressCity
string
required

City

Example:

"Huatabampo"

addressMunicipality
string
required

Municipality

Example:

"Huatabampo"

addressZip
string
required

ZIP code

Example:

"86500"

addressState
string
required

State

Example:

"Sonora"

phone
string

Customer phone number

Example:

"6474010101"

addressInterior
string

Interior number

Example:

"4"

addressCountry
string
default:MEX

Country code

Example:

"MEX"

Response

id
string
required
Example:

"590ce6c56d04f840aa8438af"

organizationId
string
required
Example:

"org-uuid"

Example:

"Dunder Mifflin"

taxId
string
required
Example:

"ABC101010111"

taxSystem
string
required
Example:

"601"

email
string
required
Example:

"email@example.com"

defaultInvoiceUse
string
required
Example:

"G01"

address
object
required
createdAt
string<date-time>
required
updatedAt
string<date-time>
required
phone
object
Example:

"6474010101"