Customer
View as MarkdownCreate, read, and update customer profiles within a store.
Authorization
PAT commerce.customer:readPersonal Access Token (PAT). Include as Authorization: Bearer $GODADDY_PAT. Required scopes: commerce.customer:read, commerce.customer:create, commerce.customer:update.
In: header
Scope: commerce.customer:read
Path Parameters
An identifier for a store
uuidQuery Parameters
The page of results to return for pagination. Only supported up to the first 10 000 records of a result set. Use pageToken rather than page where possible. PageToken and page can not be used in combination, doing so will result in a 422 response.
integer-positive1Maximum number of items to return. If used with page will return results with an offset of page * pageSize
integer-positivevalue <= 50025Use the pageToken returned from a previous search in order to obtain the next set of results. Use pageToken rather than page where possible. PageToken and page can not be used in combination, doing so will result in a 422 response.
Indicates whether the response should include the total number of items and pages through response properties totalItems and totalPages respectively.
Search term - this string will be matched as a starts with for all text fields
Filter customers by presence of at least one of these fields
Filter customers by absence of at least one of these fields
Filter customers by presence of all of these fields
Filter customers by absence of all of these fields
Filter customers by external identifier; provide as comma separated values in the form type:value (eg: poynt:123,asin:B0B9F7WNQH)
Filter customers whose updatedAt is >= the specified date
^[0-9]{4}-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])[T,t]([0-1][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)([.][0-9]+)?([Zz]|[+-][0-9]{2}:[0-9]{2})$20 <= length <= 64Filter customers whose updatedAt is <= the specified date
^[0-9]{4}-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])[T,t]([0-1][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)([.][0-9]+)?([Zz]|[+-][0-9]{2}:[0-9]{2})$20 <= length <= 64Sort expression accepted by the underlying customer search service
Whether to exclude guest customers (those without an associated user record). Defaults to true.
trueResponse Body
application/json
*/*
*/*
*/*
*/*
application/json
*/*
*/*
curl -X GET "https://example.com/stores/497f6eca-6276-4993-bfeb-53cbbbba6f08/customers"{ "links": [ { "href": "http://example.com", "rel": "string", "title": "string", "targetMediaType": "string", "targetSchema": null, "method": "string", "submissionMediaType": "application/json", "submissionSchema": null } ], "totalItems": 0, "totalPages": 0, "customers": [ { "customerId": "87d8e330-2878-4742-a86f-dbbb3bf522ac", "firstName": "Fredrick", "lastName": "Smith", "organization": "GoDaddy", "jobTitle": "string", "addresses": [], "emails": [], "instantMessages": [], "socialProfiles": [], "phones": [], "urls": [], "updatedAt": "stringstringstringst", "listKeys": [ "bbf6d5ee-f24e-4a77-a6a1-e3fd97d1db49" ], "joined": false, "orderCount": 0, "profileImageUrl": "string", "paymentCount": 0, "notes": "string", "createdAt": "stringstringstringst", "source": "string", "externalIdentifiers": [ { "externalId": "string", "source": "INVOICE" } ] } ]}Authorization
PAT commerce.customer:createPersonal Access Token (PAT). Include as Authorization: Bearer $GODADDY_PAT. Required scopes: commerce.customer:read, commerce.customer:create, commerce.customer:update.
In: header
Scope: commerce.customer:create
Path Parameters
An identifier for a store
uuidRequest Body
application/json
Customer data to import
Response Body
application/json
*/*
*/*
*/*
*/*
application/json
*/*
*/*
curl -X POST "https://example.com/stores/497f6eca-6276-4993-bfeb-53cbbbba6f08/customers" \ -H "Content-Type: application/json" \ -d '{ "customer": { "firstName": "Fredrick", "lastName": "Smith", "listKeys": [ "bbf6d5ee-f24e-4a77-a6a1-e3fd97d1db49" ] }, "source": "COMMERCE" }'{ "links": [ { "href": "string", "method": "string", "rel": "string" } ]}Authorization
PAT commerce.customer:readPersonal Access Token (PAT). Include as Authorization: Bearer $GODADDY_PAT. Required scopes: commerce.customer:read, commerce.customer:create, commerce.customer:update.
In: header
Scope: commerce.customer:read
Path Parameters
The id of the specific customer
uuidAn identifier for a store
uuidResponse Body
application/json
*/*
*/*
*/*
application/json
*/*
*/*
curl -X GET "https://example.com/stores/497f6eca-6276-4993-bfeb-53cbbbba6f08/customers/497f6eca-6276-4993-bfeb-53cbbbba6f08"{ "customer": { "customerId": "87d8e330-2878-4742-a86f-dbbb3bf522ac", "firstName": "Fredrick", "lastName": "Smith", "organization": "GoDaddy", "jobTitle": "string", "addresses": [], "emails": [], "instantMessages": [], "socialProfiles": [], "phones": [], "urls": [], "updatedAt": "stringstringstringst", "listKeys": [ "bbf6d5ee-f24e-4a77-a6a1-e3fd97d1db49" ], "joined": false, "orderCount": 0, "profileImageUrl": "string", "paymentCount": 0, "notes": "string", "createdAt": "stringstringstringst", "source": "string", "externalIdentifiers": [ { "externalId": "string", "source": "INVOICE" } ] }, "links": [ { "href": "http://example.com", "rel": "string", "title": "string", "targetMediaType": "string", "targetSchema": null, "method": "string", "submissionMediaType": "application/json", "submissionSchema": null } ]}Authorization
PAT commerce.customer:updatePersonal Access Token (PAT). Include as Authorization: Bearer $GODADDY_PAT. Required scopes: commerce.customer:read, commerce.customer:create, commerce.customer:update.
In: header
Scope: commerce.customer:update
Path Parameters
The id of the specific customer
uuidAn identifier for a store
uuidRequest Body
application/json
Customer data to import
Body shape for PATCH /stores/{storeId}/customers/{customerId}. Note that source is optional on update — the API does not require it (and production clients such as mwc-core do not send it on update calls).
Response Body
application/json
*/*
*/*
*/*
*/*
application/json
*/*
*/*
curl -X PATCH "https://example.com/stores/497f6eca-6276-4993-bfeb-53cbbbba6f08/customers/497f6eca-6276-4993-bfeb-53cbbbba6f08" \ -H "Content-Type: application/json" \ -d '{ "customer": { "firstName": "Fredrick", "lastName": "Smith", "listKeys": [ "bbf6d5ee-f24e-4a77-a6a1-e3fd97d1db49" ], "updatedAt": "stringstringstringst" } }'{ "links": [ { "href": "string", "method": "string", "rel": "string" } ]}Last updated on
How is this guide?