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

This API is not authenticated.

Acceptances

Goods receiving documents (warehouse inbound). Use these endpoints to list, create, view, update and delete acceptances.

Authentication: Bearer Token (Laravel Sanctum)

Access scope

List acceptances with advanced filtering

requires authentication

Returns a paginated list of acceptances available to the authenticated user. Supports multiple filters, ranges and sorting.

✅ Multiple exact filters are supported via arrays: field[]=1&field[]=2

Examples:

Example request:
curl --request GET \
    --get "https://localhost/api/acceptances?acc_id%5B%5D=101&acc_status%5B%5D=1&acc_wh_id%5B%5D=3&acc_shop_id%5B%5D=12&acc_type%5B%5D=1&acc_ext_id=ACC-101%0A%0A-----------------------------%0A%F0%9F%94%8E+Ranges%0A-----------------------------&acc_date_from=2026-01-01&acc_date_to=2026-01-31&created_at_from=2026-01-01&created_at_to=2026-01-31%0A%0A-----------------------------%0A%F0%9F%94%8E+Sorting%0A-----------------------------&sort=-acc_date%2Cacc_id%0A%0A-----------------------------%0A%F0%9F%94%8E+Pagination%0A-----------------------------&per_page=20&page=1" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"acc_ext_id\": [
        \"b\"
    ],
    \"acc_date_from\": \"2026-06-15T21:25:59\",
    \"acc_date_to\": \"2026-06-15T21:25:59\",
    \"created_at_from\": \"2026-06-15T21:25:59\",
    \"created_at_to\": \"2026-06-15T21:25:59\",
    \"sort\": \"architecto\",
    \"per_page\": 22,
    \"page\": 67,
    \"acc_id\": [
        16
    ],
    \"acc_status\": [
        16
    ],
    \"acc_wh_id\": [
        16
    ],
    \"acc_shop_id\": [
        16
    ],
    \"acc_type\": [
        16
    ]
}"
const url = new URL(
    "https://localhost/api/acceptances"
);

const params = {
    "acc_id[]": "101",
    "acc_status[]": "1",
    "acc_wh_id[]": "3",
    "acc_shop_id[]": "12",
    "acc_type[]": "1",
    "acc_ext_id": "ACC-101

-----------------------------
🔎 Ranges
-----------------------------",
    "acc_date_from": "2026-01-01",
    "acc_date_to": "2026-01-31",
    "created_at_from": "2026-01-01",
    "created_at_to": "2026-01-31

-----------------------------
🔎 Sorting
-----------------------------",
    "sort": "-acc_date,acc_id

-----------------------------
🔎 Pagination
-----------------------------",
    "per_page": "20",
    "page": "1",
};
Object.keys(params)
    .forEach(key => url.searchParams.append(key, params[key]));

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

let body = {
    "acc_ext_id": [
        "b"
    ],
    "acc_date_from": "2026-06-15T21:25:59",
    "acc_date_to": "2026-06-15T21:25:59",
    "created_at_from": "2026-06-15T21:25:59",
    "created_at_to": "2026-06-15T21:25:59",
    "sort": "architecto",
    "per_page": 22,
    "page": 67,
    "acc_id": [
        16
    ],
    "acc_status": [
        16
    ],
    "acc_wh_id": [
        16
    ],
    "acc_shop_id": [
        16
    ],
    "acc_type": [
        16
    ]
};

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

Example response (401):

Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
 

{
    "message": "Unauthenticated.",
    "error": "AUTH_REQUIRED"
}
 

Request      

GET api/acceptances

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

Query Parameters

acc_id[]   integer  optional    

Filter by acceptance ID(s). Example: 101

acc_status[]   integer  optional    

Filter by status ID(s). Example: 1

acc_wh_id[]   integer  optional    

Filter by warehouse ID(s). Example: 3

acc_shop_id[]   integer  optional    

Filter by shop ID(s). Example: 12

acc_type[]   integer  optional    

Filter by acceptance type ID(s). Example: 1

acc_ext_id   string  optional    

Filter by external ID (LIKE). Example: `ACC-101


🔎 Ranges -----------------------------`

acc_date_from   string  optional    

date Filter by document date from (>=). Example: 2026-01-01

acc_date_to   string  optional    

date Filter by document date to (<=). Example: 2026-01-31

created_at_from   string  optional    

date Filter by creation date from. Example: 2026-01-01

created_at_to   string  optional    

date Filter by creation date to. Example: `2026-01-31


🔎 Sorting -----------------------------`

sort   string  optional    

Sort fields separated by comma. Use "-" for DESC. Example: `-acc_date,acc_id


🔎 Pagination -----------------------------`

per_page   integer  optional    

Items per page. Max: 250. Example: 20

page   integer  optional    

Page number. Example: 1

Body Parameters

acc_ext_id   string[]  optional    

Must not be greater than 100 characters.

acc_date_from   string  optional    

Must be a valid date. Example: 2026-06-15T21:25:59

acc_date_to   string  optional    

Must be a valid date. Example: 2026-06-15T21:25:59

created_at_from   string  optional    

Must be a valid date. Example: 2026-06-15T21:25:59

created_at_to   string  optional    

Must be a valid date. Example: 2026-06-15T21:25:59

sort   string  optional    

Example: architecto

per_page   integer  optional    

Must be at least 1. Must not be greater than 250. Example: 22

page   integer  optional    

Must be at least 1. Example: 67

acc_id   integer[]  optional    
acc_status   integer[]  optional    
acc_wh_id   integer[]  optional    
acc_shop_id   integer[]  optional    
acc_type   integer[]  optional    

Create acceptance (optionally with lines)

requires authentication

Creates a new acceptance (warehouse inbound) in the caller’s domain. Server sets initial status to 1 (created) and the acc_date to now.

You may optionally send offers to create/update lines together with the document.

Example request:
curl --request POST \
    "https://localhost/api/acceptances" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"acc_wh_id\": 3,
    \"acc_shop_id\": 12,
    \"acc_type\": 1,
    \"acc_ext_id\": 1234,
    \"acc_comment\": \"\\\"Inbound from ACME\\\"\",
    \"acc_allow_add_offers_during_acceptance\": false,
    \"offers\": [
        {
            \"ao_offer_id\": 77,
            \"ao_expected\": 10,
            \"ao_price\": 4.99
        },
        {
            \"ao_offer_ext_id\": \"EXT-77\",
            \"ao_expected\": 5
        }
    ]
}"
const url = new URL(
    "https://localhost/api/acceptances"
);

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

let body = {
    "acc_wh_id": 3,
    "acc_shop_id": 12,
    "acc_type": 1,
    "acc_ext_id": 1234,
    "acc_comment": "\"Inbound from ACME\"",
    "acc_allow_add_offers_during_acceptance": false,
    "offers": [
        {
            "ao_offer_id": 77,
            "ao_expected": 10,
            "ao_price": 4.99
        },
        {
            "ao_offer_ext_id": "EXT-77",
            "ao_expected": 5
        }
    ]
};

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

Request      

POST api/acceptances

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

Body Parameters

acc_wh_id   integer     

Warehouse ID where goods are received. Example: 3

acc_shop_id   integer     

Shop (merchant) ID this document belongs to. Example: 12

acc_type   integer     

Acceptance type ID. Example: 1

acc_ext_id   integer  optional    

nullable External document ID. Example: 1234

acc_comment   string  optional    

nullable A short operator comment (max 255 chars). Example: "Inbound from ACME"

acc_allow_add_offers_during_acceptance   boolean  optional    

Example: false

offers   string[]  optional    

nullable Array of lines.

ao_offer_id   integer  optional    

Example: 16

ao_offer_ext_id   string  optional    

Example: architecto

ao_expected   number     

Must be at least 0.01. Example: 39

ao_price   number  optional    

Example: 4326.41688

ao_batch   string  optional    

Must not be greater than 50 characters. Example: m

ao_production_date   string  optional    

Must be a valid date. Example: 2026-06-15T21:25:59

ao_expiration_date   string  optional    

Must be a valid date. Example: 2026-06-15T21:25:59

ao_barcode   string  optional    

Must not be greater than 100 characters. Example: i

*   object  optional    
ao_offer_id   integer  optional    

nullable Offer ID (rw_offers.of_id). Required if ao_offer_ext_id is not provided. Example: 77

ao_offer_ext_id   string  optional    

nullable Offer external ID (rw_offers.of_ext_id). Required if ao_offer_id is not provided. Example: "EXT-77"

ao_expected   number     

Expected quantity to receive. Must be ≥ 0.01. Example: 10

ao_price   number  optional    

nullable Price per unit. Example: 4.99

ao_batch   string  optional    

nullable Batch/Lot identifier (max 50 chars). Example: "LOT-2025-11"

ao_production_date   date  optional    

nullable Production date (YYYY-MM-DD). Example: 2026-01-15

ao_expiration_date   date  optional    

nullable Expiration date (YYYY-MM-DD). Example: 2026-03-31

ao_barcode   string  optional    

nullable External barcode/label reference (max 100 chars). Example: "EAN-1234567890123"

Get acceptance by ID

requires authentication

Returns a single acceptance with related entities and line items.

Example request:
curl --request GET \
    --get "https://localhost/api/acceptances/101" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "https://localhost/api/acceptances/101"
);

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

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

Example response (401):

Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
 

{
    "message": "Unauthenticated.",
    "error": "AUTH_REQUIRED"
}
 

Request      

GET api/acceptances/{id}

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

id   integer     

Acceptance ID. Example: 101

Update acceptance (and upsert/delete lines in the same request)

requires authentication

Updates editable fields of an existing acceptance in the caller’s domain.

Optional:

Example request:
curl --request PUT \
    "https://localhost/api/acceptances/101" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"acc_date\": \"\\\"2026-02-15\\\"\",
    \"acc_ext_id\": 1234,
    \"acc_comment\": \"\\\"Adjusted note\\\"\",
    \"acc_allow_add_offers_during_acceptance\": false,
    \"offers\": [
        {
            \"ao_id\": 555,
            \"ao_expected\": 12
        },
        {
            \"ao_offer_ext_id\": \"EXT-99\",
            \"ao_expected\": 3
        }
    ],
    \"offers_delete\": [
        111,
        112
    ]
}"
const url = new URL(
    "https://localhost/api/acceptances/101"
);

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

let body = {
    "acc_date": "\"2026-02-15\"",
    "acc_ext_id": 1234,
    "acc_comment": "\"Adjusted note\"",
    "acc_allow_add_offers_during_acceptance": false,
    "offers": [
        {
            "ao_id": 555,
            "ao_expected": 12
        },
        {
            "ao_offer_ext_id": "EXT-99",
            "ao_expected": 3
        }
    ],
    "offers_delete": [
        111,
        112
    ]
};

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

Request      

PUT api/acceptances/{id}

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

id   integer     

Acceptance ID. Example: 101

Body Parameters

acc_date   date  optional    

nullable Document date (YYYY-MM-DD or ISO). Example: "2026-02-15"

acc_ext_id   integer  optional    

nullable External document ID. Example: 1234

acc_comment   string  optional    

nullable Comment (max 255 chars). Example: "Adjusted note"

acc_allow_add_offers_during_acceptance   boolean  optional    

Example: false

offers   string[]  optional    

nullable Lines to upsert.

ao_id   integer  optional    

Example: 16

ao_offer_id   integer  optional    

Example: 16

ao_offer_ext_id   string  optional    

Example: architecto

ao_expected   number  optional    

Must be at least 0.01. Example: 39

ao_price   number  optional    

Example: 4326.41688

ao_batch   string  optional    

Must not be greater than 50 characters. Example: m

ao_production_date   string  optional    

Must be a valid date. Example: 2026-06-15T21:25:59

ao_expiration_date   string  optional    

Must be a valid date. Example: 2026-06-15T21:25:59

ao_barcode   string  optional    

Must not be greater than 100 characters. Example: i

*   object  optional    
ao_id   integer  optional    

nullable If present -> update existing line in this acceptance. Example: 555

ao_offer_id   integer  optional    

nullable Offer ID (rw_offers.of_id). Required for create when ao_offer_ext_id is not provided. Example: 77

ao_offer_ext_id   string  optional    

nullable Offer ext ID. Required for create when ao_offer_id is not provided. Example: "EXT-77"

ao_expected   number  optional    

nullable Expected qty (≥ 0.01). Example: 10

ao_price   number  optional    

nullable Price per unit. Example: 4.99

ao_batch   string  optional    

nullable Batch/Lot identifier (max 50). Example: "LOT-2025-11"

ao_production_date   date  optional    

nullable Production date (YYYY-MM-DD). Example: 2026-01-15

ao_expiration_date   date  optional    

nullable Expiration date (YYYY-MM-DD). Example: 2026-03-31

ao_barcode   string  optional    

nullable Barcode (max 100). Example: "EAN-1234567890123"

offers_delete   string[]  optional    

nullable Array of ao_id to delete.

*   integer  optional    

Line id (ao_id). Example: 111

Delete acceptance

requires authentication

Deletes an acceptance in the caller’s domain.

Example request:
curl --request DELETE \
    "https://localhost/api/acceptances/101" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "https://localhost/api/acceptances/101"
);

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

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

Request      

DELETE api/acceptances/{id}

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

id   integer     

Acceptance ID. Example: 101

Acceptances » Lines

Manage line items (offers) inside an acceptance (warehouse inbound document).

Authentication: Bearer Token (Laravel Sanctum)

Access scope

Barcode note:

List offers (lines) of an acceptance

Example request:
curl --request GET \
    --get "https://localhost/api/acceptances/architecto/offers" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"ao_barcode\": \"b\",
    \"ao_batch\": \"n\",
    \"ao_expiration_from\": \"2026-06-15T21:25:59\",
    \"ao_expiration_to\": \"2026-06-15T21:25:59\",
    \"sort\": \"architecto\",
    \"per_page\": 22,
    \"page\": 67,
    \"ao_id\": [
        66
    ],
    \"ao_offer_id\": [
        27
    ]
}"
const url = new URL(
    "https://localhost/api/acceptances/architecto/offers"
);

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

let body = {
    "ao_barcode": "b",
    "ao_batch": "n",
    "ao_expiration_from": "2026-06-15T21:25:59",
    "ao_expiration_to": "2026-06-15T21:25:59",
    "sort": "architecto",
    "per_page": 22,
    "page": 67,
    "ao_id": [
        66
    ],
    "ao_offer_id": [
        27
    ]
};

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

Example response (401):

Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
 

{
    "message": "Unauthenticated.",
    "error": "AUTH_REQUIRED"
}
 

Request      

GET api/acceptances/{id}/offers

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

id   string     

The ID of the acceptance. Example: architecto

Body Parameters

ao_barcode   string  optional    

Must not be greater than 200 characters. Example: b

ao_batch   string  optional    

Must not be greater than 200 characters. Example: n

ao_expiration_from   string  optional    

Must be a valid date. Example: 2026-06-15T21:25:59

ao_expiration_to   string  optional    

Must be a valid date. Example: 2026-06-15T21:25:59

sort   string  optional    

Example: architecto

per_page   integer  optional    

Must be at least 1. Must not be greater than 500. Example: 22

page   integer  optional    

Must be at least 1. Example: 67

ao_id   integer[]  optional    

Must be at least 1.

ao_offer_id   integer[]  optional    

Must be at least 1.

Add offers (lines) to an acceptance

Example request:
curl --request POST \
    "https://localhost/api/acceptances/architecto/offers" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "https://localhost/api/acceptances/architecto/offers"
);

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

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

Request      

POST api/acceptances/{id}/offers

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

id   string     

The ID of the acceptance. Example: architecto

Update a line in an acceptance

Example request:
curl --request PUT \
    "https://localhost/api/acceptances/architecto/offers/architecto" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"ao_expected\": 27,
    \"ao_price\": 4326.41688,
    \"ao_batch\": \"m\",
    \"ao_production_date\": \"2026-06-15T21:25:59\",
    \"ao_expiration_date\": \"2026-06-15T21:25:59\",
    \"ao_barcode\": \"i\"
}"
const url = new URL(
    "https://localhost/api/acceptances/architecto/offers/architecto"
);

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

let body = {
    "ao_expected": 27,
    "ao_price": 4326.41688,
    "ao_batch": "m",
    "ao_production_date": "2026-06-15T21:25:59",
    "ao_expiration_date": "2026-06-15T21:25:59",
    "ao_barcode": "i"
};

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

Request      

PUT api/acceptances/{acceptance_id}/offers/{offer_id}

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

acceptance_id   string     

The ID of the acceptance. Example: architecto

offer_id   string     

The ID of the offer. Example: architecto

Body Parameters

ao_expected   number  optional    

Must be at least 0.01. Example: 27

ao_price   number  optional    

Example: 4326.41688

ao_batch   string  optional    

Must not be greater than 50 characters. Example: m

ao_production_date   string  optional    

Must be a valid date. Example: 2026-06-15T21:25:59

ao_expiration_date   string  optional    

Must be a valid date. Example: 2026-06-15T21:25:59

ao_barcode   string  optional    

Must not be greater than 100 characters. Example: i

Delete a line from an acceptance

Example request:
curl --request DELETE \
    "https://localhost/api/acceptances/architecto/offers/architecto" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "https://localhost/api/acceptances/architecto/offers/architecto"
);

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

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

Request      

DELETE api/acceptances/{acceptance_id}/offers/{offer_id}

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

acceptance_id   string     

The ID of the acceptance. Example: architecto

offer_id   string     

The ID of the offer. Example: architecto

DataMatrix

Manage DataMatrix codes (rw_datamatrix).

Authentication: This API uses NWMS Sanctum. Send your personal access token in the HTTP header: Authorization: Bearer {token}

Get list of DataMatrix records with advanced filtering

requires authentication

Returns a paginated list of DataMatrix records available to the authenticated user. Supports multiple filters, partial match, sorting and pagination.

✅ Multiple exact filters are supported via arrays: field[]=1&field[]=2

Access scope:

Examples:

Example request:
curl --request GET \
    --get "https://localhost/api/datamatrix?dmt_id%5B%5D=1&dmt_domain_id%5B%5D=10&dmt_status%5B%5D=0&dmt_wh_id%5B%5D=2&dmt_acceptance_id%5B%5D=538&dmt_order_id%5B%5D=105&dmt_accept_place%5B%5D=12345&dmt_order_place%5B%5D=999&dmt_barcode=460123&dmt_datamatrix=010460123456789021ABC%0A%0A-----------------------------%0A%F0%9F%94%8E+Sorting%0A-----------------------------&sort=-dmt_id%2Cdmt_status%0AAllowed+fields%3A+dmt_id%2C+dmt_status%2C+dmt_wh_id%2C+dmt_acceptance_id%2C+dmt_order_id%2C+dmt_created_date%2C+dmt_used_date%2C+created_at%0A%0A-----------------------------%0A%F0%9F%94%8E+Pagination%0A-----------------------------&per_page=250&page=1" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"dmt_barcode\": \"b\",
    \"dmt_datamatrix\": \"n\",
    \"sort\": \"architecto\",
    \"per_page\": 22,
    \"page\": 67,
    \"dmt_id\": [
        66
    ],
    \"dmt_domain_id\": [
        27
    ],
    \"dmt_status\": [
        \"1\"
    ],
    \"dmt_wh_id\": [
        35
    ],
    \"dmt_acceptance_id\": [
        43
    ],
    \"dmt_order_id\": [
        16
    ],
    \"dmt_accept_place\": [
        26
    ],
    \"dmt_order_place\": [
        40
    ]
}"
const url = new URL(
    "https://localhost/api/datamatrix"
);

const params = {
    "dmt_id[]": "1",
    "dmt_domain_id[]": "10",
    "dmt_status[]": "0",
    "dmt_wh_id[]": "2",
    "dmt_acceptance_id[]": "538",
    "dmt_order_id[]": "105",
    "dmt_accept_place[]": "12345",
    "dmt_order_place[]": "999",
    "dmt_barcode": "460123",
    "dmt_datamatrix": "010460123456789021ABC

-----------------------------
🔎 Sorting
-----------------------------",
    "sort": "-dmt_id,dmt_status
Allowed fields: dmt_id, dmt_status, dmt_wh_id, dmt_acceptance_id, dmt_order_id, dmt_created_date, dmt_used_date, created_at

-----------------------------
🔎 Pagination
-----------------------------",
    "per_page": "250",
    "page": "1",
};
Object.keys(params)
    .forEach(key => url.searchParams.append(key, params[key]));

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

let body = {
    "dmt_barcode": "b",
    "dmt_datamatrix": "n",
    "sort": "architecto",
    "per_page": 22,
    "page": 67,
    "dmt_id": [
        66
    ],
    "dmt_domain_id": [
        27
    ],
    "dmt_status": [
        "1"
    ],
    "dmt_wh_id": [
        35
    ],
    "dmt_acceptance_id": [
        43
    ],
    "dmt_order_id": [
        16
    ],
    "dmt_accept_place": [
        26
    ],
    "dmt_order_place": [
        40
    ]
};

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

Example response (401):

Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
 

{
    "message": "Unauthenticated.",
    "error": "AUTH_REQUIRED"
}
 

Request      

GET api/datamatrix

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

Query Parameters

dmt_id[]   integer  optional    

Filter by dmt_id(s). Example: 1

dmt_domain_id[]   integer  optional    

Domain filter (admin only; non-admin is forced to own domain). Example: 10

dmt_status[]   integer  optional    

Status filter (0,1,2). Example: 0

dmt_wh_id[]   integer  optional    

Warehouse ID filter. Example: 2

dmt_acceptance_id[]   integer  optional    

Acceptance ID filter. Example: 538

dmt_order_id[]   integer  optional    

Order ID filter. Example: 105

dmt_accept_place[]   integer  optional    

Acceptance place ID filter. Example: 12345

dmt_order_place[]   integer  optional    

Order place ID filter. Example: 999

dmt_barcode   string  optional    

Barcode filter (LIKE). Example: 460123

dmt_datamatrix   string  optional    

Datamatrix filter (LIKE). Example: `010460123456789021ABC


🔎 Sorting -----------------------------`

sort   string  optional    

Sort fields separated by comma. Use "-" for DESC. Example: `-dmt_id,dmt_status Allowed fields: dmt_id, dmt_status, dmt_wh_id, dmt_acceptance_id, dmt_order_id, dmt_created_date, dmt_used_date, created_at


🔎 Pagination -----------------------------`

per_page   integer  optional    

Items per page. Max: 500. Example: 250

page   integer  optional    

Page number. Example: 1

Body Parameters

dmt_barcode   string  optional    

Must not be greater than 200 characters. Example: b

dmt_datamatrix   string  optional    

Must not be greater than 500 characters. Example: n

sort   string  optional    

Example: architecto

per_page   integer  optional    

Must be at least 1. Must not be greater than 500. Example: 22

page   integer  optional    

Must be at least 1. Example: 67

dmt_id   integer[]  optional    

Must be at least 1.

dmt_domain_id   integer[]  optional    

Must be at least 1.

dmt_status   integer[]  optional    
Must be one of:
  • 0
  • 1
  • 2
dmt_wh_id   integer[]  optional    

Must be at least 1.

dmt_acceptance_id   integer[]  optional    

Must be at least 1.

dmt_order_id   integer[]  optional    

Must be at least 1.

dmt_accept_place   integer[]  optional    

Must be at least 1.

dmt_order_place   integer[]  optional    

Must be at least 1.

Create DataMatrix records (batch)

requires authentication

Creates new DataMatrix records in batch.

Access scope:

Notes:

Examples:

Example request:
curl --request POST \
    "https://localhost/api/datamatrix" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"items\": [
        \"architecto\"
    ]
}"
const url = new URL(
    "https://localhost/api/datamatrix"
);

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

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

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

Example response (201, Created):


{
    "created": 2
}
 

Request      

POST api/datamatrix

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

Body Parameters

items   string[]     

Array of DataMatrix objects.

dmt_wh_id   integer     

Warehouse ID. Example: 2

dmt_status   integer  optional    

optional Status (0,1,2). Default: 0. Example: 0

dmt_acceptance_id   integer  optional    

nullable Acceptance ID. Example: 538

dmt_order_id   integer  optional    

nullable Order ID. Example: 105

dmt_barcode   string     

Barcode. Max: 14. Example: 4601234567890

dmt_short_code   string     

Short code. Max: 14. Example: ABC123

dmt_crypto_tail   string  optional    

nullable Crypto tail. Max: 90. Example: "...."

dmt_datamatrix   string     

DataMatrix full string. Max: 125. Example: "010460123456789021ABC..."

dmt_accept_place   integer  optional    

nullable Acceptance place ID. Example: 12345

dmt_order_place   integer  optional    

nullable Order place ID. Example: 999

dmt_created_date   date  optional    

nullable Created date. Example: 2026-01-14

dmt_used_date   date  optional    

nullable Used date. Example: 2026-01-20

dmt_attachment_id   integer  optional    

nullable Attachment ID. Example: 777

dmt_domain_id   string  optional    

forbid overriding domain/id via API.

dmt_id   string  optional    

Update status for DataMatrix records (batch)

requires authentication

Updates dmt_status to 0/1/2 for multiple records by IDs.

Examples:

Example request:
curl --request PUT \
    "https://localhost/api/datamatrix/status" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"ids\": [
        101,
        102,
        103
    ],
    \"dmt_status\": 1
}"
const url = new URL(
    "https://localhost/api/datamatrix/status"
);

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

let body = {
    "ids": [
        101,
        102,
        103
    ],
    "dmt_status": 1
};

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

Example response (200, Updated):


{
    "updated": 3,
    "dmt_status": 1
}
 

Request      

PUT api/datamatrix/status

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

Body Parameters

ids   string[]     

List of dmt_id.

dmt_status   integer     

New status (0,1,2). Example: 1

Delete DataMatrix records (batch)

requires authentication

Deletes records by IDs, but only those with dmt_status = 0.

Examples:

Example request:
curl --request DELETE \
    "https://localhost/api/datamatrix" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"ids\": [
        101,
        102,
        103
    ]
}"
const url = new URL(
    "https://localhost/api/datamatrix"
);

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

let body = {
    "ids": [
        101,
        102,
        103
    ]
};

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

Example response (200, Deleted):


{
    "deleted": 2,
    "skipped": 1
}
 

Request      

DELETE api/datamatrix

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

Body Parameters

ids   string[]     

List of dmt_id.

Delivery Calculator (ApiShip)

Прокси-эндпоинты для калькулятора доставки ApiShip.

Источник данных:

Все эндпоинты требуют Bearer Token (Laravel Sanctum).

Search cities for delivery calculator

requires authentication

Возвращает города из локального справочника, который наполняется из APIShip. Подходит для autocomplete города получателя и для последующего выбора ПВЗ.

Example request:
curl --request GET \
    --get "https://localhost/api/delivery/apiship/cities?query=%D0%9C%D0%BE%D1%81%D0%BA%D0%B2%D0%B0&region=%D0%9C%D0%BE%D1%81%D0%BA%D0%BE%D0%B2%D1%81%D0%BA%D0%B0%D1%8F&providerKey=cdek&limit=20" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"query\": \"b\",
    \"region\": \"n\",
    \"providerKey\": \"g\",
    \"limit\": 16
}"
const url = new URL(
    "https://localhost/api/delivery/apiship/cities"
);

const params = {
    "query": "Москва",
    "region": "Московская",
    "providerKey": "cdek",
    "limit": "20",
};
Object.keys(params)
    .forEach(key => url.searchParams.append(key, params[key]));

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

let body = {
    "query": "b",
    "region": "n",
    "providerKey": "g",
    "limit": 16
};

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

Example response (200):


{
    "data": [
        {
            "id": 10,
            "name": "Москва",
            "type": "г",
            "guid": "0c5b2444-70a0-4932-980c-b4dc0d3f02b5",
            "region": {
                "id": 1,
                "name": "Москва",
                "type": "г"
            },
            "pickup_points_count": 1532
        }
    ]
}
 

Request      

GET api/delivery/apiship/cities

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

Query Parameters

query   string  optional    

Поисковая строка по названию города. Example: Москва

region   string  optional    

Фильтр по региону. Example: Московская

providerKey   string  optional    

Фильтр по службе доставки. Example: cdek

limit   integer  optional    

Лимит записей, максимум 50. Example: 20

Body Parameters

query   string  optional    

Must not be greater than 100 characters. Example: b

region   string  optional    

Must not be greater than 100 characters. Example: n

providerKey   string  optional    

Must not be greater than 100 characters. Example: g

limit   integer  optional    

Must be at least 1. Must not be greater than 50. Example: 16

Get pickup points for city/provider

requires authentication

Возвращает список ПВЗ из локального справочника APIShip. Используется после выбора города или для повторной загрузки ПВЗ по providerKey.

Example request:
curl --request GET \
    --get "https://localhost/api/delivery/apiship/pickup-points?cityGuid=0c5b2444-70a0-4932-980c-b4dc0d3f02b5&city=%D0%9C%D0%BE%D1%81%D0%BA%D0%B2%D0%B0&providerKey=cdek&type[]=1&type[]=2&cod=1&paymentCard=1&limit=100" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"cityGuid\": \"b\",
    \"city\": \"n\",
    \"providerKey\": \"g\",
    \"type\": [
        \"1\"
    ],
    \"cod\": \"1\",
    \"paymentCard\": \"0\",
    \"offset\": 12,
    \"stateCheckOff\": false,
    \"limit\": 17
}"
const url = new URL(
    "https://localhost/api/delivery/apiship/pickup-points"
);

const params = {
    "cityGuid": "0c5b2444-70a0-4932-980c-b4dc0d3f02b5",
    "city": "Москва",
    "providerKey": "cdek",
    "type[0]": "1",
    "type[1]": "2",
    "cod": "1",
    "paymentCard": "1",
    "limit": "100",
};
Object.keys(params)
    .forEach(key => url.searchParams.append(key, params[key]));

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

let body = {
    "cityGuid": "b",
    "city": "n",
    "providerKey": "g",
    "type": [
        "1"
    ],
    "cod": "1",
    "paymentCard": "0",
    "offset": 12,
    "stateCheckOff": false,
    "limit": 17
};

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

Example response (200):


{
    "data": [
        {
            "id": 16222,
            "providerKey": "cdek",
            "code": "MSK123",
            "name": "ПВЗ Москва",
            "type": 1,
            "availableOperation": 2,
            "address": "Москва, ул. Пример, д. 1",
            "city": "Москва",
            "cityGuid": "0c5b2444-70a0-4932-980c-b4dc0d3f02b5",
            "lat": 55.75,
            "lng": 37.61,
            "cod": 1,
            "paymentCash": 1,
            "paymentCard": 1,
            "phone": "8800...",
            "timetable": "ПН-ПТ 10:00-20:00"
        }
    ]
}
 

Request      

GET api/delivery/apiship/pickup-points

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

Query Parameters

cityGuid   string  optional    

GUID города (предпочтительный фильтр). Example: 0c5b2444-70a0-4932-980c-b4dc0d3f02b5

city   string  optional    

Название города, если cityGuid неизвестен. Example: Москва

providerKey   string  optional    

Ключ службы доставки. Example: cdek

type   integer[]  optional    

Тип точки: 1 ПВЗ, 2 постамат, 3 почта, 4 терминал.

cod   integer  optional    

Фильтр по наличию наложенного платежа: 1 или 0. Example: 1

paymentCard   integer  optional    

Фильтр по оплате картой: 1 или 0. Example: 1

limit   integer  optional    

Лимит записей, максимум 200. Example: 100

Body Parameters

cityGuid   string  optional    

Must not be greater than 100 characters. Example: b

city   string  optional    

Must not be greater than 100 characters. Example: n

providerKey   string  optional    

Must not be greater than 100 characters. Example: g

type   integer[]  optional    
Must be one of:
  • 1
  • 2
  • 3
  • 4
cod   integer  optional    

Example: 1

Must be one of:
  • 0
  • 1
paymentCard   integer  optional    

Example: 0

Must be one of:
  • 0
  • 1
offset   integer  optional    

Must be at least 0. Example: 12

stateCheckOff   boolean  optional    

Example: false

limit   integer  optional    

Must be at least 1. Must not be greater than 200. Example: 17

Calculate delivery options and price via ApiShip

requires authentication

Возвращает варианты доставки и стоимость из APIShip. Если from не передан, отправитель собирается автоматически из настроек аккаунта ApiShip текущего домена.

В ответе есть:

Example request:
curl --request POST \
    "https://localhost/api/delivery/apiship/calculate" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"from\": {
        \"countryCode\": \"RU\",
        \"region\": \"г Москва\",
        \"city\": \"Москва\",
        \"cityGuid\": \"0c5b2444-70a0-4932-980c-b4dc0d3f02b5\",
        \"addressString\": \"Москва, Хлебный пер. 19А\",
        \"index\": \"105066\",
        \"lat\": 4326.41688,
        \"lng\": 4326.41688
    },
    \"to\": {
        \"countryCode\": \"RU\",
        \"region\": \"г Москва\",
        \"city\": \"Москва\",
        \"cityGuid\": \"0c5b2444-70a0-4932-980c-b4dc0d3f02b5\",
        \"addressString\": \"Москва, ул. Машкова 21\",
        \"index\": \"105066\",
        \"lat\": 4326.41688,
        \"lng\": 4326.41688
    },
    \"places\": [
        {
            \"width\": 20,
            \"height\": 45,
            \"length\": 30,
            \"weight\": 1500
        }
    ],
    \"assessedCost\": 1000,
    \"codCost\": 0,
    \"pickupDate\": \"2026-04-30\",
    \"pickupTypes\": [
        1,
        2
    ],
    \"deliveryTypes\": [
        1,
        2
    ],
    \"providerKeys\": [
        \"cdek\",
        \"dpd\"
    ],
    \"tariffIds\": [
        19,
        54
    ],
    \"pointOutId\": 140803,
    \"includeFees\": false,
    \"timeout\": 20000
}"
const url = new URL(
    "https://localhost/api/delivery/apiship/calculate"
);

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

let body = {
    "from": {
        "countryCode": "RU",
        "region": "г Москва",
        "city": "Москва",
        "cityGuid": "0c5b2444-70a0-4932-980c-b4dc0d3f02b5",
        "addressString": "Москва, Хлебный пер. 19А",
        "index": "105066",
        "lat": 4326.41688,
        "lng": 4326.41688
    },
    "to": {
        "countryCode": "RU",
        "region": "г Москва",
        "city": "Москва",
        "cityGuid": "0c5b2444-70a0-4932-980c-b4dc0d3f02b5",
        "addressString": "Москва, ул. Машкова 21",
        "index": "105066",
        "lat": 4326.41688,
        "lng": 4326.41688
    },
    "places": [
        {
            "width": 20,
            "height": 45,
            "length": 30,
            "weight": 1500
        }
    ],
    "assessedCost": 1000,
    "codCost": 0,
    "pickupDate": "2026-04-30",
    "pickupTypes": [
        1,
        2
    ],
    "deliveryTypes": [
        1,
        2
    ],
    "providerKeys": [
        "cdek",
        "dpd"
    ],
    "tariffIds": [
        19,
        54
    ],
    "pointOutId": 140803,
    "includeFees": false,
    "timeout": 20000
};

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

Example response (200):


{
    "ok": true,
    "variants": [
        {
            "channel": "door",
            "providerKey": "cdek",
            "tariffId": 19,
            "tariffProviderId": 11,
            "tariffName": "Экспресс лайт склад-дверь",
            "deliveryCost": 370,
            "deliveryCostOriginal": 420,
            "daysMin": 2,
            "daysMax": 3,
            "pickupTypes": [
                2
            ],
            "deliveryTypes": [
                1
            ]
        }
    ],
    "raw": {
        "deliveryToDoor": [],
        "deliveryToPoint": []
    }
}
 

Request      

POST api/delivery/apiship/calculate

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

Body Parameters

from   object  optional    

nullable Адрес отправителя. Если не передан, берётся из настроек ApiShip аккаунта.

countryCode   string  optional    

nullable Код страны. Example: RU

region   string  optional    

nullable Регион. Example: г Москва

city   string  optional    

nullable Город. Example: Москва

cityGuid   string  optional    

nullable GUID ФИАС. Example: 0c5b2444-70a0-4932-980c-b4dc0d3f02b5

addressString   string  optional    

nullable Полный адрес. Example: Москва, Хлебный пер. 19А

index   string  optional    

nullable Индекс. Example: 105066

lat   number  optional    

Example: 4326.41688

lng   number  optional    

Example: 4326.41688

to   object     

Адрес получателя.

countryCode   string     

Код страны. Example: RU

region   string  optional    

nullable Регион. Example: г Москва

city   string  optional    

nullable Город. Example: Москва

cityGuid   string  optional    

nullable GUID ФИАС. Example: 0c5b2444-70a0-4932-980c-b4dc0d3f02b5

addressString   string  optional    

nullable Полный адрес. Example: Москва, ул. Машкова 21

index   string  optional    

nullable Индекс. Example: 105066

lat   number  optional    

Example: 4326.41688

lng   number  optional    

Example: 4326.41688

places   object[]     

Места отправления.

width   integer     

Ширина, см. Example: 20

height   integer     

Высота, см. Example: 45

length   integer     

Длина, см. Example: 30

weight   integer     

Вес, граммы. Example: 1500

assessedCost   number  optional    

nullable Оценочная стоимость. Example: 1000

codCost   number  optional    

nullable Наложенный платёж. Example: 0

pickupDate   string  optional    

nullable Дата забора. Example: 2026-04-30

pickupTypes   integer[]  optional    

nullable Типы забора.

deliveryTypes   integer[]  optional    

nullable Типы доставки.

providerKeys   string[]  optional    

nullable Ключи служб доставки.

tariffIds   integer[]  optional    

nullable Фильтр по тарифам APIShip.

pointOutId   integer  optional    

nullable ID ПВЗ назначения. Example: 140803

includeFees   boolean  optional    

nullable Включать сборы СД в итоговую цену. Example: false

timeout   integer  optional    

nullable Таймаут APIShip в мс. Example: 20000

Delivery Payments

Endpoints for reading order delivery payment rows (rw_order_delivery_payments).

Authorization

All endpoints require Bearer Token (Laravel Sanctum).

Domain scoping

Notes

Get delivery payments list

requires authentication

Returns a paginated list of delivery payment rows with filtering and sorting.

Pagination

Sorting

Example request:
curl --request GET \
    --get "https://localhost/api/order-delivery-payments?page=1&per_page=50&odp_id=1001&odp_order_id=555&odp_track_id=CDEK-123&odp_status_id=1&odp_payment_order_id=987&odp_etalon_order_id=ETL-777&odp_transaction_id=123456&odp_cod_act_id=222&created_from=2026-01-01&created_to=2026-01-31&sort_by=created_at&sort_dir=desc" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"per_page\": 1,
    \"odp_id\": 16,
    \"odp_order_id\": 16,
    \"odp_track_id\": \"n\",
    \"odp_status_id\": 16,
    \"odp_payment_order_id\": 16,
    \"odp_etalon_order_id\": \"n\",
    \"odp_transaction_id\": 16,
    \"odp_cod_act_id\": 16,
    \"created_from\": \"2026-06-15\",
    \"created_to\": \"2026-06-15\",
    \"sort_by\": \"architecto\",
    \"sort_dir\": \"architecto\"
}"
const url = new URL(
    "https://localhost/api/order-delivery-payments"
);

const params = {
    "page": "1",
    "per_page": "50",
    "odp_id": "1001",
    "odp_order_id": "555",
    "odp_track_id": "CDEK-123",
    "odp_status_id": "1",
    "odp_payment_order_id": "987",
    "odp_etalon_order_id": "ETL-777",
    "odp_transaction_id": "123456",
    "odp_cod_act_id": "222",
    "created_from": "2026-01-01",
    "created_to": "2026-01-31",
    "sort_by": "created_at",
    "sort_dir": "desc",
};
Object.keys(params)
    .forEach(key => url.searchParams.append(key, params[key]));

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

let body = {
    "per_page": 1,
    "odp_id": 16,
    "odp_order_id": 16,
    "odp_track_id": "n",
    "odp_status_id": 16,
    "odp_payment_order_id": 16,
    "odp_etalon_order_id": "n",
    "odp_transaction_id": 16,
    "odp_cod_act_id": 16,
    "created_from": "2026-06-15",
    "created_to": "2026-06-15",
    "sort_by": "architecto",
    "sort_dir": "architecto"
};

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

Example response (200, Success (paginated list)):


{
    "data": [
        {
            "odp_id": 1001,
            "odp_domain_id": 3,
            "odp_order_id": 555,
            "odp_track_id": "CDEK-123",
            "odp_delivery_sum": 12.5,
            "odp_delivery_tax": 2.5,
            "odp_cod_sum": 100,
            "odp_cod_agent_sum": 3,
            "odp_status_id": 1,
            "odp_payment_order_id": 987,
            "odp_etalon_order_id": "ETL-777",
            "odp_transaction_id": 123456,
            "odp_cod_act_id": 222,
            "created_at": "2026-02-05T12:00:00Z",
            "updated_at": "2026-02-05T12:30:00Z"
        }
    ],
    "links": {
        "first": "https://api.example.com/api/order-delivery-payments?page=1",
        "last": "https://api.example.com/api/order-delivery-payments?page=3",
        "prev": null,
        "next": "https://api.example.com/api/order-delivery-payments?page=2"
    },
    "meta": {
        "current_page": 1,
        "from": 1,
        "last_page": 3,
        "path": "https://api.example.com/api/order-delivery-payments",
        "per_page": 50,
        "to": 50,
        "total": 123
    }
}
 

Request      

GET api/order-delivery-payments

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

Query Parameters

page   integer  optional    

The page number for pagination. Example: 1

per_page   integer  optional    

Number of items per page (max 250). Example: 50

odp_id   integer  optional    

Filter by internal ID. Example: 1001

odp_order_id   integer  optional    

Filter by order ID. Example: 555

odp_track_id   string  optional    

Filter by track ID (substring, case-insensitive). Max 150. Example: CDEK-123

odp_status_id   integer  optional    

Filter by status. Example: 1

odp_payment_order_id   integer  optional    

Filter by payment order ID. Example: 987

odp_etalon_order_id   string  optional    

Filter by etalon order ID (substring). Max 150. Example: ETL-777

odp_transaction_id   integer  optional    

Filter by transaction ID. Example: 123456

odp_cod_act_id   integer  optional    

Filter by COD act ID. Example: 222

created_from   string  optional    

Filter by created_at >= date (YYYY-MM-DD). Example: 2026-01-01

created_to   string  optional    

Filter by created_at <= date (YYYY-MM-DD). Example: 2026-01-31

sort_by   string  optional    

Field to sort by. Allowed: odp_id, odp_order_id, odp_track_id, odp_delivery_sum, odp_delivery_tax, odp_cod_sum, odp_cod_agent_sum, odp_status_id, odp_payment_order_id, created_at. Example: created_at

sort_dir   string  optional    

Sort direction. Allowed: asc, desc. Defaults to desc. Example: desc

Body Parameters

per_page   integer  optional    

Must be at least 1. Must not be greater than 250. Example: 1

odp_id   integer  optional    

Example: 16

odp_order_id   integer  optional    

Example: 16

odp_track_id   string  optional    

Must not be greater than 150 characters. Example: n

odp_status_id   integer  optional    

Example: 16

odp_payment_order_id   integer  optional    

Example: 16

odp_etalon_order_id   string  optional    

Must not be greater than 150 characters. Example: n

odp_transaction_id   integer  optional    

Example: 16

odp_cod_act_id   integer  optional    

Example: 16

created_from   string  optional    

Must be a valid date in the format Y-m-d. Example: 2026-06-15

created_to   string  optional    

Must be a valid date in the format Y-m-d. Example: 2026-06-15

sort_by   string  optional    

Example: architecto

sort_dir   string  optional    

Example: architecto

Endpoints

POST api/openclaw/messages

Example request:
curl --request POST \
    "https://localhost/api/openclaw/messages" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"chatId\": \"b\",
    \"text\": \"n\",
    \"threadId\": \"g\",
    \"replyToId\": \"z\"
}"
const url = new URL(
    "https://localhost/api/openclaw/messages"
);

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

let body = {
    "chatId": "b",
    "text": "n",
    "threadId": "g",
    "replyToId": "z"
};

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

Request      

POST api/openclaw/messages

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

Body Parameters

chatId   string     

Must not be greater than 64 characters. Example: b

text   string     

Must not be greater than 20000 characters. Example: n

threadId   string  optional    

Must not be greater than 191 characters. Example: g

replyToId   string  optional    

Must not be greater than 191 characters. Example: z

metadata   object  optional    

GET api/user

Example request:
curl --request GET \
    --get "https://localhost/api/user" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "https://localhost/api/user"
);

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

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

Example response (401):

Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
 

{
    "message": "Unauthenticated.",
    "error": "AUTH_REQUIRED"
}
 

Request      

GET api/user

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

POST api/login

Example request:
curl --request POST \
    "https://localhost/api/login" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "https://localhost/api/login"
);

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

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

Request      

POST api/login

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

POST api/logout

Example request:
curl --request POST \
    "https://localhost/api/logout" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "https://localhost/api/logout"
);

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

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

Request      

POST api/logout

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

POST api/accounts/create

Example request:
curl --request POST \
    "https://localhost/api/accounts/create" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"language\": \"bngz\",
    \"company\": \"m\",
    \"FName\": \"i\",
    \"LName\": \"y\",
    \"email\": \"justina.gaylord@example.org\",
    \"password\": \"gxwmi\\/#iw\\/\",
    \"massage\": \"architecto\",
    \"fst\": 4326.41688,
    \"mName\": \"architecto\"
}"
const url = new URL(
    "https://localhost/api/accounts/create"
);

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

let body = {
    "language": "bngz",
    "company": "m",
    "FName": "i",
    "LName": "y",
    "email": "justina.gaylord@example.org",
    "password": "gxwmi\/#iw\/",
    "massage": "architecto",
    "fst": 4326.41688,
    "mName": "architecto"
};

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

Request      

POST api/accounts/create

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

Body Parameters

language   string     

Must not be greater than 6 characters. Example: bngz

company   string     

Must not be greater than 100 characters. Example: m

FName   string     

Must not be greater than 255 characters. Example: i

LName   string     

Must not be greater than 255 characters. Example: y

email   string     

Must be a valid email address. Example: justina.gaylord@example.org

password   string     

Must be at least 6 characters. Example: gxwmi/#iw/

massage   string  optional    

Example: architecto

fst   number     

Example: 4326.41688

mName   string  optional    

Example: architecto

POST api/clients/create

Example request:
curl --request POST \
    "https://localhost/api/clients/create" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"language\": \"bngz\",
    \"FName\": \"m\",
    \"LName\": \"i\",
    \"email\": \"okon.justina@example.com\",
    \"password\": \"Ygxwmi\\/\",
    \"shop_name\": \"c\",
    \"warehouse_name\": \"m\",
    \"billing_id\": 16
}"
const url = new URL(
    "https://localhost/api/clients/create"
);

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

let body = {
    "language": "bngz",
    "FName": "m",
    "LName": "i",
    "email": "okon.justina@example.com",
    "password": "Ygxwmi\/",
    "shop_name": "c",
    "warehouse_name": "m",
    "billing_id": 16
};

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

Request      

POST api/clients/create

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

Body Parameters

language   string     

Must not be greater than 6 characters. Example: bngz

FName   string     

Must not be greater than 255 characters. Example: m

LName   string     

Must not be greater than 255 characters. Example: i

email   string     

Must be a valid email address. Example: okon.justina@example.com

password   string     

Must be at least 6 characters. Example: Ygxwmi/

shop_name   string  optional    

Must not be greater than 255 characters. Example: c

warehouse_name   string  optional    

Must not be greater than 255 characters. Example: m

billing_id   integer  optional    

Example: 16

POST api/client-users/create

Example request:
curl --request POST \
    "https://localhost/api/client-users/create" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "https://localhost/api/client-users/create"
);

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

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

Request      

POST api/client-users/create

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

GET /api/products/offer

Формат максимально приближен к OrderAdmin.

Example request:
curl --request GET \
    --get "https://localhost/api/products/offer" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "https://localhost/api/products/offer"
);

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

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

Example response (401):

Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
 

{
    "message": "Unauthenticated.",
    "error": "AUTH_REQUIRED"
}
 

Request      

GET api/products/offer

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

Loading

List loading/unloading visits visible to the current API user.

Example request:
curl --request GET \
    --get "https://localhost/api/loading/visits?lv_status%5B%5D=waiting&lv_type%5B%5D=inbound" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"lv_status\": [
        \"architecto\"
    ],
    \"lv_type\": [
        \"outbound\"
    ],
    \"per_page\": 22
}"
const url = new URL(
    "https://localhost/api/loading/visits"
);

const params = {
    "lv_status[]": "waiting",
    "lv_type[]": "inbound",
};
Object.keys(params)
    .forEach(key => url.searchParams.append(key, params[key]));

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

let body = {
    "lv_status": [
        "architecto"
    ],
    "lv_type": [
        "outbound"
    ],
    "per_page": 22
};

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

Example response (401):

Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
 

{
    "message": "Unauthenticated.",
    "error": "AUTH_REQUIRED"
}
 

Request      

GET api/loading/visits

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

Query Parameters

lv_status[]   string  optional    

Filter by status. Example: waiting

lv_type[]   string  optional    

Filter by operation type: inbound/outbound. Example: inbound

Body Parameters

lv_status   string[]  optional    
lv_type   string[]  optional    
Must be one of:
  • inbound
  • outbound
per_page   integer  optional    

Must be at least 1. Must not be greater than 250. Example: 22

Create a loading/unloading request.

Example request:
curl --request POST \
    "https://localhost/api/loading/visits" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"lv_wh_id\": 1,
    \"lv_type\": \"inbound\",
    \"lv_planned_at\": \"2026-05-20 10:00:00\",
    \"lv_doc_type\": \"acceptance\",
    \"lv_doc_id\": 100,
    \"lv_driver_phone\": \"+79990000000\",
    \"lv_comment\": \"Delivery by client transport\"
}"
const url = new URL(
    "https://localhost/api/loading/visits"
);

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

let body = {
    "lv_wh_id": 1,
    "lv_type": "inbound",
    "lv_planned_at": "2026-05-20 10:00:00",
    "lv_doc_type": "acceptance",
    "lv_doc_id": 100,
    "lv_driver_phone": "+79990000000",
    "lv_comment": "Delivery by client transport"
};

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

Request      

POST api/loading/visits

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

Body Parameters

lv_wh_id   integer  optional    

nullable Fulfilment warehouse ID. Required if document ID cannot resolve FF warehouse. Example: 1

lv_type   string     

inbound/outbound. Example: inbound

lv_planned_at   string  optional    

nullable Planned arrival datetime. Example: 2026-05-20 10:00:00

lv_doc_type   string  optional    

nullable Document type: acceptance/order/send_document. Example: acceptance

lv_doc_id   integer  optional    

nullable Document ID according to lv_doc_type. Example: 100

lv_driver_phone   string  optional    

nullable Driver phone. Example: +79990000000

lv_comment   string  optional    

nullable Comment. Example: Delivery by client transport

Show one loading/unloading request.

Example request:
curl --request GET \
    --get "https://localhost/api/loading/visits/architecto" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "https://localhost/api/loading/visits/architecto"
);

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

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

Example response (401):

Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
 

{
    "message": "Unauthenticated.",
    "error": "AUTH_REQUIRED"
}
 

Request      

GET api/loading/visits/{id}

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

id   string     

The ID of the visit. Example: architecto

Update a loading/unloading request before planned time.

Example request:
curl --request PUT \
    "https://localhost/api/loading/visits/architecto" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "https://localhost/api/loading/visits/architecto"
);

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

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

Request      

PUT api/loading/visits/{id}

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

id   string     

The ID of the visit. Example: architecto

Cancel a loading/unloading request before planned time.

Example request:
curl --request POST \
    "https://localhost/api/loading/visits/architecto/cancel" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "https://localhost/api/loading/visits/architecto/cancel"
);

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

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

Request      

POST api/loading/visits/{id}/cancel

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

id   string     

The ID of the visit. Example: architecto

Orders

Manage warehouse orders and their associated offers.

Each order represents a warehouse document with optional related data:

The API supports:

Authentication: This API uses NWMS Sanctum. Send your personal access token in the HTTP header: Authorization: Bearer {token}

Get list of orders with advanced filtering

requires authentication

Returns a paginated list of orders available to the authenticated user.

Includes nested relations:

Delivery service data may include:

Supports:

Examples:

Example request:
curl --request GET \
    --get "https://localhost/api/orders?o_id%5B%5D[]=105&o_id%5B%5D[]=106&o_id%5B%5D[]=200&o_status_id%5B%5D[]=10&o_status_id%5B%5D[]=105&o_wh_id%5B%5D[]=2&o_wh_id%5B%5D[]=3&o_shop_id%5B%5D[]=1&o_shop_id%5B%5D[]=5&o_type_id%5B%5D[]=1&o_type_id%5B%5D[]=2&o_source_id%5B%5D[]=3&o_source_id%5B%5D[]=4&o_customer_type%5B%5D[]=0&o_customer_type%5B%5D[]=1&o_company_id%5B%5D[]=44&o_company_id%5B%5D[]=45&o_is_cod%5B%5D[]=1&o_ext_id%5B%5D[]=ORD-&o_ext_id%5B%5D[]=49060&ods_track_number=CDEK-123&ods_track_number%5B%5D[]=CDEK-&ods_track_number%5B%5D[]=123&o_sum_from=100&o_sum_to=1000&o_date_from=2026-01-01&o_date_to=2026-01-31&o_date_send_from=2026-02-01&o_date_send_to=2026-02-15&created_at_from=2026-02-01&created_at_to=2026-02-25&sort=-o_date%2Co_sum&per_page=50&page=1" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"o_id\": [
        16
    ],
    \"o_status_id\": [
        16
    ],
    \"o_wh_id\": [
        16
    ],
    \"o_shop_id\": [
        16
    ],
    \"o_type_id\": [
        16
    ],
    \"o_source_id\": [
        16
    ],
    \"o_customer_type\": [
        16
    ],
    \"o_company_id\": [
        16
    ],
    \"o_is_cod\": [
        \"0\"
    ],
    \"o_ext_id\": [
        \"n\"
    ],
    \"ods_track_number\": [
        \"g\"
    ],
    \"o_sum_from\": 4326.41688,
    \"o_sum_to\": 4326.41688,
    \"o_date_from\": \"2026-06-15T21:25:59\",
    \"o_date_to\": \"2026-06-15T21:25:59\",
    \"o_date_send_from\": \"2026-06-15T21:25:59\",
    \"o_date_send_to\": \"2026-06-15T21:25:59\",
    \"created_at_from\": \"2026-06-15T21:25:59\",
    \"created_at_to\": \"2026-06-15T21:25:59\",
    \"sort\": \"architecto\",
    \"per_page\": 22,
    \"page\": 67
}"
const url = new URL(
    "https://localhost/api/orders"
);

const params = {
    "o_id[][0]": "105",
    "o_id[][1]": "106",
    "o_id[][2]": "200",
    "o_status_id[][0]": "10",
    "o_status_id[][1]": "105",
    "o_wh_id[][0]": "2",
    "o_wh_id[][1]": "3",
    "o_shop_id[][0]": "1",
    "o_shop_id[][1]": "5",
    "o_type_id[][0]": "1",
    "o_type_id[][1]": "2",
    "o_source_id[][0]": "3",
    "o_source_id[][1]": "4",
    "o_customer_type[][0]": "0",
    "o_customer_type[][1]": "1",
    "o_company_id[][0]": "44",
    "o_company_id[][1]": "45",
    "o_is_cod[][0]": "1",
    "o_ext_id[][0]": "ORD-",
    "o_ext_id[][1]": "49060",
    "ods_track_number": "CDEK-123",
    "ods_track_number[][0]": "CDEK-",
    "ods_track_number[][1]": "123",
    "o_sum_from": "100",
    "o_sum_to": "1000",
    "o_date_from": "2026-01-01",
    "o_date_to": "2026-01-31",
    "o_date_send_from": "2026-02-01",
    "o_date_send_to": "2026-02-15",
    "created_at_from": "2026-02-01",
    "created_at_to": "2026-02-25",
    "sort": "-o_date,o_sum",
    "per_page": "50",
    "page": "1",
};
Object.keys(params)
    .forEach(key => url.searchParams.append(key, params[key]));

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

let body = {
    "o_id": [
        16
    ],
    "o_status_id": [
        16
    ],
    "o_wh_id": [
        16
    ],
    "o_shop_id": [
        16
    ],
    "o_type_id": [
        16
    ],
    "o_source_id": [
        16
    ],
    "o_customer_type": [
        16
    ],
    "o_company_id": [
        16
    ],
    "o_is_cod": [
        "0"
    ],
    "o_ext_id": [
        "n"
    ],
    "ods_track_number": [
        "g"
    ],
    "o_sum_from": 4326.41688,
    "o_sum_to": 4326.41688,
    "o_date_from": "2026-06-15T21:25:59",
    "o_date_to": "2026-06-15T21:25:59",
    "o_date_send_from": "2026-06-15T21:25:59",
    "o_date_send_to": "2026-06-15T21:25:59",
    "created_at_from": "2026-06-15T21:25:59",
    "created_at_to": "2026-06-15T21:25:59",
    "sort": "architecto",
    "per_page": 22,
    "page": 67
};

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

Example response (200):


{
    "data": [
        {
            "o_id": 49060,
            "o_ext_id": "ORD-49060",
            "o_wh_id": 106,
            "o_shop_id": 85,
            "o_status_id": 10,
            "contact": {
                "oc_first_name": "John",
                "oc_phone": "+15551234567"
            },
            "ds": {
                "ods_ds_id": 1,
                "ods_track_number": "TRACK-123",
                "ods_tariff_code": 136,
                "ods_delivery_date": "2026-03-10",
                "ods_delivery_time_start": "09:00",
                "ods_delivery_time_end": "18:00"
            },
            "comments": {
                "oc_ds_text": "Fragile",
                "oc_inner_text": "Call before delivery"
            }
        }
    ],
    "meta": {
        "current_page": 1,
        "per_page": 50,
        "total": 312
    }
}
 

Request      

GET api/orders

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

Query Parameters

o_id[]   integer[]  optional    

Filter by order ID(s).

o_status_id[]   integer[]  optional    

Filter by status ID(s).

o_wh_id[]   integer[]  optional    

Filter by warehouse ID(s).

o_shop_id[]   integer[]  optional    

Filter by shop ID(s).

o_type_id[]   integer[]  optional    

Filter by order type ID(s).

o_source_id[]   integer[]  optional    

Filter by order source ID(s).

o_customer_type[]   integer[]  optional    

Filter by customer type(s).

o_company_id[]   integer[]  optional    

Filter by company ID(s).

o_is_cod[]   integer[]  optional    

Filter by COD flag(s), allowed: 0 or 1.

o_ext_id[]   string[]  optional    

Filter by external ID fragment(s) using LIKE search.

ods_track_number   string  optional    

Filter by delivery track number fragment using LIKE search. Example: CDEK-123

ods_track_number[]   string[]  optional    

Filter by multiple delivery track number fragments using LIKE search.

o_sum_from   number  optional    

Filter orders with sum >= value. Example: 100

o_sum_to   number  optional    

Filter orders with sum <= value. Example: 1000

o_date_from   string  optional    

date Filter by order date from. Example: 2026-01-01

o_date_to   string  optional    

date Filter by order date to. Example: 2026-01-31

o_date_send_from   string  optional    

date Filter by send date from. Example: 2026-02-01

o_date_send_to   string  optional    

date Filter by send date to. Example: 2026-02-15

created_at_from   string  optional    

date Filter by creation date from. Example: 2026-02-01

created_at_to   string  optional    

date Filter by creation date to. Example: 2026-02-25

sort   string  optional    

Sort fields separated by comma. Use "-" prefix for DESC. Allowed: o_id, o_date, o_date_send, o_sum, created_at Example: -o_date,o_sum

per_page   integer  optional    

Items per page. Max: 500. Example: 50

page   integer  optional    

Page number. Example: 1

Body Parameters

o_id   integer[]  optional    
o_status_id   integer[]  optional    
o_wh_id   integer[]  optional    
o_shop_id   integer[]  optional    
o_type_id   integer[]  optional    
o_source_id   integer[]  optional    
o_customer_type   integer[]  optional    
o_company_id   integer[]  optional    
o_is_cod   integer[]  optional    
Must be one of:
  • 0
  • 1
o_ext_id   string[]  optional    

Must not be greater than 50 characters.

ods_track_number   string[]  optional    

Must not be greater than 150 characters.

o_sum_from   number  optional    

Example: 4326.41688

o_sum_to   number  optional    

Example: 4326.41688

o_date_from   string  optional    

Must be a valid date. Example: 2026-06-15T21:25:59

o_date_to   string  optional    

Must be a valid date. Example: 2026-06-15T21:25:59

o_date_send_from   string  optional    

Must be a valid date. Example: 2026-06-15T21:25:59

o_date_send_to   string  optional    

Must be a valid date. Example: 2026-06-15T21:25:59

created_at_from   string  optional    

Must be a valid date. Example: 2026-06-15T21:25:59

created_at_to   string  optional    

Must be a valid date. Example: 2026-06-15T21:25:59

sort   string  optional    

Example: architecto

per_page   integer  optional    

Must be at least 1. Must not be greater than 500. Example: 22

page   integer  optional    

Must be at least 1. Example: 67

Create a new order

requires authentication

Creates a new order in the current user's domain. Computed fields (o_sum, o_cod_sum) are prohibited.

If o_ext_id is provided, the pair (o_ext_id, o_wh_id) must be unique.

Supports nested objects:

Delivery service data may include:

ds.ods_ds_id is required for ApiShip and for direct integrations without a default delivery service. For CDEK/Speedy/Econt, if the selected ds.ods_source_id points to an integration with default *_ds_id, ds.ods_ds_id may be omitted and NWMS will use ca_ds_id.

Examples:

1) Minimal: POST /api/orders { "o_type_id": 1, "o_shop_id": 85, "o_wh_id": 106 }

2) With contact + ds + comments + offers: { "o_type_id": 1, "o_ext_id": "ORD-49060", "o_shop_id": 85, "o_wh_id": 106, "o_date_send": "2026-03-05", "contact": { "oc_first_name": "John", "oc_phone": "+15551234567", "oc_full_address": "Sofia, Bulgaria" }, "ds": { "ods_ds_id": 1, "ods_tariff_code": 136, "ods_order_label": "https://www.aaa.ru", "ods_delivery_date": "2026-03-10", "ods_delivery_time_start": "09:00", "ods_delivery_time_end": "18:00" }, "comments": { "oc_ds_text": "Leave at reception", "oc_inner_text": "VIP client" }, "offers": [ { "oo_offer_id": 77, "oo_qty": 2, "oo_price": 39.95, "oo_oc_price": 39.95 }, { "oo_offer_ext_id": "EXT-88", "oo_qty": 1, "oo_price": 9.99 } ] }

Example request:
curl --request POST \
    "https://localhost/api/orders" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"o_type_id\": 16,
    \"o_ext_id\": \"n\",
    \"o_group_id\": 16,
    \"o_shop_id\": 16,
    \"o_wh_id\": 16,
    \"o_date_send\": \"2026-06-15T21:25:59\",
    \"o_source_id\": 16,
    \"o_status_id\": 16,
    \"o_customer_type\": 16,
    \"o_weight\": 16,
    \"o_dimension_x\": 16,
    \"o_dimension_y\": 16,
    \"o_dimension_z\": 16,
    \"o_is_cod\": false,
    \"o_shipping_price\": 4326.41688,
    \"o_shipping_cost\": 4326.41688,
    \"o_company_id\": 16,
    \"contact\": {
        \"oc_first_name\": \"n\",
        \"oc_middle_name\": \"g\",
        \"oc_last_name\": \"z\",
        \"oc_phone\": \"m\",
        \"oc_email\": \"gulgowski.asia@example.com\",
        \"oc_country_id\": 16,
        \"oc_city_id\": 16,
        \"oc_postcode\": \"ngzmiyvdljnikhwa\",
        \"oc_coord_latitude\": 4326.41688,
        \"oc_coord_longitude\": 4326.41688,
        \"oc_full_address\": \"m\"
    },
    \"ds\": {
        \"ods_ds_id\": 16,
        \"ods_status\": 16,
        \"ods_track_number\": \"n\",
        \"ods_ds_pp_id\": \"g\",
        \"ods_tariff_code\": 66,
        \"ods_order_label\": \"m\",
        \"ods_delivery_date\": \"2026-06-15T21:25:59\",
        \"ods_delivery_time_start\": \"21:25\",
        \"ods_delivery_time_end\": \"21:25\"
    },
    \"comments\": {
        \"oc_ds_text\": \"architecto\",
        \"oc_inner_text\": \"architecto\"
    },
    \"offers\": [
        {
            \"oo_offer_id\": 77,
            \"oo_qty\": 2,
            \"oo_price\": 39.95
        }
    ]
}"
const url = new URL(
    "https://localhost/api/orders"
);

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

let body = {
    "o_type_id": 16,
    "o_ext_id": "n",
    "o_group_id": 16,
    "o_shop_id": 16,
    "o_wh_id": 16,
    "o_date_send": "2026-06-15T21:25:59",
    "o_source_id": 16,
    "o_status_id": 16,
    "o_customer_type": 16,
    "o_weight": 16,
    "o_dimension_x": 16,
    "o_dimension_y": 16,
    "o_dimension_z": 16,
    "o_is_cod": false,
    "o_shipping_price": 4326.41688,
    "o_shipping_cost": 4326.41688,
    "o_company_id": 16,
    "contact": {
        "oc_first_name": "n",
        "oc_middle_name": "g",
        "oc_last_name": "z",
        "oc_phone": "m",
        "oc_email": "gulgowski.asia@example.com",
        "oc_country_id": 16,
        "oc_city_id": 16,
        "oc_postcode": "ngzmiyvdljnikhwa",
        "oc_coord_latitude": 4326.41688,
        "oc_coord_longitude": 4326.41688,
        "oc_full_address": "m"
    },
    "ds": {
        "ods_ds_id": 16,
        "ods_status": 16,
        "ods_track_number": "n",
        "ods_ds_pp_id": "g",
        "ods_tariff_code": 66,
        "ods_order_label": "m",
        "ods_delivery_date": "2026-06-15T21:25:59",
        "ods_delivery_time_start": "21:25",
        "ods_delivery_time_end": "21:25"
    },
    "comments": {
        "oc_ds_text": "architecto",
        "oc_inner_text": "architecto"
    },
    "offers": [
        {
            "oo_offer_id": 77,
            "oo_qty": 2,
            "oo_price": 39.95
        }
    ]
};

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

Example response (201, Created):


{
    "data": {
        "o_id": 49060,
        "o_ext_id": "ORD-49060",
        "o_shop_id": 85,
        "o_wh_id": 106,
        "contact": {
            "oc_first_name": "John"
        },
        "ds": {
            "ods_ds_id": 1,
            "ods_tariff_code": 136,
            "ods_delivery_date": "2026-03-10",
            "ods_delivery_time_start": "09:00",
            "ods_delivery_time_end": "18:00"
        },
        "comments": {
            "oc_ds_text": "Leave at reception",
            "oc_inner_text": "VIP client"
        }
    }
}
 

Request      

POST api/orders

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

Body Parameters

o_type_id   integer     

Example: 16

o_ext_id   string  optional    

Must not be greater than 30 characters. Example: n

o_group_id   integer  optional    

Example: 16

o_shop_id   integer     

Example: 16

o_wh_id   integer     

Example: 16

o_date_send   string  optional    

Must be a valid date. Example: 2026-06-15T21:25:59

o_source_id   integer  optional    

Example: 16

o_status_id   integer  optional    

Example: 16

o_customer_type   integer  optional    

Example: 16

o_weight   integer  optional    

Example: 16

o_dimension_x   integer  optional    

Example: 16

o_dimension_y   integer  optional    

Example: 16

o_dimension_z   integer  optional    

Example: 16

o_is_cod   boolean  optional    

Example: false

o_shipping_price   number  optional    

Example: 4326.41688

o_shipping_cost   number  optional    

Example: 4326.41688

o_sum   string  optional    
o_cod_sum   string  optional    
o_company_id   integer  optional    

The co_id of an existing record in the rw_companies table. Example: 16

contact   object  optional    

contact.

oc_first_name   string  optional    

Must not be greater than 255 characters. Example: n

oc_middle_name   string  optional    

Must not be greater than 255 characters. Example: g

oc_last_name   string  optional    

Must not be greater than 255 characters. Example: z

oc_phone   string  optional    

Must not be greater than 50 characters. Example: m

oc_email   string  optional    

Must be a valid email address. Must not be greater than 255 characters. Example: gulgowski.asia@example.com

oc_country_id   integer  optional    

Example: 16

oc_city_id   integer  optional    

Example: 16

oc_postcode   string  optional    

Must not be greater than 20 characters. Example: ngzmiyvdljnikhwa

oc_coord_latitude   number  optional    

Example: 4326.41688

oc_coord_longitude   number  optional    

Example: 4326.41688

oc_full_address   string  optional    

Must not be greater than 255 characters. Example: m

ds   object  optional    

ds.

ods_ds_id   integer  optional    

Example: 16

ods_status   integer  optional    

Example: 16

ods_track_number   string  optional    

Must not be greater than 50 characters. Example: n

ods_ds_pp_id   string  optional    

Must not be greater than 100 characters. Example: g

ods_source_id   string  optional    
ods_tariff_code   integer  optional    

Must be at least 1. Example: 66

ods_order_label   string  optional    

Must not be greater than 255 characters. Example: m

ods_delivery_date   string  optional    

Must be a valid date. Example: 2026-06-15T21:25:59

ods_delivery_time_start   string  optional    

Must be a valid date in the format H:i. Example: 21:25

ods_delivery_time_end   string  optional    

Must be a valid date in the format H:i. Example: 21:25

comments   object  optional    

comments.

oc_ds_text   string  optional    

Example: architecto

oc_inner_text   string  optional    

Example: architecto

offers   string[]  optional    

nullable Product lines to create together with the order.

oo_offer_id   integer  optional    

Example: 16

oo_offer_ext_id   string  optional    

Example: architecto

oo_qty   number     

Must be at least 0.01. Example: 39

oo_oc_price   number  optional    

Must be at least 0. Example: 84

oo_price   number  optional    

Must be at least 0. Example: 12

oo_expiration_date   string  optional    

Must be a valid date. Example: 2026-06-15T21:25:59

oo_batch   string  optional    

Must not be greater than 15 characters. Example: m

oo_operation_user_id   integer  optional    

Example: 16

*   object  optional    
oo_offer_id   integer  optional    

nullable Offer ID (rw_offers.of_id). Required if oo_offer_ext_id is not provided. Example: 77

oo_offer_ext_id   string  optional    

nullable Offer external ID (rw_offers.of_ext_id). Required if oo_offer_id is not provided. Example: "EXT-77"

oo_qty   number     

Quantity. Must be ≥ 0.01. Example: 2

oo_price   number  optional    

nullable COD unit price. If omitted, product price is used. Explicit 0 is saved as 0. Example: 39.95

oo_oc_price   number  optional    

nullable Estimated unit price. If omitted, product estimated price is used. Explicit 0 is saved as 0. Example: 39.95

oo_expiration_date   date  optional    

nullable Expiration date (YYYY-MM-DD). Example: 2026-03-31

oo_batch   string  optional    

nullable Batch/Lot identifier (max 15 chars). Example: "LOT-2026"

oo_operation_user_id   integer  optional    

nullable Operator user ID. Example: 10

Get a single order by ID

requires authentication

Returns detailed information about a specific order including:

Delivery service data may include:

Example:

Example request:
curl --request GET \
    --get "https://localhost/api/orders/49060" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "https://localhost/api/orders/49060"
);

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

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

Example response (200, Found):


{
    "data": {
        "o_id": 49060,
        "o_ext_id": "49054",
        "o_shop_id": 85,
        "o_wh_id": 106,
        "contact": {
            "oc_first_name": "John",
            "oc_phone": "+15551234567"
        },
        "ds": {
            "ods_ds_id": 1,
            "ods_tariff_code": 136,
            "ods_order_label": "https://www.aaa.ru",
            "ods_delivery_date": "2026-03-10",
            "ods_delivery_time_start": "09:00",
            "ods_delivery_time_end": "18:00"
        },
        "comments": {
            "oc_ds_text": "Fragile",
            "oc_inner_text": "Internal note"
        }
    }
}
 

Request      

GET api/orders/{id}

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

id   integer     

The order ID. Example: 49060

Update an existing order

requires authentication

Partially updates editable fields of an existing order (PATCH semantics).

Supports nested objects:

Delivery service data may include:

Special DS rule: If at least one ds.* field is provided AND there is no row in rw_order_ds for this order yet, then ds.ods_ds_id becomes required unless ds.ods_source_id points to a CDEK/Speedy/Econt integration with default delivery service ca_ds_id.

Examples:

1) Update ds + comments: PATCH /api/orders/49060 { "ds": { "ods_ds_id": 1, "ods_tariff_code": 136, "ods_order_label": "https://www.aaa.ru", "ods_delivery_date": "2026-03-10", "ods_delivery_time_start": "09:00", "ods_delivery_time_end": "18:00" }, "comments": { "oc_ds_text": "oc_ds_text - тест!!!", "oc_inner_text": "oc_inner_text - тест!!!" } }

2) Update only contact phone: { "contact": { "oc_phone": "+359888123456" } }

Example request:
curl --request PUT \
    "https://localhost/api/orders/49060" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
const url = new URL(
    "https://localhost/api/orders/49060"
);

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

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

Example response (200, Updated (includes nested objects)):


{
    "data": {
        "o_id": 49060,
        "ds": {
            "ods_ds_id": 1,
            "ods_tariff_code": 136,
            "ods_order_label": "https://www.aaa.ru",
            "ods_delivery_date": "2026-03-10",
            "ods_delivery_time_start": "09:00",
            "ods_delivery_time_end": "18:00"
        },
        "comments": {
            "oc_ds_text": "oc_ds_text - тест!!!",
            "oc_inner_text": "oc_inner_text - тест!!!"
        }
    }
}
 

Example response (422, DS validation (no ds row yet)):


{
    "message": "The given data was invalid.",
    "errors": {
        "ds.ods_ds_id": [
            "The ds.ods_ds_id field is required."
        ]
    }
}
 

Request      

PUT api/orders/{id}

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

id   integer     

The order ID. Example: 49060

Body Parameters

o_sum   string  optional    
o_cod_sum   string  optional    

Delete an order

requires authentication

Deletes a specific order.

Example request:
curl --request DELETE \
    "https://localhost/api/orders/105" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "https://localhost/api/orders/105"
);

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

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

Example response (200):


{
    "message": "Deleted"
}
 

Request      

DELETE api/orders/{id}

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

id   integer     

Order ID. Example: 105

Add offers (products) to an order

requires authentication

Adds one or more product lines to an existing order.

Example: POST /api/orders/49060/offers [ {"oo_offer_id":77,"oo_qty":2,"oo_price":39.95}, {"oo_offer_id":88,"oo_qty":1,"oo_price":9.99} ]

Example request:
curl --request POST \
    "https://localhost/api/orders/49060/offers" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"*\": [
        \"architecto\"
    ]
}"
const url = new URL(
    "https://localhost/api/orders/49060/offers"
);

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

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

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

Example response (201, Added):


[
    {
        "oo_offer_id": 77,
        "oo_qty": 2,
        "oo_price": 39.95
    },
    {
        "oo_offer_id": 88,
        "oo_qty": 1,
        "oo_price": 9.99
    }
]
 

Request      

POST api/orders/{id}/offers

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

id   integer     

The order ID. Example: 49060

Body Parameters

*   string[]     

List of offers to add.

oo_offer_id   integer     

Product ID. Example: 77

oo_qty   number     

Quantity to add. Example: 2

oo_price   number  optional    

optional COD unit price. If omitted, product price is used. Explicit 0 is saved as 0. Example: 39.95

oo_oc_price   number  optional    

optional Estimated unit price. If omitted, product estimated price is used. Explicit 0 is saved as 0. Example: 39.95

oo_expiration_date   date  optional    

optional Expiration date. Example: 2026-12-31

oo_batch   string  optional    

optional Batch number. Example: "LOT-2026"

Update an offer within an order

requires authentication

Updates quantity or price for a specific offer line.

Example: PATCH /api/orders/49060/offers/123 { "oo_qty": 5, "oo_price": 45.00 }

Example request:
curl --request PUT \
    "https://localhost/api/orders/49060/offers/123" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"oo_qty\": 5,
    \"oo_oc_price\": 4326.41688,
    \"oo_price\": 45,
    \"oo_expiration_date\": \"2026-06-15T21:25:59\",
    \"oo_batch\": \"i\",
    \"oo_operation_user_id\": 16
}"
const url = new URL(
    "https://localhost/api/orders/49060/offers/123"
);

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

let body = {
    "oo_qty": 5,
    "oo_oc_price": 4326.41688,
    "oo_price": 45,
    "oo_expiration_date": "2026-06-15T21:25:59",
    "oo_batch": "i",
    "oo_operation_user_id": 16
};

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

Example response (200, Updated):


{
    "oo_id": 123,
    "oo_offer_id": 77,
    "oo_qty": 5,
    "oo_price": 45
}
 

Request      

PUT api/orders/{order_id}/offers/{offer_id}

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

order_id   integer     

The order ID. Example: 49060

offer_id   integer     

Offer ID inside this order. Example: 123

Body Parameters

oo_qty   number  optional    

optional Updated quantity. Example: 5

oo_oc_price   number  optional    

Example: 4326.41688

oo_price   number  optional    

optional Updated unit price. Example: 45

oo_expiration_date   string  optional    

Must be a valid date. Example: 2026-06-15T21:25:59

oo_batch   string  optional    

Must not be greater than 15 characters. Example: i

oo_operation_user_id   integer  optional    

Example: 16

Delete an offer from an order

requires authentication

Removes a specific offer line from an existing order.

Example: DELETE /api/orders/49060/offers/123

Example request:
curl --request DELETE \
    "https://localhost/api/orders/49060/offers/123" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "https://localhost/api/orders/49060/offers/123"
);

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

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

Example response (200):


{
    "message": "Offer removed from order"
}
 

Example response (404):


{
    "error": "Offer not found in this order"
}
 

Request      

DELETE api/orders/{order_id}/offers/{offer_id}

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

order_id   integer     

The order ID. Example: 49060

offer_id   integer     

Offer ID. Example: 123

Products

Endpoints for managing the product catalog ("offers").

Authorization

All endpoints require Bearer Token (Laravel Sanctum).

Domain & Access Scoping

Barcodes (rw_barcodes)

You can provide barcodes on create/update:

Description

You can provide of_description on create/update. It is stored in the related product description table and returned as of_description.

Get product list

requires authentication

Returns a paginated list of products.

Includes:

Filters

The following filters support:

Supported exact-match filters:

Supported partial-match filters:

If a partial-match filter is passed as an array, products matching any of the values will be returned.

Sorting

Pagination

Example request:
curl --request GET \
    --get "https://localhost/api/products?of_id=435&of_id%5B%5D[]=435&of_id%5B%5D[]=438&of_sku=SKU-001&of_sku%5B%5D[]=SKU-001&of_sku%5B%5D[]=SKU-002&of_ext_id=EXT-1001&of_ext_id%5B%5D[]=EXT-1001&of_ext_id%5B%5D[]=EXT-1002&of_shop_id=12&of_shop_id%5B%5D[]=12&of_shop_id%5B%5D[]=15&of_status=1&of_status%5B%5D[]=0&of_status%5B%5D[]=1&of_type=1&of_type%5B%5D[]=1&of_type%5B%5D[]=2&of_datamatrix=1&of_datamatrix%5B%5D[]=0&of_datamatrix%5B%5D[]=1&of_price=19.99&of_price%5B%5D[]=19.99&of_price%5B%5D[]=29.99&of_estimated_price=21.5&of_estimated_price%5B%5D[]=21.5&of_estimated_price%5B%5D[]=31.5&of_name=shirt&of_name%5B%5D[]=shirt&of_name%5B%5D[]=cotton&of_article=ART-01&of_article%5B%5D[]=ART-&of_article%5B%5D[]=01&of_comment=fragile&of_comment%5B%5D[]=fragile&of_comment%5B%5D[]=sale&sort_by=of_id&sort_dir=desc&per_page=20" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "https://localhost/api/products"
);

const params = {
    "of_id": "435",
    "of_id[][0]": "435",
    "of_id[][1]": "438",
    "of_sku": "SKU-001",
    "of_sku[][0]": "SKU-001",
    "of_sku[][1]": "SKU-002",
    "of_ext_id": "EXT-1001",
    "of_ext_id[][0]": "EXT-1001",
    "of_ext_id[][1]": "EXT-1002",
    "of_shop_id": "12",
    "of_shop_id[][0]": "12",
    "of_shop_id[][1]": "15",
    "of_status": "1",
    "of_status[][0]": "0",
    "of_status[][1]": "1",
    "of_type": "1",
    "of_type[][0]": "1",
    "of_type[][1]": "2",
    "of_datamatrix": "1",
    "of_datamatrix[][0]": "0",
    "of_datamatrix[][1]": "1",
    "of_price": "19.99",
    "of_price[][0]": "19.99",
    "of_price[][1]": "29.99",
    "of_estimated_price": "21.5",
    "of_estimated_price[][0]": "21.5",
    "of_estimated_price[][1]": "31.5",
    "of_name": "shirt",
    "of_name[][0]": "shirt",
    "of_name[][1]": "cotton",
    "of_article": "ART-01",
    "of_article[][0]": "ART-",
    "of_article[][1]": "01",
    "of_comment": "fragile",
    "of_comment[][0]": "fragile",
    "of_comment[][1]": "sale",
    "sort_by": "of_id",
    "sort_dir": "desc",
    "per_page": "20",
};
Object.keys(params)
    .forEach(key => url.searchParams.append(key, params[key]));

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

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

Example response (200):


{
    "data": [
        {
            "of_id": 435,
            "of_name": "Cotton T-shirt",
            "of_description": "Basic cotton T-shirt"
        },
        {
            "of_id": 438,
            "of_name": "Hoodie",
            "of_description": "Warm hoodie with zipper"
        }
    ]
}
 

Request      

GET api/products

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

Query Parameters

of_id   integer  optional    

Filter by product ID. Example: 435

of_id[]   integer[]  optional    

Filter by multiple product IDs.

of_sku   string  optional    

Filter by SKU. Example: SKU-001

of_sku[]   string[]  optional    

Filter by multiple SKU values.

of_ext_id   string  optional    

Filter by external product ID. Example: EXT-1001

of_ext_id[]   string[]  optional    

Filter by multiple external product IDs.

of_shop_id   integer  optional    

Filter by shop ID. Example: 12

of_shop_id[]   integer[]  optional    

Filter by multiple shop IDs.

of_status   integer  optional    

Filter by product status. Example: 1

of_status[]   integer[]  optional    

Filter by multiple product statuses.

of_type   integer  optional    

Filter by product type. Example: 1

of_type[]   integer[]  optional    

Filter by multiple product types.

of_datamatrix   integer  optional    

Filter by DataMatrix flag. Example: 1

of_datamatrix[]   integer[]  optional    

Filter by multiple DataMatrix flags.

of_price   number  optional    

Filter by exact product price. Example: 19.99

of_price[]   number[]  optional    

Filter by multiple exact product prices.

of_estimated_price   number  optional    

Filter by exact estimated product price. Example: 21.5

of_estimated_price[]   number[]  optional    

Filter by multiple exact estimated product prices.

of_name   string  optional    

Partial match by product name. Example: shirt

of_name[]   string[]  optional    

Partial match by multiple product name fragments.

of_article   string  optional    

Partial match by product article. Example: ART-01

of_article[]   string[]  optional    

Partial match by multiple product article fragments.

of_comment   string  optional    

Partial match by product comment. Example: fragile

of_comment[]   string[]  optional    

Partial match by multiple product comment fragments.

sort_by   string  optional    

Sort field. Example: of_id

sort_dir   string  optional    

Sort direction (asc or desc). Example: desc

per_page   integer  optional    

Items per page (max 250). Example: 20

Bulk create products

requires authentication

Creates multiple products in one request.

Payload is a JSON array.

You can also pass:

Example: [ { "of_shop_id": 12, "of_name": "Cotton T-shirt", "of_ext_id": "EXT-1001", "of_description": "Basic cotton T-shirt", "barcodes": [ {"br_barcode":"4601234567890","br_main":1}, {"br_barcode":"4601234567891","br_main":0} ] } ]

Example request:
curl --request POST \
    "https://localhost/api/products" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "[
    \"architecto\"
]"
const url = new URL(
    "https://localhost/api/products"
);

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

let body = [
    "architecto"
];

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

Example response (201, Created):


[
    {
        "data": {
            "of_id": 1,
            "of_name": "Cotton T-shirt",
            "of_description": "Basic cotton T-shirt"
        }
    }
]
 

Request      

POST api/products

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

Body Parameters

The request body is an array (string[]`), representing array of products.. Each item has the following properties:

of_shop_id   integer     

Shop ID. Example: 12

of_name   string     

Product name. Example: Cotton T-shirt

of_ext_id   string  optional    

nullable External product ID. Example: EXT-1001

of_article   string  optional    

nullable Article. Example: ART-01

of_sku   string  optional    

nullable SKU. Example: SKU-01

of_price   number  optional    

nullable Price. Example: 19.99

of_estimated_price   number  optional    

nullable Estimated price. Example: 21.5

of_img   string  optional    

nullable Image URL. Example: https://cdn.site/img.jpg

of_dimension_x   number  optional    

nullable Dimension X. Example: 10.5

of_dimension_y   number  optional    

nullable Dimension Y. Example: 20

of_dimension_z   number  optional    

nullable Dimension Z. Example: 3.2

of_weight   integer  optional    

nullable Weight (grams). Example: 250

of_datamatrix   integer  optional    

nullable 0|1. Example: 0

of_comment   string  optional    

nullable Comment. Example: Some note

of_description   string  optional    

nullable Product description. Example: Basic cotton T-shirt

barcodes   string[]  optional    

nullable Barcodes list for this product.

br_barcode   string     

Barcode value. Example: 4601234567890

br_main   integer  optional    

nullable 1 for main, 0 for additional. Example: 1

Bulk update products

requires authentication

Updates multiple products in one request.

Payload is a JSON array.

Identification rules:

You can also update:

Example: [ { "of_id": 10, "of_name":"Updated name", "of_description":"Updated long description", "barcodes":[{"br_barcode":"4601","br_main":1}] } ]

Example request:
curl --request PUT \
    "https://localhost/api/products" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "[
    \"architecto\"
]"
const url = new URL(
    "https://localhost/api/products"
);

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

let body = [
    "architecto"
];

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

Example response (200, Updated):


[
    {
        "data": {
            "of_id": 10,
            "of_description": "Updated long description"
        }
    }
]
 

Request      

PUT api/products

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

Body Parameters

The request body is an array (string[]`), representing array of updates.. Each item has the following properties:

of_id   integer  optional    

nullable Product ID (preferred if present). Example: 10

of_ext_id   string  optional    

nullable External product ID (used with of_shop_id). Example: EXT-1001

of_shop_id   integer  optional    

nullable Shop ID (required when using of_ext_id). Example: 12

of_name   string  optional    

nullable Product name. Example: Updated T-shirt

of_article   string  optional    

nullable Article. Example: ART-02

of_sku   string  optional    

nullable SKU. Example: SKU-02

of_price   number  optional    

nullable Price. Example: 24.5

of_estimated_price   number  optional    

nullable Estimated price. Example: 25

of_img   string  optional    

nullable Image URL. Example: https://cdn.site/new.jpg

of_dimension_x   number  optional    

nullable Dimension X. Example: 11

of_dimension_y   number  optional    

nullable Dimension Y. Example: 21

of_dimension_z   number  optional    

nullable Dimension Z. Example: 3

of_weight   integer  optional    

nullable Weight (grams). Example: 260

of_datamatrix   integer  optional    

nullable 0|1. Example: 1

of_comment   string  optional    

nullable Comment. Example: Updated note

of_status   integer  optional    

nullable 0|1. Example: 1

of_description   string  optional    

nullable Product description. Example: Updated long description

barcodes   string[]  optional    

nullable Full barcode list.

br_barcode   string     

Barcode. Example: 4601234567890

br_main   integer  optional    

nullable 1 for main, 0 for additional. Example: 1

Get single product

requires authentication

Returns one product with:

Example request:
curl --request GET \
    --get "https://localhost/api/products/435" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "https://localhost/api/products/435"
);

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

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

Example response (200):


{
    "data": {
        "of_id": 435,
        "of_name": "Cotton T-shirt",
        "of_description": "Basic cotton T-shirt"
    }
}
 

Request      

GET api/products/{id}

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

id   integer     

Product ID. Example: 435

Delete product

requires authentication

Deletes a product if it has no stock movements. Related barcodes are also removed.

Example request:
curl --request DELETE \
    "https://localhost/api/products/435" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "https://localhost/api/products/435"
);

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

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

Example response (200):


{
    "message": "Deleted"
}
 

Example response (404):


{
    "message": "Product not found"
}
 

Example response (422):


{
    "message": "Deletion forbidden",
    "error": "Product has stock movements and cannot be deleted."
}
 

Request      

DELETE api/products/{id}

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

id   integer     

Product ID. Example: 435

Shops

Manage shops (rw_shops).

Authentication: This API uses NWMS Sanctum. Send your personal access token in the HTTP header: Authorization: Bearer {token}

Get list of shops with advanced filtering

requires authentication

Returns a paginated list of shops available to the authenticated user. Supports multiple filters, partial match, sorting and pagination.

✅ Multiple exact filters are supported via arrays: field[]=1&field[]=2

Access scope:

Examples:

Example request:
curl --request GET \
    --get "https://localhost/api/shops?sh_id%5B%5D=1&sh_domain_id%5B%5D=10&sh_user_id%5B%5D=55&sh_name=%22Ozon%22%0A%0A-----------------------------%0A%F0%9F%94%8E+Sorting%0A-----------------------------&sort=-sh_id%2Csh_name%0A%0AAllowed+fields%3A+sh_id%2C+sh_name%2C+sh_user_id%2C+sh_domain_id%2C+created_at%0A%0A-----------------------------%0A%F0%9F%94%8E+Pagination%0A-----------------------------&per_page=250&page=1" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"sh_name\": \"b\",
    \"sort\": \"architecto\",
    \"per_page\": 22,
    \"page\": 67,
    \"sh_id\": [
        16
    ],
    \"sh_domain_id\": [
        16
    ],
    \"sh_user_id\": [
        16
    ]
}"
const url = new URL(
    "https://localhost/api/shops"
);

const params = {
    "sh_id[]": "1",
    "sh_domain_id[]": "10",
    "sh_user_id[]": "55",
    "sh_name": ""Ozon"

-----------------------------
🔎 Sorting
-----------------------------",
    "sort": "-sh_id,sh_name

Allowed fields: sh_id, sh_name, sh_user_id, sh_domain_id, created_at

-----------------------------
🔎 Pagination
-----------------------------",
    "per_page": "250",
    "page": "1",
};
Object.keys(params)
    .forEach(key => url.searchParams.append(key, params[key]));

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

let body = {
    "sh_name": "b",
    "sort": "architecto",
    "per_page": 22,
    "page": 67,
    "sh_id": [
        16
    ],
    "sh_domain_id": [
        16
    ],
    "sh_user_id": [
        16
    ]
};

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

Example response (200, Successful):


{
    "data": [
        {
            "sh_id": 1,
            "sh_domain_id": 10,
            "sh_user_id": 55,
            "sh_name": "Shop #1"
        }
    ],
    "meta": {
        "current_page": 1,
        "per_page": 250,
        "total": 1
    }
}
 

Request      

GET api/shops

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

Query Parameters

sh_id[]   integer  optional    

Filter by shop ID(s). Example: 1

sh_domain_id[]   integer  optional    

Domain filter (admin only; non-admin is forced to own domain). Example: 10

sh_user_id[]   integer  optional    

Owner user ID filter. Example: 55

sh_name   string  optional    

Name filter (LIKE). Example: `"Ozon"


🔎 Sorting -----------------------------`

sort   string  optional    

Sort fields separated by comma. Use "-" prefix for DESC. Example: `-sh_id,sh_name

Allowed fields: sh_id, sh_name, sh_user_id, sh_domain_id, created_at


🔎 Pagination -----------------------------`

per_page   integer  optional    

Items per page. Max: 500. Example: 250

page   integer  optional    

Page number. Example: 1

Body Parameters

sh_name   string  optional    

Must not be greater than 100 characters. Example: b

sort   string  optional    

Example: architecto

per_page   integer  optional    

Must be at least 1. Must not be greater than 500. Example: 22

page   integer  optional    

Must be at least 1. Example: 67

sh_id   integer[]  optional    
sh_domain_id   integer[]  optional    
sh_user_id   integer[]  optional    

Get a single shop by ID

requires authentication

Example request:
curl --request GET \
    --get "https://localhost/api/shops/1" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "https://localhost/api/shops/1"
);

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

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

Example response (200, Found):


{
    "sh_id": 1,
    "sh_domain_id": 10,
    "sh_user_id": 55,
    "sh_name": "Shop #1"
}
 

Example response (404, Not found):


{
    "message": "No query results for model ..."
}
 

Request      

GET api/shops/{id}

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

id   integer     

Shop ID. Example: 1

Create a new shop

requires authentication

Creates a shop in the current user's domain. sh_domain_id is taken from authenticated user and cannot be overridden (unless admin).

Example request:
curl --request POST \
    "https://localhost/api/shops" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"sh_name\": \"\\\"Ozon Shop\\\"\",
    \"sh_user_id\": 55
}"
const url = new URL(
    "https://localhost/api/shops"
);

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

let body = {
    "sh_name": "\"Ozon Shop\"",
    "sh_user_id": 55
};

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

Example response (201, Created):


{
    "sh_id": 10,
    "sh_domain_id": 10,
    "sh_user_id": 55,
    "sh_name": "Ozon Shop"
}
 

Example response (422, Validation error):


{
    "message": "The given data was invalid.",
    "errors": {
        "sh_name": [
            "The sh_name field is required."
        ]
    }
}
 

Request      

POST api/shops

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

Body Parameters

sh_name   string     

Shop name. Max: 100. Example: "Ozon Shop"

sh_user_id   integer  optional    

optional Owner user id. If omitted, current user id is used. Example: 55

sh_domain_id   string  optional    
sh_id   string  optional    

домен не даём подменять в запросе.

Update a shop (no delete)

requires authentication

Updates editable fields of a shop.

Rules:

Example request:
curl --request PUT \
    "https://localhost/api/shops/10" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"sh_name\": \"\\\"Ozon Shop - updated\\\"\",
    \"sh_user_id\": 55
}"
const url = new URL(
    "https://localhost/api/shops/10"
);

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

let body = {
    "sh_name": "\"Ozon Shop - updated\"",
    "sh_user_id": 55
};

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

Example response (200, Updated):


{
    "sh_id": 10,
    "sh_name": "Ozon Shop - updated"
}
 

Request      

PUT api/shops/{id}

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

id   integer     

Shop ID. Example: 10

Body Parameters

sh_id   string  optional    
sh_domain_id   string  optional    
sh_name   string  optional    

optional Shop name. Max: 100. Example: "Ozon Shop - updated"

sh_user_id   integer  optional    

optional Owner user id (admin only). Example: 55

Users

Manage user env JSON fields. Requires separate permissions: users.env.view for reading and users.env.update for replacing env.

Authentication: This API uses NWMS Sanctum. Send your personal access token in the HTTP header: Authorization: Bearer {token}

Get user env fields.

requires authentication

Example request:
curl --request GET \
    --get "https://localhost/api/users/42/env" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "https://localhost/api/users/42/env"
);

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

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

Example response (200):


{
    "user_id": 42,
    "env": {
        "contractUuid": "00000000-0000-0000-0000-000000000001",
        "external_id": "CRM-42",
        "limits": {
            "daily_orders": 100
        }
    }
}
 

Request      

GET api/users/{id}/env

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

id   integer     

User ID. Example: 42

Replace user env fields.

requires authentication

Existing env JSON is replaced with the request body.

Example request:
curl --request PUT \
    "https://localhost/api/users/42/env" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"env\": {
        \"contractUuid\": \"00000000-0000-0000-0000-000000000001\",
        \"external_id\": \"CRM-42\",
        \"limits\": {
            \"daily_orders\": 100
        }
    }
}"
const url = new URL(
    "https://localhost/api/users/42/env"
);

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

let body = {
    "env": {
        "contractUuid": "00000000-0000-0000-0000-000000000001",
        "external_id": "CRM-42",
        "limits": {
            "daily_orders": 100
        }
    }
};

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

Example response (200):


{
    "user_id": 42,
    "env": {
        "contractUuid": "00000000-0000-0000-0000-000000000001",
        "external_id": "CRM-42",
        "limits": {
            "daily_orders": 100
        }
    }
}
 

Request      

PUT api/users/{id}/env

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

id   integer     

User ID. Example: 42

Body Parameters

env   object     

Full env JSON object. For CDEK billing fallback, put contractUuid here.

Warehouses

Manage warehouses (rw_warehouses).

Rules:

Authentication: This API uses NWMS Sanctum. Send your personal access token in the HTTP header: Authorization: Bearer {token}

Get list of warehouses with advanced filtering

requires authentication

Returns a paginated list of warehouses available to the authenticated user. Admin and warehouse_manager can view warehouses in their domain. Clients can view their client warehouses and fulfilment warehouses.

✅ Multiple exact filters are supported via arrays: field[]=1&field[]=2

Examples:

Example request:
curl --request GET \
    --get "https://localhost/api/warehouses?wh_id%5B%5D=2&wh_status%5B%5D=1&wh_domain_id%5B%5D=10&wh_user_id%5B%5D=55&wh_country_id%5B%5D=100&wh_ff_id%5B%5D=2&wh_company_id%5B%5D=44&wh_billing_id%5B%5D=7&wh_type%5B%5D=2&wh_currency_id%5B%5D=3&wh_parent_id%5B%5D=1&wh_doc_num=BG-&wh_doc_date=2026-01&wh_name=Sofia%0A%0A-----------------------------%0A%F0%9F%94%8E+Sorting%0A-----------------------------&sort=-wh_id%2Cwh_name%0A%0A-----------------------------%0A%F0%9F%94%8E+Pagination%0A-----------------------------&per_page=250&page=1" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"wh_doc_num\": \"b\",
    \"wh_doc_date\": \"n\",
    \"wh_name\": \"g\",
    \"sort\": \"architecto\",
    \"per_page\": 22,
    \"page\": 67,
    \"wh_id\": [
        16
    ],
    \"wh_status\": [
        16
    ],
    \"wh_domain_id\": [
        16
    ],
    \"wh_user_id\": [
        16
    ],
    \"wh_country_id\": [
        16
    ],
    \"wh_ff_id\": [
        16
    ],
    \"wh_company_id\": [
        16
    ],
    \"wh_billing_id\": [
        16
    ],
    \"wh_type\": [
        16
    ],
    \"wh_currency_id\": [
        16
    ],
    \"wh_parent_id\": [
        16
    ]
}"
const url = new URL(
    "https://localhost/api/warehouses"
);

const params = {
    "wh_id[]": "2",
    "wh_status[]": "1",
    "wh_domain_id[]": "10",
    "wh_user_id[]": "55",
    "wh_country_id[]": "100",
    "wh_ff_id[]": "2",
    "wh_company_id[]": "44",
    "wh_billing_id[]": "7",
    "wh_type[]": "2",
    "wh_currency_id[]": "3",
    "wh_parent_id[]": "1",
    "wh_doc_num": "BG-",
    "wh_doc_date": "2026-01",
    "wh_name": "Sofia

-----------------------------
🔎 Sorting
-----------------------------",
    "sort": "-wh_id,wh_name

-----------------------------
🔎 Pagination
-----------------------------",
    "per_page": "250",
    "page": "1",
};
Object.keys(params)
    .forEach(key => url.searchParams.append(key, params[key]));

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

let body = {
    "wh_doc_num": "b",
    "wh_doc_date": "n",
    "wh_name": "g",
    "sort": "architecto",
    "per_page": 22,
    "page": 67,
    "wh_id": [
        16
    ],
    "wh_status": [
        16
    ],
    "wh_domain_id": [
        16
    ],
    "wh_user_id": [
        16
    ],
    "wh_country_id": [
        16
    ],
    "wh_ff_id": [
        16
    ],
    "wh_company_id": [
        16
    ],
    "wh_billing_id": [
        16
    ],
    "wh_type": [
        16
    ],
    "wh_currency_id": [
        16
    ],
    "wh_parent_id": [
        16
    ]
};

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

Example response (200, Successful):


{
    "data": [
        {
            "wh_id": 2,
            "wh_status": 1,
            "wh_domain_id": 10,
            "wh_user_id": 55,
            "wh_type": 2,
            "wh_ff_id": 1,
            "wh_name": "Client warehouse Sofia",
            "wh_country_id": 100,
            "wh_currency_id": 3,
            "wh_custom_json": {
                "pickup": true,
                "cutoff": "18:00",
                "contractUuid": "CDEK-CONTRACT-0000000001",
                "sla": 95,
                "officeCode": "MSK-1"
            }
        }
    ],
    "meta": {
        "current_page": 1,
        "per_page": 50,
        "total": 10
    }
}
 

Request      

GET api/warehouses

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

Query Parameters

wh_id[]   integer  optional    

Filter by warehouse ID(s). Example: 2

wh_status[]   integer  optional    

Status filter. Example: 1

wh_domain_id[]   integer  optional    

Domain filter (admin only; non-admin is forced to own domain). Example: 10

wh_user_id[]   integer  optional    

Owner user ID filter. Example: 55

wh_country_id[]   integer  optional    

Country ID filter. Example: 100

wh_ff_id[]   integer  optional    

Fulfilment warehouse id filter. Example: 2

wh_company_id[]   integer  optional    

Company ID filter. Example: 44

wh_billing_id[]   integer  optional    

Billing setting ID filter. Example: 7

wh_type[]   integer  optional    

Warehouse type (1 fulfilment, 2 client). Example: 2

wh_currency_id[]   integer  optional    

Currency ID filter. Example: 3

wh_parent_id[]   integer  optional    

Parent warehouse ID filter. Example: 1

wh_doc_num   string  optional    

Document number (LIKE). Example: BG-

wh_doc_date   string  optional    

Document date (LIKE). Example: 2026-01

wh_name   string  optional    

Name (LIKE). Example: `Sofia


🔎 Sorting -----------------------------`

sort   string  optional    

Sort fields separated by comma. Use "-" for DESC. Example: `-wh_id,wh_name


🔎 Pagination -----------------------------`

per_page   integer  optional    

Items per page. Max: 500. Example: 250

page   integer  optional    

Page number. Example: 1

Body Parameters

wh_doc_num   string  optional    

Must not be greater than 50 characters. Example: b

wh_doc_date   string  optional    

Must not be greater than 50 characters. Example: n

wh_name   string  optional    

Must not be greater than 100 characters. Example: g

sort   string  optional    

Example: architecto

per_page   integer  optional    

Must be at least 1. Must not be greater than 500. Example: 22

page   integer  optional    

Must be at least 1. Example: 67

wh_id   integer[]  optional    
wh_status   integer[]  optional    
wh_domain_id   integer[]  optional    
wh_user_id   integer[]  optional    
wh_country_id   integer[]  optional    
wh_ff_id   integer[]  optional    
wh_company_id   integer[]  optional    
wh_billing_id   integer[]  optional    
wh_type   integer[]  optional    
wh_currency_id   integer[]  optional    
wh_parent_id   integer[]  optional    

Get a single warehouse by ID

requires authentication

Returns one warehouse available to the authenticated user.

Example request:
curl --request GET \
    --get "https://localhost/api/warehouses/2" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "https://localhost/api/warehouses/2"
);

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

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

Example response (200, Found):


{
    "wh_id": 2,
    "wh_status": 1,
    "wh_domain_id": 10,
    "wh_user_id": 55,
    "wh_type": 2,
    "wh_ff_id": 1,
    "wh_name": "Client warehouse Sofia",
    "wh_country_id": 100,
    "wh_custom_json": {
        "pickup": true,
        "cutoff": "18:00",
        "contractUuid": "CDEK-CONTRACT-0000000001",
        "sla": 95,
        "officeCode": "MSK-1"
    }
}
 

Example response (404, Not found):


{
    "message": "No query results for model ..."
}
 

Request      

GET api/warehouses/{id}

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

id   integer     

Warehouse ID. Example: 2

Create a new client warehouse (wh_type = 2)

requires authentication

Admin and warehouse_manager can create warehouses in their domain. Clients can create only client warehouses (wh_type=2) for themselves.

Constraints:

Example request:
curl --request POST \
    "https://localhost/api/warehouses" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"wh_name\": \"\\\"Client warehouse Sofia\\\"\",
    \"wh_ff_id\": 1,
    \"wh_status\": 1,
    \"wh_country_id\": 100,
    \"wh_company_id\": 44,
    \"wh_billing_id\": 7,
    \"wh_doc_num\": \"\\\"BG-001\\\"\",
    \"wh_doc_date\": \"\\\"2026-01-14\\\"\",
    \"wh_currency_id\": 3,
    \"wh_parent_id\": 1,
    \"wh_type\": 16,
    \"wh_user_id\": 55,
    \"wh_set_expiration_date\": 1,
    \"wh_set_batch\": 1,
    \"wh_set_production_date\": 0,
    \"wh_custom_json\": {
        \"delivery\": {
            \"cdek\": {
                \"shipment_point\": \"MSK1\",
                \"sender_city\": \"Москва\",
                \"sender_address\": \"ул. Ленина 1\",
                \"sender_company\": \"ООО Ромашка\",
                \"sender_name\": \"Иван Иванов\",
                \"sender_phone\": \"+79990000000\",
                \"sender_email\": \"sender@example.com\"
            }
        },
        \"contractUuid\": \"CDEK-CONTRACT-0000000001\",
        \"sla\": 95,
        \"officeCode\": \"MSK-1\"
    }
}"
const url = new URL(
    "https://localhost/api/warehouses"
);

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

let body = {
    "wh_name": "\"Client warehouse Sofia\"",
    "wh_ff_id": 1,
    "wh_status": 1,
    "wh_country_id": 100,
    "wh_company_id": 44,
    "wh_billing_id": 7,
    "wh_doc_num": "\"BG-001\"",
    "wh_doc_date": "\"2026-01-14\"",
    "wh_currency_id": 3,
    "wh_parent_id": 1,
    "wh_type": 16,
    "wh_user_id": 55,
    "wh_set_expiration_date": 1,
    "wh_set_batch": 1,
    "wh_set_production_date": 0,
    "wh_custom_json": {
        "delivery": {
            "cdek": {
                "shipment_point": "MSK1",
                "sender_city": "Москва",
                "sender_address": "ул. Ленина 1",
                "sender_company": "ООО Ромашка",
                "sender_name": "Иван Иванов",
                "sender_phone": "+79990000000",
                "sender_email": "sender@example.com"
            }
        },
        "contractUuid": "CDEK-CONTRACT-0000000001",
        "sla": 95,
        "officeCode": "MSK-1"
    }
};

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

Example response (201, Created):


{
    "wh_id": 10,
    "wh_domain_id": 10,
    "wh_type": 2,
    "wh_ff_id": 1,
    "wh_user_id": 55,
    "wh_name": "Client warehouse Sofia",
    "wh_country_id": 100,
    "wh_custom_json": {
        "pickup": true,
        "cutoff": "18:00",
        "contractUuid": "CDEK-CONTRACT-0000000001",
        "sla": 95,
        "officeCode": "MSK-1"
    }
}
 

Example response (422, Validation error):


{
    "message": "The given data was invalid.",
    "errors": {
        "wh_ff_id": [
            "The selected wh_ff_id is invalid."
        ]
    }
}
 

Request      

POST api/warehouses

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

Body Parameters

wh_name   string     

Warehouse name. Max: 100. Example: "Client warehouse Sofia"

wh_ff_id   integer     

Fulfilment warehouse id (must exist in the same domain and be wh_type=1). Example: 1

wh_status   integer  optional    

optional Status. Default: 1. Example: 1

wh_country_id   integer  optional    

nullable Country ID. Defaults to the fulfilment warehouse country for client warehouses when omitted. Example: 100

wh_company_id   integer  optional    

nullable Company ID. Example: 44

wh_billing_id   integer  optional    

optional Billing setting ID. Default: 0. Example: 7

wh_doc_num   string  optional    

nullable Document number. Max: 10. Example: "BG-001"

wh_doc_date   string  optional    

nullable Document date. Max: 15. Example: "2026-01-14"

wh_currency_id   integer  optional    

optional Currency ID. Defaults to the fulfilment warehouse currency for client warehouses when omitted. Example: 3

wh_parent_id   integer  optional    

nullable Parent warehouse id. Example: 1

wh_type   integer  optional    

Example: 16

wh_user_id   integer  optional    

optional Owner user id. Defaults to current user. Admin/warehouse_manager can assign a user in the same domain; clients can pass only themselves or parent account. Example: 55

wh_set_expiration_date   integer  optional    

optional 0/1. Default: 0. Example: 1

wh_set_batch   integer  optional    

optional 0/1. Default: 0. Example: 1

wh_set_production_date   integer  optional    

optional 0/1. Default: 0. Example: 0

wh_custom_json   object  optional    

nullable Additional warehouse fields. CDEK sender settings for FF warehouse are stored in delivery.cdek: shipment_point, sender_city, sender_address, sender_company, sender_name, sender_phone, sender_email.

Update warehouse (no delete)

requires authentication

Only admin or warehouse_manager.

Notes:

Example request:
curl --request PUT \
    "https://localhost/api/warehouses/2" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"wh_user_id\": 55,
    \"wh_name\": \"\\\"Client warehouse Sofia - updated\\\"\",
    \"wh_status\": 1,
    \"wh_country_id\": 100,
    \"wh_company_id\": 44,
    \"wh_billing_id\": 7,
    \"wh_doc_num\": \"\\\"BG-001\\\"\",
    \"wh_doc_date\": \"\\\"2026-01-14\\\"\",
    \"wh_currency_id\": 3,
    \"wh_parent_id\": 1,
    \"wh_ff_id\": 1,
    \"wh_set_expiration_date\": 1,
    \"wh_set_batch\": 1,
    \"wh_set_production_date\": 0,
    \"wh_custom_json\": {
        \"delivery\": {
            \"cdek\": {
                \"shipment_point\": \"MSK1\",
                \"sender_city\": \"Москва\",
                \"sender_address\": \"ул. Ленина 1\",
                \"sender_company\": \"ООО Ромашка\",
                \"sender_name\": \"Иван Иванов\",
                \"sender_phone\": \"+79990000000\",
                \"sender_email\": \"sender@example.com\"
            }
        },
        \"contractUuid\": \"CDEK-CONTRACT-0000000001\",
        \"sla\": 95,
        \"officeCode\": \"MSK-1\"
    }
}"
const url = new URL(
    "https://localhost/api/warehouses/2"
);

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

let body = {
    "wh_user_id": 55,
    "wh_name": "\"Client warehouse Sofia - updated\"",
    "wh_status": 1,
    "wh_country_id": 100,
    "wh_company_id": 44,
    "wh_billing_id": 7,
    "wh_doc_num": "\"BG-001\"",
    "wh_doc_date": "\"2026-01-14\"",
    "wh_currency_id": 3,
    "wh_parent_id": 1,
    "wh_ff_id": 1,
    "wh_set_expiration_date": 1,
    "wh_set_batch": 1,
    "wh_set_production_date": 0,
    "wh_custom_json": {
        "delivery": {
            "cdek": {
                "shipment_point": "MSK1",
                "sender_city": "Москва",
                "sender_address": "ул. Ленина 1",
                "sender_company": "ООО Ромашка",
                "sender_name": "Иван Иванов",
                "sender_phone": "+79990000000",
                "sender_email": "sender@example.com"
            }
        },
        "contractUuid": "CDEK-CONTRACT-0000000001",
        "sla": 95,
        "officeCode": "MSK-1"
    }
};

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

Example response (200, Updated):


{
    "wh_id": 2,
    "wh_name": "Client warehouse Sofia - updated",
    "wh_country_id": 100,
    "wh_custom_json": {
        "pickup": false,
        "contractUuid": "CDEK-CONTRACT-0000000001",
        "sla": 95,
        "officeCode": "MSK-1"
    }
}
 

Request      

PUT api/warehouses/{id}

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

id   integer     

Warehouse ID. Example: 2

Body Parameters

wh_id   string  optional    
wh_domain_id   string  optional    
wh_type   string  optional    
wh_user_id   integer  optional    

optional Owner user id. Requires elevated warehouse access. Example: 55

wh_name   string  optional    

optional Warehouse name. Max: 100. Example: "Client warehouse Sofia - updated"

wh_status   integer  optional    

optional Status. Example: 1

wh_country_id   integer  optional    

nullable Country ID. Example: 100

wh_company_id   integer  optional    

nullable Company ID. Example: 44

wh_billing_id   integer  optional    

optional Billing setting ID. Example: 7

wh_doc_num   string  optional    

nullable Document number. Max: 10. Example: "BG-001"

wh_doc_date   string  optional    

nullable Document date. Max: 15. Example: "2026-01-14"

wh_currency_id   integer  optional    

optional Currency ID. Example: 3

wh_parent_id   integer  optional    

nullable Parent warehouse id. Example: 1

wh_ff_id   integer  optional    

optional Fulfilment warehouse id (must exist in the same domain and be wh_type=1). Example: 1

wh_set_expiration_date   integer  optional    

optional 0/1. Example: 1

wh_set_batch   integer  optional    

optional 0/1. Example: 1

wh_set_production_date   integer  optional    

optional 0/1. Example: 0

wh_custom_json   object  optional    

nullable Additional warehouse fields. CDEK sender settings for FF warehouse are stored in delivery.cdek: shipment_point, sender_city, sender_address, sender_company, sender_name, sender_phone, sender_email.

Get fulfilment warehouse data

requires authentication

Returns the fulfilment warehouse (wh_type = 1) by its ID.

Authentication (Sanctum):

Authorization:

Example request:
curl --request GET \
    --get "https://localhost/api/warehouses/fulfillment/warehouses/1" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "https://localhost/api/warehouses/fulfillment/warehouses/1"
);

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

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

Example response (200, Found):


{
    "data": {
        "id": 1,
        "name": "Fulfilment warehouse Varna",
        "domain_id": 10,
        "country_id": 100,
        "address": null,
        "phone": null
    }
}
 

Example response (403, Forbidden):


{
    "message": "Forbidden: only admin or warehouse_manager"
}
 

Example response (403, Domain mismatch):


{
    "message": "Forbidden: domain mismatch"
}
 

Example response (404, Not found):


{
    "message": "No query results for model ..."
}
 

Request      

GET api/warehouses/fulfillment/warehouses/{ffWarehouseId}

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

ffWarehouseId   integer     

Fulfilment warehouse ID (wh_id). Example: 1

Get client warehouses of a fulfilment warehouse

requires authentication

Returns client warehouses (wh_type = 2) linked to the given fulfilment warehouse. Link is done via wh_ff_id (client warehouse points to fulfilment warehouse).

Authentication (Sanctum):

Authorization:

Example request:
curl --request GET \
    --get "https://localhost/api/warehouses/fulfillment/warehouses/1/client-warehouses" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "https://localhost/api/warehouses/fulfillment/warehouses/1/client-warehouses"
);

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

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

Example response (200, Successful):


{
    "data": [
        {
            "id": 10,
            "name": "Client warehouse Sofia",
            "domain_id": 10,
            "country_id": 100
        }
    ]
}
 

Example response (403, Forbidden):


{
    "message": "Forbidden: only admin or warehouse_manager"
}
 

Example response (403, Domain mismatch):


{
    "message": "Forbidden: domain mismatch"
}
 

Example response (404, Not found):


{
    "message": "No query results for model ..."
}
 

Request      

GET api/warehouses/fulfillment/warehouses/{ffWarehouseId}/client-warehouses

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

ffWarehouseId   integer     

Fulfilment warehouse ID (wh_id). Example: 1

Интеграции CDEK

API для управления подключениями к CDEK API v2.

Доступ совпадает с ЛК: старые роли admin, warehouse_manager, warehouse_worker и новые права integrations/Orchid route permissions. Видимость записей ограничена data scope пользователя: global, domain, warehouse, owner.

В ответах ca_client_secret не возвращается. Для заказов используйте source_id в формате cdek-{ca_id}, он передается в ds.ods_source_id. Настройки отправителя в интеграции имеют приоритет. Если ca_shipment_point, ca_sender_city, ca_sender_address или контактные поля отправителя пустые, отправка берет их из вкладки "Доставки" FF-склада заказа.

Список интеграций CDEK.

requires authentication

Возвращает только интеграции, доступные текущему пользователю.

Example request:
curl --request GET \
    --get "https://localhost/api/integrations/cdek?ca_status=1&ca_domain_id=10&ca_user_id=55&ca_name=%D0%9E%D1%81%D0%BD%D0%BE%D0%B2%D0%BD%D0%BE%D0%B9+CDEK&sort=-ca_id&per_page=50" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"ca_status\": 16,
    \"ca_domain_id\": 22,
    \"ca_user_id\": 67,
    \"ca_name\": \"z\",
    \"sort\": \"architecto\",
    \"per_page\": 22,
    \"page\": 67
}"
const url = new URL(
    "https://localhost/api/integrations/cdek"
);

const params = {
    "ca_status": "1",
    "ca_domain_id": "10",
    "ca_user_id": "55",
    "ca_name": "Основной CDEK",
    "sort": "-ca_id",
    "per_page": "50",
};
Object.keys(params)
    .forEach(key => url.searchParams.append(key, params[key]));

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

let body = {
    "ca_status": 16,
    "ca_domain_id": 22,
    "ca_user_id": 67,
    "ca_name": "z",
    "sort": "architecto",
    "per_page": 22,
    "page": 67
};

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

Example response (200):


{
    "data": [
        {
            "ca_id": 1,
            "source_id": "cdek-1",
            "ca_status": 1,
            "ca_name": "Основной CDEK",
            "ca_base_url": "https://api.cdek.ru",
            "ca_client_id": "account",
            "ca_client_secret_set": true,
            "ca_timeout": 20,
            "ca_domain_id": 10,
            "ca_user_id": null,
            "ca_test_mode": false,
            "ca_order_type": 1,
            "ca_ds_id": 2,
            "ca_tariff_code": 136,
            "ca_label_format": "A6",
            "ca_shipment_point": "MSK1"
        }
    ]
}
 

Request      

GET api/integrations/cdek

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

Query Parameters

ca_status   integer  optional    

Фильтр по статусу: 1 активна, 0 выключена. Example: 1

ca_domain_id   integer  optional    

Фильтр по домену. Для не-global scope дополнительно ограничивается своим доменом. Example: 10

ca_user_id   integer  optional    

Фильтр по пользователю-владельцу. Example: 55

ca_name   string  optional    

Поиск по названию. Example: Основной CDEK

sort   string  optional    

Сортировка через запятую. Поля: ca_id, ca_name, ca_status, ca_domain_id, ca_user_id, updated_at. Минус означает DESC. Example: -ca_id

per_page   integer  optional    

Кол-во записей на страницу, максимум 250. Example: 50

Body Parameters

ca_status   integer  optional    

Example: 16

ca_domain_id   integer  optional    

Must be at least 1. Example: 22

ca_user_id   integer  optional    

Must be at least 1. Example: 67

ca_name   string  optional    

Must not be greater than 190 characters. Example: z

sort   string  optional    

Example: architecto

per_page   integer  optional    

Must be at least 1. Must not be greater than 250. Example: 22

page   integer  optional    

Must be at least 1. Example: 67

Создать интеграцию CDEK.

requires authentication

Для global scope можно передать любой ca_domain_id. Для остальных scope домен всегда фиксируется на домене текущего пользователя. Для owner scope владелец фиксируется на текущем мастер-пользователе клиента.

Example request:
curl --request POST \
    "https://localhost/api/integrations/cdek" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"ca_name\": \"Основной CDEK\",
    \"ca_base_url\": \"https:\\/\\/api.cdek.ru\",
    \"ca_client_id\": \"account-id\",
    \"ca_client_secret\": \"secret\",
    \"ca_domain_id\": 10,
    \"ca_user_id\": 55,
    \"ca_status\": 1,
    \"ca_test_mode\": false,
    \"ca_order_type\": 1,
    \"ca_ds_id\": 2,
    \"ca_tariff_code\": 136,
    \"ca_label_format\": \"A6\",
    \"ca_shipment_point\": \"MSK1\",
    \"ca_sender_company\": \"ООО Ромашка\",
    \"ca_sender_name\": \"Иван Иванов\",
    \"ca_sender_phone\": \"+79990000000\",
    \"ca_sender_email\": \"sender@example.com\",
    \"ca_sender_city\": \"Москва\",
    \"ca_sender_address\": \"ул. Ленина 1\"
}"
const url = new URL(
    "https://localhost/api/integrations/cdek"
);

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

let body = {
    "ca_name": "Основной CDEK",
    "ca_base_url": "https:\/\/api.cdek.ru",
    "ca_client_id": "account-id",
    "ca_client_secret": "secret",
    "ca_domain_id": 10,
    "ca_user_id": 55,
    "ca_status": 1,
    "ca_test_mode": false,
    "ca_order_type": 1,
    "ca_ds_id": 2,
    "ca_tariff_code": 136,
    "ca_label_format": "A6",
    "ca_shipment_point": "MSK1",
    "ca_sender_company": "ООО Ромашка",
    "ca_sender_name": "Иван Иванов",
    "ca_sender_phone": "+79990000000",
    "ca_sender_email": "sender@example.com",
    "ca_sender_city": "Москва",
    "ca_sender_address": "ул. Ленина 1"
};

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

Example response (201):


{
    "ca_id": 1,
    "source_id": "cdek-1",
    "ca_name": "Основной CDEK",
    "ca_client_secret_set": true,
    "ca_ds_id": 2
}
 

Request      

POST api/integrations/cdek

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

Body Parameters

ca_name   string     

Название интеграции. Example: Основной CDEK

ca_base_url   string     

Базовый URL CDEK. Example: https://api.cdek.ru

ca_client_id   string     

Account/client_id из ЛК CDEK. Example: account-id

ca_client_secret   string     

Secure password/client_secret из ЛК CDEK. Example: secret

ca_domain_id   integer  optional    

Домен интеграции, только для global scope. Example: 10

ca_user_id   integer  optional    

Владелец интеграции. 0/null означает "для всех клиентов домена". Example: 55

ca_status   integer  optional    

Активность: 1 или 0. Example: 1

ca_test_mode   boolean  optional    

Тестовый контур. Example: false

ca_order_type   integer  optional    

Тип заказа CDEK: 1 интернет-магазин, 2 доставка. Example: 1

ca_ds_id   integer  optional    

Необязательная служба доставки NWMS по умолчанию. Если задана, для заказов с этим ds.ods_source_id поле ds.ods_ds_id можно не передавать. Example: 2

ca_tariff_code   integer  optional    

Необязательный тариф CDEK по умолчанию. Основной тариф задается в заказе: ds.ods_tariff_code. Example: 136

ca_label_format   string  optional    

Формат этикетки CDEK: A6, A5 или A4. По умолчанию A6. Example: A6

ca_shipment_point   string  optional    

Необязательный код ПВЗ/склада отправителя CDEK. Если пусто, используется настройка FF-склада. Example: MSK1

ca_sender_company   string  optional    

Необязательная компания отправителя. Если пусто, используется настройка FF-склада. Example: ООО Ромашка

ca_sender_name   string  optional    

Необязательное контактное лицо отправителя. Если пусто, используется настройка FF-склада. Example: Иван Иванов

ca_sender_phone   string  optional    

Необязательный телефон отправителя. Если пусто, используется настройка FF-склада. Example: +79990000000

ca_sender_email   string  optional    

Необязательный email отправителя. Если пусто, используется настройка FF-склада. Example: sender@example.com

ca_sender_city   string  optional    

Необязательный город отправителя. Если пусто, используется настройка FF-склада. Example: Москва

ca_sender_address   string  optional    

Необязательный адрес отправителя. Если пусто, используется настройка FF-склада. Example: ул. Ленина 1

Получить интеграцию CDEK.

requires authentication

Example request:
curl --request GET \
    --get "https://localhost/api/integrations/cdek/1" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "https://localhost/api/integrations/cdek/1"
);

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

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

Example response (401):

Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
 

{
    "message": "Unauthenticated.",
    "error": "AUTH_REQUIRED"
}
 

Request      

GET api/integrations/cdek/{id}

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

id   integer     

ID интеграции CDEK. Example: 1

Обновить интеграцию CDEK.

requires authentication

Можно передавать только изменяемые поля. Если ca_client_secret не передан или передан пустым, сохраненный секрет не меняется.

Example request:
curl --request PUT \
    "https://localhost/api/integrations/cdek/1" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"ca_name\": \"CDEK склад Москва\",
    \"ca_base_url\": \"https:\\/\\/api.edu.cdek.ru\",
    \"ca_client_id\": \"account-id\",
    \"ca_client_secret\": \"new-secret\",
    \"ca_domain_id\": 10,
    \"ca_user_id\": 55,
    \"ca_status\": 1,
    \"ca_test_mode\": true,
    \"ca_order_type\": 1,
    \"ca_ds_id\": 2,
    \"ca_tariff_code\": 136,
    \"ca_label_format\": \"A6\",
    \"ca_shipment_point\": \"MSK1\"
}"
const url = new URL(
    "https://localhost/api/integrations/cdek/1"
);

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

let body = {
    "ca_name": "CDEK склад Москва",
    "ca_base_url": "https:\/\/api.edu.cdek.ru",
    "ca_client_id": "account-id",
    "ca_client_secret": "new-secret",
    "ca_domain_id": 10,
    "ca_user_id": 55,
    "ca_status": 1,
    "ca_test_mode": true,
    "ca_order_type": 1,
    "ca_ds_id": 2,
    "ca_tariff_code": 136,
    "ca_label_format": "A6",
    "ca_shipment_point": "MSK1"
};

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

Request      

PUT api/integrations/cdek/{id}

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

id   integer     

ID интеграции CDEK. Example: 1

Body Parameters

ca_name   string  optional    

Название интеграции. Example: CDEK склад Москва

ca_base_url   string  optional    

Базовый URL CDEK. Example: https://api.edu.cdek.ru

ca_client_id   string  optional    

Account/client_id из ЛК CDEK. Example: account-id

ca_client_secret   string  optional    

Новый client_secret. Example: new-secret

ca_domain_id   integer  optional    

Домен интеграции, только для global scope. Example: 10

ca_user_id   integer  optional    

Владелец интеграции. 0/null означает "для всех клиентов домена". Example: 55

ca_status   integer  optional    

Активность: 1 или 0. Example: 1

ca_test_mode   boolean  optional    

Тестовый контур. Example: true

ca_order_type   integer  optional    

Тип заказа CDEK: 1 интернет-магазин, 2 доставка. Example: 1

ca_ds_id   integer  optional    

Необязательная служба доставки NWMS по умолчанию. Если задана, для заказов с этим ds.ods_source_id поле ds.ods_ds_id можно не передавать. Example: 2

ca_tariff_code   integer  optional    

Необязательный тариф CDEK по умолчанию. Основной тариф задается в заказе: ds.ods_tariff_code. Example: 136

ca_label_format   string  optional    

Формат этикетки CDEK: A6, A5 или A4. Example: A6

ca_shipment_point   string  optional    

Необязательный код ПВЗ/склада отправителя CDEK. Если пусто, используется настройка FF-склада. Example: MSK1

Удалить интеграцию CDEK.

requires authentication

Доступно пользователям с правом удаления модуля integrations или старым ролям admin/warehouse_manager.

Example request:
curl --request DELETE \
    "https://localhost/api/integrations/cdek/1" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "https://localhost/api/integrations/cdek/1"
);

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

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

Example response (200):


{
    "deleted": true
}
 

Request      

DELETE api/integrations/cdek/{id}

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

id   integer     

ID интеграции CDEK. Example: 1

Интеграции Econt

API для управления подключениями к Econt SOAP/JSON API.

В ответах ea_password не возвращается. Для заказов используйте source_id в формате econt-{ea_id}, он передается в ds.ods_source_id.

GET api/integrations/econt

requires authentication

Example request:
curl --request GET \
    --get "https://localhost/api/integrations/econt" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"ea_status\": 16,
    \"ea_domain_id\": 22,
    \"ea_user_id\": 67,
    \"ea_name\": \"z\",
    \"sort\": \"architecto\",
    \"per_page\": 22,
    \"page\": 67
}"
const url = new URL(
    "https://localhost/api/integrations/econt"
);

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

let body = {
    "ea_status": 16,
    "ea_domain_id": 22,
    "ea_user_id": 67,
    "ea_name": "z",
    "sort": "architecto",
    "per_page": 22,
    "page": 67
};

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

Example response (401):

Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
 

{
    "message": "Unauthenticated.",
    "error": "AUTH_REQUIRED"
}
 

Request      

GET api/integrations/econt

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

Body Parameters

ea_status   integer  optional    

Example: 16

ea_domain_id   integer  optional    

Must be at least 1. Example: 22

ea_user_id   integer  optional    

Must be at least 1. Example: 67

ea_name   string  optional    

Must not be greater than 190 characters. Example: z

sort   string  optional    

Example: architecto

per_page   integer  optional    

Must be at least 1. Must not be greater than 250. Example: 22

page   integer  optional    

Must be at least 1. Example: 67

POST api/integrations/econt

requires authentication

Example request:
curl --request POST \
    "https://localhost/api/integrations/econt" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "https://localhost/api/integrations/econt"
);

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

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

Request      

POST api/integrations/econt

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

GET api/integrations/econt/{id}

requires authentication

Example request:
curl --request GET \
    --get "https://localhost/api/integrations/econt/architecto" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "https://localhost/api/integrations/econt/architecto"
);

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

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

Example response (401):

Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
 

{
    "message": "Unauthenticated.",
    "error": "AUTH_REQUIRED"
}
 

Request      

GET api/integrations/econt/{id}

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

id   string     

The ID of the econt. Example: architecto

PUT api/integrations/econt/{id}

requires authentication

Example request:
curl --request PUT \
    "https://localhost/api/integrations/econt/architecto" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "https://localhost/api/integrations/econt/architecto"
);

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

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

Request      

PUT api/integrations/econt/{id}

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

id   string     

The ID of the econt. Example: architecto

DELETE api/integrations/econt/{id}

requires authentication

Example request:
curl --request DELETE \
    "https://localhost/api/integrations/econt/architecto" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "https://localhost/api/integrations/econt/architecto"
);

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

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

Request      

DELETE api/integrations/econt/{id}

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

id   string     

The ID of the econt. Example: architecto

Интеграции Speedy

API для управления подключениями к Speedy REST API v1.

В ответах sa_password не возвращается. Для заказов используйте source_id в формате speedy-{sa_id}, он передается в ds.ods_source_id.

GET api/integrations/speedy

requires authentication

Example request:
curl --request GET \
    --get "https://localhost/api/integrations/speedy" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"sa_status\": 16,
    \"sa_domain_id\": 22,
    \"sa_user_id\": 67,
    \"sa_name\": \"z\",
    \"sort\": \"architecto\",
    \"per_page\": 22,
    \"page\": 67
}"
const url = new URL(
    "https://localhost/api/integrations/speedy"
);

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

let body = {
    "sa_status": 16,
    "sa_domain_id": 22,
    "sa_user_id": 67,
    "sa_name": "z",
    "sort": "architecto",
    "per_page": 22,
    "page": 67
};

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

Example response (401):

Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
 

{
    "message": "Unauthenticated.",
    "error": "AUTH_REQUIRED"
}
 

Request      

GET api/integrations/speedy

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

Body Parameters

sa_status   integer  optional    

Example: 16

sa_domain_id   integer  optional    

Must be at least 1. Example: 22

sa_user_id   integer  optional    

Must be at least 1. Example: 67

sa_name   string  optional    

Must not be greater than 190 characters. Example: z

sort   string  optional    

Example: architecto

per_page   integer  optional    

Must be at least 1. Must not be greater than 250. Example: 22

page   integer  optional    

Must be at least 1. Example: 67

POST api/integrations/speedy

requires authentication

Example request:
curl --request POST \
    "https://localhost/api/integrations/speedy" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "https://localhost/api/integrations/speedy"
);

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

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

Request      

POST api/integrations/speedy

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

GET api/integrations/speedy/{id}

requires authentication

Example request:
curl --request GET \
    --get "https://localhost/api/integrations/speedy/architecto" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "https://localhost/api/integrations/speedy/architecto"
);

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

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

Example response (401):

Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
 

{
    "message": "Unauthenticated.",
    "error": "AUTH_REQUIRED"
}
 

Request      

GET api/integrations/speedy/{id}

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

id   string     

The ID of the speedy. Example: architecto

PUT api/integrations/speedy/{id}

requires authentication

Example request:
curl --request PUT \
    "https://localhost/api/integrations/speedy/architecto" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "https://localhost/api/integrations/speedy/architecto"
);

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

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

Request      

PUT api/integrations/speedy/{id}

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

id   string     

The ID of the speedy. Example: architecto

DELETE api/integrations/speedy/{id}

requires authentication

Example request:
curl --request DELETE \
    "https://localhost/api/integrations/speedy/architecto" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "https://localhost/api/integrations/speedy/architecto"
);

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

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

Request      

DELETE api/integrations/speedy/{id}

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

id   string     

The ID of the speedy. Example: architecto