Get customer
const url = 'https://customer.shopgate.io/v1/merchants/example/customers/example?ignoreInternalAttributes=false';const options = {method: 'GET'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request GET \ --url 'https://customer.shopgate.io/v1/merchants/example/customers/example?ignoreInternalAttributes=false'Get customer
Parameters
Section titled “Parameters”Path Parameters
Section titled “Path Parameters”Query Parameters
Section titled “Query Parameters”Locale code to change the language of the attributes
Ignores internal attributes in the result set
Responses
Section titled “Responses”object
object
Internal Customer number, set automatically upon creation
External Customer number
First name of the customer
Middle name of the customer
Last name of the customer
Indicates anonymous/guest customer.
Tax class of the customer.
object
API identifier for the contact
External identifier of the contact
object
Number of a postbox
Number of a post
Validated according to country code
Validated according to country code
Validated according to country code
Custom customer attribute
object
Code of the defined customer attribute
Value for this attribute. Its a free text field for attributes where no values are set. Attributes which have value set should contains the code in an object. For instance value: { "code": "fish" }
Human readable name of the attribute
All customer settings which are defined by Shopgate
object
Communication Preferences.
Example
{ "customer": { "id": "d162439c-e2f9-4050-8b94-6bff33e8163b", "internalCustomerNumber": 2, "externalCustomerNumber": "10001", "firstName": "Max", "middleName": "René", "lastName": "Muster", "emailAddress": "max.muster@shopgate.com", "status": "active", "isAnonymous": true, "externalUpdateDate": "2022-01-26T15:56:48.047Z", "taxExempt": false, "taxClass": "string", "contacts": [ { "id": "55a94ee0-6671-11e9-bb49-13684cb7b248", "externalContactCode": "357709b0-9378-470b-976e-1b040e29b97b", "status": "active", "firstName": "Max", "middleName": "René", "lastName": "Muster", "companyName": "Shopgate GmbH", "address1": "Schloßstr. 10", "address2": "Haus B", "address3": "erste Etage", "address4": null, "city": "Butzbach", "postalCode": "78732", "region": "HE", "country": "DE", "additionalFields": { "dhlPostBoxNumber": 12345, "dhlPostNumber": 1234567890 }, "phone": "+49 12345 6789 001", "fax": "+49 12345 6789 002", "mobile": "+49 12345 6789 003", "emailAddress": "max.muster@shopgate.com", "isDefaultShipping": true, "isDefaultBilling": true, "externalUpdateDate": "2022-01-26T15:51:21.125Z" } ], "attributes": [ { "code": "tshirtSize", "name": "T-Shirt Size", "value": { "code": "l", "name": "L" } }, { "code": "nameOfCat", "name": "Name of your cat", "value": "Some Cat Name" } ], "settings": { "defaultLocale": "en-us", "defaultCurrency": "USD", "communicationPreferences": [ "email", "push", "sms" ], "defaultLocationCode": "DERetail001", "marketingOptIn": false } }}Merchant not found
default
Section titled “default”Unexpected error
object
Machine readable error code
Human readable error code
Examplegenerated
{ "code": "example", "message": "example"}
