Shopping Lists
Gets shopping list by name or defaults to all shopping lists if name is not provided. When scope is provided then all shopping lists are returned. If scope is not provided, then only own shopping list is returned.
Additional scope info
shoppinglist.shoppinglist_read- Required only for the employee to read shopping lists. If scope is not present, then the customerId is resolved from the token.
- : Needed to retrieve shopping lists.
Your Emporix tenant name.
Note: The tenant name should always be written in lowercase.
saasdev2Name of the shopping list. If missing all shopping lists are provided. This query param has no effect when it's used by employee.
Resource successfully retrieved.
Request syntactically incorrect. Any details will be provided within the response payload.
Given request is unauthorized - the authorization token is invalid or has expired. Details will be provided in the response payload.
Some server side error occurred.
GET /shoppinglist/{tenant}/shopping-lists HTTP/1.1
Host: api.emporix.io
Authorization: Bearer YOUR_OAUTH2_TOKEN
Accept: */*
[
{
"customerId": "C120046",
"default": {
"name": "default",
"items": [
{
"id": 1,
"productId": "55cdcd91a88ed11babd7ca7e",
"quantity": 7.1,
"cuttingOption": "small",
"servicePackagingOption": "paper",
"comment": "fragile"
},
{
"id": 2,
"productId": "75cdcd91a88ed11babd7ca9i",
"quantity": 1.5,
"cuttingOption": "small",
"servicePackagingOption": "paper",
"comment": "fragile"
}
]
}
}
]To generate a customer access token, go to the Logging in a customer endpoint.
Your Emporix tenant name.
Note: The tenant name should always be written in lowercase.
saasdev2The shopping list resource has been successfully created.
Request syntactically incorrect. Any details will be provided within the response payload.
Given request is unauthorized - the authorization token is invalid or has expired. Details will be provided in the response payload.
Creation failed because there was a conflict with another resource. Details of the error are included in the response payload.
Some server side error occurred.
POST /shoppinglist/{tenant}/shopping-lists HTTP/1.1
Host: api.emporix.io
Authorization: Bearer YOUR_SECRET_TOKEN
Content-Type: application/json
Accept: */*
Content-Length: 191
{
"customerId": "C120043",
"name": "default",
"items": [
{
"id": 1,
"productId": "55cdcd91a88ed11babd7ca7e",
"quantity": 7.1,
"cuttingOption": "small",
"servicePackagingOption": "paper",
"comment": "fragile"
}
]
}{
"id": "C120043"
}Retrieves a shopping list based on the customer number. This endpoint is valid only for the employee.
To generate a customer access token, go to the Logging in a customer endpoint.
Your Emporix tenant name.
Note: The tenant name should always be written in lowercase.
saasdev2Unique identifier of the customer.
C120053Name of the shopping list
shopping list successfully retrieved.
Given request is unauthorized - the authorization token is invalid or has expired. Details will be provided in the response payload.
Given authorization scopes are not sufficient and do not match required scopes.
The requested resource does not exist.
Some server side error occurred.
GET /shoppinglist/{tenant}/shopping-lists/{customerId} HTTP/1.1
Host: api.emporix.io
Authorization: Bearer YOUR_SECRET_TOKEN
Accept: */*
{
"customerId": "C120048",
"default": {
"name": "default",
"items": [
{
"id": 1,
"productId": "55cdcd91a88ed11babd7ca7e",
"quantity": 7.1,
"cuttingOption": "small",
"servicePackagingOption": "paper",
"comment": "fragile"
},
{
"id": 2,
"productId": "75cdcd91a88ed11babd7ca9i",
"quantity": 1.5,
"cuttingOption": "small",
"servicePackagingOption": "paper",
"comment": "fragile"
}
]
}
}To generate a customer access token, go to the Logging in a customer endpoint.
Your Emporix tenant name.
Note: The tenant name should always be written in lowercase.
saasdev2Unique identifier of the customer.
C120053The resource has been successfully updated.
Request syntactically incorrect. Any details will be provided within the response payload.
Given request is unauthorized - the authorization token is invalid or has expired. Details will be provided in the response payload.
The requested resource does not exist.
Creation failed because there was a conflict with another resource. Details of the error are included in the response payload.
Some server side error occurred.
PUT /shoppinglist/{tenant}/shopping-lists/{customerId} HTTP/1.1
Host: api.emporix.io
Authorization: Bearer YOUR_SECRET_TOKEN
Content-Type: application/json
Accept: */*
Content-Length: 168
{
"name": "default",
"items": [
{
"id": 3,
"productId": "23cdcd91a88ed11babd7ca7y",
"quantity": 2.4,
"cuttingOption": "small",
"servicePackagingOption": "paper",
"comment": "fragile"
}
]
}No content
- : Needed to delete shopping lists.
Your Emporix tenant name.
Note: The tenant name should always be written in lowercase.
saasdev2Unique identifier of the customer.
C120053Name of the shopping list. If no name is provided, then all shopping lists of given customer are removed.
The resource has been successfully deleted.
Request syntactically incorrect. Any details will be provided within the response payload.
Given request is unauthorized - the authorization token is invalid or has expired. Details will be provided in the response payload.
Given authorization scopes are not sufficient and do not match required scopes.
The requested resource does not exist.
Some server side error occurred.
DELETE /shoppinglist/{tenant}/shopping-lists/{customerId} HTTP/1.1
Host: api.emporix.io
Authorization: Bearer YOUR_OAUTH2_TOKEN
Accept: */*
No content
Last updated
Was this helpful?

