Skip to content
Coritan Docs

Organization API: Customers: Commerce

The 4 Organization API operations for commerce.

View as Markdown

Part of Customers.

Method Path Summary
PUT /api/v1/orgs/{org_slug}/commerce/customer-groups/{group_id}/customers Set group customers
GET /api/v1/orgs/{org_slug}/commerce/customers Newest first, with each customer's order count, spend and groups
GET /api/v1/orgs/{org_slug}/commerce/customers/{customer_id} The customer, their saved addresses, note, tags, groups and spend
PATCH /api/v1/orgs/{org_slug}/commerce/customers/{customer_id} Note, tags, tax exemption, VAT id and its check; acceptsmarketing takes only false

PUT /api/v1/orgs/{org_slug}/commerce/customer-groups/{group_id}/customers

Make customer_ids exactly the group's customers (at most 1000); an id that is not one of the store's customers is not found.

Name In Type Required
group_id path integer yes
org_slug path string yes

application/json (required)

Field Type Required
customer_ids array of integer yes
Status Meaning
200 Success.
422 The request is not valid. detail lists each problem.

Newest first, with each customer's order count, spend and groups

Section titled Newest first, with each customer's order count, spend and groups

GET /api/v1/orgs/{org_slug}/commerce/customers

Newest first, with each customer's order count, spend and groups.

Name In Type Required Description
org_slug path string yes
q query string or null no Part of an email or a name.
group_id query integer or null no
limit query integer no Default: 50.
offset query integer no Default: 0.
Status Meaning
200 Success.
422 The request is not valid. detail lists each problem.

The customer, their saved addresses, note, tags, groups and spend

Section titled The customer, their saved addresses, note, tags, groups and spend

GET /api/v1/orgs/{org_slug}/commerce/customers/{customer_id}

The customer, their saved addresses, note, tags, groups and spend.

Name In Type Required
customer_id path integer yes
org_slug path string yes
Status Meaning
200 Success.
422 The request is not valid. detail lists each problem.

Note, tags, tax exemption, VAT id and its check; acceptsmarketing takes only false

Section titled Note, tags, tax exemption, VAT id and its check; acceptsmarketing takes only false

PATCH /api/v1/orgs/{org_slug}/commerce/customers/{customer_id}

Note, tags, tax exemption, VAT id and its check; accepts_marketing takes only false. Changing vat_id clears its check.

Name In Type Required
customer_id path integer yes
org_slug path string yes

application/json (required)

Field Type Required Description
accepts_marketing boolean or null no Only false: a store can turn consent off.
note string or null no
tags array of string or null no
tax_exempt boolean or null no
vat_id string or null no
vat_id_valid boolean or null no Whether the VAT id was checked and found valid.
Status Meaning
200 Success.
422 The request is not valid. detail lists each problem.