The API uses an auth token to recognize customers.
The following endpoints can issue tokens:
POST /login
POST /register
POST /addToCart
When a (new) token is issued the token will be set as a cookie named token
by the server and also be returned as an additional root level property token
on the JSON response of the endpoint.
The auth token can then be submitted with the subsequent requests in one of two ways:
Authorization
headerTo clear the token
cookie you can call the POST /logout
endpoint.
If no (valid) auth token is presented, but the called endpoint requires one, the API responds with the 401
status code.
Tokens expire after one week.
All endpoints require the following path parameters:
project
Your project key (e.g. finecollections
)country
ISO 3166-1 alpha-2 country code (e.g. DE
for Germany)To pick the correct translations of e.g. product attributes the API needs to know the client's language. By default the API will make an educated guess based on the Accept-Language
header. To overwrite this behavior all relevant endpoints accept an additional lang
query parameter.
Powered by Doctave