MENU navbar-image

Introduction

This documentation aims to provide all the information you need to work with our API.

<aside>As you scroll, you'll see code examples for working with the API in different programming languages in the dark area to the right (or as part of the content on mobile).
You can switch the language used with the tabs at the top right (or from the nav menu at the top left on mobile).</aside>

Authenticating requests

To authenticate requests, include an Authorization header with the value "Bearer {YOUR_AUTH_KEY}".

All authenticated endpoints are marked with a requires authentication badge in the documentation below.

You can retrieve your token by visiting your dashboard and clicking Generate API token.

CustomerPrices

DELETE api/customer-prices/truncate

requires authentication

Example request:
curl --request DELETE \
    "http://localhost/api/customer-prices/truncate" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "http://localhost/api/customer-prices/truncate"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "application/json",
    "Accept": "application/json",
};


fetch(url, {
    method: "DELETE",
    headers,
}).then(response => response.json());

Example response (204):

Empty response
 

Request      

DELETE api/customer-prices/truncate

Headers

Authorization        

Example: Bearer {YOUR_AUTH_KEY}

Content-Type        

Example: application/json

Accept        

Example: application/json

Customer Products

DELETE api/customer-products/truncate

requires authentication

Example request:
curl --request DELETE \
    "http://localhost/api/customer-products/truncate" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"visibility\": \"visible\"
}"
const url = new URL(
    "http://localhost/api/customer-products/truncate"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "application/json",
    "Accept": "application/json",
};

let body = {
    "visibility": "visible"
};

fetch(url, {
    method: "DELETE",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());

Request      

DELETE api/customer-products/truncate

Headers

Authorization        

Example: Bearer {YOUR_AUTH_KEY}

Content-Type        

Example: application/json

Accept        

Example: application/json

Body Parameters

visibility   string  optional    

Example: visible

Must be one of:
  • visible
  • hidden
  • force_visible

Customers

Organizations

DELETE api/customer-organizations/{id}

requires authentication

Example request:
curl --request DELETE \
    "http://localhost/api/customer-organizations/architecto" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "http://localhost/api/customer-organizations/architecto"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "application/json",
    "Accept": "application/json",
};


fetch(url, {
    method: "DELETE",
    headers,
}).then(response => response.json());

Example response (204):

Empty response
 

Request      

DELETE api/customer-organizations/{id}

Headers

Authorization        

Example: Bearer {YOUR_AUTH_KEY}

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

id   string     

The ID of the customer organization. Example: architecto

DELETE api/customers/{id}

requires authentication

Example request:
curl --request DELETE \
    "http://localhost/api/customers/architecto" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "http://localhost/api/customers/architecto"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "application/json",
    "Accept": "application/json",
};


fetch(url, {
    method: "DELETE",
    headers,
}).then(response => response.json());

Example response (204):

Empty response
 

Request      

DELETE api/customers/{id}

Headers

Authorization        

Example: Bearer {YOUR_AUTH_KEY}

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

id   string     

The ID of the customer. Example: architecto

Products

DELETE api/customers/{customer_id}/products/{id}

requires authentication

Example request:
curl --request DELETE \
    "http://localhost/api/customers/architecto/products/architecto" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "http://localhost/api/customers/architecto/products/architecto"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "application/json",
    "Accept": "application/json",
};


fetch(url, {
    method: "DELETE",
    headers,
}).then(response => response.json());

Example response (204):

Empty response
 

Request      

DELETE api/customers/{customer_id}/products/{id}

Headers

Authorization        

Example: Bearer {YOUR_AUTH_KEY}

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

customer_id   string     

The ID of the customer. Example: architecto

id   string     

The ID of the product. Example: architecto

Order lists

DELETE api/customers/{customer_id}/order-lists/{id}

requires authentication

Example request:
curl --request DELETE \
    "http://localhost/api/customers/architecto/order-lists/architecto" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "http://localhost/api/customers/architecto/order-lists/architecto"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "application/json",
    "Accept": "application/json",
};


fetch(url, {
    method: "DELETE",
    headers,
}).then(response => response.json());

Example response (204):

Empty response
 

Request      

DELETE api/customers/{customer_id}/order-lists/{id}

Headers

Authorization        

Example: Bearer {YOUR_AUTH_KEY}

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

customer_id   string     

The ID of the customer. Example: architecto

id   string     

The ID of the order list. Example: architecto

POST api/customer-order-lists/{customer_id}/bulk

requires authentication

Example request:
curl --request POST \
    "http://localhost/api/customer-order-lists/architecto/bulk" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"product_ids\": [
        \"architecto\"
    ]
}"
const url = new URL(
    "http://localhost/api/customer-order-lists/architecto/bulk"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "application/json",
    "Accept": "application/json",
};

let body = {
    "product_ids": [
        "architecto"
    ]
};

fetch(url, {
    method: "POST",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());

Example response (201, Insert as bulk):



 

Request      

POST api/customer-order-lists/{customer_id}/bulk

Headers

Authorization        

Example: Bearer {YOUR_AUTH_KEY}

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

customer_id   string     

The ID of the customer. Example: architecto

Body Parameters

product_ids   string[]     

The id of an existing record in the products table.

Endpoints

POST api/forgot-password

requires authentication

Example request:
curl --request POST \
    "http://localhost/api/forgot-password" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"email\": \"gbailey@example.net\",
    \"username\": \"architecto\"
}"
const url = new URL(
    "http://localhost/api/forgot-password"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "application/json",
    "Accept": "application/json",
};

let body = {
    "email": "gbailey@example.net",
    "username": "architecto"
};

fetch(url, {
    method: "POST",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());

Request      

POST api/forgot-password

Headers

Authorization        

Example: Bearer {YOUR_AUTH_KEY}

Content-Type        

Example: application/json

Accept        

Example: application/json

Body Parameters

email   string     

:Attribute is geen geldig e-mailadres. Example: gbailey@example.net

username   string     

Example: architecto

POST api/reset-password

requires authentication

Example request:
curl --request POST \
    "http://localhost/api/reset-password" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"username\": \"architecto\",
    \"email\": \"zbailey@example.net\",
    \"token\": \"architecto\",
    \"password\": \"]|{+-0pBNvYg\",
    \"password_confirmation\": \"hwaykcmyuwpwlvqwrsitcpscql\"
}"
const url = new URL(
    "http://localhost/api/reset-password"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "application/json",
    "Accept": "application/json",
};

let body = {
    "username": "architecto",
    "email": "zbailey@example.net",
    "token": "architecto",
    "password": "]|{+-0pBNvYg",
    "password_confirmation": "hwaykcmyuwpwlvqwrsitcpscql"
};

fetch(url, {
    method: "POST",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());

Request      

POST api/reset-password

Headers

Authorization        

Example: Bearer {YOUR_AUTH_KEY}

Content-Type        

Example: application/json

Accept        

Example: application/json

Body Parameters

username   string     

Example: architecto

email   string     

:Attribute is geen geldig e-mailadres. Example: zbailey@example.net

token   string     

Example: architecto

password   string     

:Attribute moet minimaal 8 tekens zijn. Example: ]|{+-0pBNvYg

password_confirmation   string     

:Attribute moet minimaal 8 tekens zijn. Example: hwaykcmyuwpwlvqwrsitcpscql

POST api/request-account

requires authentication

Example request:
curl --request POST \
    "http://localhost/api/request-account" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"company_name\": \"architecto\",
    \"customer_number\": \"architecto\",
    \"address\": \"architecto\",
    \"postal_code\": \"architecto\",
    \"place\": \"architecto\",
    \"email\": \"zbailey@example.net\"
}"
const url = new URL(
    "http://localhost/api/request-account"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "application/json",
    "Accept": "application/json",
};

let body = {
    "company_name": "architecto",
    "customer_number": "architecto",
    "address": "architecto",
    "postal_code": "architecto",
    "place": "architecto",
    "email": "zbailey@example.net"
};

fetch(url, {
    method: "POST",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());

Request      

POST api/request-account

Headers

Authorization        

Example: Bearer {YOUR_AUTH_KEY}

Content-Type        

Example: application/json

Accept        

Example: application/json

Body Parameters

company_name   string     

Example: architecto

customer_number   string  optional    

Example: architecto

address   string     

Example: architecto

postal_code   string     

Example: architecto

place   string     

Example: architecto

email   string     

:Attribute is geen geldig e-mailadres. Example: zbailey@example.net

POST api/action-price-blocks

requires authentication

Example request:
curl --request POST \
    "http://localhost/api/action-price-blocks" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"action_price_id\": 16,
    \"customer_id\": 16,
    \"customer_organization_id\": 16
}"
const url = new URL(
    "http://localhost/api/action-price-blocks"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "application/json",
    "Accept": "application/json",
};

let body = {
    "action_price_id": 16,
    "customer_id": 16,
    "customer_organization_id": 16
};

fetch(url, {
    method: "POST",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());

Request      

POST api/action-price-blocks

Headers

Authorization        

Example: Bearer {YOUR_AUTH_KEY}

Content-Type        

Example: application/json

Accept        

Example: application/json

Body Parameters

action_price_id   integer     

The id of an existing record in the action_prices table. Example: 16

customer_id   integer  optional    

This field is required when customer_organization_id is not present. The id of an existing record in the customers table. Example: 16

customer_organization_id   integer  optional    

This field is required when customer_id is not present. The id of an existing record in the customer_organizations table. Example: 16

POST api/promos/{promo_id}/promo-products

requires authentication

Example request:
curl --request POST \
    "http://localhost/api/promos/16/promo-products" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"product_id\": \"architecto\",
    \"info\": \"architecto\",
    \"single_price_discount\": 39,
    \"quantity\": 67,
    \"quantity_free\": 12
}"
const url = new URL(
    "http://localhost/api/promos/16/promo-products"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "application/json",
    "Accept": "application/json",
};

let body = {
    "product_id": "architecto",
    "info": "architecto",
    "single_price_discount": 39,
    "quantity": 67,
    "quantity_free": 12
};

fetch(url, {
    method: "POST",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());

Request      

POST api/promos/{promo_id}/promo-products

Headers

Authorization        

Example: Bearer {YOUR_AUTH_KEY}

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

promo_id   integer     

The ID of the promo. Example: 16

Body Parameters

product_id   string     

The id of an existing record in the products table. Example: architecto

info   string  optional    

Example: architecto

single_price_discount   number     

:Attribute moet minimaal 0 zijn. Example: 39

quantity   integer     

:Attribute moet minimaal 1 zijn. Example: 67

quantity_free   integer     

:Attribute moet minimaal 0 zijn. Example: 12

PUT api/promos/{promo_id}/promo-products/{id}

requires authentication

Example request:
curl --request PUT \
    "http://localhost/api/promos/16/promo-products/16" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"product_id\": \"architecto\",
    \"info\": \"architecto\",
    \"single_price_discount\": 39,
    \"quantity\": 67,
    \"quantity_free\": 12
}"
const url = new URL(
    "http://localhost/api/promos/16/promo-products/16"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "application/json",
    "Accept": "application/json",
};

let body = {
    "product_id": "architecto",
    "info": "architecto",
    "single_price_discount": 39,
    "quantity": 67,
    "quantity_free": 12
};

fetch(url, {
    method: "PUT",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());

Request      

PUT api/promos/{promo_id}/promo-products/{id}

PATCH api/promos/{promo_id}/promo-products/{id}

Headers

Authorization        

Example: Bearer {YOUR_AUTH_KEY}

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

promo_id   integer     

The ID of the promo. Example: 16

id   integer     

The ID of the promo product. Example: 16

Body Parameters

product_id   string     

The id of an existing record in the products table. Example: architecto

info   string  optional    

Example: architecto

single_price_discount   number     

:Attribute moet minimaal 0 zijn. Example: 39

quantity   integer     

:Attribute moet minimaal 1 zijn. Example: 67

quantity_free   integer     

:Attribute moet minimaal 0 zijn. Example: 12

DELETE api/promos/{promo_id}/promo-products/{id}

requires authentication

Example request:
curl --request DELETE \
    "http://localhost/api/promos/16/promo-products/16" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "http://localhost/api/promos/16/promo-products/16"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "application/json",
    "Accept": "application/json",
};


fetch(url, {
    method: "DELETE",
    headers,
}).then(response => response.json());

Request      

DELETE api/promos/{promo_id}/promo-products/{id}

Headers

Authorization        

Example: Bearer {YOUR_AUTH_KEY}

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

promo_id   integer     

The ID of the promo. Example: 16

id   integer     

The ID of the promo product. Example: 16

DELETE api/action-prices/truncate

requires authentication

Example request:
curl --request DELETE \
    "http://localhost/api/action-prices/truncate" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "http://localhost/api/action-prices/truncate"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "application/json",
    "Accept": "application/json",
};


fetch(url, {
    method: "DELETE",
    headers,
}).then(response => response.json());

Example response (204, No content):

Empty response
 

Request      

DELETE api/action-prices/truncate

Headers

Authorization        

Example: Bearer {YOUR_AUTH_KEY}

Content-Type        

Example: application/json

Accept        

Example: application/json

DELETE api/action-price-blocks/truncate

requires authentication

Example request:
curl --request DELETE \
    "http://localhost/api/action-price-blocks/truncate" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "http://localhost/api/action-price-blocks/truncate"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "application/json",
    "Accept": "application/json",
};


fetch(url, {
    method: "DELETE",
    headers,
}).then(response => response.json());

Example response (204, No content):

Empty response
 

Request      

DELETE api/action-price-blocks/truncate

Headers

Authorization        

Example: Bearer {YOUR_AUTH_KEY}

Content-Type        

Example: application/json

Accept        

Example: application/json

POST api/frontend/users/{user}/act-as

requires authentication

Example request:
curl --request POST \
    "http://localhost/api/frontend/users/architecto/act-as" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "http://localhost/api/frontend/users/architecto/act-as"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "application/json",
    "Accept": "application/json",
};


fetch(url, {
    method: "POST",
    headers,
}).then(response => response.json());

Request      

POST api/frontend/users/{user}/act-as

Headers

Authorization        

Example: Bearer {YOUR_AUTH_KEY}

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

user   string     

The user. Example: architecto

Orders

Representative Order Row

DELETE api/representative-order-rows/{id}

requires authentication

Example request:
curl --request DELETE \
    "http://localhost/api/representative-order-rows/architecto" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "http://localhost/api/representative-order-rows/architecto"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "application/json",
    "Accept": "application/json",
};


fetch(url, {
    method: "DELETE",
    headers,
}).then(response => response.json());

Example response (204):

Empty response
 

Request      

DELETE api/representative-order-rows/{id}

Headers

Authorization        

Example: Bearer {YOUR_AUTH_KEY}

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

id   string     

The ID of the representative order row. Example: architecto

DELETE api/representative-order-rows-truncate

requires authentication

Example request:
curl --request DELETE \
    "http://localhost/api/representative-order-rows-truncate" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "http://localhost/api/representative-order-rows-truncate"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "application/json",
    "Accept": "application/json",
};


fetch(url, {
    method: "DELETE",
    headers,
}).then(response => response.json());

Example response (204):

Empty response
 

Request      

DELETE api/representative-order-rows-truncate

Headers

Authorization        

Example: Bearer {YOUR_AUTH_KEY}

Content-Type        

Example: application/json

Accept        

Example: application/json

Frontend

POST api/frontend/orders/{order}/confirm

requires authentication

Example request:
curl --request POST \
    "http://localhost/api/frontend/orders/architecto/confirm" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"comments\": \"b\",
    \"order_type\": \"preorder\"
}"
const url = new URL(
    "http://localhost/api/frontend/orders/architecto/confirm"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "application/json",
    "Accept": "application/json",
};

let body = {
    "comments": "b",
    "order_type": "preorder"
};

fetch(url, {
    method: "POST",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());

Request      

POST api/frontend/orders/{order}/confirm

Headers

Authorization        

Example: Bearer {YOUR_AUTH_KEY}

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

order   string     

The order. Example: architecto

Body Parameters

comments   string  optional    

:Attribute mag niet uit meer dan 255 tekens bestaan. Example: b

order_type   string     

Example: preorder

Must be one of:
  • standard
  • reorder
  • preorder
  • pickup

Products

DELETE api/products/{id}

requires authentication

Example request:
curl --request DELETE \
    "http://localhost/api/products/architecto" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "http://localhost/api/products/architecto"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "application/json",
    "Accept": "application/json",
};


fetch(url, {
    method: "DELETE",
    headers,
}).then(response => response.json());

Example response (204):

Empty response
 

Request      

DELETE api/products/{id}

Headers

Authorization        

Example: Bearer {YOUR_AUTH_KEY}

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

id   string     

The ID of the product. Example: architecto

Price updates

DELETE api/products/{product_id}/price-updates/{id}

requires authentication

Example request:
curl --request DELETE \
    "http://localhost/api/products/architecto/price-updates/architecto" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "http://localhost/api/products/architecto/price-updates/architecto"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "application/json",
    "Accept": "application/json",
};


fetch(url, {
    method: "DELETE",
    headers,
}).then(response => response.json());

Example response (204):

Empty response
 

Request      

DELETE api/products/{product_id}/price-updates/{id}

Headers

Authorization        

Example: Bearer {YOUR_AUTH_KEY}

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

product_id   string     

The ID of the product. Example: architecto

id   string     

The ID of the price update. Example: architecto

Customer Prices

DELETE api/products/{product_id}/customer-prices/{id}

requires authentication

Example request:
curl --request DELETE \
    "http://localhost/api/products/architecto/customer-prices/architecto" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "http://localhost/api/products/architecto/customer-prices/architecto"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "application/json",
    "Accept": "application/json",
};


fetch(url, {
    method: "DELETE",
    headers,
}).then(response => response.json());

Example response (204):

Empty response
 

Request      

DELETE api/products/{product_id}/customer-prices/{id}

Headers

Authorization        

Example: Bearer {YOUR_AUTH_KEY}

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

product_id   string     

The ID of the product. Example: architecto

id   string     

The ID of the customer price. Example: architecto

POST api/customer-prices/{product_id}/bulk

requires authentication

Example request:
curl --request POST \
    "http://localhost/api/customer-prices/architecto/bulk" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "http://localhost/api/customer-prices/architecto/bulk"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "application/json",
    "Accept": "application/json",
};


fetch(url, {
    method: "POST",
    headers,
}).then(response => response.json());

Example response (201, Bulk created):



 

Request      

POST api/customer-prices/{product_id}/bulk

Headers

Authorization        

Example: Bearer {YOUR_AUTH_KEY}

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

product_id   string     

The ID of the product. Example: architecto

Action Prices

DELETE api/products/{product_id}/action-prices/{id}

requires authentication

Example request:
curl --request DELETE \
    "http://localhost/api/products/architecto/action-prices/architecto" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "http://localhost/api/products/architecto/action-prices/architecto"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "application/json",
    "Accept": "application/json",
};


fetch(url, {
    method: "DELETE",
    headers,
}).then(response => response.json());

Example response (204, No content):

Empty response
 

Request      

DELETE api/products/{product_id}/action-prices/{id}

Headers

Authorization        

Example: Bearer {YOUR_AUTH_KEY}

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

product_id   string     

The ID of the product. Example: architecto

id   string     

The ID of the action price. Example: architecto

POST api/action-prices/{product_id}/bulk

requires authentication

Example request:
curl --request POST \
    "http://localhost/api/action-prices/architecto/bulk" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "http://localhost/api/action-prices/architecto/bulk"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "application/json",
    "Accept": "application/json",
};


fetch(url, {
    method: "POST",
    headers,
}).then(response => response.json());

Example response (201, Bulk created):



 

Request      

POST api/action-prices/{product_id}/bulk

Headers

Authorization        

Example: Bearer {YOUR_AUTH_KEY}

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

product_id   string     

The ID of the product. Example: architecto

Groups

DELETE api/product-groups/{id}

requires authentication

Example request:
curl --request DELETE \
    "http://localhost/api/product-groups/architecto" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "http://localhost/api/product-groups/architecto"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "application/json",
    "Accept": "application/json",
};


fetch(url, {
    method: "DELETE",
    headers,
}).then(response => response.json());

Example response (204):

Empty response
 

Example response (400, Cannot delete group with sub groups):



 

Request      

DELETE api/product-groups/{id}

Headers

Authorization        

Example: Bearer {YOUR_AUTH_KEY}

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

id   string     

The ID of the product group. Example: architecto

Bulk

Clean up products

requires authentication

(soft) delete all unknown products

Example request:
curl --request POST \
    "http://localhost/api/products/bulk/cleanup?knownProductNumbers[]=1234567&knownProductNumbers[]=1234568&knownProductNumbers[]=1234569" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
const url = new URL(
    "http://localhost/api/products/bulk/cleanup"
);

const params = {
    "knownProductNumbers[0]": "1234567",
    "knownProductNumbers[1]": "1234568",
    "knownProductNumbers[2]": "1234569",
};
Object.keys(params)
    .forEach(key => url.searchParams.append(key, params[key]));

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "application/json",
    "Accept": "application/json",
};


fetch(url, {
    method: "POST",
    headers,
}).then(response => response.json());

Example response (200):


{
    "affected": [
        {
            "id": 1,
            "external_id": 100056
        }
    ],
    "affected_count": 1
}
 

Request      

POST api/products/bulk/cleanup

Headers

Authorization        

Example: Bearer {YOUR_AUTH_KEY}

Content-Type        

Example: application/json

Accept        

Example: application/json

Query Parameters

knownProductNumbers   string[]     

Complete list of product numbers available in the portal

Body Parameters

knownProductNumbers   string[]  optional    

Price Updates

DELETE api/product-price-updates/truncate

requires authentication

Example request:
curl --request DELETE \
    "http://localhost/api/product-price-updates/truncate" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "http://localhost/api/product-price-updates/truncate"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "application/json",
    "Accept": "application/json",
};


fetch(url, {
    method: "DELETE",
    headers,
}).then(response => response.json());

Example response (204):

Empty response
 

Request      

DELETE api/product-price-updates/truncate

Headers

Authorization        

Example: Bearer {YOUR_AUTH_KEY}

Content-Type        

Example: application/json

Accept        

Example: application/json

Stock

Get access token

Example request:
curl --request POST \
    "http://localhost/api/external/stock/authenticate" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"username\": \"architecto\",
    \"password\": \"|]|{+-\"
}"
const url = new URL(
    "http://localhost/api/external/stock/authenticate"
);

const headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
};

let body = {
    "username": "architecto",
    "password": "|]|{+-"
};

fetch(url, {
    method: "POST",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());

Request      

POST api/external/stock/authenticate

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

Body Parameters

username   string     

Example: architecto

password   string     

Example: |]|{+-

Get inventory information

requires authentication

Example request:
curl --request GET \
    --get "http://localhost/api/external/stock/inventory" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "http://localhost/api/external/stock/inventory"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "application/json",
    "Accept": "application/json",
};


fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());

Example response (200):


{
    "data": [
        "100740",
        "100064",
        "199014"
    ]
}
 

Request      

GET api/external/stock/inventory

Headers

Authorization        

Example: Bearer {YOUR_AUTH_KEY}

Content-Type        

Example: application/json

Accept        

Example: application/json

Suppliers

DELETE api/suppliers/{id}

requires authentication

Example request:
curl --request DELETE \
    "http://localhost/api/suppliers/architecto" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "http://localhost/api/suppliers/architecto"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "application/json",
    "Accept": "application/json",
};


fetch(url, {
    method: "DELETE",
    headers,
}).then(response => response.json());

Example response (204):

Empty response
 

Request      

DELETE api/suppliers/{id}

Headers

Authorization        

Example: Bearer {YOUR_AUTH_KEY}

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

id   string     

The ID of the supplier. Example: architecto

Users

DELETE api/users/{id}

requires authentication

Example request:
curl --request DELETE \
    "http://localhost/api/users/architecto" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "http://localhost/api/users/architecto"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "application/json",
    "Accept": "application/json",
};


fetch(url, {
    method: "DELETE",
    headers,
}).then(response => response.json());

Example response (204):

Empty response
 

Request      

DELETE api/users/{id}

Headers

Authorization        

Example: Bearer {YOUR_AUTH_KEY}

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

id   string     

The ID of the user. Example: architecto

PUT api/user/{user}/restore

requires authentication

Example request:
curl --request PUT \
    "http://localhost/api/user/architecto/restore" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "http://localhost/api/user/architecto/restore"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "application/json",
    "Accept": "application/json",
};


fetch(url, {
    method: "PUT",
    headers,
}).then(response => response.json());

Request      

PUT api/user/{user}/restore

Headers

Authorization        

Example: Bearer {YOUR_AUTH_KEY}

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

user   string     

The user. Example: architecto

VtOrders

Frontend

POST api/frontend/vt-orders/{order}/confirm

requires authentication

Example request:
curl --request POST \
    "http://localhost/api/frontend/vt-orders/16/confirm" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"comments\": \"b\",
    \"order_type\": \"standard\"
}"
const url = new URL(
    "http://localhost/api/frontend/vt-orders/16/confirm"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "application/json",
    "Accept": "application/json",
};

let body = {
    "comments": "b",
    "order_type": "standard"
};

fetch(url, {
    method: "POST",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());

Request      

POST api/frontend/vt-orders/{order}/confirm

Headers

Authorization        

Example: Bearer {YOUR_AUTH_KEY}

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

order   integer     

Example: 16

Body Parameters

comments   string  optional    

:Attribute mag niet uit meer dan 255 tekens bestaan. Example: b

order_type   string     

Example: standard

Must be one of:
  • standard
  • reorder
  • preorder
  • pickup