MENU navbar-image

Introduction

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

Authenticating requests

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

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

You can retrieve your token by visiting your dashboard and clicking Tokens in API menu.

API V1 - Couriers

Couriers Endpoints

GET Allowed Couriers and SubAccounts

requires authentication

List all allowed couriers and their sub accounts, if exists.

Throttling: Max 60 requests per minute. (60/1)

Example request:
$client = new \GuzzleHttp\Client();
$url = 'https://clients.metrica.bg/api/v1/connectors/client/couriers/allowed';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_TOKEN}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://clients.metrica.bg/api/v1/connectors/client/couriers/allowed"
);

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

fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());
curl --request GET \
    --get "https://clients.metrica.bg/api/v1/connectors/client/couriers/allowed" \
    --header "Authorization: Bearer {YOUR_AUTH_TOKEN}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
import requests
import json

url = 'https://clients.metrica.bg/api/v1/connectors/client/couriers/allowed'
headers = {
  'Authorization': 'Bearer {YOUR_AUTH_TOKEN}',
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}

response = requests.request('GET', url, headers=headers)
response.json()

Example response (200):

Show headers
cache-control: no-cache, private
content-type: application/json
x-ratelimit-limit: 60
x-ratelimit-remaining: 59
access-control-allow-origin: *
 

{
    "data": {
        "allowedCouriers": [
            {
                "id": 18,
                "description": "Pickup from Warehouse",
                "hasSubAccounts": false
            },
            {
                "id": 113,
                "description": "BoxNow",
                "hasSubAccounts": false
            }
        ]
    },
    "success": true
}
 

Request      

GET api/v1/connectors/client/couriers/allowed

Headers

Authorization      

Example: Bearer {YOUR_AUTH_TOKEN}

Content-Type      

Example: application/json

Accept      

Example: application/json

API V1 - Entries

Entries Endpoints

GET All Entries

requires authentication

List all product entries.

Throttling: Max 40 requests per minute. (40/1)

Presents the result with page size and pagination.

Default page size : 200 records per page.

Example request:
$client = new \GuzzleHttp\Client();
$url = 'https://clients.metrica.bg/api/v1/connectors/client/entries';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_TOKEN}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'query' => [
            'page' => '1',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://clients.metrica.bg/api/v1/connectors/client/entries"
);

const params = {
    "page": "1",
};
Object.keys(params)
    .forEach(key => url.searchParams.append(key, params[key]));

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

fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());
curl --request GET \
    --get "https://clients.metrica.bg/api/v1/connectors/client/entries?page=1" \
    --header "Authorization: Bearer {YOUR_AUTH_TOKEN}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
import requests
import json

url = 'https://clients.metrica.bg/api/v1/connectors/client/entries'
params = {
  'page': '1',
}
headers = {
  'Authorization': 'Bearer {YOUR_AUTH_TOKEN}',
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}

response = requests.request('GET', url, headers=headers, params=params)
response.json()

Example response (200):

Show headers
cache-control: no-cache, private
content-type: application/json
x-ratelimit-limit: 40
x-ratelimit-remaining: 39
access-control-allow-origin: *
 

{
    "data": [
        {
            "entryId": 287302,
            "entryDate": "2023-09-29",
            "isReturnedOrder": false,
            "deliveryNote": "Test14092023",
            "moreInfo": "",
            "quantity": 6,
            "productInfo": {
                "productId": 9,
                "description": "Produs TestClient 8Produs TestClient 8Produs TestClient 8",
                "pictureUrl": "",
                "productCode": "prodtestclient8",
                "ean": "zang8",
                "externalId": 10008,
                "price": "0.00",
                "VATPercentage": 0,
                "WEEETax": "0.00",
                "weight": null,
                "productType": "Normal",
                "expirationType": "0",
                "expirationTypeDescription": "Normal",
                "useDefaultExpiryOnReception": false,
                "generalType": null,
                "condition": "GOOD",
                "invoiceExternalIdentifier": null,
                "externalSource": null,
                "externalSourceProductId": null,
                "hasSerialNumber": false,
                "createdAt": null,
                "updatedAt": null
            }
        },
        {
            "entryId": 287303,
            "entryDate": "2023-09-29",
            "isReturnedOrder": false,
            "deliveryNote": "Test14092023",
            "moreInfo": "",
            "quantity": 1,
            "productInfo": {
                "productId": 10,
                "description": "Produs TestClient 9",
                "pictureUrl": "",
                "productCode": "prodtestclient9",
                "ean": "zang9",
                "externalId": 10009,
                "price": "0.00",
                "VATPercentage": 0,
                "WEEETax": "0.00",
                "weight": null,
                "productType": "Normal",
                "expirationType": "0",
                "expirationTypeDescription": "Normal",
                "useDefaultExpiryOnReception": false,
                "generalType": null,
                "condition": "GOOD",
                "invoiceExternalIdentifier": null,
                "externalSource": null,
                "externalSourceProductId": null,
                "hasSerialNumber": false,
                "createdAt": null,
                "updatedAt": null
            }
        },
        {
            "entryId": 289514,
            "entryDate": "2023-11-01",
            "isReturnedOrder": false,
            "deliveryNote": "test 3",
            "moreInfo": "",
            "quantity": 1,
            "productInfo": {
                "productId": 28160,
                "description": "Test Fast print orders",
                "pictureUrl": "",
                "productCode": "NewTest",
                "ean": "5896545632104",
                "externalId": 0,
                "price": "0.00",
                "VATPercentage": 0,
                "WEEETax": "0.00",
                "weight": 0,
                "productType": "Normal",
                "expirationType": "0",
                "expirationTypeDescription": "Normal",
                "useDefaultExpiryOnReception": false,
                "generalType": null,
                "condition": "GOOD",
                "invoiceExternalIdentifier": null,
                "externalSource": null,
                "externalSourceProductId": null,
                "hasSerialNumber": false,
                "createdAt": "2023-11-01T09:37:35.000000Z",
                "updatedAt": "2023-11-01T09:37:35.000000Z"
            }
        },
        {
            "entryId": 291697,
            "entryDate": "2023-11-17",
            "isReturnedOrder": false,
            "deliveryNote": "test entry",
            "moreInfo": "",
            "quantity": 5,
            "productInfo": {
                "productId": 2,
                "description": "\"Produs TestClient 1",
                "pictureUrl": "https://www.youtube.com/test/123/",
                "productCode": "prodtestclient1",
                "ean": "zang1",
                "externalId": 10001,
                "price": "0.00",
                "VATPercentage": 0,
                "WEEETax": "0.00",
                "weight": 25000,
                "productType": "Normal",
                "expirationType": "0",
                "expirationTypeDescription": "Normal",
                "useDefaultExpiryOnReception": false,
                "generalType": null,
                "condition": "GOOD",
                "invoiceExternalIdentifier": null,
                "externalSource": null,
                "externalSourceProductId": null,
                "hasSerialNumber": false,
                "createdAt": null,
                "updatedAt": null
            }
        },
        {
            "entryId": 348775,
            "entryDate": "2024-11-11",
            "isReturnedOrder": false,
            "deliveryNote": "11112024test",
            "moreInfo": "",
            "quantity": 1,
            "productInfo": {
                "productId": 17,
                "description": "Produs TestClient 16",
                "pictureUrl": "",
                "productCode": "prodtestclient16",
                "ean": "zang16",
                "externalId": 10016,
                "price": "0.00",
                "VATPercentage": 0,
                "WEEETax": "0.00",
                "weight": null,
                "productType": "Normal",
                "expirationType": "0",
                "expirationTypeDescription": "Normal",
                "useDefaultExpiryOnReception": false,
                "generalType": null,
                "condition": "GOOD",
                "invoiceExternalIdentifier": null,
                "externalSource": null,
                "externalSourceProductId": null,
                "hasSerialNumber": false,
                "createdAt": null,
                "updatedAt": null
            }
        },
        {
            "entryId": 378680,
            "entryDate": "2025-03-06",
            "isReturnedOrder": false,
            "deliveryNote": "test",
            "moreInfo": "",
            "quantity": 3,
            "productInfo": {
                "productId": 86352,
                "description": "BAGSO 2",
                "pictureUrl": "https://clients.mercoria.com/uploads/images/products/16/45250-1-20221122_113025698_ios_webp.webp",
                "productCode": "97554",
                "ean": "12377AS",
                "externalId": 45250,
                "price": "0.00",
                "VATPercentage": 0,
                "WEEETax": "0.00",
                "weight": 0,
                "productType": "Normal",
                "expirationType": "0",
                "expirationTypeDescription": "Normal",
                "useDefaultExpiryOnReception": false,
                "generalType": null,
                "condition": "GOOD",
                "invoiceExternalIdentifier": null,
                "externalSource": null,
                "externalSourceProductId": null,
                "hasSerialNumber": false,
                "createdAt": null,
                "updatedAt": null
            }
        }
    ],
    "links": {
        "first": "https://clients.metrica.bg/api/v1/connectors/client/entries?page=1",
        "last": "https://clients.metrica.bg/api/v1/connectors/client/entries?page=1",
        "prev": null,
        "next": null
    },
    "meta": {
        "current_page": 1,
        "from": 1,
        "last_page": 1,
        "links": [
            {
                "url": null,
                "label": "« Previous",
                "active": false
            },
            {
                "url": "https://clients.metrica.bg/api/v1/connectors/client/entries?page=1",
                "label": "1",
                "active": true
            },
            {
                "url": null,
                "label": "Next »",
                "active": false
            }
        ],
        "path": "https://clients.metrica.bg/api/v1/connectors/client/entries",
        "per_page": 200,
        "to": 6,
        "total": 6
    },
    "success": true
}
 

Request      

GET api/v1/connectors/client/entries

Headers

Authorization      

Example: Bearer {YOUR_AUTH_TOKEN}

Content-Type      

Example: application/json

Accept      

Example: application/json

Query Parameters

page   integer  optional  

Which page to show. Example: 1

GET Entries created today

requires authentication

List all entries that were created today

Presents the result with page size and pagination.

Throttling: Max 5 requests per minute. (5/1)

Default page size : 200 records per page.

Example request:
$client = new \GuzzleHttp\Client();
$url = 'https://clients.metrica.bg/api/v1/connectors/client/entries/createdToday';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_TOKEN}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'query' => [
            'page' => '1',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://clients.metrica.bg/api/v1/connectors/client/entries/createdToday"
);

const params = {
    "page": "1",
};
Object.keys(params)
    .forEach(key => url.searchParams.append(key, params[key]));

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

fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());
curl --request GET \
    --get "https://clients.metrica.bg/api/v1/connectors/client/entries/createdToday?page=1" \
    --header "Authorization: Bearer {YOUR_AUTH_TOKEN}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
import requests
import json

url = 'https://clients.metrica.bg/api/v1/connectors/client/entries/createdToday'
params = {
  'page': '1',
}
headers = {
  'Authorization': 'Bearer {YOUR_AUTH_TOKEN}',
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}

response = requests.request('GET', url, headers=headers, params=params)
response.json()

Example response (200):

Show headers
cache-control: no-cache, private
content-type: application/json
x-ratelimit-limit: 5
x-ratelimit-remaining: 4
access-control-allow-origin: *
 

{
    "data": [],
    "links": {
        "first": "https://clients.metrica.bg/api/v1/connectors/client/entries/createdToday?page=1",
        "last": "https://clients.metrica.bg/api/v1/connectors/client/entries/createdToday?page=1",
        "prev": null,
        "next": null
    },
    "meta": {
        "current_page": 1,
        "from": null,
        "last_page": 1,
        "links": [
            {
                "url": null,
                "label": "« Previous",
                "active": false
            },
            {
                "url": "https://clients.metrica.bg/api/v1/connectors/client/entries/createdToday?page=1",
                "label": "1",
                "active": true
            },
            {
                "url": null,
                "label": "Next »",
                "active": false
            }
        ],
        "path": "https://clients.metrica.bg/api/v1/connectors/client/entries/createdToday",
        "per_page": 200,
        "to": null,
        "total": 0
    },
    "success": true
}
 

Request      

GET api/v1/connectors/client/entries/createdToday

Headers

Authorization      

Example: Bearer {YOUR_AUTH_TOKEN}

Content-Type      

Example: application/json

Accept      

Example: application/json

Query Parameters

page   integer  optional  

Which page to show. Example: 1

GET Returned Entries

requires authentication

List sumOf product entries from returned orders, grouped by products and orders

Throttling: Max 20 requests per minute. (20/1)

Presents the result with page size and pagination.

Default page size : 200 records per page.

Example request:
$client = new \GuzzleHttp\Client();
$url = 'https://clients.metrica.bg/api/v1/connectors/client/entries/returns/sumOfQty';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_TOKEN}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'query' => [
            'page' => '1',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://clients.metrica.bg/api/v1/connectors/client/entries/returns/sumOfQty"
);

const params = {
    "page": "1",
};
Object.keys(params)
    .forEach(key => url.searchParams.append(key, params[key]));

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

fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());
curl --request GET \
    --get "https://clients.metrica.bg/api/v1/connectors/client/entries/returns/sumOfQty?page=1" \
    --header "Authorization: Bearer {YOUR_AUTH_TOKEN}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
import requests
import json

url = 'https://clients.metrica.bg/api/v1/connectors/client/entries/returns/sumOfQty'
params = {
  'page': '1',
}
headers = {
  'Authorization': 'Bearer {YOUR_AUTH_TOKEN}',
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}

response = requests.request('GET', url, headers=headers, params=params)
response.json()

Example response (200):

Show headers
cache-control: no-cache, private
content-type: application/json
x-ratelimit-limit: 20
x-ratelimit-remaining: 19
access-control-allow-origin: *
 

{
    "data": [],
    "links": {
        "first": "https://clients.metrica.bg/api/v1/connectors/client/entries/returns/sumOfQty?page=1",
        "last": "https://clients.metrica.bg/api/v1/connectors/client/entries/returns/sumOfQty?page=1",
        "prev": null,
        "next": null
    },
    "meta": {
        "current_page": 1,
        "from": null,
        "last_page": 1,
        "links": [
            {
                "url": null,
                "label": "« Previous",
                "active": false
            },
            {
                "url": "https://clients.metrica.bg/api/v1/connectors/client/entries/returns/sumOfQty?page=1",
                "label": "1",
                "active": true
            },
            {
                "url": null,
                "label": "Next »",
                "active": false
            }
        ],
        "path": "https://clients.metrica.bg/api/v1/connectors/client/entries/returns/sumOfQty",
        "per_page": 200,
        "to": null,
        "total": 0
    },
    "success": true
}
 

Request      

GET api/v1/connectors/client/entries/returns/sumOfQty

Headers

Authorization      

Example: Bearer {YOUR_AUTH_TOKEN}

Content-Type      

Example: application/json

Accept      

Example: application/json

Query Parameters

page   integer  optional  

Which page to show. Example: 1

GET Import Entries

requires authentication

List sumOf product entries from imports, grouped by products and imports

Throttling: Max 20 requests per minute. (20/1)

Presents the result with page size and pagination.

Default page size : 200 records per page.

Example request:
$client = new \GuzzleHttp\Client();
$url = 'https://clients.metrica.bg/api/v1/connectors/client/entries/imports/sumOfQty';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_TOKEN}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'query' => [
            'page' => '1',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://clients.metrica.bg/api/v1/connectors/client/entries/imports/sumOfQty"
);

const params = {
    "page": "1",
};
Object.keys(params)
    .forEach(key => url.searchParams.append(key, params[key]));

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

fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());
curl --request GET \
    --get "https://clients.metrica.bg/api/v1/connectors/client/entries/imports/sumOfQty?page=1" \
    --header "Authorization: Bearer {YOUR_AUTH_TOKEN}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
import requests
import json

url = 'https://clients.metrica.bg/api/v1/connectors/client/entries/imports/sumOfQty'
params = {
  'page': '1',
}
headers = {
  'Authorization': 'Bearer {YOUR_AUTH_TOKEN}',
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}

response = requests.request('GET', url, headers=headers, params=params)
response.json()

Example response (200):

Show headers
cache-control: no-cache, private
content-type: application/json
x-ratelimit-limit: 20
x-ratelimit-remaining: 19
access-control-allow-origin: *
 

{
    "data": [
        {
            "entryDate": "2025-03-06",
            "sumOfQuantity": 3,
            "isReturnedOrder": false,
            "deliveryNote": "test",
            "moreInfo": "",
            "productInfo": {
                "productId": 86352,
                "description": "BAGSO 2",
                "pictureUrl": "https://clients.mercoria.com/uploads/images/products/16/45250-1-20221122_113025698_ios_webp.webp",
                "productCode": "97554",
                "ean": "12377AS",
                "externalId": 45250,
                "price": "0.00",
                "VATPercentage": 0,
                "WEEETax": "0.00",
                "weight": 0,
                "productType": "Normal",
                "expirationType": "0",
                "expirationTypeDescription": "Normal",
                "useDefaultExpiryOnReception": false,
                "generalType": null,
                "condition": "GOOD",
                "invoiceExternalIdentifier": null,
                "externalSource": null,
                "externalSourceProductId": null,
                "hasSerialNumber": false,
                "createdAt": null,
                "updatedAt": null
            }
        },
        {
            "entryDate": "2024-11-11",
            "sumOfQuantity": 1,
            "isReturnedOrder": false,
            "deliveryNote": "11112024test",
            "moreInfo": "",
            "productInfo": {
                "productId": 17,
                "description": "Produs TestClient 16",
                "pictureUrl": "",
                "productCode": "prodtestclient16",
                "ean": "zang16",
                "externalId": 10016,
                "price": "0.00",
                "VATPercentage": 0,
                "WEEETax": "0.00",
                "weight": null,
                "productType": "Normal",
                "expirationType": "0",
                "expirationTypeDescription": "Normal",
                "useDefaultExpiryOnReception": false,
                "generalType": null,
                "condition": "GOOD",
                "invoiceExternalIdentifier": null,
                "externalSource": null,
                "externalSourceProductId": null,
                "hasSerialNumber": false,
                "createdAt": null,
                "updatedAt": null
            }
        },
        {
            "entryDate": "2023-11-17",
            "sumOfQuantity": 5,
            "isReturnedOrder": false,
            "deliveryNote": "test entry",
            "moreInfo": "",
            "productInfo": {
                "productId": 2,
                "description": "\"Produs TestClient 1",
                "pictureUrl": "https://www.youtube.com/test/123/",
                "productCode": "prodtestclient1",
                "ean": "zang1",
                "externalId": 10001,
                "price": "0.00",
                "VATPercentage": 0,
                "WEEETax": "0.00",
                "weight": 25000,
                "productType": "Normal",
                "expirationType": "0",
                "expirationTypeDescription": "Normal",
                "useDefaultExpiryOnReception": false,
                "generalType": null,
                "condition": "GOOD",
                "invoiceExternalIdentifier": null,
                "externalSource": null,
                "externalSourceProductId": null,
                "hasSerialNumber": false,
                "createdAt": null,
                "updatedAt": null
            }
        },
        {
            "entryDate": "2023-11-01",
            "sumOfQuantity": 1,
            "isReturnedOrder": false,
            "deliveryNote": "test 3",
            "moreInfo": "",
            "productInfo": {
                "productId": 28160,
                "description": "Test Fast print orders",
                "pictureUrl": "",
                "productCode": "NewTest",
                "ean": "5896545632104",
                "externalId": 0,
                "price": "0.00",
                "VATPercentage": 0,
                "WEEETax": "0.00",
                "weight": 0,
                "productType": "Normal",
                "expirationType": "0",
                "expirationTypeDescription": "Normal",
                "useDefaultExpiryOnReception": false,
                "generalType": null,
                "condition": "GOOD",
                "invoiceExternalIdentifier": null,
                "externalSource": null,
                "externalSourceProductId": null,
                "hasSerialNumber": false,
                "createdAt": "2023-11-01T09:37:35.000000Z",
                "updatedAt": "2023-11-01T09:37:35.000000Z"
            }
        },
        {
            "entryDate": "2023-09-29",
            "sumOfQuantity": 1,
            "isReturnedOrder": false,
            "deliveryNote": "Test14092023",
            "moreInfo": "",
            "productInfo": {
                "productId": 10,
                "description": "Produs TestClient 9",
                "pictureUrl": "",
                "productCode": "prodtestclient9",
                "ean": "zang9",
                "externalId": 10009,
                "price": "0.00",
                "VATPercentage": 0,
                "WEEETax": "0.00",
                "weight": null,
                "productType": "Normal",
                "expirationType": "0",
                "expirationTypeDescription": "Normal",
                "useDefaultExpiryOnReception": false,
                "generalType": null,
                "condition": "GOOD",
                "invoiceExternalIdentifier": null,
                "externalSource": null,
                "externalSourceProductId": null,
                "hasSerialNumber": false,
                "createdAt": null,
                "updatedAt": null
            }
        },
        {
            "entryDate": "2023-09-29",
            "sumOfQuantity": 6,
            "isReturnedOrder": false,
            "deliveryNote": "Test14092023",
            "moreInfo": "",
            "productInfo": {
                "productId": 9,
                "description": "Produs TestClient 8Produs TestClient 8Produs TestClient 8",
                "pictureUrl": "",
                "productCode": "prodtestclient8",
                "ean": "zang8",
                "externalId": 10008,
                "price": "0.00",
                "VATPercentage": 0,
                "WEEETax": "0.00",
                "weight": null,
                "productType": "Normal",
                "expirationType": "0",
                "expirationTypeDescription": "Normal",
                "useDefaultExpiryOnReception": false,
                "generalType": null,
                "condition": "GOOD",
                "invoiceExternalIdentifier": null,
                "externalSource": null,
                "externalSourceProductId": null,
                "hasSerialNumber": false,
                "createdAt": null,
                "updatedAt": null
            }
        }
    ],
    "links": {
        "first": "https://clients.metrica.bg/api/v1/connectors/client/entries/imports/sumOfQty?page=1",
        "last": "https://clients.metrica.bg/api/v1/connectors/client/entries/imports/sumOfQty?page=1",
        "prev": null,
        "next": null
    },
    "meta": {
        "current_page": 1,
        "from": 1,
        "last_page": 1,
        "links": [
            {
                "url": null,
                "label": "« Previous",
                "active": false
            },
            {
                "url": "https://clients.metrica.bg/api/v1/connectors/client/entries/imports/sumOfQty?page=1",
                "label": "1",
                "active": true
            },
            {
                "url": null,
                "label": "Next »",
                "active": false
            }
        ],
        "path": "https://clients.metrica.bg/api/v1/connectors/client/entries/imports/sumOfQty",
        "per_page": 200,
        "to": 6,
        "total": 6
    },
    "success": true
}
 

Request      

GET api/v1/connectors/client/entries/imports/sumOfQty

Headers

Authorization      

Example: Bearer {YOUR_AUTH_TOKEN}

Content-Type      

Example: application/json

Accept      

Example: application/json

Query Parameters

page   integer  optional  

Which page to show. Example: 1

API V1 - Orders

Orders Endpoints

GET All Orders

requires authentication

List all orders.

Throttling: Max 5 requests per minute. (5/1) Max 20 requests per hour. (20/60)

Presents the result with page size and simple pagination (without showing the total number of records and last page).

Default page size : 500 records per page. The ordering is newest orders first.

Example request:
$client = new \GuzzleHttp\Client();
$url = 'https://clients.metrica.bg/api/v1/connectors/client/orders';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_TOKEN}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'query' => [
            'page' => '1',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://clients.metrica.bg/api/v1/connectors/client/orders"
);

const params = {
    "page": "1",
};
Object.keys(params)
    .forEach(key => url.searchParams.append(key, params[key]));

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

fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());
curl --request GET \
    --get "https://clients.metrica.bg/api/v1/connectors/client/orders?page=1" \
    --header "Authorization: Bearer {YOUR_AUTH_TOKEN}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
import requests
import json

url = 'https://clients.metrica.bg/api/v1/connectors/client/orders'
params = {
  'page': '1',
}
headers = {
  'Authorization': 'Bearer {YOUR_AUTH_TOKEN}',
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}

response = requests.request('GET', url, headers=headers, params=params)
response.json()

Example response (200):

Show headers
cache-control: no-cache, private
content-type: application/json
x-ratelimit-limit: 5
x-ratelimit-remaining: 4
access-control-allow-origin: *
 

{
    "data": [
        {
            "orderId": 531017,
            "externalId": "MHMR153155O7bY",
            "entryDate": "2025-05-29 15:31:55",
            "prefDate": "2025-05-29",
            "sentDate": null,
            "companyName": null,
            "companyUniqueIdentifier": "",
            "companyRegistrationNumber": null,
            "contactPerson": "Metrica",
            "address": "божурище",
            "streetId": null,
            "cityId": null,
            "city": "Румен",
            "county": "Bozhurishte",
            "country": "Bulgaria",
            "postalCode": "",
            "contactPhone": "0882444366",
            "contactEmail": "",
            "lockerDeliveryIdentifier": null,
            "cashOnDelivery": "0",
            "declaredValueAmount": "0",
            "declaredValueAmountCurrency": null,
            "warehouseRemarks": "",
            "shippingInstructions": "",
            "courier": "selfpickup",
            "courierSubAccount": "",
            "awbNumber": null,
            "multipleAWBNumbers": null,
            "courierShipmentNumber": null,
            "multipleCourierShipmentNumbers": null,
            "shippedParcels": 0,
            "courierStatus": "",
            "courierStatusId": 0,
            "invoiceUrl": null,
            "awbUrl": null,
            "deliveryNoteUrl": null,
            "status": "Locked",
            "isReturned": false,
            "returnedDate": "0000-00-00",
            "returnStatus": null,
            "externalSource": "Metrica",
            "externalSourceOrderId": "MHMR153155O7bY",
            "tags": null,
            "products": [
                {
                    "productId": 86352,
                    "quantity": 3,
                    "isReturned": false,
                    "returnedDate": "0000-00-00",
                    "price": 0,
                    "productInfo": {
                        "productId": 86352,
                        "description": "BAGSO 2",
                        "pictureUrl": "https://clients.mercoria.com/uploads/images/products/16/45250-1-20221122_113025698_ios_webp.webp",
                        "productCode": "97554",
                        "ean": "12377AS",
                        "externalId": 45250,
                        "price": "0.00",
                        "VATPercentage": 0,
                        "WEEETax": "0.00",
                        "weight": 0,
                        "productType": "Normal",
                        "expirationType": "0",
                        "expirationTypeDescription": "Normal",
                        "useDefaultExpiryOnReception": false,
                        "generalType": null,
                        "condition": "GOOD",
                        "invoiceExternalIdentifier": null,
                        "externalSource": null,
                        "externalSourceProductId": null,
                        "hasSerialNumber": false,
                        "createdAt": null,
                        "updatedAt": null
                    }
                }
            ]
        },
        {
            "orderId": 530034,
            "externalId": "MHMF1535183nBV",
            "entryDate": "2025-05-28 15:35:18",
            "prefDate": "2025-05-28",
            "sentDate": "2025-05-29 15:28:54",
            "companyName": "",
            "companyUniqueIdentifier": "",
            "companyRegistrationNumber": null,
            "contactPerson": "Тест",
            "address": "Симеон Петров 19",
            "streetId": null,
            "cityId": null,
            "city": "Божурище",
            "county": "Божурище",
            "country": "BG",
            "postalCode": "",
            "contactPhone": "0888112233",
            "contactEmail": "",
            "lockerDeliveryIdentifier": null,
            "cashOnDelivery": "0",
            "declaredValueAmount": "0",
            "declaredValueAmountCurrency": null,
            "warehouseRemarks": "",
            "shippingInstructions": "",
            "courier": "selfpickup",
            "courierSubAccount": "",
            "awbNumber": "",
            "multipleAWBNumbers": null,
            "courierShipmentNumber": null,
            "multipleCourierShipmentNumbers": null,
            "shippedParcels": 2,
            "courierStatus": "",
            "courierStatusId": 0,
            "invoiceUrl": null,
            "awbUrl": null,
            "deliveryNoteUrl": null,
            "status": "Sent",
            "isReturned": false,
            "returnedDate": "0000-00-00",
            "returnStatus": null,
            "externalSource": "Metrica",
            "externalSourceOrderId": "MHMF1535183nBV",
            "tags": null,
            "products": [
                {
                    "productId": 9,
                    "quantity": 2,
                    "isReturned": false,
                    "returnedDate": "0000-00-00",
                    "price": 0,
                    "productInfo": {
                        "productId": 9,
                        "description": "Produs TestClient 8Produs TestClient 8Produs TestClient 8",
                        "pictureUrl": "",
                        "productCode": "prodtestclient8",
                        "ean": "zang8",
                        "externalId": 10008,
                        "price": "0.00",
                        "VATPercentage": 0,
                        "WEEETax": "0.00",
                        "weight": null,
                        "productType": "Normal",
                        "expirationType": "0",
                        "expirationTypeDescription": "Normal",
                        "useDefaultExpiryOnReception": false,
                        "generalType": null,
                        "condition": "GOOD",
                        "invoiceExternalIdentifier": null,
                        "externalSource": null,
                        "externalSourceProductId": null,
                        "hasSerialNumber": false,
                        "createdAt": null,
                        "updatedAt": null
                    }
                }
            ]
        },
        {
            "orderId": 530019,
            "externalId": "MHMF151814bptj",
            "entryDate": "2025-05-28 15:18:14",
            "prefDate": "2025-05-28",
            "sentDate": null,
            "companyName": null,
            "companyUniqueIdentifier": "",
            "companyRegistrationNumber": null,
            "contactPerson": "Metrica",
            "address": "божурище",
            "streetId": null,
            "cityId": null,
            "city": "Божурище",
            "county": "Bozhurishte",
            "country": "Bulgaria",
            "postalCode": "",
            "contactPhone": "0882444366",
            "contactEmail": "",
            "lockerDeliveryIdentifier": null,
            "cashOnDelivery": "0",
            "declaredValueAmount": "0",
            "declaredValueAmountCurrency": null,
            "warehouseRemarks": "",
            "shippingInstructions": "",
            "courier": "selfpickup",
            "courierSubAccount": "",
            "awbNumber": "",
            "multipleAWBNumbers": null,
            "courierShipmentNumber": null,
            "multipleCourierShipmentNumbers": null,
            "shippedParcels": 0,
            "courierStatus": "",
            "courierStatusId": 0,
            "invoiceUrl": null,
            "awbUrl": null,
            "deliveryNoteUrl": null,
            "status": "Locked",
            "isReturned": false,
            "returnedDate": "0000-00-00",
            "returnStatus": null,
            "externalSource": "Metrica",
            "externalSourceOrderId": "MHMF151814bptj",
            "tags": null,
            "products": [
                {
                    "productId": 86352,
                    "quantity": 3,
                    "isReturned": false,
                    "returnedDate": "0000-00-00",
                    "price": 0,
                    "productInfo": {
                        "productId": 86352,
                        "description": "BAGSO 2",
                        "pictureUrl": "https://clients.mercoria.com/uploads/images/products/16/45250-1-20221122_113025698_ios_webp.webp",
                        "productCode": "97554",
                        "ean": "12377AS",
                        "externalId": 45250,
                        "price": "0.00",
                        "VATPercentage": 0,
                        "WEEETax": "0.00",
                        "weight": 0,
                        "productType": "Normal",
                        "expirationType": "0",
                        "expirationTypeDescription": "Normal",
                        "useDefaultExpiryOnReception": false,
                        "generalType": null,
                        "condition": "GOOD",
                        "invoiceExternalIdentifier": null,
                        "externalSource": null,
                        "externalSourceProductId": null,
                        "hasSerialNumber": false,
                        "createdAt": null,
                        "updatedAt": null
                    }
                }
            ]
        },
        {
            "orderId": 453691,
            "externalId": "MHMF115107dxk0",
            "entryDate": "2025-03-06 11:51:07",
            "prefDate": "2025-03-06",
            "sentDate": null,
            "companyName": null,
            "companyUniqueIdentifier": "",
            "companyRegistrationNumber": null,
            "contactPerson": "Kristyan Dilovski TEST",
            "address": "Sofia Vrajdebna 41 N:22a",
            "streetId": null,
            "cityId": null,
            "city": "Sofia (1000)",
            "county": "Bulgaria",
            "country": "Bulgaria",
            "postalCode": "1839",
            "contactPhone": "0896755950",
            "contactEmail": "ymcmb1611@gmail.com",
            "lockerDeliveryIdentifier": null,
            "cashOnDelivery": "0",
            "declaredValueAmount": "0",
            "declaredValueAmountCurrency": null,
            "warehouseRemarks": "",
            "shippingInstructions": "",
            "courier": "boxnow",
            "courierSubAccount": "",
            "awbNumber": "4532902907",
            "multipleAWBNumbers": null,
            "courierShipmentNumber": null,
            "multipleCourierShipmentNumbers": null,
            "shippedParcels": 0,
            "courierStatus": "",
            "courierStatusId": 0,
            "invoiceUrl": null,
            "awbUrl": "",
            "deliveryNoteUrl": null,
            "status": "Processing",
            "isReturned": false,
            "returnedDate": "0000-00-00",
            "returnStatus": null,
            "externalSource": "Metrica",
            "externalSourceOrderId": "MHMF115107dxk0",
            "tags": null,
            "products": [
                {
                    "productId": 86352,
                    "quantity": 1,
                    "isReturned": false,
                    "returnedDate": "0000-00-00",
                    "price": 0,
                    "productInfo": {
                        "productId": 86352,
                        "description": "BAGSO 2",
                        "pictureUrl": "https://clients.mercoria.com/uploads/images/products/16/45250-1-20221122_113025698_ios_webp.webp",
                        "productCode": "97554",
                        "ean": "12377AS",
                        "externalId": 45250,
                        "price": "0.00",
                        "VATPercentage": 0,
                        "WEEETax": "0.00",
                        "weight": 0,
                        "productType": "Normal",
                        "expirationType": "0",
                        "expirationTypeDescription": "Normal",
                        "useDefaultExpiryOnReception": false,
                        "generalType": null,
                        "condition": "GOOD",
                        "invoiceExternalIdentifier": null,
                        "externalSource": null,
                        "externalSourceProductId": null,
                        "hasSerialNumber": false,
                        "createdAt": null,
                        "updatedAt": null
                    }
                }
            ]
        },
        {
            "orderId": 414293,
            "externalId": "40098",
            "entryDate": "2025-01-20 12:34:16",
            "prefDate": "2025-01-20",
            "sentDate": null,
            "companyName": null,
            "companyUniqueIdentifier": "",
            "companyRegistrationNumber": null,
            "contactPerson": "Tihomir Sokolov МЕРКОРИЯ",
            "address": "33, Bakston blvd.",
            "streetId": 0,
            "cityId": null,
            "city": "София",
            "county": "София",
            "country": "BG",
            "postalCode": "1000",
            "contactPhone": "0899196290",
            "contactEmail": "tihomir.sokolov@gmail.com",
            "lockerDeliveryIdentifier": null,
            "cashOnDelivery": "0",
            "declaredValueAmount": "0",
            "declaredValueAmountCurrency": null,
            "warehouseRemarks": " ",
            "shippingInstructions": "тест ТТ",
            "courier": "speedy",
            "courierSubAccount": null,
            "awbNumber": "",
            "multipleAWBNumbers": null,
            "courierShipmentNumber": null,
            "multipleCourierShipmentNumbers": null,
            "shippedParcels": 0,
            "courierStatus": "",
            "courierStatusId": 0,
            "invoiceUrl": "",
            "awbUrl": "",
            "deliveryNoteUrl": null,
            "status": "Sent",
            "isReturned": false,
            "returnedDate": "0000-00-00",
            "returnStatus": null,
            "externalSource": null,
            "externalSourceOrderId": null,
            "tags": null,
            "products": [
                {
                    "productId": 1,
                    "quantity": 4,
                    "isReturned": false,
                    "returnedDate": "0000-00-00",
                    "price": 0,
                    "productInfo": {
                        "productId": 1,
                        "description": "Produs neregasit in BD - Comanda incompleta",
                        "pictureUrl": "",
                        "productCode": "",
                        "ean": "",
                        "externalId": -1,
                        "price": "0.00",
                        "VATPercentage": 0,
                        "WEEETax": "0.00",
                        "weight": null,
                        "productType": "Normal",
                        "expirationType": "0",
                        "expirationTypeDescription": "Normal",
                        "useDefaultExpiryOnReception": false,
                        "generalType": null,
                        "condition": "GOOD",
                        "invoiceExternalIdentifier": null,
                        "externalSource": null,
                        "externalSourceProductId": null,
                        "hasSerialNumber": false,
                        "createdAt": null,
                        "updatedAt": null
                    }
                }
            ]
        },
        {
            "orderId": 409454,
            "externalId": "39410",
            "entryDate": "2025-01-13 10:13:43",
            "prefDate": "2025-01-13",
            "sentDate": null,
            "companyName": null,
            "companyUniqueIdentifier": "",
            "companyRegistrationNumber": null,
            "contactPerson": "Valival Test",
            "address": "Спиди, До офис, гр. АЙТОС [8500] ул. КИРИЛ И МЕТОДИЙ No 17 Бърза поръчка",
            "streetId": 0,
            "cityId": null,
            "city": "АЙТОС",
            "county": "АЙТОС",
            "country": "RO",
            "postalCode": "8500",
            "contactPhone": "0123465789",
            "contactEmail": "test@valival.com",
            "lockerDeliveryIdentifier": null,
            "cashOnDelivery": "0",
            "declaredValueAmount": "0",
            "declaredValueAmountCurrency": null,
            "warehouseRemarks": " ",
            "shippingInstructions": "",
            "courier": "speedyapi",
            "courierSubAccount": null,
            "awbNumber": "",
            "multipleAWBNumbers": null,
            "courierShipmentNumber": null,
            "multipleCourierShipmentNumbers": null,
            "shippedParcels": 0,
            "courierStatus": "",
            "courierStatusId": 0,
            "invoiceUrl": "",
            "awbUrl": "",
            "deliveryNoteUrl": null,
            "status": "Locked",
            "isReturned": false,
            "returnedDate": "0000-00-00",
            "returnStatus": null,
            "externalSource": null,
            "externalSourceOrderId": null,
            "tags": null,
            "products": [
                {
                    "productId": 1,
                    "quantity": 1,
                    "isReturned": false,
                    "returnedDate": "0000-00-00",
                    "price": 0,
                    "productInfo": {
                        "productId": 1,
                        "description": "Produs neregasit in BD - Comanda incompleta",
                        "pictureUrl": "",
                        "productCode": "",
                        "ean": "",
                        "externalId": -1,
                        "price": "0.00",
                        "VATPercentage": 0,
                        "WEEETax": "0.00",
                        "weight": null,
                        "productType": "Normal",
                        "expirationType": "0",
                        "expirationTypeDescription": "Normal",
                        "useDefaultExpiryOnReception": false,
                        "generalType": null,
                        "condition": "GOOD",
                        "invoiceExternalIdentifier": null,
                        "externalSource": null,
                        "externalSourceProductId": null,
                        "hasSerialNumber": false,
                        "createdAt": null,
                        "updatedAt": null
                    }
                }
            ]
        },
        {
            "orderId": 354021,
            "externalId": "MHMF101325371H",
            "entryDate": "2024-11-11 10:13:25",
            "prefDate": "2024-11-11",
            "sentDate": null,
            "companyName": null,
            "companyUniqueIdentifier": "",
            "companyRegistrationNumber": null,
            "contactPerson": "Kristina IVanova",
            "address": "ул. Обелско шосе 7",
            "streetId": null,
            "cityId": null,
            "city": "София",
            "county": "bg",
            "country": "Bulgaria",
            "postalCode": "1360",
            "contactPhone": "0895444645",
            "contactEmail": "ecommerce@mediaposthitmail.bg",
            "lockerDeliveryIdentifier": null,
            "cashOnDelivery": "0",
            "declaredValueAmount": "0",
            "declaredValueAmountCurrency": null,
            "warehouseRemarks": "",
            "shippingInstructions": "",
            "courier": "boxnow",
            "courierSubAccount": "",
            "awbNumber": "",
            "multipleAWBNumbers": null,
            "courierShipmentNumber": null,
            "multipleCourierShipmentNumbers": null,
            "shippedParcels": 0,
            "courierStatus": "",
            "courierStatusId": 0,
            "invoiceUrl": null,
            "awbUrl": null,
            "deliveryNoteUrl": null,
            "status": "Processing",
            "isReturned": false,
            "returnedDate": "0000-00-00",
            "returnStatus": null,
            "externalSource": "Metrica",
            "externalSourceOrderId": "MHMF101325371H",
            "tags": null,
            "products": [
                {
                    "productId": 28160,
                    "quantity": 1,
                    "isReturned": false,
                    "returnedDate": "0000-00-00",
                    "price": 0,
                    "productInfo": {
                        "productId": 28160,
                        "description": "Test Fast print orders",
                        "pictureUrl": "",
                        "productCode": "NewTest",
                        "ean": "5896545632104",
                        "externalId": 0,
                        "price": "0.00",
                        "VATPercentage": 0,
                        "WEEETax": "0.00",
                        "weight": 0,
                        "productType": "Normal",
                        "expirationType": "0",
                        "expirationTypeDescription": "Normal",
                        "useDefaultExpiryOnReception": false,
                        "generalType": null,
                        "condition": "GOOD",
                        "invoiceExternalIdentifier": null,
                        "externalSource": null,
                        "externalSourceProductId": null,
                        "hasSerialNumber": false,
                        "createdAt": "2023-11-01T09:37:35.000000Z",
                        "updatedAt": "2023-11-01T09:37:35.000000Z"
                    }
                }
            ]
        },
        {
            "orderId": 86496,
            "externalId": "MHMF1159224j0f",
            "entryDate": "2023-11-01 11:59:22",
            "prefDate": "2023-11-01",
            "sentDate": "2023-11-06 16:23:35",
            "companyName": null,
            "companyUniqueIdentifier": "",
            "companyRegistrationNumber": null,
            "contactPerson": "test fast print",
            "address": "божурище",
            "streetId": null,
            "cityId": null,
            "city": "божурище",
            "county": "bg",
            "country": "Bulgaria",
            "postalCode": "2225",
            "contactPhone": "+359889902261",
            "contactEmail": "",
            "lockerDeliveryIdentifier": null,
            "cashOnDelivery": "0",
            "declaredValueAmount": "0",
            "declaredValueAmountCurrency": null,
            "warehouseRemarks": "",
            "shippingInstructions": "",
            "courier": "selfpickup",
            "courierSubAccount": "",
            "awbNumber": "",
            "multipleAWBNumbers": null,
            "courierShipmentNumber": null,
            "multipleCourierShipmentNumbers": null,
            "shippedParcels": 1,
            "courierStatus": "",
            "courierStatusId": 0,
            "invoiceUrl": null,
            "awbUrl": null,
            "deliveryNoteUrl": null,
            "status": "Sent",
            "isReturned": false,
            "returnedDate": "0000-00-00",
            "returnStatus": null,
            "externalSource": null,
            "externalSourceOrderId": null,
            "tags": null,
            "products": [
                {
                    "productId": 28160,
                    "quantity": 1,
                    "isReturned": false,
                    "returnedDate": "0000-00-00",
                    "price": 0,
                    "productInfo": {
                        "productId": 28160,
                        "description": "Test Fast print orders",
                        "pictureUrl": "",
                        "productCode": "NewTest",
                        "ean": "5896545632104",
                        "externalId": 0,
                        "price": "0.00",
                        "VATPercentage": 0,
                        "WEEETax": "0.00",
                        "weight": 0,
                        "productType": "Normal",
                        "expirationType": "0",
                        "expirationTypeDescription": "Normal",
                        "useDefaultExpiryOnReception": false,
                        "generalType": null,
                        "condition": "GOOD",
                        "invoiceExternalIdentifier": null,
                        "externalSource": null,
                        "externalSourceProductId": null,
                        "hasSerialNumber": false,
                        "createdAt": "2023-11-01T09:37:35.000000Z",
                        "updatedAt": "2023-11-01T09:37:35.000000Z"
                    }
                }
            ]
        }
    ],
    "links": {
        "first": "https://clients.metrica.bg/api/v1/connectors/client/orders?page=1",
        "last": null,
        "prev": null,
        "next": null
    },
    "meta": {
        "current_page": 1,
        "from": 1,
        "path": "https://clients.metrica.bg/api/v1/connectors/client/orders",
        "per_page": 500,
        "to": 8
    },
    "success": true
}
 

Request      

GET api/v1/connectors/client/orders

Headers

Authorization      

Example: Bearer {YOUR_AUTH_TOKEN}

Content-Type      

Example: application/json

Accept      

Example: application/json

Query Parameters

page   integer  optional  

Which page to show. Example: 1

GET Filtered Orders

requires authentication

List all orders that match filters.

Throttling: Max 5 requests per minute. (5/1) Max 20 requests per hour. (20/60)

Presents the result with page size and pagination.

Default page size : 250 records per page. (Maximum 500)

Example request:
$client = new \GuzzleHttp\Client();
$url = 'https://clients.metrica.bg/api/v1/connectors/client/orders/filter';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_TOKEN}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'query' => [
            'page' => '1',
        ],
        'json' => [
            'ids' => '3234201,3234202',
            'external_ids' => 'MHMF134018SHNi,MHMF134018SH12',
            'startDate' => '2024-01-01 12:59:59',
            'endDate' => '2024-12-22 19:30:00',
            'dateFilterBy' => 'CREATED_AT',
            'sortDate' => 'ASC',
            'status' => 'InProcessing,Sent',
            'customerName' => 'ContactPerson3',
            'customerPhone' => '0700112233',
            'isReturned' => false,
            'withCashOnDelivery' => '0',
            'perPage' => 250,
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://clients.metrica.bg/api/v1/connectors/client/orders/filter"
);

const params = {
    "page": "1",
};
Object.keys(params)
    .forEach(key => url.searchParams.append(key, params[key]));

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

let body = {
    "ids": "3234201,3234202",
    "external_ids": "MHMF134018SHNi,MHMF134018SH12",
    "startDate": "2024-01-01 12:59:59",
    "endDate": "2024-12-22 19:30:00",
    "dateFilterBy": "CREATED_AT",
    "sortDate": "ASC",
    "status": "InProcessing,Sent",
    "customerName": "ContactPerson3",
    "customerPhone": "0700112233",
    "isReturned": false,
    "withCashOnDelivery": "0",
    "perPage": 250
};

fetch(url, {
    method: "GET",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());
curl --request GET \
    --get "https://clients.metrica.bg/api/v1/connectors/client/orders/filter?page=1" \
    --header "Authorization: Bearer {YOUR_AUTH_TOKEN}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"ids\": \"3234201,3234202\",
    \"external_ids\": \"MHMF134018SHNi,MHMF134018SH12\",
    \"startDate\": \"2024-01-01 12:59:59\",
    \"endDate\": \"2024-12-22 19:30:00\",
    \"dateFilterBy\": \"CREATED_AT\",
    \"sortDate\": \"ASC\",
    \"status\": \"InProcessing,Sent\",
    \"customerName\": \"ContactPerson3\",
    \"customerPhone\": \"0700112233\",
    \"isReturned\": false,
    \"withCashOnDelivery\": \"0\",
    \"perPage\": 250
}"
import requests
import json

url = 'https://clients.metrica.bg/api/v1/connectors/client/orders/filter'
payload = {
    "ids": "3234201,3234202",
    "external_ids": "MHMF134018SHNi,MHMF134018SH12",
    "startDate": "2024-01-01 12:59:59",
    "endDate": "2024-12-22 19:30:00",
    "dateFilterBy": "CREATED_AT",
    "sortDate": "ASC",
    "status": "InProcessing,Sent",
    "customerName": "ContactPerson3",
    "customerPhone": "0700112233",
    "isReturned": false,
    "withCashOnDelivery": "0",
    "perPage": 250
}
params = {
  'page': '1',
}
headers = {
  'Authorization': 'Bearer {YOUR_AUTH_TOKEN}',
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}

response = requests.request('GET', url, headers=headers, json=payload, params=params)
response.json()

Example response (200):

Show headers
cache-control: no-cache, private
content-type: application/json
x-ratelimit-limit: 5
x-ratelimit-remaining: 4
access-control-allow-origin: *
 

{
    "data": [],
    "links": {
        "first": "https://clients.metrica.bg/api/v1/connectors/client/orders/filter?page=1",
        "last": "https://clients.metrica.bg/api/v1/connectors/client/orders/filter?page=1",
        "prev": null,
        "next": null
    },
    "meta": {
        "current_page": 1,
        "from": null,
        "last_page": 1,
        "links": [
            {
                "url": null,
                "label": "« Previous",
                "active": false
            },
            {
                "url": "https://clients.metrica.bg/api/v1/connectors/client/orders/filter?page=1",
                "label": "1",
                "active": true
            },
            {
                "url": null,
                "label": "Next »",
                "active": false
            }
        ],
        "path": "https://clients.metrica.bg/api/v1/connectors/client/orders/filter",
        "per_page": 250,
        "to": null,
        "total": 0
    },
    "success": true
}
 

Request      

GET api/v1/connectors/client/orders/filter

Headers

Authorization      

Example: Bearer {YOUR_AUTH_TOKEN}

Content-Type      

Example: application/json

Accept      

Example: application/json

Query Parameters

page   integer  optional  

Which page to show. Example: 1

Body Parameters

ids   string  optional  

List of comma-separated Order IDs. Example: 3234201,3234202

external_ids   string  optional  

List of comma-separated Order external IDs. Example: MHMF134018SHNi,MHMF134018SH12

startDate   date  optional  

A date between past and today. The format must be in: Y-m-d H:i:s. Example: 2024-01-01 12:59:59

endDate   date  optional  

A date between past and today. If there is a startDate, endDate must be later than startDate. The format must be in: Y-m-d H:i:s. Example: 2024-12-22 19:30:00

dateFilterBy   enum(CREATED_AT,UPDATED_AT,SHIPPED_AT,RETURNED_AT)  optional  

The column to which startDate and endDate are compared. - Default: CREATED_AT. Example: CREATED_AT

sortDate   enum(DESC,ASC)  optional  

Order in which to retrieve results. - default ASC Example: ASC

status   enum(Sent,Callcenter,InProcessing,NotReady,Locked)  optional  

Filter orders by their status specified by a comma-separated list. Example: InProcessing,Sent

shippingAWB   string  optional  

The AWB number.

customerName   string  optional  

The name of the customer. Example: ContactPerson3

customerPhone   string  optional  

The customer's phone number. Example: 0700112233

isReturned   boolean  optional  

A filter that will select only orders that are returned or not returned. Example: false

withCashOnDelivery   boolean/int/string  optional  

A filter that will select only the orders with or without cash on delivery. Accepted inputs are true, false, 1, 0, "1", and "0". Example: 0

perPage   integer  optional  

Number of entries per page. The allowed values are between 10 and 500. If not provided, the default is 250. Example: 250

POST Filter Orders by Date

requires authentication

Returns a list with the orders filtered by the date of entry, the shipping date or the returned date.

Throttling: Max 20 requests per minute. (20/1)

Presents the result with page size and pagination.

Example request:
$client = new \GuzzleHttp\Client();
$url = 'https://clients.metrica.bg/api/v1/connectors/client/orders/filterByDate';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_TOKEN}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'query' => [
            'page' => '1',
        ],
        'json' => [
            'filterBy' => 'entryDate',
            'fromDate' => '2020-01-01',
            'perPage' => 100,
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://clients.metrica.bg/api/v1/connectors/client/orders/filterByDate"
);

const params = {
    "page": "1",
};
Object.keys(params)
    .forEach(key => url.searchParams.append(key, params[key]));

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

let body = {
    "filterBy": "entryDate",
    "fromDate": "2020-01-01",
    "perPage": 100
};

fetch(url, {
    method: "POST",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());
curl --request POST \
    "https://clients.metrica.bg/api/v1/connectors/client/orders/filterByDate?page=1" \
    --header "Authorization: Bearer {YOUR_AUTH_TOKEN}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"filterBy\": \"entryDate\",
    \"fromDate\": \"2020-01-01\",
    \"perPage\": 100
}"
import requests
import json

url = 'https://clients.metrica.bg/api/v1/connectors/client/orders/filterByDate'
payload = {
    "filterBy": "entryDate",
    "fromDate": "2020-01-01",
    "perPage": 100
}
params = {
  'page': '1',
}
headers = {
  'Authorization': 'Bearer {YOUR_AUTH_TOKEN}',
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}

response = requests.request('POST', url, headers=headers, json=payload, params=params)
response.json()

Request      

POST api/v1/connectors/client/orders/filterByDate

Headers

Authorization      

Example: Bearer {YOUR_AUTH_TOKEN}

Content-Type      

Example: application/json

Accept      

Example: application/json

Query Parameters

page   integer  optional  

Which page to show. Example: 1

Body Parameters

filterBy   string   

The filterBy field accepts only the following values: entryDate, shippingDate, returnedDate. Example: entryDate

fromDate   date   

A date in the past that is applied to the chosen filter. The date must be older than today and not older than 62 days from today. The format must be in: yyyy-mm-dd Example: 2020-01-01

perPage   integer   

Number of orders to show per page. The allowed values are between 10 and 500. Example: 100

POST Filter Orders by Date Intervals

requires authentication

Returns a list with the orders between two dates. The result can be filtered by the date of entry, the shipping date or the returned date.

Throttling: Max 20 requests per minute. (20/1)

Presents the result with page size and pagination.

Example request:
$client = new \GuzzleHttp\Client();
$url = 'https://clients.metrica.bg/api/v1/connectors/client/orders/filterByDateIntervals';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_TOKEN}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'query' => [
            'page' => '1',
        ],
        'json' => [
            'filterBy' => 'entryDate',
            'startDate' => '2024-01-01',
            'endDate' => '2024-01-31',
            'withCashOnDelivery' => false,
            'perPage' => 100,
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://clients.metrica.bg/api/v1/connectors/client/orders/filterByDateIntervals"
);

const params = {
    "page": "1",
};
Object.keys(params)
    .forEach(key => url.searchParams.append(key, params[key]));

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

let body = {
    "filterBy": "entryDate",
    "startDate": "2024-01-01",
    "endDate": "2024-01-31",
    "withCashOnDelivery": false,
    "perPage": 100
};

fetch(url, {
    method: "POST",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());
curl --request POST \
    "https://clients.metrica.bg/api/v1/connectors/client/orders/filterByDateIntervals?page=1" \
    --header "Authorization: Bearer {YOUR_AUTH_TOKEN}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"filterBy\": \"entryDate\",
    \"startDate\": \"2024-01-01\",
    \"endDate\": \"2024-01-31\",
    \"withCashOnDelivery\": false,
    \"perPage\": 100
}"
import requests
import json

url = 'https://clients.metrica.bg/api/v1/connectors/client/orders/filterByDateIntervals'
payload = {
    "filterBy": "entryDate",
    "startDate": "2024-01-01",
    "endDate": "2024-01-31",
    "withCashOnDelivery": false,
    "perPage": 100
}
params = {
  'page': '1',
}
headers = {
  'Authorization': 'Bearer {YOUR_AUTH_TOKEN}',
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}

response = requests.request('POST', url, headers=headers, json=payload, params=params)
response.json()

Request      

POST api/v1/connectors/client/orders/filterByDateIntervals

Headers

Authorization      

Example: Bearer {YOUR_AUTH_TOKEN}

Content-Type      

Example: application/json

Accept      

Example: application/json

Query Parameters

page   integer  optional  

Which page to show. Example: 1

Body Parameters

filterBy   string   

The filterBy field accepts only the following values: entryDate, shippingDate, returnedDate. Example: entryDate

startDate   date   

A date between past and today. The format must be in: yyyy-mm-dd Example: 2024-01-01

endDate   date   

A date between past and today. The date must later or equal to startDate and not later than 62 days. The format must be in: yyyy-mm-dd Example: 2024-01-31

withCashOnDelivery   boolean  optional  

A filter that will select only the orders with or without cash on delivery. Accepted input are true, false, 1, 0, "1", and "0". Example: false

perPage   integer   

Number of orders per page. The allowed values are between 10 and 500. Example: 100

POST Filter Orders by Status

requires authentication

List the orders in our system filtering by the order status

Throttling: Max 20 requests per minute. (20/1)

Presents the result with page size and pagination.

Example request:
$client = new \GuzzleHttp\Client();
$url = 'https://clients.metrica.bg/api/v1/connectors/client/orders/filterByStatus';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_TOKEN}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'query' => [
            'page' => '1',
        ],
        'json' => [
            'status' => 'Shipped',
            'perPage' => 100,
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://clients.metrica.bg/api/v1/connectors/client/orders/filterByStatus"
);

const params = {
    "page": "1",
};
Object.keys(params)
    .forEach(key => url.searchParams.append(key, params[key]));

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

let body = {
    "status": "Shipped",
    "perPage": 100
};

fetch(url, {
    method: "POST",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());
curl --request POST \
    "https://clients.metrica.bg/api/v1/connectors/client/orders/filterByStatus?page=1" \
    --header "Authorization: Bearer {YOUR_AUTH_TOKEN}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"status\": \"Shipped\",
    \"perPage\": 100
}"
import requests
import json

url = 'https://clients.metrica.bg/api/v1/connectors/client/orders/filterByStatus'
payload = {
    "status": "Shipped",
    "perPage": 100
}
params = {
  'page': '1',
}
headers = {
  'Authorization': 'Bearer {YOUR_AUTH_TOKEN}',
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}

response = requests.request('POST', url, headers=headers, json=payload, params=params)
response.json()

Request      

POST api/v1/connectors/client/orders/filterByStatus

Headers

Authorization      

Example: Bearer {YOUR_AUTH_TOKEN}

Content-Type      

Example: application/json

Accept      

Example: application/json

Query Parameters

page   integer  optional  

Which page to show. Example: 1

Body Parameters

status   string   

The status field accepts only the following values: Locked, Callcenter, NotReady, Processing, Shipped, NotShipped. Example: Shipped

perPage   integer   

Number of orders to show per page. The allowed values are between 10 and 500. Example: 100

GET Today latest updated orders

requires authentication

Retrieve a list of today's latest updated orders.

Throttling: Max 1 request per 10 minutes. (1/10)

Example request:
$client = new \GuzzleHttp\Client();
$url = 'https://clients.metrica.bg/api/v1/connectors/client/orders/todayLatestUpdated';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_TOKEN}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://clients.metrica.bg/api/v1/connectors/client/orders/todayLatestUpdated"
);

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

fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());
curl --request GET \
    --get "https://clients.metrica.bg/api/v1/connectors/client/orders/todayLatestUpdated" \
    --header "Authorization: Bearer {YOUR_AUTH_TOKEN}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
import requests
import json

url = 'https://clients.metrica.bg/api/v1/connectors/client/orders/todayLatestUpdated'
headers = {
  'Authorization': 'Bearer {YOUR_AUTH_TOKEN}',
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}

response = requests.request('GET', url, headers=headers)
response.json()

Example response (429):

Show headers
cache-control: no-cache, private
content-type: application/json
x-ratelimit-limit: 400
x-ratelimit-remaining: 338
access-control-allow-origin: *
 

{
    "success": false,
    "error": {
        "message": "Too Many Attempts.",
        "code": 429
    }
}
 

Request      

GET api/v1/connectors/client/orders/todayLatestUpdated

Headers

Authorization      

Example: Bearer {YOUR_AUTH_TOKEN}

Content-Type      

Example: application/json

Accept      

Example: application/json

GET Order By ID

requires authentication

Get Order information by internal ID.

Throttling: Max 60 requests per minute. (60/1)

Example request:
$client = new \GuzzleHttp\Client();
$url = 'https://clients.metrica.bg/api/v1/connectors/client/orders/byId/3234201';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_TOKEN}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://clients.metrica.bg/api/v1/connectors/client/orders/byId/3234201"
);

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

fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());
curl --request GET \
    --get "https://clients.metrica.bg/api/v1/connectors/client/orders/byId/3234201" \
    --header "Authorization: Bearer {YOUR_AUTH_TOKEN}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
import requests
import json

url = 'https://clients.metrica.bg/api/v1/connectors/client/orders/byId/3234201'
headers = {
  'Authorization': 'Bearer {YOUR_AUTH_TOKEN}',
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}

response = requests.request('GET', url, headers=headers)
response.json()

Example response (404):


{
    "success": false,
    "error": {
        "message": "Entry for OrderItem not found",
        "code": 404
    }
}
 

Example response (404):

Show headers
cache-control: no-cache, private
content-type: application/json
x-ratelimit-limit: 60
x-ratelimit-remaining: 59
access-control-allow-origin: *
 

{
    "success": false,
    "error": {
        "message": "Entry for OrderItem not found",
        "code": 404
    }
}
 

Request      

GET api/v1/connectors/client/orders/byId/{orderId}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_TOKEN}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

orderId   integer   

The order ID. Example: 3234201

GET Order By External ID

requires authentication

Get Order information by external ID.

Throttling: Max 60 requests per minute. (60/1)

Example request:
$client = new \GuzzleHttp\Client();
$url = 'https://clients.metrica.bg/api/v1/connectors/client/orders/byExternalId/MHMF1338580SQl';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_TOKEN}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://clients.metrica.bg/api/v1/connectors/client/orders/byExternalId/MHMF1338580SQl"
);

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

fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());
curl --request GET \
    --get "https://clients.metrica.bg/api/v1/connectors/client/orders/byExternalId/MHMF1338580SQl" \
    --header "Authorization: Bearer {YOUR_AUTH_TOKEN}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
import requests
import json

url = 'https://clients.metrica.bg/api/v1/connectors/client/orders/byExternalId/MHMF1338580SQl'
headers = {
  'Authorization': 'Bearer {YOUR_AUTH_TOKEN}',
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}

response = requests.request('GET', url, headers=headers)
response.json()

Example response (404):


{
    "success": false,
    "error": {
        "message": "Entry for OrderItem not found",
        "code": 404
    }
}
 

Example response (404):

Show headers
cache-control: no-cache, private
content-type: application/json
x-ratelimit-limit: 60
x-ratelimit-remaining: 59
access-control-allow-origin: *
 

{
    "success": false,
    "error": {
        "message": "Entry for OrderItem not found",
        "code": 404
    }
}
 

Request      

GET api/v1/connectors/client/orders/byExternalId/{externalId}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_TOKEN}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

externalId   string   

The order external ID. Example: MHMF1338580SQl

GET Order By AWB

requires authentication

Get Order information by AWB Number.

Throttling: Max 60 requests per minute. (60/1)

Example request:
$client = new \GuzzleHttp\Client();
$url = 'https://clients.metrica.bg/api/v1/connectors/client/orders/byAwb/AWBNO9923';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_TOKEN}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://clients.metrica.bg/api/v1/connectors/client/orders/byAwb/AWBNO9923"
);

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

fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());
curl --request GET \
    --get "https://clients.metrica.bg/api/v1/connectors/client/orders/byAwb/AWBNO9923" \
    --header "Authorization: Bearer {YOUR_AUTH_TOKEN}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
import requests
import json

url = 'https://clients.metrica.bg/api/v1/connectors/client/orders/byAwb/AWBNO9923'
headers = {
  'Authorization': 'Bearer {YOUR_AUTH_TOKEN}',
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}

response = requests.request('GET', url, headers=headers)
response.json()

Example response (404):


{
    "success": false,
    "error": {
        "message": "Entry for OrderItem not found",
        "code": 404
    }
}
 

Example response (404):

Show headers
cache-control: no-cache, private
content-type: application/json
x-ratelimit-limit: 60
x-ratelimit-remaining: 59
access-control-allow-origin: *
 

{
    "success": false,
    "error": {
        "message": "Entry for OrderItem not found",
        "code": 404
    }
}
 

Request      

GET api/v1/connectors/client/orders/byAwb/{awb}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_TOKEN}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

awb   string  optional  

alphaNum required The order AWB Number. Example: AWBNO9923

GET Order By External Source Order ID

requires authentication

Get Order information by external source order ID.

Throttling: Max 60 requests per minute. (60/1)

Example request:
$client = new \GuzzleHttp\Client();
$url = 'https://clients.metrica.bg/api/v1/connectors/client/orders/byExternalSourceOrderId/SID323';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_TOKEN}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://clients.metrica.bg/api/v1/connectors/client/orders/byExternalSourceOrderId/SID323"
);

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

fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());
curl --request GET \
    --get "https://clients.metrica.bg/api/v1/connectors/client/orders/byExternalSourceOrderId/SID323" \
    --header "Authorization: Bearer {YOUR_AUTH_TOKEN}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
import requests
import json

url = 'https://clients.metrica.bg/api/v1/connectors/client/orders/byExternalSourceOrderId/SID323'
headers = {
  'Authorization': 'Bearer {YOUR_AUTH_TOKEN}',
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}

response = requests.request('GET', url, headers=headers)
response.json()

Example response (404):


{
    "success": false,
    "error": {
        "message": "Entry for OrderItem not found",
        "code": 404
    }
}
 

Example response (404):

Show headers
cache-control: no-cache, private
content-type: application/json
x-ratelimit-limit: 60
x-ratelimit-remaining: 59
access-control-allow-origin: *
 

{
    "success": false,
    "error": {
        "message": "Entry for OrderItem not found",
        "code": 404
    }
}
 

Request      

GET api/v1/connectors/client/orders/byExternalSourceOrderId/{externalSourceOrderId}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_TOKEN}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

externalSourceOrderId   string  optional  

alphaNum required The order externalSourceOrderId. Example: SID323

GET Shipped Orders With Expiry Dates

requires authentication

Returns a list with the shipped orders and a field named shippedExpiryDates for each product that contains a list with the quantity of each date/batch. The expiryDate and batch fields will be null if the productType is Normal. The orders are sorted DESC by the shipped date.

Throttling: Max 10 requests per minute. (10/1)

Presents the result with page size and pagination.

Example request:
$client = new \GuzzleHttp\Client();
$url = 'https://clients.metrica.bg/api/v1/connectors/client/orders/shipped/with/expiryDates';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_TOKEN}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://clients.metrica.bg/api/v1/connectors/client/orders/shipped/with/expiryDates"
);

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

fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());
curl --request GET \
    --get "https://clients.metrica.bg/api/v1/connectors/client/orders/shipped/with/expiryDates" \
    --header "Authorization: Bearer {YOUR_AUTH_TOKEN}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
import requests
import json

url = 'https://clients.metrica.bg/api/v1/connectors/client/orders/shipped/with/expiryDates'
headers = {
  'Authorization': 'Bearer {YOUR_AUTH_TOKEN}',
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}

response = requests.request('GET', url, headers=headers)
response.json()

Example response (200):

Show headers
cache-control: no-cache, private
content-type: application/json
x-ratelimit-limit: 10
x-ratelimit-remaining: 9
access-control-allow-origin: *
 

{
    "data": [
        {
            "orderId": 530034,
            "externalId": "MHMF1535183nBV",
            "entryDate": "2025-05-28 15:35:18",
            "prefDate": "2025-05-28",
            "sentDate": "2025-05-29 15:28:54",
            "companyName": "",
            "companyUniqueIdentifier": "",
            "companyRegistrationNumber": null,
            "contactPerson": "Тест",
            "address": "Симеон Петров 19",
            "streetId": null,
            "cityId": null,
            "city": "Божурище",
            "county": "Божурище",
            "country": "BG",
            "postalCode": "",
            "contactPhone": "0888112233",
            "contactEmail": "",
            "lockerDeliveryIdentifier": null,
            "cashOnDelivery": "0",
            "declaredValueAmount": "0",
            "declaredValueAmountCurrency": null,
            "warehouseRemarks": "",
            "shippingInstructions": "",
            "courier": "selfpickup",
            "courierSubAccount": "",
            "awbNumber": "",
            "multipleAWBNumbers": null,
            "courierShipmentNumber": null,
            "multipleCourierShipmentNumbers": null,
            "shippedParcels": 2,
            "courierStatus": "",
            "courierStatusId": 0,
            "invoiceUrl": null,
            "awbUrl": null,
            "deliveryNoteUrl": null,
            "status": "Sent",
            "isReturned": false,
            "returnedDate": "0000-00-00",
            "returnStatus": null,
            "externalSource": "Metrica",
            "externalSourceOrderId": "MHMF1535183nBV",
            "tags": null,
            "products": [
                {
                    "productId": 9,
                    "quantity": 2,
                    "isReturned": false,
                    "returnedDate": "0000-00-00",
                    "price": 0,
                    "productInfo": {
                        "productId": 9,
                        "description": "Produs TestClient 8Produs TestClient 8Produs TestClient 8",
                        "pictureUrl": "",
                        "productCode": "prodtestclient8",
                        "ean": "zang8",
                        "externalId": 10008,
                        "price": "0.00",
                        "VATPercentage": 0,
                        "WEEETax": "0.00",
                        "weight": null,
                        "productType": "Normal",
                        "expirationType": "0",
                        "expirationTypeDescription": "Normal",
                        "useDefaultExpiryOnReception": false,
                        "generalType": null,
                        "condition": "GOOD",
                        "invoiceExternalIdentifier": null,
                        "externalSource": null,
                        "externalSourceProductId": null,
                        "hasSerialNumber": false,
                        "createdAt": null,
                        "updatedAt": null
                    },
                    "shippedExpiryDates": [
                        {
                            "productId": 9,
                            "expiryDate": null,
                            "batch": null,
                            "quantity": 2
                        }
                    ]
                }
            ]
        },
        {
            "orderId": 86496,
            "externalId": "MHMF1159224j0f",
            "entryDate": "2023-11-01 11:59:22",
            "prefDate": "2023-11-01",
            "sentDate": "2023-11-06 16:23:35",
            "companyName": null,
            "companyUniqueIdentifier": "",
            "companyRegistrationNumber": null,
            "contactPerson": "test fast print",
            "address": "божурище",
            "streetId": null,
            "cityId": null,
            "city": "божурище",
            "county": "bg",
            "country": "Bulgaria",
            "postalCode": "2225",
            "contactPhone": "+359889902261",
            "contactEmail": "",
            "lockerDeliveryIdentifier": null,
            "cashOnDelivery": "0",
            "declaredValueAmount": "0",
            "declaredValueAmountCurrency": null,
            "warehouseRemarks": "",
            "shippingInstructions": "",
            "courier": "selfpickup",
            "courierSubAccount": "",
            "awbNumber": "",
            "multipleAWBNumbers": null,
            "courierShipmentNumber": null,
            "multipleCourierShipmentNumbers": null,
            "shippedParcels": 1,
            "courierStatus": "",
            "courierStatusId": 0,
            "invoiceUrl": null,
            "awbUrl": null,
            "deliveryNoteUrl": null,
            "status": "Sent",
            "isReturned": false,
            "returnedDate": "0000-00-00",
            "returnStatus": null,
            "externalSource": null,
            "externalSourceOrderId": null,
            "tags": null,
            "products": [
                {
                    "productId": 28160,
                    "quantity": 1,
                    "isReturned": false,
                    "returnedDate": "0000-00-00",
                    "price": 0,
                    "productInfo": {
                        "productId": 28160,
                        "description": "Test Fast print orders",
                        "pictureUrl": "",
                        "productCode": "NewTest",
                        "ean": "5896545632104",
                        "externalId": 0,
                        "price": "0.00",
                        "VATPercentage": 0,
                        "WEEETax": "0.00",
                        "weight": 0,
                        "productType": "Normal",
                        "expirationType": "0",
                        "expirationTypeDescription": "Normal",
                        "useDefaultExpiryOnReception": false,
                        "generalType": null,
                        "condition": "GOOD",
                        "invoiceExternalIdentifier": null,
                        "externalSource": null,
                        "externalSourceProductId": null,
                        "hasSerialNumber": false,
                        "createdAt": "2023-11-01T09:37:35.000000Z",
                        "updatedAt": "2023-11-01T09:37:35.000000Z"
                    },
                    "shippedExpiryDates": []
                }
            ]
        },
        {
            "orderId": 414293,
            "externalId": "40098",
            "entryDate": "2025-01-20 12:34:16",
            "prefDate": "2025-01-20",
            "sentDate": null,
            "companyName": null,
            "companyUniqueIdentifier": "",
            "companyRegistrationNumber": null,
            "contactPerson": "Tihomir Sokolov МЕРКОРИЯ",
            "address": "33, Bakston blvd.",
            "streetId": 0,
            "cityId": null,
            "city": "София",
            "county": "София",
            "country": "BG",
            "postalCode": "1000",
            "contactPhone": "0899196290",
            "contactEmail": "tihomir.sokolov@gmail.com",
            "lockerDeliveryIdentifier": null,
            "cashOnDelivery": "0",
            "declaredValueAmount": "0",
            "declaredValueAmountCurrency": null,
            "warehouseRemarks": " ",
            "shippingInstructions": "тест ТТ",
            "courier": "speedy",
            "courierSubAccount": null,
            "awbNumber": "",
            "multipleAWBNumbers": null,
            "courierShipmentNumber": null,
            "multipleCourierShipmentNumbers": null,
            "shippedParcels": 0,
            "courierStatus": "",
            "courierStatusId": 0,
            "invoiceUrl": "",
            "awbUrl": "",
            "deliveryNoteUrl": null,
            "status": "Sent",
            "isReturned": false,
            "returnedDate": "0000-00-00",
            "returnStatus": null,
            "externalSource": null,
            "externalSourceOrderId": null,
            "tags": null,
            "products": [
                {
                    "productId": 1,
                    "quantity": 4,
                    "isReturned": false,
                    "returnedDate": "0000-00-00",
                    "price": 0,
                    "productInfo": {
                        "productId": 1,
                        "description": "Produs neregasit in BD - Comanda incompleta",
                        "pictureUrl": "",
                        "productCode": "",
                        "ean": "",
                        "externalId": -1,
                        "price": "0.00",
                        "VATPercentage": 0,
                        "WEEETax": "0.00",
                        "weight": null,
                        "productType": "Normal",
                        "expirationType": "0",
                        "expirationTypeDescription": "Normal",
                        "useDefaultExpiryOnReception": false,
                        "generalType": null,
                        "condition": "GOOD",
                        "invoiceExternalIdentifier": null,
                        "externalSource": null,
                        "externalSourceProductId": null,
                        "hasSerialNumber": false,
                        "createdAt": null,
                        "updatedAt": null
                    },
                    "shippedExpiryDates": []
                }
            ]
        }
    ],
    "links": {
        "first": "https://clients.metrica.bg/api/v1/connectors/client/orders/shipped/with/expiryDates?page=1",
        "last": "https://clients.metrica.bg/api/v1/connectors/client/orders/shipped/with/expiryDates?page=1",
        "prev": null,
        "next": null
    },
    "meta": {
        "current_page": 1,
        "from": 1,
        "last_page": 1,
        "links": [
            {
                "url": null,
                "label": "« Previous",
                "active": false
            },
            {
                "url": "https://clients.metrica.bg/api/v1/connectors/client/orders/shipped/with/expiryDates?page=1",
                "label": "1",
                "active": true
            },
            {
                "url": null,
                "label": "Next »",
                "active": false
            }
        ],
        "path": "https://clients.metrica.bg/api/v1/connectors/client/orders/shipped/with/expiryDates",
        "per_page": 150,
        "to": 3,
        "total": 3
    },
    "success": true
}
 

Request      

GET api/v1/connectors/client/orders/shipped/with/expiryDates

Headers

Authorization      

Example: Bearer {YOUR_AUTH_TOKEN}

Content-Type      

Example: application/json

Accept      

Example: application/json

CREATE Order

requires authentication

Creates a new Order.

Throttling: Max 15 requests per minute. (15/1)

Example request:
$client = new \GuzzleHttp\Client();
$url = 'https://clients.metrica.bg/api/v1/connectors/client/orders/create';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_TOKEN}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'externalId' => 'ID123',
            'prefDate' => '2040-12-31',
            'address' => 'Str. My Street, No.10, Ap. 99',
            'streetId' => 995,
            'cityId' => 15,
            'city' => 'Bucuresti',
            'county' => 'Sector 1',
            'country' => 'RO',
            'postalCode' => '010111',
            'companyName' => 'Company SA',
            'companyUniqueIdentifier' => 'RO55599888',
            'companyRegistrationNumber' => 'J99/9999/1950',
            'contactPerson' => 'Contact Person',
            'contactPhone' => '0700999111',
            'contactEmail' => 'test@test.com',
            'cashOnDelivery' => '100.99',
            'declaredValueAmount' => '100.99',
            'warehouseRemarks' => 'voluptatem',
            'shippingInstructions' => 'molestias',
            'courierId' => 15,
            'courierSubAccountId' => 4,
            'awbUrl' => 'https://pathtomyawb.pdf',
            'invoiceUrl' => 'https://pathtomyinvoice.pdf',
            'deliveryNoteUrl' => 'https://pathtomydeliverynote.pdf',
            'maxKeepDays' => 365,
            'externalSource' => 'Shopify MyWebSite',
            'externalSourceOrderId' => 'AxZ00001',
            'awbNumber' => 'AWB001',
            'withPriority' => false,
            'saveAsLocked' => false,
            'lockerId' => '"5959"',
            'useOverriddenValidationRules' => false,
            'products' => [
                [
                    'id' => '184736',
                    'quantity' => 3,
                    'price' => 100.9999,
                ],
            ],
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://clients.metrica.bg/api/v1/connectors/client/orders/create"
);

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

let body = {
    "externalId": "ID123",
    "prefDate": "2040-12-31",
    "address": "Str. My Street, No.10, Ap. 99",
    "streetId": 995,
    "cityId": 15,
    "city": "Bucuresti",
    "county": "Sector 1",
    "country": "RO",
    "postalCode": "010111",
    "companyName": "Company SA",
    "companyUniqueIdentifier": "RO55599888",
    "companyRegistrationNumber": "J99\/9999\/1950",
    "contactPerson": "Contact Person",
    "contactPhone": "0700999111",
    "contactEmail": "test@test.com",
    "cashOnDelivery": "100.99",
    "declaredValueAmount": "100.99",
    "warehouseRemarks": "voluptatem",
    "shippingInstructions": "molestias",
    "courierId": 15,
    "courierSubAccountId": 4,
    "awbUrl": "https:\/\/pathtomyawb.pdf",
    "invoiceUrl": "https:\/\/pathtomyinvoice.pdf",
    "deliveryNoteUrl": "https:\/\/pathtomydeliverynote.pdf",
    "maxKeepDays": 365,
    "externalSource": "Shopify MyWebSite",
    "externalSourceOrderId": "AxZ00001",
    "awbNumber": "AWB001",
    "withPriority": false,
    "saveAsLocked": false,
    "lockerId": "\"5959\"",
    "useOverriddenValidationRules": false,
    "products": [
        {
            "id": "184736",
            "quantity": 3,
            "price": 100.9999
        }
    ]
};

fetch(url, {
    method: "POST",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());
curl --request POST \
    "https://clients.metrica.bg/api/v1/connectors/client/orders/create" \
    --header "Authorization: Bearer {YOUR_AUTH_TOKEN}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"externalId\": \"ID123\",
    \"prefDate\": \"2040-12-31\",
    \"address\": \"Str. My Street, No.10, Ap. 99\",
    \"streetId\": 995,
    \"cityId\": 15,
    \"city\": \"Bucuresti\",
    \"county\": \"Sector 1\",
    \"country\": \"RO\",
    \"postalCode\": \"010111\",
    \"companyName\": \"Company SA\",
    \"companyUniqueIdentifier\": \"RO55599888\",
    \"companyRegistrationNumber\": \"J99\\/9999\\/1950\",
    \"contactPerson\": \"Contact Person\",
    \"contactPhone\": \"0700999111\",
    \"contactEmail\": \"test@test.com\",
    \"cashOnDelivery\": \"100.99\",
    \"declaredValueAmount\": \"100.99\",
    \"warehouseRemarks\": \"voluptatem\",
    \"shippingInstructions\": \"molestias\",
    \"courierId\": 15,
    \"courierSubAccountId\": 4,
    \"awbUrl\": \"https:\\/\\/pathtomyawb.pdf\",
    \"invoiceUrl\": \"https:\\/\\/pathtomyinvoice.pdf\",
    \"deliveryNoteUrl\": \"https:\\/\\/pathtomydeliverynote.pdf\",
    \"maxKeepDays\": 365,
    \"externalSource\": \"Shopify MyWebSite\",
    \"externalSourceOrderId\": \"AxZ00001\",
    \"awbNumber\": \"AWB001\",
    \"withPriority\": false,
    \"saveAsLocked\": false,
    \"lockerId\": \"\\\"5959\\\"\",
    \"useOverriddenValidationRules\": false,
    \"products\": [
        {
            \"id\": \"184736\",
            \"quantity\": 3,
            \"price\": 100.9999
        }
    ]
}"
import requests
import json

url = 'https://clients.metrica.bg/api/v1/connectors/client/orders/create'
payload = {
    "externalId": "ID123",
    "prefDate": "2040-12-31",
    "address": "Str. My Street, No.10, Ap. 99",
    "streetId": 995,
    "cityId": 15,
    "city": "Bucuresti",
    "county": "Sector 1",
    "country": "RO",
    "postalCode": "010111",
    "companyName": "Company SA",
    "companyUniqueIdentifier": "RO55599888",
    "companyRegistrationNumber": "J99\/9999\/1950",
    "contactPerson": "Contact Person",
    "contactPhone": "0700999111",
    "contactEmail": "test@test.com",
    "cashOnDelivery": "100.99",
    "declaredValueAmount": "100.99",
    "warehouseRemarks": "voluptatem",
    "shippingInstructions": "molestias",
    "courierId": 15,
    "courierSubAccountId": 4,
    "awbUrl": "https:\/\/pathtomyawb.pdf",
    "invoiceUrl": "https:\/\/pathtomyinvoice.pdf",
    "deliveryNoteUrl": "https:\/\/pathtomydeliverynote.pdf",
    "maxKeepDays": 365,
    "externalSource": "Shopify MyWebSite",
    "externalSourceOrderId": "AxZ00001",
    "awbNumber": "AWB001",
    "withPriority": false,
    "saveAsLocked": false,
    "lockerId": "\"5959\"",
    "useOverriddenValidationRules": false,
    "products": [
        {
            "id": "184736",
            "quantity": 3,
            "price": 100.9999
        }
    ]
}
headers = {
  'Authorization': 'Bearer {YOUR_AUTH_TOKEN}',
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}

response = requests.request('POST', url, headers=headers, json=payload)
response.json()

Request      

POST api/v1/connectors/client/orders/create

Headers

Authorization      

Example: Bearer {YOUR_AUTH_TOKEN}

Content-Type      

Example: application/json

Accept      

Example: application/json

Body Parameters

externalId   string  optional  

sometimes The order external ID. Is generated automatically by us if not provided. To avoid order duplicates provide it from your source id field. Example: ID123

prefDate   date   

Preferred shipment date of the order. Use the current date if it does not exist. Example: 2040-12-31

address   string  optional  

requiredIf The recipient address. This field is required only if awbUrl field is empty. Example: Str. My Street, No.10, Ap. 99

streetId   integer  optional  

The recipient street id. Is usually used in some courier integrations. Example: 995

cityId   integer  optional  

requiredIf The recipient city id. This field is required only if the selected courier is EMAG (courierId 7). Is usually used in some courier integrations. Example: 15

city   string  optional  

requiredIf The recipient city. The field must have at least 1 character. This field is required only if awbUrl field is empty. Max 50 characters allowed. Example: Bucuresti

county   string  optional  

requiredIf The recipient county. The field must have at least 1 character. This field is required only if awbUrl field is empty. Max 50 characters allowed. Example: Sector 1

country   string  optional  

requiredIf The recipient country. The field must have min 2 characters. It is required if awbUrl field is empty. Between 2 and 50 characters allowed. Example: RO

postalCode   string  optional  

The recipient postal code. Max 10 characters allowed. Example: 010111

companyName   string  optional  

The recipient company name. Fill only if the shipment is B2B. Max 150 characters allowed. Example: Company SA

companyUniqueIdentifier   string  optional  

The recipient Company Unique Identifier (CUI/VAT). Fill only if the shipment is B2B. Max 20 characters allowed. Example: RO55599888

companyRegistrationNumber   string  optional  

The recipient company registration number. Fill only if the shipment is B2B. Max 100 characters allowed. Example: J99/9999/1950

contactPerson   string  optional  

requiredIf The recipient contact person. This field is required only if awbUrl field is empty. Max 200 characters allowed. Example: Contact Person

contactPhone   string  optional  

requiredIf The recipient contact person phone. This field is required only if awbUrl field is empty. The phone number must contain the correct number of digits (usually between 8-14) and the allowed characters between digits are: space, dash, dots or parenthesis. Example: 0700999111

contactEmail   email  optional  

requiredIf The recipient contact person email. It is required if the selected courier is DPD (courierId 3) and the country is not RO/Romania. Example: test@test.com

cashOnDelivery   numeric   

The shipment Cash On Delivery amount. The amount can have max 2 decimals. If the order does not have Cash On Delivery the field value must be 0. Example: 100.99

declaredValueAmount   numeric  optional  

The shipment declared value amount. The amount can have max 2 decimals. Example: 100.99

warehouseRemarks   sting  optional  

Info for the Warehouse operators. Example: voluptatem

shippingInstructions   sting  optional  

Info for the shipping courier. Example: molestias

courierId   integer   

The courier ID. Example: 15

courierSubAccountId   integer  optional  

The SubAccount courier ID. Example: 4

awbUrl   url  optional  

Url path to a pdf containing the order AWB. Max 250 characters allowed. Example: https://pathtomyawb.pdf

invoiceUrl   url  optional  

Url path to a pdf containing the order invoice. Max 250 characters allowed. Example: https://pathtomyinvoice.pdf

deliveryNoteUrl   url  optional  

Url path to a pdf containing the order delivery note. Max 250 characters allowed. Example: https://pathtomydeliverynote.pdf

maxKeepDays   integer   

Value between 0 and 365. Example: 365

externalSource   string  optional  

The name of the external source of the order. The value must start with a value from in External Source List endpoint result. Example: Shopify MyWebSite

externalSourceOrderId   string  optional  

The order website id or any other id that can help identify the order in our system. Example: AxZ00001

awbNumber   alphaNumeric  optional  

The AWB Number. Max 150 characters allowed. Example: AWB001

withPriority   boolean  optional  

Mention if the order must be prioritized. Accepted input are true, false, 1, 0, "1", and "0". Example: false

saveAsLocked   boolean  optional  

Mention if the order must be saved as Locked. Accepted input are true, false, 1, 0, "1", and "0". Example: false

lockerId   string  optional  

Value must have max 100 characters. Allowed characters are: alphanumeric, space or parenthesis. The lockerId is only allowed on a few couriers. Example: "5959"

useOverriddenValidationRules   boolean  optional  

If there are custom validation rules added by developers this field must be passed as true in order to be taken into account. Example: false

products   object[]   

Array of products

id   string   

The product (internal) ID. The id must be unique(distinct) in the products object. Example: 184736

quantity   integer   

The product quantity. The value must be at least 1. Example: 3

price   number  optional  

The product price. The price can have max 4 decimals. Example: 100.9999

UPDATE Order

requires authentication

Updates order by ID

Throttling: Max 15 requests per minute. (15/1)

Example request:
$client = new \GuzzleHttp\Client();
$url = 'https://clients.metrica.bg/api/v1/connectors/client/orders/update/';
$response = $client->put(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_TOKEN}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'address' => 'Str. My Street, No.10, Ap. 99',
            'city' => 'Bucuresti',
            'county' => 'Sector 12307050000008470',
            'country' => 'RO',
            'postalCode' => 'quam',
            'companyName' => 'Company SA',
            'companyUniqueIdentifier' => 'RO55599888',
            'companyRegistrationNumber' => 'J99/9999/1950',
            'contactPerson' => 'fugiat',
            'contactPhone' => '0700999111',
            'contactEmail' => 'stan38@example.com',
            'cashOnDelivery' => '100.99',
            'warehouseRemarks' => 'suscipit',
            'shippingInstructions' => 'rerum',
            'courierId' => 15,
            'courierSubAccountId' => 4,
            'awbUrl' => 'https://pathtomyawb.pdf',
            'invoiceUrl' => 'https://pathtomyinvoice.pdf',
            'deliveryNoteUrl' => 'https://pathtomydeliverynote.pdf',
            'maxKeepDays' => 365,
            'externalSource' => 'Shopify MyWebSite',
            'externalSourceOrderId' => 'AxZ00001',
            'awbNumber' => 'AWB001',
            'withPriority' => false,
            'lockerId' => '"5959"',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://clients.metrica.bg/api/v1/connectors/client/orders/update/"
);

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

let body = {
    "address": "Str. My Street, No.10, Ap. 99",
    "city": "Bucuresti",
    "county": "Sector 12307050000008470",
    "country": "RO",
    "postalCode": "quam",
    "companyName": "Company SA",
    "companyUniqueIdentifier": "RO55599888",
    "companyRegistrationNumber": "J99\/9999\/1950",
    "contactPerson": "fugiat",
    "contactPhone": "0700999111",
    "contactEmail": "stan38@example.com",
    "cashOnDelivery": "100.99",
    "warehouseRemarks": "suscipit",
    "shippingInstructions": "rerum",
    "courierId": 15,
    "courierSubAccountId": 4,
    "awbUrl": "https:\/\/pathtomyawb.pdf",
    "invoiceUrl": "https:\/\/pathtomyinvoice.pdf",
    "deliveryNoteUrl": "https:\/\/pathtomydeliverynote.pdf",
    "maxKeepDays": 365,
    "externalSource": "Shopify MyWebSite",
    "externalSourceOrderId": "AxZ00001",
    "awbNumber": "AWB001",
    "withPriority": false,
    "lockerId": "\"5959\""
};

fetch(url, {
    method: "PUT",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());
curl --request PUT \
    "https://clients.metrica.bg/api/v1/connectors/client/orders/update/" \
    --header "Authorization: Bearer {YOUR_AUTH_TOKEN}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"address\": \"Str. My Street, No.10, Ap. 99\",
    \"city\": \"Bucuresti\",
    \"county\": \"Sector 12307050000008470\",
    \"country\": \"RO\",
    \"postalCode\": \"quam\",
    \"companyName\": \"Company SA\",
    \"companyUniqueIdentifier\": \"RO55599888\",
    \"companyRegistrationNumber\": \"J99\\/9999\\/1950\",
    \"contactPerson\": \"fugiat\",
    \"contactPhone\": \"0700999111\",
    \"contactEmail\": \"stan38@example.com\",
    \"cashOnDelivery\": \"100.99\",
    \"warehouseRemarks\": \"suscipit\",
    \"shippingInstructions\": \"rerum\",
    \"courierId\": 15,
    \"courierSubAccountId\": 4,
    \"awbUrl\": \"https:\\/\\/pathtomyawb.pdf\",
    \"invoiceUrl\": \"https:\\/\\/pathtomyinvoice.pdf\",
    \"deliveryNoteUrl\": \"https:\\/\\/pathtomydeliverynote.pdf\",
    \"maxKeepDays\": 365,
    \"externalSource\": \"Shopify MyWebSite\",
    \"externalSourceOrderId\": \"AxZ00001\",
    \"awbNumber\": \"AWB001\",
    \"withPriority\": false,
    \"lockerId\": \"\\\"5959\\\"\"
}"
import requests
import json

url = 'https://clients.metrica.bg/api/v1/connectors/client/orders/update/'
payload = {
    "address": "Str. My Street, No.10, Ap. 99",
    "city": "Bucuresti",
    "county": "Sector 12307050000008470",
    "country": "RO",
    "postalCode": "quam",
    "companyName": "Company SA",
    "companyUniqueIdentifier": "RO55599888",
    "companyRegistrationNumber": "J99\/9999\/1950",
    "contactPerson": "fugiat",
    "contactPhone": "0700999111",
    "contactEmail": "stan38@example.com",
    "cashOnDelivery": "100.99",
    "warehouseRemarks": "suscipit",
    "shippingInstructions": "rerum",
    "courierId": 15,
    "courierSubAccountId": 4,
    "awbUrl": "https:\/\/pathtomyawb.pdf",
    "invoiceUrl": "https:\/\/pathtomyinvoice.pdf",
    "deliveryNoteUrl": "https:\/\/pathtomydeliverynote.pdf",
    "maxKeepDays": 365,
    "externalSource": "Shopify MyWebSite",
    "externalSourceOrderId": "AxZ00001",
    "awbNumber": "AWB001",
    "withPriority": false,
    "lockerId": "\"5959\""
}
headers = {
  'Authorization': 'Bearer {YOUR_AUTH_TOKEN}',
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}

response = requests.request('PUT', url, headers=headers, json=payload)
response.json()

Request      

PUT api/v1/connectors/client/orders/update/{orderId}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_TOKEN}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

orderId   integer   

The order ID.

Body Parameters

address   string  optional  

requiredIf The recipient address. It is required if awbUrl field is empty. Example: Str. My Street, No.10, Ap. 99

city   string  optional  

requiredIf The recipient city. The field must have at least 1 character. It is required if awbUrl field is empty. Max 50 characters allowed. Example: Bucuresti

county   string  optional  

requiredIf The recipient county. The field must have at least 1 character. It is required if awbUrl field is empty. Max 50 characters allowed. Example: Sector 12307050000008470

country   string  optional  

requiredIf The recipient country. The field must have min 2 characters. It is required if awbUrl field is empty. Between 2 and 50 characters allowed. Example: RO

postalCode   string  optional  

The recipient postal code. Max 10 characters allowed. Example: quam

companyName   string  optional  

The recipient company name. Fill only if the shipment is B2B. Max 150 characters allowed. Example: Company SA

companyUniqueIdentifier   string  optional  

The recipient Company Unique Identifier (CUI/VAT). Fill only if the shipment is B2B. Max 20 characters allowed. Example: RO55599888

companyRegistrationNumber   string  optional  

The recipient company registration number. Fill only if the shipment is B2B. Max 100 characters allowed. Example: J99/9999/1950

contactPerson   string   

The recipient contact person. Max 200 characters allowed. Example: fugiat

contactPhone   string   

The recipient contact person phone. The phone number must contain the correct number of digits and the allowed characters between digits are: space, dash, dots or parenthesis. Example: 0700999111

contactEmail   email  optional  

requiredIf The recipient contact person email. It is required if the selected courier is DPD (courierId 7) and the country is not RO/Romania. Example: stan38@example.com

cashOnDelivery   numeric   

The shipment Cash On Delivery amount. The amount can have max 2 decimals. If the order does not have Cash On Delivery the field value must be 0. Example: 100.99

warehouseRemarks   sting  optional  

Info for Warehouse. Example: suscipit

shippingInstructions   sting  optional  

Info for the shipping courier. Example: rerum

courierId   integer   

The courier ID. Example: 15

courierSubAccountId   integer  optional  

The SubAccount courier ID. Example: 4

awbUrl   url  optional  

Url path to a pdf containing the order AWB. Max 250 characters allowed. Example: https://pathtomyawb.pdf

invoiceUrl   url  optional  

Url path to a pdf containing the order invoice. Max 250 characters allowed. Example: https://pathtomyinvoice.pdf

deliveryNoteUrl   url  optional  

Url path to a pdf containing the order delivery note. Max 250 characters allowed. Example: https://pathtomydeliverynote.pdf

maxKeepDays   integer   

Value between 0 and 365. Example: 365

externalSource   string  optional  

The name of the external source of the order. The value must start with a value from in External Source List endpoint result. Example: Shopify MyWebSite

externalSourceOrderId   string  optional  

The order website id or any other id that can help identify the order in our system. Example: AxZ00001

awbNumber   string  optional  

The AWB Number. Max 150 characters allowed. Example: AWB001

withPriority   boolean  optional  

Mention if the order must be prioritized. Accepted input are true, false, 1, 0, "1", and "0". Example: false

lockerId   string  optional  

Value must have max 100 characters. Allowed characters are: alphanumeric, space or parenthesis. The lockerId is only allowed on a few couriers. Example: "5959"

UPDATE Order Url Field

requires authentication

Directly updates order url fields by ID

Throttling: Max 5 requests per minute. (5/1)

Example request:
$client = new \GuzzleHttp\Client();
$url = 'https://clients.metrica.bg/api/v1/connectors/client/orders/updateUrlField/';
$response = $client->put(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_TOKEN}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'urlField' => 'invoiceUrl',
            'url' => 'https://pathtomyurl.pdf',
            'deliveryNoteSerialNumber' => 'NO-001',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://clients.metrica.bg/api/v1/connectors/client/orders/updateUrlField/"
);

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

let body = {
    "urlField": "invoiceUrl",
    "url": "https:\/\/pathtomyurl.pdf",
    "deliveryNoteSerialNumber": "NO-001"
};

fetch(url, {
    method: "PUT",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());
curl --request PUT \
    "https://clients.metrica.bg/api/v1/connectors/client/orders/updateUrlField/" \
    --header "Authorization: Bearer {YOUR_AUTH_TOKEN}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"urlField\": \"invoiceUrl\",
    \"url\": \"https:\\/\\/pathtomyurl.pdf\",
    \"deliveryNoteSerialNumber\": \"NO-001\"
}"
import requests
import json

url = 'https://clients.metrica.bg/api/v1/connectors/client/orders/updateUrlField/'
payload = {
    "urlField": "invoiceUrl",
    "url": "https:\/\/pathtomyurl.pdf",
    "deliveryNoteSerialNumber": "NO-001"
}
headers = {
  'Authorization': 'Bearer {YOUR_AUTH_TOKEN}',
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}

response = requests.request('PUT', url, headers=headers, json=payload)
response.json()

Request      

PUT api/v1/connectors/client/orders/updateUrlField/{orderId}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_TOKEN}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

orderId   integer   

The order ID.

Body Parameters

urlField   enum(invoiceUrl,deliveryNoteUrl)   

The target order url field that should be updated. Example: invoiceUrl

url   url  optional  

The url path that returns a PDF file. Max 250 characters allowed. Example: https://pathtomyurl.pdf

deliveryNoteSerialNumber   string  optional  

The delivery note serial number. Allowed only when urlField is equal to deliveryNoteUrl. Max 30 characters allowed. Example: NO-001

DELETE Order By ID

requires authentication

Delete Order by internal id

Throttling: Max 60 requests per minute. (60/1)

Example request:
$client = new \GuzzleHttp\Client();
$url = 'https://clients.metrica.bg/api/v1/connectors/client/orders/delete/';
$response = $client->delete(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_TOKEN}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://clients.metrica.bg/api/v1/connectors/client/orders/delete/"
);

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

fetch(url, {
    method: "DELETE",
    headers,
}).then(response => response.json());
curl --request DELETE \
    "https://clients.metrica.bg/api/v1/connectors/client/orders/delete/" \
    --header "Authorization: Bearer {YOUR_AUTH_TOKEN}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
import requests
import json

url = 'https://clients.metrica.bg/api/v1/connectors/client/orders/delete/'
headers = {
  'Authorization': 'Bearer {YOUR_AUTH_TOKEN}',
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}

response = requests.request('DELETE', url, headers=headers)
response.json()

Example response (404):


{
    "success": false,
    "error": {
        "message": "Entry for OrderItem not found",
        "code": 404
    }
}
 

Request      

DELETE api/v1/connectors/client/orders/delete/{orderId}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_TOKEN}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

orderId   integer   

The order ID.

LOCK Order By ID

requires authentication

LOCK Order by internal id. This will prevent the start of order processing until it's unlocked.

Throttling: Max 60 requests per minute. (60/1)

Example request:
$client = new \GuzzleHttp\Client();
$url = 'https://clients.metrica.bg/api/v1/connectors/client/orders/lock/';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_TOKEN}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://clients.metrica.bg/api/v1/connectors/client/orders/lock/"
);

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

fetch(url, {
    method: "POST",
    headers,
}).then(response => response.json());
curl --request POST \
    "https://clients.metrica.bg/api/v1/connectors/client/orders/lock/" \
    --header "Authorization: Bearer {YOUR_AUTH_TOKEN}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
import requests
import json

url = 'https://clients.metrica.bg/api/v1/connectors/client/orders/lock/'
headers = {
  'Authorization': 'Bearer {YOUR_AUTH_TOKEN}',
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}

response = requests.request('POST', url, headers=headers)
response.json()

Example response (404):


{
    "success": false,
    "error": {
        "message": "Entry for OrderItem not found",
        "code": 404
    }
}
 

Request      

POST api/v1/connectors/client/orders/lock/{orderId}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_TOKEN}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

orderId   integer   

The order ID.

UNLOCK Order By ID

requires authentication

UNLOCK Order by internal id. This will unlock the order so the warehouse operators can start the picking and packing processes.

Throttling: Max 60 requests per minute. (60/1)

Example request:
$client = new \GuzzleHttp\Client();
$url = 'https://clients.metrica.bg/api/v1/connectors/client/orders/unlock/';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_TOKEN}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://clients.metrica.bg/api/v1/connectors/client/orders/unlock/"
);

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

fetch(url, {
    method: "POST",
    headers,
}).then(response => response.json());
curl --request POST \
    "https://clients.metrica.bg/api/v1/connectors/client/orders/unlock/" \
    --header "Authorization: Bearer {YOUR_AUTH_TOKEN}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
import requests
import json

url = 'https://clients.metrica.bg/api/v1/connectors/client/orders/unlock/'
headers = {
  'Authorization': 'Bearer {YOUR_AUTH_TOKEN}',
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}

response = requests.request('POST', url, headers=headers)
response.json()

Example response (404):


{
    "success": false,
    "error": {
        "message": "Entry for OrderItem not found",
        "code": 404
    }
}
 

Request      

POST api/v1/connectors/client/orders/unlock/{orderId}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_TOKEN}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

orderId   integer   

The order ID.

GET External Source List

requires authentication

Retrieve a list with the allowed external sources.

Throttling: Max 100 requests per minute. (100/1)

Please inform us if your source is not on this list, so we can add it.

Example request:
$client = new \GuzzleHttp\Client();
$url = 'https://clients.metrica.bg/api/v1/connectors/client/orders/externalSourceList';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_TOKEN}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://clients.metrica.bg/api/v1/connectors/client/orders/externalSourceList"
);

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

fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());
curl --request GET \
    --get "https://clients.metrica.bg/api/v1/connectors/client/orders/externalSourceList" \
    --header "Authorization: Bearer {YOUR_AUTH_TOKEN}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
import requests
import json

url = 'https://clients.metrica.bg/api/v1/connectors/client/orders/externalSourceList'
headers = {
  'Authorization': 'Bearer {YOUR_AUTH_TOKEN}',
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}

response = requests.request('GET', url, headers=headers)
response.json()

Example response (200):

Show headers
cache-control: no-cache, private
content-type: application/json
x-ratelimit-limit: 100
x-ratelimit-remaining: 99
access-control-allow-origin: *
 

{
    "data": [
        "Fulfill",
        "Gomag",
        "EasySales",
        "Teamshare",
        "ContentSpeed",
        "BaseLinker",
        "VTEX",
        "Shopify",
        "Magento",
        "PrestaShop",
        "OpenCart",
        "WooCommerce",
        "MerchantPro",
        "EMAG RO",
        "EMAG HU",
        "EMAG BG",
        "CEL",
        "Elefant",
        "Vivre",
        "OLX",
        "Okazii",
        "Wordpress",
        "Mentor",
        "Metrica",
        "Fashion Days",
        "Trendyol",
        "SeniorSoftware"
    ],
    "success": true
}
 

Request      

GET api/v1/connectors/client/orders/externalSourceList

Headers

Authorization      

Example: Bearer {YOUR_AUTH_TOKEN}

Content-Type      

Example: application/json

Accept      

Example: application/json

REQUEST DPD Pickup

requires authentication

Creates a new DPD AWB number and Pickup request for the given order ID.

Example request:
$client = new \GuzzleHttp\Client();
$url = 'https://clients.metrica.bg/api/v1/connectors/client/orders/requestDPDPickup';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_TOKEN}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'id' => '1234',
            'identifiedAs' => 'orderId',
            'sender' => [
                'clientName' => 'Company 999',
                'contactName' => 'Contact Test',
                'contactPhoneNumber' => 'delectus',
                'address' => 'Test address',
                'city' => 'City',
                'county' => 'County',
                'postCode' => '999999',
            ],
            'extra' => [
                'declaredValueAmount' => '100.99',
            ],
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://clients.metrica.bg/api/v1/connectors/client/orders/requestDPDPickup"
);

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

let body = {
    "id": "1234",
    "identifiedAs": "orderId",
    "sender": {
        "clientName": "Company 999",
        "contactName": "Contact Test",
        "contactPhoneNumber": "delectus",
        "address": "Test address",
        "city": "City",
        "county": "County",
        "postCode": "999999"
    },
    "extra": {
        "declaredValueAmount": "100.99"
    }
};

fetch(url, {
    method: "POST",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());
curl --request POST \
    "https://clients.metrica.bg/api/v1/connectors/client/orders/requestDPDPickup" \
    --header "Authorization: Bearer {YOUR_AUTH_TOKEN}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"id\": \"1234\",
    \"identifiedAs\": \"orderId\",
    \"sender\": {
        \"clientName\": \"Company 999\",
        \"contactName\": \"Contact Test\",
        \"contactPhoneNumber\": \"delectus\",
        \"address\": \"Test address\",
        \"city\": \"City\",
        \"county\": \"County\",
        \"postCode\": \"999999\"
    },
    \"extra\": {
        \"declaredValueAmount\": \"100.99\"
    }
}"
import requests
import json

url = 'https://clients.metrica.bg/api/v1/connectors/client/orders/requestDPDPickup'
payload = {
    "id": "1234",
    "identifiedAs": "orderId",
    "sender": {
        "clientName": "Company 999",
        "contactName": "Contact Test",
        "contactPhoneNumber": "delectus",
        "address": "Test address",
        "city": "City",
        "county": "County",
        "postCode": "999999"
    },
    "extra": {
        "declaredValueAmount": "100.99"
    }
}
headers = {
  'Authorization': 'Bearer {YOUR_AUTH_TOKEN}',
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}

response = requests.request('POST', url, headers=headers, json=payload)
response.json()

Request      

POST api/v1/connectors/client/orders/requestDPDPickup

Headers

Authorization      

Example: Bearer {YOUR_AUTH_TOKEN}

Content-Type      

Example: application/json

Accept      

Example: application/json

Body Parameters

id   string   

Requested order id. Example: 1234

identifiedAs   enum(orderId,externalId,externalSourceOrderId)   

Order column identifier for specifying where the provided id value should be searched. Example: orderId

sender   object   

Contains information about the sender of the shipment.

clientName   string   

Sender client name. Example: Company 999

contactName   string   

Sender contact name. Example: Contact Test

contactPhoneNumber   string   

Sender contact phone. Example: delectus

address   string   

Sender address. Example: Test address

city   string   

Sender city. Example: City

county   string   

Sender county. Example: County

postCode   string   

Sender postal code. Example: 999999

extra   object  optional  

Contains extra information for DPD.

declaredValueAmount   numeric  optional  

The amount can have max 2 decimals. Example: 100.99

API V1 - Order Invoices

Order Invoice Endpoints

GET Invoices Information

requires authentication

Returns a list with all invoices information that can be filtered by the available parameters.

Throttling: Max 20 requests per hour. (20/60)

Default page size : 100 records per page.

Presents the result with page size and pagination.

Example request:
$client = new \GuzzleHttp\Client();
$url = 'https://clients.metrica.bg/api/v1/connectors/client/orders/invoice/information';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_TOKEN}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'query' => [
            'page' => '1',
        ],
        'json' => [
            'hasInvoiceNumber' => false,
            'orderIsShipped' => true,
            'startDate' => '2024-01-01 12:59:59',
            'dateQueryType' => 'orderSentDate',
            'orderByField' => 'orderSentDate',
            'orderByDirection' => 'ASC',
            'perPage' => 100,
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://clients.metrica.bg/api/v1/connectors/client/orders/invoice/information"
);

const params = {
    "page": "1",
};
Object.keys(params)
    .forEach(key => url.searchParams.append(key, params[key]));

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

let body = {
    "hasInvoiceNumber": false,
    "orderIsShipped": true,
    "startDate": "2024-01-01 12:59:59",
    "dateQueryType": "orderSentDate",
    "orderByField": "orderSentDate",
    "orderByDirection": "ASC",
    "perPage": 100
};

fetch(url, {
    method: "GET",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());
curl --request GET \
    --get "https://clients.metrica.bg/api/v1/connectors/client/orders/invoice/information?page=1" \
    --header "Authorization: Bearer {YOUR_AUTH_TOKEN}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"hasInvoiceNumber\": false,
    \"orderIsShipped\": true,
    \"startDate\": \"2024-01-01 12:59:59\",
    \"dateQueryType\": \"orderSentDate\",
    \"orderByField\": \"orderSentDate\",
    \"orderByDirection\": \"ASC\",
    \"perPage\": 100
}"
import requests
import json

url = 'https://clients.metrica.bg/api/v1/connectors/client/orders/invoice/information'
payload = {
    "hasInvoiceNumber": false,
    "orderIsShipped": true,
    "startDate": "2024-01-01 12:59:59",
    "dateQueryType": "orderSentDate",
    "orderByField": "orderSentDate",
    "orderByDirection": "ASC",
    "perPage": 100
}
params = {
  'page': '1',
}
headers = {
  'Authorization': 'Bearer {YOUR_AUTH_TOKEN}',
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}

response = requests.request('GET', url, headers=headers, json=payload, params=params)
response.json()

Example response (403):

Show headers
cache-control: no-cache, private
content-type: application/json
x-ratelimit-limit: 10
x-ratelimit-remaining: 9
access-control-allow-origin: *
 

{
    "success": false,
    "error": {
        "message": "Not allowed to access this endpoint.",
        "code": 403
    }
}
 

Request      

GET api/v1/connectors/client/orders/invoice/information

Headers

Authorization      

Example: Bearer {YOUR_AUTH_TOKEN}

Content-Type      

Example: application/json

Accept      

Example: application/json

Query Parameters

page   integer  optional  

Which page to show. Example: 1

Body Parameters

hasInvoiceNumber   boolean  optional  

The result is filtered based on the presence of the invoice number in the information. If missing the filter will not be added. Example: false

orderIsShipped   boolean  optional  

The result is filtered based on the internal order status. If missing the filter will not be added. Example: true

startDate   date  optional  

A date between past and today. The format must be in: Y-m-d H:i:s Example: 2024-01-01 12:59:59

dateQueryType   enum(invoiceInformationCreatedDate,orderSentDate)  optional  

The column that should be queried by startDate field. Example: orderSentDate

orderByField   enum(invoiceInformationCreatedDate,orderSentDate)  optional  

The field responsible for ordering the result. Example: orderSentDate

orderByDirection   enum(ASC,DESC)  optional  

The direction of order for orderByField field. Example: ASC

perPage   integer  optional  

Number of records to show per page. The allowed values are between 10 and 250. If not provided, the default is 100. Example: 100

GET Invoice Info By Order ID

requires authentication

GET Invoice Information By Order internal ID

Throttling: Max 10 requests per minute. (10/1)

Example request:
$client = new \GuzzleHttp\Client();
$url = 'https://clients.metrica.bg/api/v1/connectors/client/orders/invoice/information/byOrderId/asperiores';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_TOKEN}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://clients.metrica.bg/api/v1/connectors/client/orders/invoice/information/byOrderId/asperiores"
);

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

fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());
curl --request GET \
    --get "https://clients.metrica.bg/api/v1/connectors/client/orders/invoice/information/byOrderId/asperiores" \
    --header "Authorization: Bearer {YOUR_AUTH_TOKEN}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
import requests
import json

url = 'https://clients.metrica.bg/api/v1/connectors/client/orders/invoice/information/byOrderId/asperiores'
headers = {
  'Authorization': 'Bearer {YOUR_AUTH_TOKEN}',
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}

response = requests.request('GET', url, headers=headers)
response.json()

Example response (403):

Show headers
cache-control: no-cache, private
content-type: application/json
x-ratelimit-limit: 10
x-ratelimit-remaining: 9
access-control-allow-origin: *
 

{
    "success": false,
    "error": {
        "message": "Not allowed to access this endpoint.",
        "code": 403
    }
}
 

Example response (404):


{
    "success": false,
    "error": {
        "message": "Entry for OrderItem not found",
        "code": 404
    }
}
 

Request      

GET api/v1/connectors/client/orders/invoice/information/byOrderId/{orderId}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_TOKEN}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

orderId   string   

Example: asperiores

order_id   integer   

The order ID. Example: 101

CREATE Order Invoice Information

requires authentication

Creates a new Order Invoice Information.

Throttling: Max 15 requests per minute. (15/1)

Example request:
$client = new \GuzzleHttp\Client();
$url = 'https://clients.metrica.bg/api/v1/connectors/client/orders/invoice/information/create/';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_TOKEN}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'isLegalEntity' => false,
            'companyName' => 'Company Name',
            'companyUniqueIdentifier' => 'RO55599888',
            'companyRegistrationNumber' => 'J99/9999/1950',
            'companyBankName' => 'The Bank of',
            'companyIban' => 'RO49AAAA1B31007593840000',
            'firstName' => 'First',
            'lastName' => 'Last',
            'address' => 'Str. My Street, No.10, Ap. 99',
            'city' => 'Bucuresti',
            'county' => 'Sector 1',
            'country' => 'RO',
            'postalCode' => '010111',
            'phone' => '0700999111',
            'email' => 'test@test.com',
            'shippingTax' => '100.50',
            'processingFee' => '0',
            'discountsTotal' => '100.99',
            'invoiceTotal' => '999.99',
            'invoiceNumber' => 'SN-RO-001',
            'urlPath' => 'https://pathtomyinvoice.pdf',
            'unlockOrder' => false,
            'sameLinesAsOrder' => false,
            'linesPriceCheck' => false,
            'discounts' => [
                [
                    'name' => 'Discount Name No-1',
                    'value' => '100.9999',
                ],
            ],
            'discountApplications' => [
                [
                    'allocationMethod' => 'each',
                    'targetSelection' => 'explicit',
                    'targetType' => 'shipping_line',
                    'code' => 'CODEX101',
                    'title' => 'title',
                    'description' => 'description',
                    'type' => 'discount_code',
                    'value' => '20.0',
                    'valueType' => 'fixed_amount',
                    'calculatedAmount' => '100.9999',
                ],
            ],
            'invoiceLines' => [
                [
                    'productId' => 123456,
                    'lineExternalIdentifier' => 'reiciendis',
                    'pricePerUnit' => '10.55',
                    'quantity' => 5,
                    'totalDiscount' => '10.55',
                    'taxLines' => [
                        [
                            'title' => 'VAT RO',
                        ],
                    ],
                    'price' => '10.55',
                    'rate' => '0.99',
                ],
            ],
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://clients.metrica.bg/api/v1/connectors/client/orders/invoice/information/create/"
);

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

let body = {
    "isLegalEntity": false,
    "companyName": "Company Name",
    "companyUniqueIdentifier": "RO55599888",
    "companyRegistrationNumber": "J99\/9999\/1950",
    "companyBankName": "The Bank of",
    "companyIban": "RO49AAAA1B31007593840000",
    "firstName": "First",
    "lastName": "Last",
    "address": "Str. My Street, No.10, Ap. 99",
    "city": "Bucuresti",
    "county": "Sector 1",
    "country": "RO",
    "postalCode": "010111",
    "phone": "0700999111",
    "email": "test@test.com",
    "shippingTax": "100.50",
    "processingFee": "0",
    "discountsTotal": "100.99",
    "invoiceTotal": "999.99",
    "invoiceNumber": "SN-RO-001",
    "urlPath": "https:\/\/pathtomyinvoice.pdf",
    "unlockOrder": false,
    "sameLinesAsOrder": false,
    "linesPriceCheck": false,
    "discounts": [
        {
            "name": "Discount Name No-1",
            "value": "100.9999"
        }
    ],
    "discountApplications": [
        {
            "allocationMethod": "each",
            "targetSelection": "explicit",
            "targetType": "shipping_line",
            "code": "CODEX101",
            "title": "title",
            "description": "description",
            "type": "discount_code",
            "value": "20.0",
            "valueType": "fixed_amount",
            "calculatedAmount": "100.9999"
        }
    ],
    "invoiceLines": [
        {
            "productId": 123456,
            "lineExternalIdentifier": "reiciendis",
            "pricePerUnit": "10.55",
            "quantity": 5,
            "totalDiscount": "10.55",
            "taxLines": [
                {
                    "title": "VAT RO"
                }
            ],
            "price": "10.55",
            "rate": "0.99"
        }
    ]
};

fetch(url, {
    method: "POST",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());
curl --request POST \
    "https://clients.metrica.bg/api/v1/connectors/client/orders/invoice/information/create/" \
    --header "Authorization: Bearer {YOUR_AUTH_TOKEN}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"isLegalEntity\": false,
    \"companyName\": \"Company Name\",
    \"companyUniqueIdentifier\": \"RO55599888\",
    \"companyRegistrationNumber\": \"J99\\/9999\\/1950\",
    \"companyBankName\": \"The Bank of\",
    \"companyIban\": \"RO49AAAA1B31007593840000\",
    \"firstName\": \"First\",
    \"lastName\": \"Last\",
    \"address\": \"Str. My Street, No.10, Ap. 99\",
    \"city\": \"Bucuresti\",
    \"county\": \"Sector 1\",
    \"country\": \"RO\",
    \"postalCode\": \"010111\",
    \"phone\": \"0700999111\",
    \"email\": \"test@test.com\",
    \"shippingTax\": \"100.50\",
    \"processingFee\": \"0\",
    \"discountsTotal\": \"100.99\",
    \"invoiceTotal\": \"999.99\",
    \"invoiceNumber\": \"SN-RO-001\",
    \"urlPath\": \"https:\\/\\/pathtomyinvoice.pdf\",
    \"unlockOrder\": false,
    \"sameLinesAsOrder\": false,
    \"linesPriceCheck\": false,
    \"discounts\": [
        {
            \"name\": \"Discount Name No-1\",
            \"value\": \"100.9999\"
        }
    ],
    \"discountApplications\": [
        {
            \"allocationMethod\": \"each\",
            \"targetSelection\": \"explicit\",
            \"targetType\": \"shipping_line\",
            \"code\": \"CODEX101\",
            \"title\": \"title\",
            \"description\": \"description\",
            \"type\": \"discount_code\",
            \"value\": \"20.0\",
            \"valueType\": \"fixed_amount\",
            \"calculatedAmount\": \"100.9999\"
        }
    ],
    \"invoiceLines\": [
        {
            \"productId\": 123456,
            \"lineExternalIdentifier\": \"reiciendis\",
            \"pricePerUnit\": \"10.55\",
            \"quantity\": 5,
            \"totalDiscount\": \"10.55\",
            \"taxLines\": [
                {
                    \"title\": \"VAT RO\"
                }
            ],
            \"price\": \"10.55\",
            \"rate\": \"0.99\"
        }
    ]
}"
import requests
import json

url = 'https://clients.metrica.bg/api/v1/connectors/client/orders/invoice/information/create/'
payload = {
    "isLegalEntity": false,
    "companyName": "Company Name",
    "companyUniqueIdentifier": "RO55599888",
    "companyRegistrationNumber": "J99\/9999\/1950",
    "companyBankName": "The Bank of",
    "companyIban": "RO49AAAA1B31007593840000",
    "firstName": "First",
    "lastName": "Last",
    "address": "Str. My Street, No.10, Ap. 99",
    "city": "Bucuresti",
    "county": "Sector 1",
    "country": "RO",
    "postalCode": "010111",
    "phone": "0700999111",
    "email": "test@test.com",
    "shippingTax": "100.50",
    "processingFee": "0",
    "discountsTotal": "100.99",
    "invoiceTotal": "999.99",
    "invoiceNumber": "SN-RO-001",
    "urlPath": "https:\/\/pathtomyinvoice.pdf",
    "unlockOrder": false,
    "sameLinesAsOrder": false,
    "linesPriceCheck": false,
    "discounts": [
        {
            "name": "Discount Name No-1",
            "value": "100.9999"
        }
    ],
    "discountApplications": [
        {
            "allocationMethod": "each",
            "targetSelection": "explicit",
            "targetType": "shipping_line",
            "code": "CODEX101",
            "title": "title",
            "description": "description",
            "type": "discount_code",
            "value": "20.0",
            "valueType": "fixed_amount",
            "calculatedAmount": "100.9999"
        }
    ],
    "invoiceLines": [
        {
            "productId": 123456,
            "lineExternalIdentifier": "reiciendis",
            "pricePerUnit": "10.55",
            "quantity": 5,
            "totalDiscount": "10.55",
            "taxLines": [
                {
                    "title": "VAT RO"
                }
            ],
            "price": "10.55",
            "rate": "0.99"
        }
    ]
}
headers = {
  'Authorization': 'Bearer {YOUR_AUTH_TOKEN}',
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}

response = requests.request('POST', url, headers=headers, json=payload)
response.json()

Request      

POST api/v1/connectors/client/orders/invoice/information/create/{orderId}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_TOKEN}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

orderId   integer   

The order ID.

Body Parameters

isLegalEntity   boolean   

Mention if the order invoice information is a legal entity/juridical person or an individual/natural person. Accepted input are true, false, 1, 0, "1", and "0". Example: false

companyName   string  optional  

requiredIf The billing Company name. Fill only if the invoice is a legal entity. Max 75 characters allowed. Example: Company Name

companyUniqueIdentifier   string  optional  

requiredIf The billing Company Unique Identifier (CUI/VAT). Fill only if the invoice is a legal entity. All whitespaces and non-alphanumeric characters are automatically removed from this field. Max 30 characters allowed. Example: RO55599888

companyRegistrationNumber   string  optional  

The billing company registration number. Max 50 characters allowed. Example: J99/9999/1950

companyBankName   string  optional  

The billing company bank name. Fill only if the invoice is for a legal entity. Max 50 characters allowed. Example: The Bank of

companyIban   string  optional  

The billing company IBAN. Fill only if the invoice is for a legal entity. Max 34 characters allowed. Example: RO49AAAA1B31007593840000

firstName   string  optional  

requiredIf required The billing contact first name. Max 50 characters allowed. Required if lastName is not present. Example: First

lastName   string  optional  

requiredIf required The billing contact last name. Max 50 characters allowed. Required if firstName is not present. Example: Last

address   string   

The billing address. Example: Str. My Street, No.10, Ap. 99

city   string   

The billing city. The field must have at least 1 character. Max 50 characters allowed. Example: Bucuresti

county   string   

The billing county. The field must have at least 1 character. Max 50 characters allowed. Example: Sector 1

country   string   

The billing country. Between 2 and 50 characters allowed. Example: RO

postalCode   string  optional  

The billing postal code. Max 10 characters allowed. Example: 010111

phone   string  optional  

The billing phone. The phone number must contain the correct number of digits and the allowed characters between digits are: space, dash, dots or parenthesis. Example: 0700999111

email   string  optional  

The billing email. Example: test@test.com

shippingTax   decimal   

The shipping tax. The value can have up to 2 decimal places. Example: 100.50

processingFee   decimal  optional  

The processing fee for the order. The value can have up to 2 decimal places. Example: 0

discountsTotal   decimal  optional  

The current total value of all the discounts. The value can have up to 2 decimal places. Example: 100.99

invoiceTotal   decimal  optional  

The current total value of the invoice. The value can have up to 2 decimal places. Example: 999.99

invoiceNumber   string  optional  

An invoice number is a unique number assigned to invoices. They allow invoices to be easily identified and tracked for accounting and tax purposes. Example: SN-RO-001

urlPath   url  optional  

Url path to a pdf containing the order invoice. Max 100 characters allowed. Example: https://pathtomyinvoice.pdf

unlockOrder   boolean  optional  

Mention if the order must be unlocked after the Invoice Information is added. Its recommended to create the order as Locked if the invoice information is required through its lifetime. Accepted input are true, false, 1, 0, "1", and "0". Example: false

sameLinesAsOrder   boolean  optional  

Activate a validation check that will verify if the provided invoice lines are the same as order lines. Accepted input are true, false, 1, 0, "1", and "0". Example: false

linesPriceCheck   boolean  optional  

Activate a validation check that will verify if the sum of provided invoice lines is equal to invoiceTotal value. Accepted input are true, false, 1, 0, "1", and "0". Example: false

discounts   object[]  optional  

Contains a list of discounts. This object parameter will be deprecated in the future. Please use discountApplications instead.

name   string   

The discount name. Max 30 characters allowed. The field must be distinct. The field may have alphanumeric characters, as well as dashes and underscores. Example: Discount Name No-1

value   decimal   

The discount value. The value can have up to 4 decimals and can also be a negative value. Example: 100.9999

discountApplications   object[]  optional  

Contains a list of discounts applied to the order based on Shopify REST Order resource model.

allocationMethod   string  optional  

The method by which the discount application value has been allocated to entitled lines. Example: each

targetSelection   string  optional  

The lines on the order, of the type defined by target_type, that the discount is allocated over. Valid values: all, entitled, explicit. Example: explicit

targetType   string  optional  

The type of line on the order that the discount is applicable on. Valid values: line_item, shipping_line. Example: shipping_line

code   string  optional  

The discount code that was used to apply the discount. Available only for discount code applications. Example: CODEX101

title   string  optional  

The title of the discount application, as defined by the merchant. Available only for manual discount applications. Example: title

description   string  optional  

The description of the discount application, as defined by the merchant. Available only for manual and script discount applications. Example: description

type   string  optional  

The discount application type. Valid values: automatic, discount_code, manual, script. Example: discount_code

value   decimal   

The value of the discount application as a decimal. This represents the intention of the discount application. For example, if the intent was to apply a 20% discount, then the value will be 20.0. If the intent was to apply a $15 discount, then the value will be 15.0 Example: 20.0

valueType   string   

The type of the value. Valid values: fixed_amount, percentage. Example: fixed_amount

calculatedAmount   decimal   

The calculated discount amount. Example: 100.9999

invoiceLines   object[]  optional  

Contains a list of invoice lines.

productId   integer   

The order product ID. The field must be distinct. Example: 123456

lineExternalIdentifier   string  optional  

The external id of the corresponding invoice line. Max 50 characters allowed. Example: reiciendis

pricePerUnit   decimal   

The invoice line price per unit. The value must be a positive number and can have up to 2 decimal places. Example: 10.55

quantity   integer   

The invoice line quantity. The value must be a positive number. Example: 5

totalDiscount   decimal   

The invoice line total discount. The value must be a positive number and can have up to 2 decimal places. Example: 10.55

taxLines   object[]  optional  

Contains a list of tax lines for each invoice line.

title   string   

The tax title. Between 3 and 50 characters allowed. Example: VAT RO

price   decimal   

The tax price. The value must be a positive number and can have up to 2 decimal places. Example: 10.55

rate   decimal  optional  

The tax rate percentage. The value must be a positive number and can have up to 2 decimal places. Example: 0.99

UPDATE Order Invoice Info Number

requires authentication

Updates the invoice number for the Order invoice information by ID

Throttling: Max 50 requests per minute. (50/1)

Example request:
$client = new \GuzzleHttp\Client();
$url = 'https://clients.metrica.bg/api/v1/connectors/client/orders/invoice/information/update/13/invoiceNumber';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_TOKEN}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'query' => [
            'page' => '1',
        ],
        'json' => [
            'invoiceNumber' => 'SN-RO-001',
            'urlPath' => 'https://pathtomyinvoice.pdf',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://clients.metrica.bg/api/v1/connectors/client/orders/invoice/information/update/13/invoiceNumber"
);

const params = {
    "page": "1",
};
Object.keys(params)
    .forEach(key => url.searchParams.append(key, params[key]));

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

let body = {
    "invoiceNumber": "SN-RO-001",
    "urlPath": "https:\/\/pathtomyinvoice.pdf"
};

fetch(url, {
    method: "POST",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());
curl --request POST \
    "https://clients.metrica.bg/api/v1/connectors/client/orders/invoice/information/update/13/invoiceNumber?page=1" \
    --header "Authorization: Bearer {YOUR_AUTH_TOKEN}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"invoiceNumber\": \"SN-RO-001\",
    \"urlPath\": \"https:\\/\\/pathtomyinvoice.pdf\"
}"
import requests
import json

url = 'https://clients.metrica.bg/api/v1/connectors/client/orders/invoice/information/update/13/invoiceNumber'
payload = {
    "invoiceNumber": "SN-RO-001",
    "urlPath": "https:\/\/pathtomyinvoice.pdf"
}
params = {
  'page': '1',
}
headers = {
  'Authorization': 'Bearer {YOUR_AUTH_TOKEN}',
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}

response = requests.request('POST', url, headers=headers, json=payload, params=params)
response.json()

Request      

POST api/v1/connectors/client/orders/invoice/information/update/{orderInvoiceInformation_id}/invoiceNumber

Headers

Authorization      

Example: Bearer {YOUR_AUTH_TOKEN}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

orderInvoiceInformation_id   integer   

The ID of the orderInvoiceInformation. Example: 13

orderInvoiceInformation   integer   

The Order invoice information ID.

Query Parameters

page   integer  optional  

Which page to show. Example: 1

Body Parameters

invoiceNumber   string   

An invoice number is a unique number assigned to invoices. They allow invoices to be easily identified and tracked for accounting and tax purposes. Example: SN-RO-001

urlPath   url  optional  

Url path to a pdf containing the order invoice. Max 100 characters allowed. Example: https://pathtomyinvoice.pdf

API V1 - Products

Products Endpoints

GET All Products

requires authentication

List all products.

Presents the result with page size and simple pagination (without showing the total number of records and last page).

Throttling: Max 20 requests per minute. (20/1) Max 100 requests per hour. (100/60)

Default page size : 1000 records per page.

Example request:
$client = new \GuzzleHttp\Client();
$url = 'https://clients.metrica.bg/api/v1/connectors/client/products';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_TOKEN}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'query' => [
            'page' => '1',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://clients.metrica.bg/api/v1/connectors/client/products"
);

const params = {
    "page": "1",
};
Object.keys(params)
    .forEach(key => url.searchParams.append(key, params[key]));

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

fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());
curl --request GET \
    --get "https://clients.metrica.bg/api/v1/connectors/client/products?page=1" \
    --header "Authorization: Bearer {YOUR_AUTH_TOKEN}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
import requests
import json

url = 'https://clients.metrica.bg/api/v1/connectors/client/products'
params = {
  'page': '1',
}
headers = {
  'Authorization': 'Bearer {YOUR_AUTH_TOKEN}',
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}

response = requests.request('GET', url, headers=headers, params=params)
response.json()

Example response (200):

Show headers
cache-control: no-cache, private
content-type: application/json
x-ratelimit-limit: 20
x-ratelimit-remaining: 19
access-control-allow-origin: *
 

{
    "data": [
        {
            "productId": 1,
            "description": "Produs neregasit in BD - Comanda incompleta",
            "pictureUrl": "",
            "productCode": "",
            "ean": "",
            "externalId": -1,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": null,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 2,
            "description": "\"Produs TestClient 1",
            "pictureUrl": "https://www.youtube.com/test/123/",
            "productCode": "prodtestclient1",
            "ean": "zang1",
            "externalId": 10001,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": 25000,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 3,
            "description": "Produs TestClient 2",
            "pictureUrl": "",
            "productCode": "prodtestclient2",
            "ean": "zang2",
            "externalId": 10002,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": 1000,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 4,
            "description": "Produs TestClient 3",
            "pictureUrl": "",
            "productCode": "prodtestclient3",
            "ean": "zang3",
            "externalId": 10003,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": null,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 5,
            "description": "Produs TestClient 4",
            "pictureUrl": "",
            "productCode": "prodtestclient4",
            "ean": "zang4",
            "externalId": 10004,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": null,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": true,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 6,
            "description": "Produs TestClient 5",
            "pictureUrl": "",
            "productCode": "prodtestclient5",
            "ean": "zang5",
            "externalId": 10005,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": null,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 7,
            "description": "Produs TestClient 6",
            "pictureUrl": "",
            "productCode": "prodtestclient6",
            "ean": "zang6",
            "externalId": 10006,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": null,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 8,
            "description": "Produs TestClient 7",
            "pictureUrl": "",
            "productCode": "prodtestclient7",
            "ean": "zang7",
            "externalId": 10007,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": null,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 9,
            "description": "Produs TestClient 8Produs TestClient 8Produs TestClient 8",
            "pictureUrl": "",
            "productCode": "prodtestclient8",
            "ean": "zang8",
            "externalId": 10008,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": null,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 10,
            "description": "Produs TestClient 9",
            "pictureUrl": "",
            "productCode": "prodtestclient9",
            "ean": "zang9",
            "externalId": 10009,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": null,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 11,
            "description": "Produs TestClient 10",
            "pictureUrl": "",
            "productCode": "prodtestclient10",
            "ean": "zang10",
            "externalId": 10010,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": null,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 12,
            "description": "Produs TestClient 11",
            "pictureUrl": "",
            "productCode": "prodtestclient11",
            "ean": "zang11",
            "externalId": 10011,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": null,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 13,
            "description": "Produs TestClient 12Produs TestClient 12Produs TestClient 12Produs TestClient 12Produs TestClient 12",
            "pictureUrl": "",
            "productCode": "prodtestclient12",
            "ean": "zang12",
            "externalId": 10012,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": null,
            "productType": "With Expiration Date",
            "expirationType": "1",
            "expirationTypeDescription": "With Expiration Date",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 14,
            "description": "Produs TestClient 13",
            "pictureUrl": "",
            "productCode": "prodtestclient13",
            "ean": "zang13",
            "externalId": 10013,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": null,
            "productType": "With Expiration Date & Production Batch",
            "expirationType": "2",
            "expirationTypeDescription": "With Expiration Date & Production Batch",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 15,
            "description": "Produs TestClient 14",
            "pictureUrl": "",
            "productCode": "prodtestclient14",
            "ean": "zang14",
            "externalId": 10014,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": null,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 16,
            "description": "Produs TestClient 15",
            "pictureUrl": "",
            "productCode": "prodtestclient15",
            "ean": "zang15",
            "externalId": 10015,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": null,
            "productType": "With Expiration Date & Production Batch",
            "expirationType": "2",
            "expirationTypeDescription": "With Expiration Date & Production Batch",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 17,
            "description": "Produs TestClient 16",
            "pictureUrl": "",
            "productCode": "prodtestclient16",
            "ean": "zang16",
            "externalId": 10016,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": null,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 18,
            "description": "Produs TestClient 17",
            "pictureUrl": "",
            "productCode": "prodtestclient17",
            "ean": "zang17",
            "externalId": 10017,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": null,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 19,
            "description": "Produs TestClient 18",
            "pictureUrl": "",
            "productCode": "prodtestclient18",
            "ean": "zang18",
            "externalId": 10018,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": null,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 20,
            "description": "Produs TestClient 19",
            "pictureUrl": "",
            "productCode": "prodtestclient19",
            "ean": "zang19",
            "externalId": 10019,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": null,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 21,
            "description": "Produs TestClient 20",
            "pictureUrl": "",
            "productCode": "prodtestclient20",
            "ean": "zang20",
            "externalId": 10020,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": 100,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 22,
            "description": "Produs evidenta palet sus",
            "pictureUrl": "",
            "productCode": "paletproduct_22",
            "ean": "paletproduct_22",
            "externalId": 0,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": 0,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 12212,
            "description": "Produs TestClient 99992",
            "pictureUrl": "",
            "productCode": "8033524170111-DEC",
            "ean": "meh1_a_A-a.a..a.az",
            "externalId": 0,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": 0,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": true,
            "createdAt": "2023-07-13T12:46:41.000000Z",
            "updatedAt": "2023-11-01T09:32:08.000000Z"
        },
        {
            "productId": 28160,
            "description": "Test Fast print orders",
            "pictureUrl": "",
            "productCode": "NewTest",
            "ean": "5896545632104",
            "externalId": 0,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": 0,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": "2023-11-01T09:37:35.000000Z",
            "updatedAt": "2023-11-01T09:37:35.000000Z"
        },
        {
            "productId": 86271,
            "description": "Rapala Sliver Воблер",
            "pictureUrl": "https://clients.mercoria.com/uploads/images/products/16/45268-rapala-sliver-vobler-2.jpg",
            "productCode": "10329",
            "ean": "",
            "externalId": 45268,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": 16,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 86272,
            "description": "Rapala Shadow Rap Воблер",
            "pictureUrl": "https://clients.mercoria.com/uploads/images/products/16/45271-rapala-shadow-rap-vobler-2.jpg",
            "productCode": "10426",
            "ean": "",
            "externalId": 45271,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": 12,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 86273,
            "description": "Salmo Image Tiny Sinking Воблер",
            "pictureUrl": "https://clients.mercoria.com/uploads/images/products/16/45272-salmo-image-tiny-sinking-vobler-1.jpg",
            "productCode": "10539",
            "ean": "",
            "externalId": 45272,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": 2,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 86274,
            "description": "Salmo Freediver Super Deep Runner Floating 12 cm Воблер плуващ",
            "pictureUrl": "https://clients.mercoria.com/uploads/images/products/16/45273-salmo-freediver-super-deep-runner-floating-vobler-3.jpg",
            "productCode": "10633",
            "ean": "",
            "externalId": 45273,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": 24,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 86275,
            "description": "Simrad NSS7 Evo2 Touch Сонар",
            "pictureUrl": "https://clients.mercoria.com/uploads/images/products/16/47969-180903101803simrad-nss7-evo2-touch-sonar-4.jpg",
            "productCode": "20162",
            "ean": "",
            "externalId": 47969,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": 0,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 86276,
            "description": "Humminbird Onyx 8cxi SI Combo Сонар",
            "pictureUrl": "https://clients.mercoria.com/uploads/images/products/16/47966-180903101708humminbird-onyx-8cxi-si-combo-sonar-1.jpg",
            "productCode": "20163",
            "ean": "",
            "externalId": 47966,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": 0,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 86277,
            "description": "Humminbird 1199cxi HD SI Combo Сонар",
            "pictureUrl": "https://clients.mercoria.com/uploads/images/products/16/47970-180831172407humminbird-1199cxi-hd-si-combo-sonar-2.jpg",
            "productCode": "20164",
            "ean": "",
            "externalId": 47970,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": 0,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 86278,
            "description": "Humminbird 999cxi HD SI COMBO Сонар",
            "pictureUrl": "https://clients.mercoria.com/uploads/images/products/16/47971-180903101618humminbird-999cxi-hd-si-combo-sonar-1.png",
            "productCode": "20165",
            "ean": "",
            "externalId": 47971,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": 0,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 86279,
            "description": "Humminbird 899cxi HD SI Combo Сонар",
            "pictureUrl": "https://clients.mercoria.com/uploads/images/products/16/47972-180903101526humminbird-899cxi-hd-si-combo-sonar-2.png",
            "productCode": "20166",
            "ean": "",
            "externalId": 47972,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": 0,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 86280,
            "description": "Strike Pro Cyber Vibe JG-005A 3.5см 4.5г Цикада",
            "pictureUrl": "https://clients.mercoria.com/uploads/images/products/16/47943-strike-pro-cyber-vibe-jg-005a-35sm-45g-cikada-1.png",
            "productCode": "20277",
            "ean": "",
            "externalId": 47943,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": 4,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 86281,
            "description": "Simrad NSS 9 Evo3 Сонар",
            "pictureUrl": "https://clients.mercoria.com/uploads/images/products/16/47973-simrad-nss-9-evo3-sonar-1.jpg",
            "productCode": "26190",
            "ean": "",
            "externalId": 47973,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": 0,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 86282,
            "description": "Simrad NSS 7 Evo3 Сонар",
            "pictureUrl": "https://clients.mercoria.com/uploads/images/products/16/47974-simrad-nss-7-evo3-sonar-1.jpg",
            "productCode": "26192",
            "ean": "",
            "externalId": 47974,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": 0,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 86283,
            "description": "Humminbird Helix 12 Chirp SI GPS Сонар",
            "pictureUrl": "https://clients.mercoria.com/uploads/images/products/16/47975-humminbird-helix-12-chirp-si-gps-sonar-1.jpg",
            "productCode": "26208",
            "ean": "",
            "externalId": 47975,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": 0,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 86284,
            "description": "Humminbird HELIX 12 CHIRP MEGA SI GPS G2N Сонар",
            "pictureUrl": "https://clients.mercoria.com/uploads/images/products/16/47963-humminbird-helix-12-chirp-mega-si-gps-g2n-sonar-1.jpg",
            "productCode": "263",
            "ean": "",
            "externalId": 47963,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": 0,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 86285,
            "description": "Humminbird HELIX 10 CHIRP MEGA SI GPS G2N Сонар",
            "pictureUrl": "https://clients.mercoria.com/uploads/images/products/16/47964-humminbird-helix-10-chirp-mega-si-gps-g2n-sonar-1.jpg",
            "productCode": "265",
            "ean": "",
            "externalId": 47964,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": 0,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 86286,
            "description": "Humminbird HELIX 10 SI GPS Сонар",
            "pictureUrl": "https://clients.mercoria.com/uploads/images/products/16/47967-humminbird-helix-10-si-gps-sonar-1.png",
            "productCode": "266",
            "ean": "",
            "externalId": 47967,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": 0,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 86287,
            "description": "Humminbird HELIX 9 CHIRP MEGA SI GPS G2N Сонар",
            "pictureUrl": "https://clients.mercoria.com/uploads/images/products/16/47965-humminbird-helix-9-chirp-mega-si-gps-g2n-sonar-1.jpg",
            "productCode": "267",
            "ean": "",
            "externalId": 47965,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": 0,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 86288,
            "description": "Humminbird HELIX 9 SI GPS Сонар",
            "pictureUrl": "https://clients.mercoria.com/uploads/images/products/16/47968-humminbird-helix-9-si-gps-sonar-1.png",
            "productCode": "268",
            "ean": "",
            "externalId": 47968,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": 0,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 86289,
            "description": "Pontoon 21 Jilt 2.5'' Силиконова примамка",
            "pictureUrl": "https://clients.mercoria.com/uploads/images/products/16/47944-0038358.jpeg",
            "productCode": "32018",
            "ean": "",
            "externalId": 47944,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": 0,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 86290,
            "description": "Pontoon 21 Jilt 3'' Силиконова примамка",
            "pictureUrl": "https://clients.mercoria.com/uploads/images/products/16/47945-0038358.jpeg",
            "productCode": "32039",
            "ean": "",
            "externalId": 47945,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": 0,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 86291,
            "description": "Garmin VIRB® Ultra 30 Eкшън камера",
            "pictureUrl": "https://clients.mercoria.com/uploads/images/products/16/47958-virb_ultra30-image-00.jpg",
            "productCode": "37791",
            "ean": "",
            "externalId": 47958,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": 0,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 86292,
            "description": "Garmin VIRB® XE Водоустойчивa HD екшън камера",
            "pictureUrl": "https://clients.mercoria.com/uploads/images/products/16/47960-virb_xe_hr_34391-1000x750.jpg",
            "productCode": "37832",
            "ean": "",
            "externalId": 47960,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": 0,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 86293,
            "description": "Garmin Dash Cam™ 45 Видеорегистратор",
            "pictureUrl": "https://clients.mercoria.com/uploads/images/products/16/45224-27-pic_9728_480.jpg",
            "productCode": "37839",
            "ean": "",
            "externalId": 45224,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": 0,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 86294,
            "description": "Garmin Garmin Dash Cam™ 55 Видеорегистратор",
            "pictureUrl": "https://clients.mercoria.com/uploads/images/products/16/45225-27-pic_9734_480.jpg",
            "productCode": "37848",
            "ean": "",
            "externalId": 45225,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": 0,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 86295,
            "description": "Garmin echoMAP™ CHIRP 52cv Сонар",
            "pictureUrl": "https://clients.mercoria.com/uploads/images/products/16/45226-27-pic_8390_480.jpg",
            "productCode": "37879",
            "ean": "",
            "externalId": 45226,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": 0,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 86296,
            "description": "Garmin Garmin Dash Cam™ 65W Камера",
            "pictureUrl": "https://clients.mercoria.com/uploads/images/products/16/45227-27-pic_9909_480.jpg",
            "productCode": "37883",
            "ean": "",
            "externalId": 45227,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": 0,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 86297,
            "description": "Garmin GFL™ 10, NMEA 2000 адаптор за ниво на горивото в резервоара",
            "pictureUrl": "https://clients.mercoria.com/uploads/images/products/16/45228-27-pic_3168_480.jpg",
            "productCode": "37970",
            "ean": "",
            "externalId": 45228,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": 0,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 86298,
            "description": "Garmin GPS 19x HVS Антена/приемник",
            "pictureUrl": "https://clients.mercoria.com/uploads/images/products/16/47957-0-24447cc0-800.jpg",
            "productCode": "38112",
            "ean": "",
            "externalId": 47957,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": 0,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 86299,
            "description": "Garmin GPS 19x NMEA 2000 Антена/приемник",
            "pictureUrl": "https://clients.mercoria.com/uploads/images/products/16/47959-0-c35ce9ab-800.jpg",
            "productCode": "38114",
            "ean": "",
            "externalId": 47959,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": 0,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 86300,
            "description": "Pontoon 21 Awaruna 102 Силиконова примамка",
            "pictureUrl": "https://clients.mercoria.com/uploads/images/products/16/47946-e_26b2be831b9b07fb26d398c2c590116a.jpg",
            "productCode": "41051",
            "ean": "",
            "externalId": 47946,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": 0,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 86301,
            "description": "Pontoon 21 Awaruna 4.5 Силиконова примамка",
            "pictureUrl": "https://clients.mercoria.com/uploads/images/products/16/47947-f_e8fe517a55184106ecce88438c87c22e.jpg",
            "productCode": "41454",
            "ean": "",
            "externalId": 47947,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": 0,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 86302,
            "description": "Pontoon 21 Awaruna 1.5 Силиконова примамка",
            "pictureUrl": "https://clients.mercoria.com/uploads/images/products/16/47948-awaruna_45-logo.jpg",
            "productCode": "41456",
            "ean": "",
            "externalId": 47948,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": 0,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 86303,
            "description": "Pontoon 21 Awaruna 2.5 Силиконова примамка",
            "pictureUrl": "https://clients.mercoria.com/uploads/images/products/16/47949-181123112138awaruna_45-logo.jpg",
            "productCode": "41457",
            "ean": "",
            "externalId": 47949,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": 0,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 86304,
            "description": "Pontoon 21 Awaruna 3.5 Силиконова примамка",
            "pictureUrl": "https://clients.mercoria.com/uploads/images/products/16/47950-pontoon21-awaruna-440-1508249302-2.jpg",
            "productCode": "41458",
            "ean": "",
            "externalId": 47950,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": 0,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 86305,
            "description": "Pontoon 21 Awaruna 2.0 Силиконова примамка",
            "pictureUrl": "https://clients.mercoria.com/uploads/images/products/16/47951-awaruna4.jpg",
            "productCode": "41468",
            "ean": "",
            "externalId": 47951,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": 0,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 86306,
            "description": "GKJ-S63/2",
            "pictureUrl": "",
            "productCode": "41686",
            "ean": "",
            "externalId": 45221,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": 0,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 86307,
            "description": "GKJ-S56/6",
            "pictureUrl": "",
            "productCode": "41687",
            "ean": "",
            "externalId": 45229,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": 0,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 86308,
            "description": "GKJ-S63/4",
            "pictureUrl": "",
            "productCode": "41688",
            "ean": "640106",
            "externalId": 45230,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": 0,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 86309,
            "description": "GKJ-B54/6",
            "pictureUrl": "",
            "productCode": "41689",
            "ean": "",
            "externalId": 45231,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": 0,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 86310,
            "description": "NJB-65/3SP",
            "pictureUrl": "",
            "productCode": "41701",
            "ean": "640110",
            "externalId": 45235,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": 0,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 86311,
            "description": "NJB-65/4SP",
            "pictureUrl": "",
            "productCode": "41702",
            "ean": "640109",
            "externalId": 45236,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": 0,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 86312,
            "description": "NJB-65/5 SP",
            "pictureUrl": "",
            "productCode": "41703",
            "ean": "640142",
            "externalId": 45240,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": 0,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 86313,
            "description": "68ML/TR",
            "pictureUrl": "",
            "productCode": "41704",
            "ean": "640147",
            "externalId": 45241,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": 0,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 86314,
            "description": "NJS-63/3",
            "pictureUrl": "",
            "productCode": "41705",
            "ean": "640101",
            "externalId": 45245,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": 0,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 86315,
            "description": "62/4",
            "pictureUrl": "https://clients.mercoria.com/uploads/images/products/16/47955-g-624.jpg",
            "productCode": "41775",
            "ean": "",
            "externalId": 47955,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": 188,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 86316,
            "description": "Garmin GHS 11i VHF слушалка",
            "pictureUrl": "https://clients.mercoria.com/uploads/images/products/16/47956-garmin-ghs-11i-vhf.jpg",
            "productCode": "47505",
            "ean": "",
            "externalId": 47956,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": 0,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 86317,
            "description": "Garmin радVHF 315i Морско радио",
            "pictureUrl": "https://clients.mercoria.com/uploads/images/products/16/47962-315i.jpg",
            "productCode": "47517",
            "ean": "",
            "externalId": 47962,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": 0,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 86318,
            "description": "Maria FLA-PEN Shallow 85 Воблер",
            "pictureUrl": "https://clients.mercoria.com/uploads/images/products/16/45219-maria-fla-pen-shallow-85-vobler-2.jpg",
            "productCode": "7524",
            "ean": "",
            "externalId": 45219,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": 12,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 86319,
            "description": "Maria ANGEL KISS EKF 140 Воблер",
            "pictureUrl": "https://clients.mercoria.com/uploads/images/products/16/45220-maria-angel-kiss-ekf-140-vobler-1.jpg",
            "productCode": "7537",
            "ean": "",
            "externalId": 45220,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": 27,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 86320,
            "description": "Maria SQUASH S95 Воблер",
            "pictureUrl": "https://clients.mercoria.com/uploads/images/products/16/45222-maria-squash-s95-vobler-1.jpg",
            "productCode": "7562",
            "ean": "",
            "externalId": 45222,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": 12,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 86321,
            "description": "Maria SQUASH S125 Воблер",
            "pictureUrl": "https://clients.mercoria.com/uploads/images/products/16/45223-maria-squash-s125-vobler-1.jpg",
            "productCode": "7573",
            "ean": "",
            "externalId": 45223,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": 22,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 86322,
            "description": "Maria FAKE BAITS F50 Воблер",
            "pictureUrl": "https://clients.mercoria.com/uploads/images/products/16/45232-maria-fake-baits-f50-vobler-1.jpg",
            "productCode": "7587",
            "ean": "",
            "externalId": 45232,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": 2,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 86323,
            "description": "Maria FAKE BAITS F90 Воблер",
            "pictureUrl": "https://clients.mercoria.com/uploads/images/products/16/45233-maria-fake-baits-f90-vobler-1.jpg",
            "productCode": "7589",
            "ean": "",
            "externalId": 45233,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": 5,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 86324,
            "description": "Salmo Minnow Floating Воблер",
            "pictureUrl": "https://clients.mercoria.com/uploads/images/products/16/45234-180810172643salmo-minnow-floating-vobler-2.jpg",
            "productCode": "7762",
            "ean": "",
            "externalId": 45234,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": 3,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 86325,
            "description": "Rapala Jointed Shad Rap 7см Воблер",
            "pictureUrl": "https://clients.mercoria.com/uploads/images/products/16/45237-rapala-jointed-shad-rap-7sm-vobler-2.jpg",
            "productCode": "7780",
            "ean": "",
            "externalId": 45237,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": 13,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 86326,
            "description": "Salmo Butcher Super Deep Runner Floating Воблер",
            "pictureUrl": "https://clients.mercoria.com/uploads/images/products/16/45238-salmo-butcher-super-deep-runner-floating-vobler-1.jpg",
            "productCode": "7819",
            "ean": "",
            "externalId": 45238,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": 6,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 86327,
            "description": "Rapala Scatter Rap Deep Husky Jerk 10см. Воблер",
            "pictureUrl": "https://clients.mercoria.com/uploads/images/products/16/45239-rapala-scatter-rap-deep-husky-jerk-10sm-vobler-2.jpg",
            "productCode": "7973",
            "ean": "",
            "externalId": 45239,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": 10,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 86328,
            "description": "Rapala Risto Rap 8см Воблер",
            "pictureUrl": "https://clients.mercoria.com/uploads/images/products/16/45242-rapala-risto-rap-8sm-vobler-2.jpg",
            "productCode": "7988",
            "ean": "",
            "externalId": 45242,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": 21,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 86329,
            "description": "DAIWA CREEK SPINNER 3.0g Блесна",
            "pictureUrl": "https://clients.mercoria.com/uploads/images/products/16/47952-210714151912screenshot_8.jpg",
            "productCode": "80313",
            "ean": "",
            "externalId": 47952,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": 3,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 86330,
            "description": "DAIWA CREEK SPINNER 6.0g Блесна",
            "pictureUrl": "https://clients.mercoria.com/uploads/images/products/16/47953-21071415430720120910451919192124345.jpg",
            "productCode": "80314",
            "ean": "",
            "externalId": 47953,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": 6,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 86331,
            "description": "DAIWA CREEK SPINNER 4.0g Блесна",
            "pictureUrl": "https://clients.mercoria.com/uploads/images/products/16/47954-210714154556screenshot_9.jpg",
            "productCode": "80315",
            "ean": "",
            "externalId": 47954,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": 4,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 86332,
            "description": "Rapala Ultra Light Shad Воблер",
            "pictureUrl": "https://clients.mercoria.com/uploads/images/products/16/45243-rapala-ultra-light-shad-vobler-2.jpg",
            "productCode": "8074",
            "ean": "",
            "externalId": 45243,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": 3,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 86333,
            "description": "Rapala Shad Rap 9см Воблер",
            "pictureUrl": "https://clients.mercoria.com/uploads/images/products/16/45244-rapala-shad-rap-9sm-vobler-2.jpg",
            "productCode": "8238",
            "ean": "",
            "externalId": 45244,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": 15,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 86334,
            "description": "Rapala Shadow Rap Shad Deep Воблер",
            "pictureUrl": "https://clients.mercoria.com/uploads/images/products/16/45246-rapala-shadow-rap-shad-deep-vobler-2.jpg",
            "productCode": "8389",
            "ean": "",
            "externalId": 45246,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": 12,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 86335,
            "description": "Salmo Freediver Saltwater Super Deep Runner Floating Воблер",
            "pictureUrl": "https://clients.mercoria.com/uploads/images/products/16/45249-salmo-freediver-saltwater-super-deep-runner-floating-vobler-2.jpg",
            "productCode": "8409",
            "ean": "5902730314066",
            "externalId": 45249,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": 24,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 86336,
            "description": "Rapala Husky Magnum Воблер",
            "pictureUrl": "https://clients.mercoria.com/uploads/images/products/16/45247-rapala-husky-magnum-vobler-2.jpg",
            "productCode": "8453",
            "ean": "",
            "externalId": 45247,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": 36,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 86337,
            "description": "Rapala Scatter Rap Tail Dancer Воблер",
            "pictureUrl": "https://clients.mercoria.com/uploads/images/products/16/45252-rapala-scatter-rap-tail-dancer-vobler-2.jpg",
            "productCode": "8481",
            "ean": "",
            "externalId": 45252,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": 13,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 86338,
            "description": "Scatter Rap Shad Deep Воблер",
            "pictureUrl": "https://clients.mercoria.com/uploads/images/products/16/45253-scatter-rap-shad-deep-vobler-2.jpg",
            "productCode": "8659",
            "ean": "",
            "externalId": 45253,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": 7,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 86339,
            "description": "Rapala Floating Magnum Воблер",
            "pictureUrl": "https://clients.mercoria.com/uploads/images/products/16/45254-rapala-floating-magnum-vobler-2.jpg",
            "productCode": "8745",
            "ean": "",
            "externalId": 45254,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": 15,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 86340,
            "description": "Геймърска мишка Logitech G903 Lightspeed, Черна | 910-005672",
            "pictureUrl": "",
            "productCode": "88056",
            "ean": "",
            "externalId": 47924,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": 0,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 86341,
            "description": "Rapala Down Deep Husky Jerk 12см Воблер",
            "pictureUrl": "https://clients.mercoria.com/uploads/images/products/16/45256-rapala-down-deep-husky-jerk-12sm-vobler-3.jpg",
            "productCode": "8817",
            "ean": "",
            "externalId": 45256,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": 11,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 86342,
            "description": "Rapala Ultra Light Crank Воблер",
            "pictureUrl": "https://clients.mercoria.com/uploads/images/products/16/45257-rapala-u-l-crank.jpg",
            "productCode": "8901",
            "ean": "",
            "externalId": 45257,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": 4,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 86343,
            "description": "Rapala X-Rap Magnum XRMAG40 Воблер",
            "pictureUrl": "https://clients.mercoria.com/uploads/images/products/16/45258-rapala-x-rap-magnum-xrmag40-vobler-5.jpg",
            "productCode": "8939",
            "ean": "",
            "externalId": 45258,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": 77,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 86344,
            "description": "Rapala CountDown CD11 Воблер",
            "pictureUrl": "https://clients.mercoria.com/uploads/images/products/16/45259-rapala-countdown-cd11-vobler-3.jpg",
            "productCode": "9160",
            "ean": "",
            "externalId": 45259,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": 16,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 86345,
            "description": "Rapala Weedless Shad Воблер",
            "pictureUrl": "https://clients.mercoria.com/uploads/images/products/16/45260-rapala-weedless-shad-vobler-3.jpg",
            "productCode": "9284",
            "ean": "",
            "externalId": 45260,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": 16,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 86346,
            "description": "Salmo Hornet Deep Runner 9F Воблер",
            "pictureUrl": "https://clients.mercoria.com/uploads/images/products/16/45261-180810173050salmo-hornet-deep-runner-9f-vobler-1.jpg",
            "productCode": "9331",
            "ean": "",
            "externalId": 45261,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": 36,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 86347,
            "description": "Salmo Hornet Deep Runner H6S Воблер",
            "pictureUrl": "https://clients.mercoria.com/uploads/images/products/16/45262-salmo-hornet-deep-runner-h6s-vobler-1.jpg",
            "productCode": "9384",
            "ean": "",
            "externalId": 45262,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": 14,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 86348,
            "description": "Rapala Ultra Light Pop Воблер",
            "pictureUrl": "https://clients.mercoria.com/uploads/images/products/16/45263-rapala-ultra-light-pop-vobler-2.jpg",
            "productCode": "9474",
            "ean": "",
            "externalId": 45263,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": 3,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 86349,
            "description": "Rapala Max Rap Fat Minnow Воблер",
            "pictureUrl": "https://clients.mercoria.com/uploads/images/products/16/45264-rapala-max-rap-fat-minnow-vobler-2.jpg",
            "productCode": "9607",
            "ean": "",
            "externalId": 45264,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": 13,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 86350,
            "description": "Rapala Shallow Shad Rap 9см Воблер",
            "pictureUrl": "https://clients.mercoria.com/uploads/images/products/16/45266-rapala-shallow-shad-rap-9.jpg",
            "productCode": "9733",
            "ean": "",
            "externalId": 45266,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": 12,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 86351,
            "description": "Тест на наличност",
            "pictureUrl": "",
            "productCode": "97477",
            "ean": "",
            "externalId": 45248,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": 0,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 86352,
            "description": "BAGSO 2",
            "pictureUrl": "https://clients.mercoria.com/uploads/images/products/16/45250-1-20221122_113025698_ios_webp.webp",
            "productCode": "97554",
            "ean": "12377AS",
            "externalId": 45250,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": 0,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 86353,
            "description": "тест атрубътуи",
            "pictureUrl": "",
            "productCode": "97612",
            "ean": "",
            "externalId": 45265,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": 0,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 86354,
            "description": "Персонализация - селект",
            "pictureUrl": "",
            "productCode": "97631",
            "ean": "",
            "externalId": 45269,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": 0,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 86355,
            "description": "Тест на продукти без цени",
            "pictureUrl": "",
            "productCode": "97632",
            "ean": "",
            "externalId": 45270,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": 0,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 86356,
            "description": "Серво мотор 200W-750W",
            "pictureUrl": "",
            "productCode": "97665",
            "ean": "",
            "externalId": 47961,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": 0,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 108249,
            "description": "Produs evidenta palet sus",
            "pictureUrl": "",
            "productCode": "paletproduct_35499_tisho",
            "ean": "paletproduct_35499_tisho",
            "externalId": 0,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": 0,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": null,
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": null,
            "updatedAt": null
        },
        {
            "productId": 130224,
            "description": "iPhone 16 256GB",
            "pictureUrl": "",
            "productCode": "10001",
            "ean": "10001",
            "externalId": 10001,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": 0,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": "Metrica",
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": "2025-06-06T10:57:35.000000Z",
            "updatedAt": "2025-06-06T10:58:32.000000Z"
        },
        {
            "productId": 130225,
            "description": "USB-C Cabel 3m",
            "pictureUrl": "",
            "productCode": "10007",
            "ean": "10007",
            "externalId": 10007,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": 0,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": "Metrica",
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": "2025-06-06T10:57:52.000000Z",
            "updatedAt": "2025-06-06T10:57:52.000000Z"
        },
        {
            "productId": 130226,
            "description": "iPhone 15 Pro 128GB",
            "pictureUrl": "",
            "productCode": "10003",
            "ean": "10003",
            "externalId": 10003,
            "price": "0.00",
            "VATPercentage": 0,
            "WEEETax": "0.00",
            "weight": 0,
            "productType": "Normal",
            "expirationType": "0",
            "expirationTypeDescription": "Normal",
            "useDefaultExpiryOnReception": false,
            "generalType": null,
            "condition": "GOOD",
            "invoiceExternalIdentifier": null,
            "externalSource": "Metrica",
            "externalSourceProductId": null,
            "hasSerialNumber": false,
            "createdAt": "2025-06-06T10:58:06.000000Z",
            "updatedAt": "2025-06-06T10:58:06.000000Z"
        }
    ],
    "links": {
        "first": "https://clients.metrica.bg/api/v1/connectors/client/products?page=1",
        "last": null,
        "prev": null,
        "next": null
    },
    "meta": {
        "current_page": 1,
        "from": 1,
        "path": "https://clients.metrica.bg/api/v1/connectors/client/products",
        "per_page": 1000,
        "to": 114
    },
    "success": true
}
 

Request      

GET api/v1/connectors/client/products

Headers

Authorization      

Example: Bearer {YOUR_AUTH_TOKEN}

Content-Type      

Example: application/json

Accept      

Example: application/json

Query Parameters

page   integer  optional  

Which page to show. Example: 1

GET Filtered Products

requires authentication

List all products that match filters.

Presents the result with page size and simple pagination (without showing the total number of records and last page).

Throttling: Max 20 requests per minute. (20/1) Max 100 requests per hour. (100/60)

Default page size : 250 records per page. (Maximum 1000 records per page)

Example request:
$client = new \GuzzleHttp\Client();
$url = 'https://clients.metrica.bg/api/v1/connectors/client/products/filter';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_TOKEN}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'query' => [
            'page' => '1',
        ],
        'json' => [
            'ids' => '184735,184736,3049927',
            'productCode' => 'MHM223259',
            'barcode' => '4971850911119',
            'externalId' => '109',
            'startDate' => '2025-01-01 12:59:59',
            'endDate' => '2025-02-07 13:10:00',
            'dateFilterBy' => 'CREATED_AT',
            'sortDate' => 'ASC',
            'perPage' => 250,
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://clients.metrica.bg/api/v1/connectors/client/products/filter"
);

const params = {
    "page": "1",
};
Object.keys(params)
    .forEach(key => url.searchParams.append(key, params[key]));

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

let body = {
    "ids": "184735,184736,3049927",
    "productCode": "MHM223259",
    "barcode": "4971850911119",
    "externalId": "109",
    "startDate": "2025-01-01 12:59:59",
    "endDate": "2025-02-07 13:10:00",
    "dateFilterBy": "CREATED_AT",
    "sortDate": "ASC",
    "perPage": 250
};

fetch(url, {
    method: "GET",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());
curl --request GET \
    --get "https://clients.metrica.bg/api/v1/connectors/client/products/filter?page=1" \
    --header "Authorization: Bearer {YOUR_AUTH_TOKEN}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"ids\": \"184735,184736,3049927\",
    \"productCode\": \"MHM223259\",
    \"barcode\": \"4971850911119\",
    \"externalId\": \"109\",
    \"startDate\": \"2025-01-01 12:59:59\",
    \"endDate\": \"2025-02-07 13:10:00\",
    \"dateFilterBy\": \"CREATED_AT\",
    \"sortDate\": \"ASC\",
    \"perPage\": 250
}"
import requests
import json

url = 'https://clients.metrica.bg/api/v1/connectors/client/products/filter'
payload = {
    "ids": "184735,184736,3049927",
    "productCode": "MHM223259",
    "barcode": "4971850911119",
    "externalId": "109",
    "startDate": "2025-01-01 12:59:59",
    "endDate": "2025-02-07 13:10:00",
    "dateFilterBy": "CREATED_AT",
    "sortDate": "ASC",
    "perPage": 250
}
params = {
  'page': '1',
}
headers = {
  'Authorization': 'Bearer {YOUR_AUTH_TOKEN}',
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}

response = requests.request('GET', url, headers=headers, json=payload, params=params)
response.json()

Example response (200):

Show headers
cache-control: no-cache, private
content-type: application/json
x-ratelimit-limit: 20
x-ratelimit-remaining: 19
access-control-allow-origin: *
 

{
    "data": [],
    "links": {
        "first": "https://clients.metrica.bg/api/v1/connectors/client/products/filter?page=1",
        "last": null,
        "prev": null,
        "next": null
    },
    "meta": {
        "current_page": 1,
        "from": null,
        "path": "https://clients.metrica.bg/api/v1/connectors/client/products/filter",
        "per_page": 250,
        "to": null
    },
    "success": true
}
 

Request      

GET api/v1/connectors/client/products/filter

Headers

Authorization      

Example: Bearer {YOUR_AUTH_TOKEN}

Content-Type      

Example: application/json

Accept      

Example: application/json

Query Parameters

page   integer  optional  

Which page to show. Example: 1

Body Parameters

ids   string  optional  

List of comma-separated Product IDs. Example: 184735,184736,3049927

productCode   string  optional  

The product code. Example: MHM223259

barcode   string  optional  

The product barcode/ean. Example: 4971850911119

externalId   string  optional  

The product external id. Example: 109

startDate   date  optional  

A date between past and today. The format must be in: Y-m-d H:i:s. Example: 2025-01-01 12:59:59

endDate   date  optional  

A date between past and today. If there is a startDate, endDate must be later than startDate. The format must be in: Y-m-d H:i:s. Example: 2025-02-07 13:10:00

dateFilterBy   enum(CREATED_AT,UPDATED_AT)  optional  

The column to which startDate and endDate are compared. - Default: CREATED_AT. Example: CREATED_AT

sortDate   enum(DESC,ASC)  optional  

Order in which to retrieve results. - Default : ASC. Example: ASC

perPage   integer  optional  

Number of entries per page. The allowed values are between 10 and 1000. If not provided, the default is 250. Example: 250

GET Products created today

requires authentication

List all products that were created today

Presents the result with page size and pagination.

Throttling: Max 20 requests per hour. (20/60)

Default page size : 1000 records per page.

Example request:
$client = new \GuzzleHttp\Client();
$url = 'https://clients.metrica.bg/api/v1/connectors/client/products/filter/createdToday';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_TOKEN}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'query' => [
            'page' => '1',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://clients.metrica.bg/api/v1/connectors/client/products/filter/createdToday"
);

const params = {
    "page": "1",
};
Object.keys(params)
    .forEach(key => url.searchParams.append(key, params[key]));

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

fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());
curl --request GET \
    --get "https://clients.metrica.bg/api/v1/connectors/client/products/filter/createdToday?page=1" \
    --header "Authorization: Bearer {YOUR_AUTH_TOKEN}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
import requests
import json

url = 'https://clients.metrica.bg/api/v1/connectors/client/products/filter/createdToday'
params = {
  'page': '1',
}
headers = {
  'Authorization': 'Bearer {YOUR_AUTH_TOKEN}',
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}

response = requests.request('GET', url, headers=headers, params=params)
response.json()

Example response (200):

Show headers
cache-control: no-cache, private
content-type: application/json
x-ratelimit-limit: 20
x-ratelimit-remaining: 18
access-control-allow-origin: *
 

{
    "data": [],
    "links": {
        "first": "https://clients.metrica.bg/api/v1/connectors/client/products/filter/createdToday?page=1",
        "last": "https://clients.metrica.bg/api/v1/connectors/client/products/filter/createdToday?page=1",
        "prev": null,
        "next": null
    },
    "meta": {
        "current_page": 1,
        "from": null,
        "last_page": 1,
        "links": [
            {
                "url": null,
                "label": "« Previous",
                "active": false
            },
            {
                "url": "https://clients.metrica.bg/api/v1/connectors/client/products/filter/createdToday?page=1",
                "label": "1",
                "active": true
            },
            {
                "url": null,
                "label": "Next »",
                "active": false
            }
        ],
        "path": "https://clients.metrica.bg/api/v1/connectors/client/products/filter/createdToday",
        "per_page": 1000,
        "to": null,
        "total": 0
    },
    "success": true
}
 

Request      

GET api/v1/connectors/client/products/filter/createdToday

Headers

Authorization      

Example: Bearer {YOUR_AUTH_TOKEN}

Content-Type      

Example: application/json

Accept      

Example: application/json

Query Parameters

page   integer  optional  

Which page to show. Example: 1

GET Products updated today

requires authentication

List all products that were updated today

Presents the result with page size and pagination. Changes on product stock does not reflect as a product update.

Throttling: Max 20 requests per hour. (20/60)

Default page size : 1000 records per page.

Example request:
$client = new \GuzzleHttp\Client();
$url = 'https://clients.metrica.bg/api/v1/connectors/client/products/filter/updatedToday';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_TOKEN}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'query' => [
            'page' => '1',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://clients.metrica.bg/api/v1/connectors/client/products/filter/updatedToday"
);

const params = {
    "page": "1",
};
Object.keys(params)
    .forEach(key => url.searchParams.append(key, params[key]));

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

fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());
curl --request GET \
    --get "https://clients.metrica.bg/api/v1/connectors/client/products/filter/updatedToday?page=1" \
    --header "Authorization: Bearer {YOUR_AUTH_TOKEN}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
import requests
import json

url = 'https://clients.metrica.bg/api/v1/connectors/client/products/filter/updatedToday'
params = {
  'page': '1',
}
headers = {
  'Authorization': 'Bearer {YOUR_AUTH_TOKEN}',
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}

response = requests.request('GET', url, headers=headers, params=params)
response.json()

Example response (200):

Show headers
cache-control: no-cache, private
content-type: application/json
x-ratelimit-limit: 20
x-ratelimit-remaining: 18
access-control-allow-origin: *
 

{
    "data": [],
    "links": {
        "first": "https://clients.metrica.bg/api/v1/connectors/client/products/filter/updatedToday?page=1",
        "last": "https://clients.metrica.bg/api/v1/connectors/client/products/filter/updatedToday?page=1",
        "prev": null,
        "next": null
    },
    "meta": {
        "current_page": 1,
        "from": null,
        "last_page": 1,
        "links": [
            {
                "url": null,
                "label": "« Previous",
                "active": false
            },
            {
                "url": "https://clients.metrica.bg/api/v1/connectors/client/products/filter/updatedToday?page=1",
                "label": "1",
                "active": true
            },
            {
                "url": null,
                "label": "Next »",
                "active": false
            }
        ],
        "path": "https://clients.metrica.bg/api/v1/connectors/client/products/filter/updatedToday",
        "per_page": 1000,
        "to": null,
        "total": 0
    },
    "success": true
}
 

Request      

GET api/v1/connectors/client/products/filter/updatedToday

Headers

Authorization      

Example: Bearer {YOUR_AUTH_TOKEN}

Content-Type      

Example: application/json

Accept      

Example: application/json

Query Parameters

page   integer  optional  

Which page to show. Example: 1

GET Product By ID

requires authentication

Get Product information by internal ID

Throttling: Max 60 requests per minute. (60/1)

Example request:
$client = new \GuzzleHttp\Client();
$url = 'https://clients.metrica.bg/api/v1/connectors/client/products/byId/184742';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_TOKEN}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://clients.metrica.bg/api/v1/connectors/client/products/byId/184742"
);

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

fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());
curl --request GET \
    --get "https://clients.metrica.bg/api/v1/connectors/client/products/byId/184742" \
    --header "Authorization: Bearer {YOUR_AUTH_TOKEN}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
import requests
import json

url = 'https://clients.metrica.bg/api/v1/connectors/client/products/byId/184742'
headers = {
  'Authorization': 'Bearer {YOUR_AUTH_TOKEN}',
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}

response = requests.request('GET', url, headers=headers)
response.json()

Example response (404):


{
    "success": false,
    "error": {
        "message": "Entry for Product not found",
        "code": 404
    }
}
 

Example response (404):

Show headers
cache-control: no-cache, private
content-type: application/json
x-ratelimit-limit: 60
x-ratelimit-remaining: 59
access-control-allow-origin: *
 

{
    "success": false,
    "error": {
        "message": "Entry for Product not found",
        "code": 404
    }
}
 

Request      

GET api/v1/connectors/client/products/byId/{id}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_TOKEN}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

id   integer   

The product ID. Example: 184742

GET Product By EAN

requires authentication

Get Product information by its EAN (barcode)

This endpoint will return the first product found with the given param value!

Throttling: Max 60 requests per minute. (60/1)

Example request:
$client = new \GuzzleHttp\Client();
$url = 'https://clients.metrica.bg/api/v1/connectors/client/products/byEan/4971850911118';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_TOKEN}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://clients.metrica.bg/api/v1/connectors/client/products/byEan/4971850911118"
);

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

fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());
curl --request GET \
    --get "https://clients.metrica.bg/api/v1/connectors/client/products/byEan/4971850911118" \
    --header "Authorization: Bearer {YOUR_AUTH_TOKEN}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
import requests
import json

url = 'https://clients.metrica.bg/api/v1/connectors/client/products/byEan/4971850911118'
headers = {
  'Authorization': 'Bearer {YOUR_AUTH_TOKEN}',
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}

response = requests.request('GET', url, headers=headers)
response.json()

Example response (404):


{
    "success": false,
    "error": {
        "message": "Entry for Product not found",
        "code": 404
    }
}
 

Example response (404):

Show headers
cache-control: no-cache, private
content-type: application/json
x-ratelimit-limit: 60
x-ratelimit-remaining: 59
access-control-allow-origin: *
 

{
    "success": false,
    "error": {
        "message": "Entry for Product not found",
        "code": 404
    }
}
 

Request      

GET api/v1/connectors/client/products/byEan/{ean}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_TOKEN}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

ean   string   

The product EAN. Example: 4971850911118

GET Product By Product Code

requires authentication

Get Product information by its Product Code

This endpoint will return the first product found with the given param value!

Throttling: Max 60 requests per minute. (60/1)

Example request:
$client = new \GuzzleHttp\Client();
$url = 'https://clients.metrica.bg/api/v1/connectors/client/products/byProductCode/MHM223256';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_TOKEN}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://clients.metrica.bg/api/v1/connectors/client/products/byProductCode/MHM223256"
);

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

fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());
curl --request GET \
    --get "https://clients.metrica.bg/api/v1/connectors/client/products/byProductCode/MHM223256" \
    --header "Authorization: Bearer {YOUR_AUTH_TOKEN}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
import requests
import json

url = 'https://clients.metrica.bg/api/v1/connectors/client/products/byProductCode/MHM223256'
headers = {
  'Authorization': 'Bearer {YOUR_AUTH_TOKEN}',
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}

response = requests.request('GET', url, headers=headers)
response.json()

Example response (404):


{
    "success": false,
    "error": {
        "message": "Entry for Product not found",
        "code": 404
    }
}
 

Example response (404):

Show headers
cache-control: no-cache, private
content-type: application/json
x-ratelimit-limit: 60
x-ratelimit-remaining: 59
access-control-allow-origin: *
 

{
    "success": false,
    "error": {
        "message": "Entry for Product not found",
        "code": 404
    }
}
 

Request      

GET api/v1/connectors/client/products/byProductCode/{productCode}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_TOKEN}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

productCode   string   

The product code. Example: MHM223256

GET Product By External ID

requires authentication

Get Product information by its External ID

This endpoint will return the first product found with the given param value!

Throttling: Max 60 requests per minute. (60/1)

Example request:
$client = new \GuzzleHttp\Client();
$url = 'https://clients.metrica.bg/api/v1/connectors/client/products/byExternalId/105';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_TOKEN}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://clients.metrica.bg/api/v1/connectors/client/products/byExternalId/105"
);

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

fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());
curl --request GET \
    --get "https://clients.metrica.bg/api/v1/connectors/client/products/byExternalId/105" \
    --header "Authorization: Bearer {YOUR_AUTH_TOKEN}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
import requests
import json

url = 'https://clients.metrica.bg/api/v1/connectors/client/products/byExternalId/105'
headers = {
  'Authorization': 'Bearer {YOUR_AUTH_TOKEN}',
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}

response = requests.request('GET', url, headers=headers)
response.json()

Example response (404):


{
    "success": false,
    "error": {
        "message": "Entry for Product not found",
        "code": 404
    }
}
 

Example response (404):

Show headers
cache-control: no-cache, private
content-type: application/json
x-ratelimit-limit: 60
x-ratelimit-remaining: 59
access-control-allow-origin: *
 

{
    "success": false,
    "error": {
        "message": "Entry for Product not found",
        "code": 404
    }
}
 

Request      

GET api/v1/connectors/client/products/byExternalId/{externalId}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_TOKEN}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

externalId   string   

The product External ID. Example: 105

GET Product Stock By ID

requires authentication

Get Product stock information by internal ID

Throttling: Max 60 requests per minute. (60/1)

Example request:
$client = new \GuzzleHttp\Client();
$url = 'https://clients.metrica.bg/api/v1/connectors/client/products/stock/byId/184742';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_TOKEN}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://clients.metrica.bg/api/v1/connectors/client/products/stock/byId/184742"
);

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

fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());
curl --request GET \
    --get "https://clients.metrica.bg/api/v1/connectors/client/products/stock/byId/184742" \
    --header "Authorization: Bearer {YOUR_AUTH_TOKEN}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
import requests
import json

url = 'https://clients.metrica.bg/api/v1/connectors/client/products/stock/byId/184742'
headers = {
  'Authorization': 'Bearer {YOUR_AUTH_TOKEN}',
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}

response = requests.request('GET', url, headers=headers)
response.json()

Example response (404):


{
    "success": false,
    "error": {
        "message": "Entry for Product not found",
        "code": 404
    }
}
 

Example response (404):

Show headers
cache-control: no-cache, private
content-type: application/json
x-ratelimit-limit: 60
x-ratelimit-remaining: 58
access-control-allow-origin: *
 

{
    "success": false,
    "error": {
        "message": "Entry for Product not found",
        "code": 404
    }
}
 

Request      

GET api/v1/connectors/client/products/stock/byId/{id}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_TOKEN}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

id   integer   

The product ID. Example: 184742

CREATE Product

requires authentication

Create a new Product

Throttling: Max 100 requests per minute. (100/1)

Example request:
$client = new \GuzzleHttp\Client();
$url = 'https://clients.metrica.bg/api/v1/connectors/client/products/create';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_TOKEN}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'description' => 'TestProduct',
            'productCode' => 'ABQ.123+',
            'ean' => '8009000123A-2.A',
            'externalId' => 10999,
            'price' => '10.55',
            'weight_grams' => 1500,
            'pictureUrl' => 'https://www.pathtomyimage.com',
            'productType' => '1',
            'useDefaultExpiryOnReception' => 'no',
            'useProdIdAsEan' => 'no',
            'productSpecialType' => 'quaerat',
            'externalSource' => 'Shopify MyWebSite',
            'externalSourceProductId' => 'PRD00001',
            'useOverriddenValidationRules' => false,
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://clients.metrica.bg/api/v1/connectors/client/products/create"
);

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

let body = {
    "description": "TestProduct",
    "productCode": "ABQ.123+",
    "ean": "8009000123A-2.A",
    "externalId": 10999,
    "price": "10.55",
    "weight_grams": 1500,
    "pictureUrl": "https:\/\/www.pathtomyimage.com",
    "productType": "1",
    "useDefaultExpiryOnReception": "no",
    "useProdIdAsEan": "no",
    "productSpecialType": "quaerat",
    "externalSource": "Shopify MyWebSite",
    "externalSourceProductId": "PRD00001",
    "useOverriddenValidationRules": false
};

fetch(url, {
    method: "POST",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());
curl --request POST \
    "https://clients.metrica.bg/api/v1/connectors/client/products/create" \
    --header "Authorization: Bearer {YOUR_AUTH_TOKEN}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"description\": \"TestProduct\",
    \"productCode\": \"ABQ.123+\",
    \"ean\": \"8009000123A-2.A\",
    \"externalId\": 10999,
    \"price\": \"10.55\",
    \"weight_grams\": 1500,
    \"pictureUrl\": \"https:\\/\\/www.pathtomyimage.com\",
    \"productType\": \"1\",
    \"useDefaultExpiryOnReception\": \"no\",
    \"useProdIdAsEan\": \"no\",
    \"productSpecialType\": \"quaerat\",
    \"externalSource\": \"Shopify MyWebSite\",
    \"externalSourceProductId\": \"PRD00001\",
    \"useOverriddenValidationRules\": false
}"
import requests
import json

url = 'https://clients.metrica.bg/api/v1/connectors/client/products/create'
payload = {
    "description": "TestProduct",
    "productCode": "ABQ.123+",
    "ean": "8009000123A-2.A",
    "externalId": 10999,
    "price": "10.55",
    "weight_grams": 1500,
    "pictureUrl": "https:\/\/www.pathtomyimage.com",
    "productType": "1",
    "useDefaultExpiryOnReception": "no",
    "useProdIdAsEan": "no",
    "productSpecialType": "quaerat",
    "externalSource": "Shopify MyWebSite",
    "externalSourceProductId": "PRD00001",
    "useOverriddenValidationRules": false
}
headers = {
  'Authorization': 'Bearer {YOUR_AUTH_TOKEN}',
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}

response = requests.request('POST', url, headers=headers, json=payload)
response.json()

Request      

POST api/v1/connectors/client/products/create

Headers

Authorization      

Example: Bearer {YOUR_AUTH_TOKEN}

Content-Type      

Example: application/json

Accept      

Example: application/json

Body Parameters

description   string   

The product name. Between 3 and 100 characters allowed. Example: TestProduct

productCode   string   

The product code. The field may have alpha-numeric characters, as well as dash, dot, forward slash, plus sign and underscore. Between 3 and 100 characters allowed. The non alpha-numeric characters are not allowed at the beginning of the string. The underscore, dot and forward slash are not allowed at the end of the string. Example: ABQ.123+ Example: ABQ.123+

ean   string   

The product barcode. The field may have alpha-numeric characters, as well as dashes, dots and underscores. Between 4 and 20 characters allowed. The non alpha-numeric characters are not allowed at the beginning/end of the string. Example: 8009000123A-2.A

externalId   integer  optional  

The product external id. The value must be a positive integer. Example: 10999

price   decimal  optional  

The product price. The value must be a positive number and can support up 2 decimal places. Example: 10.55

weight_grams   integer   

The product weight in grams. The value must be a positive integer. Example: 1500

pictureUrl   url  optional  

The product image url. Between 10 and 200 characters allowed. Example: https://www.pathtomyimage.com

productType   enum(0,1,2)   

The product type must be one of next possible values: 0 - Normal; 1 - With Expiration Date; 2 - With Expiration Date & Production Lot. Example: 1

useDefaultExpiryOnReception   enum(no,yes)   

if productType is not 0. If the field is set to yes, a far future expiry date will be used as the default upon product reception. Example: no

useProdIdAsEan   enum(no,yes)   

If the field is set to yes, the product EAN will be updated with the ProductId after the product is created. Example: no

productSpecialType   alphaNumeric  optional  

If the product is a special type (e.g. each received piece has a SerialNumber) the value needs to be mentioned here from a possible list of values given by developers. This field can be set only if the productType value is set to 0. Example: quaerat

externalSource   string  optional  

The name of the external source of the product. The value must start with a value from in External Source List endpoint result. Example: Shopify MyWebSite

externalSourceProductId   string  optional  

The product internal website id or any other id that can help identify the product in our system. Example: PRD00001

useOverriddenValidationRules   boolean  optional  

If there are custom validation rules added by developers this field must be passed as true in order to be taken into account. Example: false

UPDATE Product

requires authentication

Updates product by ID

Throttling: Max 100 requests per minute. (100/1)

Example request:
$client = new \GuzzleHttp\Client();
$url = 'https://clients.metrica.bg/api/v1/connectors/client/products/update/1';
$response = $client->put(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_TOKEN}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'description' => 'TestProduct',
            'productCode' => 'ABQ.123+',
            'ean' => '8009000123A-2.A',
            'externalId' => 10999,
            'price' => '10.55',
            'weight_grams' => 1500,
            'pictureUrl' => 'https://www.pathtomyimage.com',
            'productType' => '1',
            'useDefaultExpiryOnReception' => 'no',
            'externalSource' => 'Shopify MyWebSite',
            'externalSourceProductId' => 'PRD00001',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://clients.metrica.bg/api/v1/connectors/client/products/update/1"
);

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

let body = {
    "description": "TestProduct",
    "productCode": "ABQ.123+",
    "ean": "8009000123A-2.A",
    "externalId": 10999,
    "price": "10.55",
    "weight_grams": 1500,
    "pictureUrl": "https:\/\/www.pathtomyimage.com",
    "productType": "1",
    "useDefaultExpiryOnReception": "no",
    "externalSource": "Shopify MyWebSite",
    "externalSourceProductId": "PRD00001"
};

fetch(url, {
    method: "PUT",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());
curl --request PUT \
    "https://clients.metrica.bg/api/v1/connectors/client/products/update/1" \
    --header "Authorization: Bearer {YOUR_AUTH_TOKEN}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"description\": \"TestProduct\",
    \"productCode\": \"ABQ.123+\",
    \"ean\": \"8009000123A-2.A\",
    \"externalId\": 10999,
    \"price\": \"10.55\",
    \"weight_grams\": 1500,
    \"pictureUrl\": \"https:\\/\\/www.pathtomyimage.com\",
    \"productType\": \"1\",
    \"useDefaultExpiryOnReception\": \"no\",
    \"externalSource\": \"Shopify MyWebSite\",
    \"externalSourceProductId\": \"PRD00001\"
}"
import requests
import json

url = 'https://clients.metrica.bg/api/v1/connectors/client/products/update/1'
payload = {
    "description": "TestProduct",
    "productCode": "ABQ.123+",
    "ean": "8009000123A-2.A",
    "externalId": 10999,
    "price": "10.55",
    "weight_grams": 1500,
    "pictureUrl": "https:\/\/www.pathtomyimage.com",
    "productType": "1",
    "useDefaultExpiryOnReception": "no",
    "externalSource": "Shopify MyWebSite",
    "externalSourceProductId": "PRD00001"
}
headers = {
  'Authorization': 'Bearer {YOUR_AUTH_TOKEN}',
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}

response = requests.request('PUT', url, headers=headers, json=payload)
response.json()

Request      

PUT api/v1/connectors/client/products/update/{product_idp}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_TOKEN}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

product_idp   integer   

Example: 1

Body Parameters

description   string   

The product name. Between 3 and 100 characters allowed. Example: TestProduct

productCode   string   

The product code. The field may have alpha-numeric characters, as well as dash, dot, forward slash, plus sign and underscore. Between 3 and 100 characters allowed. The non alpha-numeric characters are not allowed at the beginning of the string. The underscore, dot and forward slash are not allowed at the end of the string. Example: ABQ.123+ Example: ABQ.123+

ean   string   

The product barcode. The field may have alpha-numeric characters, as well as dashes, dots and underscores. Between 4 and 20 characters allowed. The non alpha-numeric characters are not allowed at the beginning/end of the string. Example: 8009000123A-2.A Example: 8009000123A-2.A

externalId   integer  optional  

The product external id. The value must be a positive integer. Example: 10999

price   decimal  optional  

The product price. The value must be a positive number and can have up to 2 decimal places. Example: 10.55

weight_grams   integer   

The product weight in grams. The value must be a positive integer. Example: 1500

pictureUrl   url  optional  

The product image url. Between 10 and 200 characters allowed. Example: https://www.pathtomyimage.com

productType   enum(0,1,2)   

The product type must be one of next possible values: 0 - Normal; 1 - With Expiration Date; 2 - With Expiration Date & Production Lot Example: 1

useDefaultExpiryOnReception   enum(no,yes)   

if productType is not 0. If the field is set to yes, a far future expiry date will be used as the default upon product reception. Example: no

externalSource   string  optional  

The name of the external source of the product. The value must start with a value from in External Source List endpoint result. Example: Shopify MyWebSite

externalSourceProductId   string  optional  

The product internal website id or any other id that can help identify the product in our system. Example: PRD00001

GET External Source List

requires authentication

Retrieve a list with the allowed external sources.

Throttling: Max 100 requests per minute. (100/1)

Please inform us if your source is not on this list, so we can add it.

Example request:
$client = new \GuzzleHttp\Client();
$url = 'https://clients.metrica.bg/api/v1/connectors/client/products/externalSourceList';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_TOKEN}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://clients.metrica.bg/api/v1/connectors/client/products/externalSourceList"
);

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

fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());
curl --request GET \
    --get "https://clients.metrica.bg/api/v1/connectors/client/products/externalSourceList" \
    --header "Authorization: Bearer {YOUR_AUTH_TOKEN}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
import requests
import json

url = 'https://clients.metrica.bg/api/v1/connectors/client/products/externalSourceList'
headers = {
  'Authorization': 'Bearer {YOUR_AUTH_TOKEN}',
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}

response = requests.request('GET', url, headers=headers)
response.json()

Example response (200):

Show headers
cache-control: no-cache, private
content-type: application/json
x-ratelimit-limit: 100
x-ratelimit-remaining: 99
access-control-allow-origin: *
 

{
    "data": [
        "Fulfill",
        "Gomag",
        "EasySales",
        "Teamshare",
        "ContentSpeed",
        "BaseLinker",
        "VTEX",
        "Shopify",
        "Magento",
        "PrestaShop",
        "OpenCart",
        "WooCommerce",
        "MerchantPro",
        "EMAG RO",
        "EMAG HU",
        "EMAG BG",
        "CEL",
        "Elefant",
        "Vivre",
        "OLX",
        "Okazii",
        "Wordpress",
        "Mentor",
        "Metrica",
        "Fashion Days",
        "Trendyol",
        "SeniorSoftware"
    ],
    "success": true
}
 

Request      

GET api/v1/connectors/client/products/externalSourceList

Headers

Authorization      

Example: Bearer {YOUR_AUTH_TOKEN}

Content-Type      

Example: application/json

Accept      

Example: application/json

API V1 - Receptions

Reception Endpoints

GET All Receptions

requires authentication

List all receptions.

Throttling: Max 30 requests per minute. (30/1)

Presents the result with page size and pagination.

Default page size : 200 records per page.

Example request:
$client = new \GuzzleHttp\Client();
$url = 'https://clients.metrica.bg/api/v1/connectors/client/receptions';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_TOKEN}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'query' => [
            'page' => '1',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://clients.metrica.bg/api/v1/connectors/client/receptions"
);

const params = {
    "page": "1",
};
Object.keys(params)
    .forEach(key => url.searchParams.append(key, params[key]));

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

fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());
curl --request GET \
    --get "https://clients.metrica.bg/api/v1/connectors/client/receptions?page=1" \
    --header "Authorization: Bearer {YOUR_AUTH_TOKEN}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
import requests
import json

url = 'https://clients.metrica.bg/api/v1/connectors/client/receptions'
params = {
  'page': '1',
}
headers = {
  'Authorization': 'Bearer {YOUR_AUTH_TOKEN}',
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}

response = requests.request('GET', url, headers=headers, params=params)
response.json()

Example response (403):

Show headers
cache-control: no-cache, private
content-type: application/json
x-ratelimit-limit: 30
x-ratelimit-remaining: 29
access-control-allow-origin: *
 

{
    "success": false,
    "error": {
        "message": "Not allowed to access this endpoint.",
        "code": 403
    }
}
 

Request      

GET api/v1/connectors/client/receptions

Headers

Authorization      

Example: Bearer {YOUR_AUTH_TOKEN}

Content-Type      

Example: application/json

Accept      

Example: application/json

Query Parameters

page   integer  optional  

Which page to show. Example: 1

GET Filtered Receptions with Reception Plans

requires authentication

List filtered receptions with reception plans.

Throttling: Max 15 requests per minute. (15/1)

Presents the result with page size and pagination.

Default page size : 200 records per page. (Maximum 300)

Example request:
$client = new \GuzzleHttp\Client();
$url = 'https://clients.metrica.bg/api/v1/connectors/client/receptions/filter';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_TOKEN}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'query' => [
            'page' => '1',
        ],
        'json' => [
            'ids' => '31084,31072',
            'startDate' => '2020-01-01 12:59:59',
            'endDate' => '2020-12-30 19:30:00',
            'dateFilterBy' => 'CREATED_AT',
            'sortDate' => 'ASC',
            'isProcessed' => false,
            'withReceptionPlans' => false,
            'perPage' => 200,
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://clients.metrica.bg/api/v1/connectors/client/receptions/filter"
);

const params = {
    "page": "1",
};
Object.keys(params)
    .forEach(key => url.searchParams.append(key, params[key]));

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

let body = {
    "ids": "31084,31072",
    "startDate": "2020-01-01 12:59:59",
    "endDate": "2020-12-30 19:30:00",
    "dateFilterBy": "CREATED_AT",
    "sortDate": "ASC",
    "isProcessed": false,
    "withReceptionPlans": false,
    "perPage": 200
};

fetch(url, {
    method: "GET",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());
curl --request GET \
    --get "https://clients.metrica.bg/api/v1/connectors/client/receptions/filter?page=1" \
    --header "Authorization: Bearer {YOUR_AUTH_TOKEN}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"ids\": \"31084,31072\",
    \"startDate\": \"2020-01-01 12:59:59\",
    \"endDate\": \"2020-12-30 19:30:00\",
    \"dateFilterBy\": \"CREATED_AT\",
    \"sortDate\": \"ASC\",
    \"isProcessed\": false,
    \"withReceptionPlans\": false,
    \"perPage\": 200
}"
import requests
import json

url = 'https://clients.metrica.bg/api/v1/connectors/client/receptions/filter'
payload = {
    "ids": "31084,31072",
    "startDate": "2020-01-01 12:59:59",
    "endDate": "2020-12-30 19:30:00",
    "dateFilterBy": "CREATED_AT",
    "sortDate": "ASC",
    "isProcessed": false,
    "withReceptionPlans": false,
    "perPage": 200
}
params = {
  'page': '1',
}
headers = {
  'Authorization': 'Bearer {YOUR_AUTH_TOKEN}',
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}

response = requests.request('GET', url, headers=headers, json=payload, params=params)
response.json()

Example response (403):

Show headers
cache-control: no-cache, private
content-type: application/json
x-ratelimit-limit: 15
x-ratelimit-remaining: 14
access-control-allow-origin: *
 

{
    "success": false,
    "error": {
        "message": "Not allowed to access this endpoint.",
        "code": 403
    }
}
 

Request      

GET api/v1/connectors/client/receptions/filter

Headers

Authorization      

Example: Bearer {YOUR_AUTH_TOKEN}

Content-Type      

Example: application/json

Accept      

Example: application/json

Query Parameters

page   integer  optional  

Which page to show. Example: 1

Body Parameters

ids   string  optional  

List of comma-separated Order IDs. Example: 31084,31072

startDate   date  optional  

A date between past and today. The format must be in: Y-m-d H:i:s. Example: 2020-01-01 12:59:59

endDate   date  optional  

A date between past and today. If there is a startDate, endDate must be later than startDate. The format must be in: Y-m-d H:i:s. Example: 2020-12-30 19:30:00

dateFilterBy   enum(CREATED_AT,UPDATED_AT,PROCESSED_AT)  optional  

The column to which startDate and endDate are compared. - Default: CREATED_AT. Example: CREATED_AT

sortDate   enum(DESC,ASC)  optional  

Order in which to retrieve results. - Default : ASC. Example: ASC

isProcessed   boolean  optional  

A filter that will only select receptions that are processed or not processed. Example: false

shippingAWB   string  optional  

The AWB number.

withReceptionPlans   boolean  optional  

A filter that when true the response will show additional info regarding the reception plans. - Default: false Example: false

perPage   integer  optional  

Number of entries per page. The allowed values are between 10 and 300. If not provided, the default is 200. Example: 200

GET Reception By ID

requires authentication

Get Reception information by internal ID.

Throttling: Max 60 requests per minute. (60/1)

Example request:
$client = new \GuzzleHttp\Client();
$url = 'https://clients.metrica.bg/api/v1/connectors/client/receptions/byId/31072';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_TOKEN}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://clients.metrica.bg/api/v1/connectors/client/receptions/byId/31072"
);

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

fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());
curl --request GET \
    --get "https://clients.metrica.bg/api/v1/connectors/client/receptions/byId/31072" \
    --header "Authorization: Bearer {YOUR_AUTH_TOKEN}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
import requests
import json

url = 'https://clients.metrica.bg/api/v1/connectors/client/receptions/byId/31072'
headers = {
  'Authorization': 'Bearer {YOUR_AUTH_TOKEN}',
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}

response = requests.request('GET', url, headers=headers)
response.json()

Example response (403):

Show headers
cache-control: no-cache, private
content-type: application/json
x-ratelimit-limit: 60
x-ratelimit-remaining: 59
access-control-allow-origin: *
 

{
    "success": false,
    "error": {
        "message": "Not allowed to access this endpoint.",
        "code": 403
    }
}
 

Example response (404):


{
    "success": false,
    "error": {
        "message": "Entry for Reception not found",
        "code": 404
    }
}
 

Request      

GET api/v1/connectors/client/receptions/byId/{receptionId}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_TOKEN}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

receptionId   integer   

The reception ID. Example: 31072

GET Reception Contents By ID

requires authentication

Get Reception contents ( received products ana quantity ) by internal ID.

Throttling: Max 20 requests per minute. (20/1)

Example request:
$client = new \GuzzleHttp\Client();
$url = 'https://clients.metrica.bg/api/v1/connectors/client/receptions/byId/13/contents';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_TOKEN}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://clients.metrica.bg/api/v1/connectors/client/receptions/byId/13/contents"
);

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

fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());
curl --request GET \
    --get "https://clients.metrica.bg/api/v1/connectors/client/receptions/byId/13/contents" \
    --header "Authorization: Bearer {YOUR_AUTH_TOKEN}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
import requests
import json

url = 'https://clients.metrica.bg/api/v1/connectors/client/receptions/byId/13/contents'
headers = {
  'Authorization': 'Bearer {YOUR_AUTH_TOKEN}',
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}

response = requests.request('GET', url, headers=headers)
response.json()

Example response (403):

Show headers
cache-control: no-cache, private
content-type: application/json
x-ratelimit-limit: 20
x-ratelimit-remaining: 19
access-control-allow-origin: *
 

{
    "success": false,
    "error": {
        "message": "Not allowed to access this endpoint.",
        "code": 403
    }
}
 

Example response (404):


{
    "success": false,
    "error": {
        "message": "Entry for Reception not found",
        "code": 404
    }
}
 

Request      

GET api/v1/connectors/client/receptions/byId/{reception_id}/contents

Headers

Authorization      

Example: Bearer {YOUR_AUTH_TOKEN}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

reception_id   integer   

The ID of the reception. Example: 13

reception   integer   

The reception ID. Example: 31072

API V1 - Reception Plans

Reception Plan Endpoints

GET All Reception Plans

requires authentication

List all reception plans.

Throttling: Max 30 requests per minute. (30/1)

Presents the result with page size and pagination.

Default page size : 200 records per page.

Example request:
$client = new \GuzzleHttp\Client();
$url = 'https://clients.metrica.bg/api/v1/connectors/client/receptionPlans';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_TOKEN}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'query' => [
            'page' => '1',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://clients.metrica.bg/api/v1/connectors/client/receptionPlans"
);

const params = {
    "page": "1",
};
Object.keys(params)
    .forEach(key => url.searchParams.append(key, params[key]));

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

fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());
curl --request GET \
    --get "https://clients.metrica.bg/api/v1/connectors/client/receptionPlans?page=1" \
    --header "Authorization: Bearer {YOUR_AUTH_TOKEN}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
import requests
import json

url = 'https://clients.metrica.bg/api/v1/connectors/client/receptionPlans'
params = {
  'page': '1',
}
headers = {
  'Authorization': 'Bearer {YOUR_AUTH_TOKEN}',
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}

response = requests.request('GET', url, headers=headers, params=params)
response.json()

Example response (403):

Show headers
cache-control: no-cache, private
content-type: application/json
x-ratelimit-limit: 30
x-ratelimit-remaining: 29
access-control-allow-origin: *
 

{
    "success": false,
    "error": {
        "message": "Not allowed to access this endpoint.",
        "code": 403
    }
}
 

Request      

GET api/v1/connectors/client/receptionPlans

Headers

Authorization      

Example: Bearer {YOUR_AUTH_TOKEN}

Content-Type      

Example: application/json

Accept      

Example: application/json

Query Parameters

page   integer  optional  

Which page to show. Example: 1

GET Reception Plan By ID

requires authentication

Get Reception Plan by internal ID.

Throttling: Max 60 requests per minute. (60/1)

Example request:
$client = new \GuzzleHttp\Client();
$url = 'https://clients.metrica.bg/api/v1/connectors/client/receptionPlans/byId/101';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_TOKEN}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://clients.metrica.bg/api/v1/connectors/client/receptionPlans/byId/101"
);

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

fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());
curl --request GET \
    --get "https://clients.metrica.bg/api/v1/connectors/client/receptionPlans/byId/101" \
    --header "Authorization: Bearer {YOUR_AUTH_TOKEN}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
import requests
import json

url = 'https://clients.metrica.bg/api/v1/connectors/client/receptionPlans/byId/101'
headers = {
  'Authorization': 'Bearer {YOUR_AUTH_TOKEN}',
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}

response = requests.request('GET', url, headers=headers)
response.json()

Example response (403):

Show headers
cache-control: no-cache, private
content-type: application/json
x-ratelimit-limit: 60
x-ratelimit-remaining: 59
access-control-allow-origin: *
 

{
    "success": false,
    "error": {
        "message": "Not allowed to access this endpoint.",
        "code": 403
    }
}
 

Example response (404):


{
    "success": false,
    "error": {
        "message": "Entry for ReceptionPlan not found",
        "code": 404
    }
}
 

Request      

GET api/v1/connectors/client/receptionPlans/byId/{receptionPlan_id}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_TOKEN}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

receptionPlan_id   integer   

The reception plan ID. Example: 101

CREATE Reception Plan

requires authentication

Create a new Reception Plan

Throttling: Max 10 requests per minute. (10/1)

Example request:
$client = new \GuzzleHttp\Client();
$url = 'https://clients.metrica.bg/api/v1/connectors/client/receptionPlans/create';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_TOKEN}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'name' => 'TestPlan',
            'externalId' => '10999',
            'supplierName' => 'My Supplier',
            'awbNumber' => 'AWB001',
            'estimatedArrivalDate' => '2035-01-01',
            'hasStrictMaxQuantity' => false,
            'hasUniqueProducts' => false,
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://clients.metrica.bg/api/v1/connectors/client/receptionPlans/create"
);

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

let body = {
    "name": "TestPlan",
    "externalId": "10999",
    "supplierName": "My Supplier",
    "awbNumber": "AWB001",
    "estimatedArrivalDate": "2035-01-01",
    "hasStrictMaxQuantity": false,
    "hasUniqueProducts": false
};

fetch(url, {
    method: "POST",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());
curl --request POST \
    "https://clients.metrica.bg/api/v1/connectors/client/receptionPlans/create" \
    --header "Authorization: Bearer {YOUR_AUTH_TOKEN}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"name\": \"TestPlan\",
    \"externalId\": \"10999\",
    \"supplierName\": \"My Supplier\",
    \"awbNumber\": \"AWB001\",
    \"estimatedArrivalDate\": \"2035-01-01\",
    \"hasStrictMaxQuantity\": false,
    \"hasUniqueProducts\": false
}"
import requests
import json

url = 'https://clients.metrica.bg/api/v1/connectors/client/receptionPlans/create'
payload = {
    "name": "TestPlan",
    "externalId": "10999",
    "supplierName": "My Supplier",
    "awbNumber": "AWB001",
    "estimatedArrivalDate": "2035-01-01",
    "hasStrictMaxQuantity": false,
    "hasUniqueProducts": false
}
headers = {
  'Authorization': 'Bearer {YOUR_AUTH_TOKEN}',
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}

response = requests.request('POST', url, headers=headers, json=payload)
response.json()

Request      

POST api/v1/connectors/client/receptionPlans/create

Headers

Authorization      

Example: Bearer {YOUR_AUTH_TOKEN}

Content-Type      

Example: application/json

Accept      

Example: application/json

Body Parameters

name   string   

The reception plan name. Between 5 and 50 characters allowed. Example: TestPlan

externalId   alphaNumeric   

The reception plan external id. Between 2 and 50 characters allowed. Example: 10999

supplierName   string  optional  

The reception plan supplier. Between 3 and 50 characters allowed. Example: My Supplier

awbNumber   string  optional  

The reception plan shipping AWB Number. Between 3 and 50 characters allowed. Example: AWB001

estimatedArrivalDate   date  optional  

The reception plan estimated arrival date. The date must later or equal to today. The format must be in: yyyy-mm-dd. Example: 2035-01-01

hasStrictMaxQuantity   boolean  optional  

When is enabled cannot be received more pcs of a product than the given quantity in the reception plan. Example: false

hasUniqueProducts   boolean  optional  

When is enabled the reception plan contents can't have the same product more than once. The product needs to be unique even if multiple imports are added in the current plan. Example: false

UPDATE Reception Plan

requires authentication

Updates reception plan by ID

Throttling: Max 10 requests per minute. (10/1)

Example request:
$client = new \GuzzleHttp\Client();
$url = 'https://clients.metrica.bg/api/v1/connectors/client/receptionPlans/update/3';
$response = $client->put(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_TOKEN}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'supplierName' => 'My Supplier',
            'awbNumber' => 'AWB001',
            'estimatedArrivalDate' => '2035-01-01',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://clients.metrica.bg/api/v1/connectors/client/receptionPlans/update/3"
);

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

let body = {
    "supplierName": "My Supplier",
    "awbNumber": "AWB001",
    "estimatedArrivalDate": "2035-01-01"
};

fetch(url, {
    method: "PUT",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());
curl --request PUT \
    "https://clients.metrica.bg/api/v1/connectors/client/receptionPlans/update/3" \
    --header "Authorization: Bearer {YOUR_AUTH_TOKEN}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"supplierName\": \"My Supplier\",
    \"awbNumber\": \"AWB001\",
    \"estimatedArrivalDate\": \"2035-01-01\"
}"
import requests
import json

url = 'https://clients.metrica.bg/api/v1/connectors/client/receptionPlans/update/3'
payload = {
    "supplierName": "My Supplier",
    "awbNumber": "AWB001",
    "estimatedArrivalDate": "2035-01-01"
}
headers = {
  'Authorization': 'Bearer {YOUR_AUTH_TOKEN}',
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}

response = requests.request('PUT', url, headers=headers, json=payload)
response.json()

Request      

PUT api/v1/connectors/client/receptionPlans/update/{receptionPlan_id}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_TOKEN}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

receptionPlan_id   integer   

The ID of the receptionPlan. Example: 3

Body Parameters

supplierName   string  optional  

The reception plan supplier. Between 3 and 50 characters allowed. Example: My Supplier

awbNumber   string  optional  

The reception plan shipping AWB Number. Between 3 and 50 characters allowed. Example: AWB001

estimatedArrivalDate   date  optional  

The reception plan estimated arrival date. The date must later or equal to today. The format must be in: yyyy-mm-dd. Example: 2035-01-01

GET Reception Plan Imports

requires authentication

Get Reception Plan Imports by internal ID.

Throttling: Max 30 requests per minute. (30/1)

Example request:
$client = new \GuzzleHttp\Client();
$url = 'https://clients.metrica.bg/api/v1/connectors/client/receptionPlans/byId/126/imports';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_TOKEN}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://clients.metrica.bg/api/v1/connectors/client/receptionPlans/byId/126/imports"
);

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

fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());
curl --request GET \
    --get "https://clients.metrica.bg/api/v1/connectors/client/receptionPlans/byId/126/imports" \
    --header "Authorization: Bearer {YOUR_AUTH_TOKEN}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
import requests
import json

url = 'https://clients.metrica.bg/api/v1/connectors/client/receptionPlans/byId/126/imports'
headers = {
  'Authorization': 'Bearer {YOUR_AUTH_TOKEN}',
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}

response = requests.request('GET', url, headers=headers)
response.json()

Example response (403):

Show headers
cache-control: no-cache, private
content-type: application/json
x-ratelimit-limit: 30
x-ratelimit-remaining: 29
access-control-allow-origin: *
 

{
    "success": false,
    "error": {
        "message": "Not allowed to access this endpoint.",
        "code": 403
    }
}
 

Request      

GET api/v1/connectors/client/receptionPlans/byId/{receptionPlan_id}/imports

Headers

Authorization      

Example: Bearer {YOUR_AUTH_TOKEN}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

receptionPlan_id   integer   

The reception plan ID. Example: 126

GET Reception Plan Details

requires authentication

Get Reception Plan Details by internal ID.

Throttling: Max 15 requests per minute. (15/1)

Example request:
$client = new \GuzzleHttp\Client();
$url = 'https://clients.metrica.bg/api/v1/connectors/client/receptionPlans/byId/126/details';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_TOKEN}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://clients.metrica.bg/api/v1/connectors/client/receptionPlans/byId/126/details"
);

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

fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());
curl --request GET \
    --get "https://clients.metrica.bg/api/v1/connectors/client/receptionPlans/byId/126/details" \
    --header "Authorization: Bearer {YOUR_AUTH_TOKEN}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
import requests
import json

url = 'https://clients.metrica.bg/api/v1/connectors/client/receptionPlans/byId/126/details'
headers = {
  'Authorization': 'Bearer {YOUR_AUTH_TOKEN}',
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}

response = requests.request('GET', url, headers=headers)
response.json()

Example response (403):

Show headers
cache-control: no-cache, private
content-type: application/json
x-ratelimit-limit: 15
x-ratelimit-remaining: 14
access-control-allow-origin: *
 

{
    "success": false,
    "error": {
        "message": "Not allowed to access this endpoint.",
        "code": 403
    }
}
 

Request      

GET api/v1/connectors/client/receptionPlans/byId/{receptionPlan_id}/details

Headers

Authorization      

Example: Bearer {YOUR_AUTH_TOKEN}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

receptionPlan_id   integer   

The reception plan ID. Example: 126

GET Reception Plan Report By ID

requires authentication

Get Reception Plan report by internal ID.

Throttling: Max 15 requests per minute. (15/1)

Example request:
$client = new \GuzzleHttp\Client();
$url = 'https://clients.metrica.bg/api/v1/connectors/client/receptionPlans/byId/126/report';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_TOKEN}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://clients.metrica.bg/api/v1/connectors/client/receptionPlans/byId/126/report"
);

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

fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());
curl --request GET \
    --get "https://clients.metrica.bg/api/v1/connectors/client/receptionPlans/byId/126/report" \
    --header "Authorization: Bearer {YOUR_AUTH_TOKEN}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
import requests
import json

url = 'https://clients.metrica.bg/api/v1/connectors/client/receptionPlans/byId/126/report'
headers = {
  'Authorization': 'Bearer {YOUR_AUTH_TOKEN}',
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}

response = requests.request('GET', url, headers=headers)
response.json()

Example response (403):


{
    "message": "This action is unauthorized."
}
 

Example response (403):

Show headers
cache-control: no-cache, private
content-type: application/json
x-ratelimit-limit: 15
x-ratelimit-remaining: 14
access-control-allow-origin: *
 

{
    "success": false,
    "error": {
        "message": "Not allowed to access this endpoint.",
        "code": 403
    }
}
 

Example response (404):


{
    "success": false,
    "error": {
        "message": "Entry for ReceptionPlan not found",
        "code": 404
    }
}
 

Request      

GET api/v1/connectors/client/receptionPlans/byId/{receptionPlan_id}/report

Headers

Authorization      

Example: Bearer {YOUR_AUTH_TOKEN}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

receptionPlan_id   integer   

The reception plan ID. Example: 126

FINISH Reception Plan

requires authentication

Finish Reception Plan

Throttling: Max 10 requests per minute. (10/1)

Example request:
$client = new \GuzzleHttp\Client();
$url = 'https://clients.metrica.bg/api/v1/connectors/client/receptionPlans/byId//finish';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_TOKEN}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://clients.metrica.bg/api/v1/connectors/client/receptionPlans/byId//finish"
);

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

fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());
curl --request GET \
    --get "https://clients.metrica.bg/api/v1/connectors/client/receptionPlans/byId//finish" \
    --header "Authorization: Bearer {YOUR_AUTH_TOKEN}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
import requests
import json

url = 'https://clients.metrica.bg/api/v1/connectors/client/receptionPlans/byId//finish'
headers = {
  'Authorization': 'Bearer {YOUR_AUTH_TOKEN}',
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}

response = requests.request('GET', url, headers=headers)
response.json()

Example response (404):

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

{
    "success": false,
    "error": {
        "message": "Requested Endpoint not found",
        "code": 404
    }
}
 

Request      

GET api/v1/connectors/client/receptionPlans/byId/{receptionPlan_id}/finish

Headers

Authorization      

Example: Bearer {YOUR_AUTH_TOKEN}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

receptionPlan_id   integer   

The reception plan ID.

DELETE Reception Plan

requires authentication

Delete Reception Plan by internal id

Throttling: Max 10 requests per minute. (10/1)

Example request:
$client = new \GuzzleHttp\Client();
$url = 'https://clients.metrica.bg/api/v1/connectors/client/receptionPlans/byId//delete';
$response = $client->delete(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_TOKEN}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://clients.metrica.bg/api/v1/connectors/client/receptionPlans/byId//delete"
);

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

fetch(url, {
    method: "DELETE",
    headers,
}).then(response => response.json());
curl --request DELETE \
    "https://clients.metrica.bg/api/v1/connectors/client/receptionPlans/byId//delete" \
    --header "Authorization: Bearer {YOUR_AUTH_TOKEN}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
import requests
import json

url = 'https://clients.metrica.bg/api/v1/connectors/client/receptionPlans/byId//delete'
headers = {
  'Authorization': 'Bearer {YOUR_AUTH_TOKEN}',
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}

response = requests.request('DELETE', url, headers=headers)
response.json()

Example response (404):


{
    "success": false,
    "error": {
        "message": "Entry for ReceptionPlan not found",
        "code": 404
    }
}
 

Request      

DELETE api/v1/connectors/client/receptionPlans/byId/{receptionPlan_id}/delete

Headers

Authorization      

Example: Bearer {YOUR_AUTH_TOKEN}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

receptionPlan_id   integer   

The Reception Plan ID.

API V1 - Reception Plan Imports

Reception Plan Import Endpoints

GET Reception Plan Details

requires authentication

Get Reception Plan Details by import ID.

Throttling: Max 15 requests per minute. (15/1)

Example request:
$client = new \GuzzleHttp\Client();
$url = 'https://clients.metrica.bg/api/v1/connectors/client/receptionPlanImports/395/details';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_TOKEN}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://clients.metrica.bg/api/v1/connectors/client/receptionPlanImports/395/details"
);

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

fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());
curl --request GET \
    --get "https://clients.metrica.bg/api/v1/connectors/client/receptionPlanImports/395/details" \
    --header "Authorization: Bearer {YOUR_AUTH_TOKEN}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
import requests
import json

url = 'https://clients.metrica.bg/api/v1/connectors/client/receptionPlanImports/395/details'
headers = {
  'Authorization': 'Bearer {YOUR_AUTH_TOKEN}',
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}

response = requests.request('GET', url, headers=headers)
response.json()

Example response (403):

Show headers
cache-control: no-cache, private
content-type: application/json
x-ratelimit-limit: 60
x-ratelimit-remaining: 59
access-control-allow-origin: *
 

{
    "success": false,
    "error": {
        "message": "Not allowed to access this endpoint.",
        "code": 403
    }
}
 

Request      

GET api/v1/connectors/client/receptionPlanImports/{receptionPlanImport_id}/details

Headers

Authorization      

Example: Bearer {YOUR_AUTH_TOKEN}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

receptionPlanImport_id   integer   

The reception plan import ID. Example: 395

CREATE Reception Plan Import

requires authentication

Create a new Reception Plan Import

Throttling: Max 10 requests per minute. (10/1)

Example request:
$client = new \GuzzleHttp\Client();
$url = 'https://clients.metrica.bg/api/v1/connectors/client/receptionPlanImports/create/101';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_TOKEN}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'name' => 'TestImportPlan',
            'productIdentifierType' => 'barcode',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://clients.metrica.bg/api/v1/connectors/client/receptionPlanImports/create/101"
);

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

let body = {
    "name": "TestImportPlan",
    "productIdentifierType": "barcode"
};

fetch(url, {
    method: "POST",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());
curl --request POST \
    "https://clients.metrica.bg/api/v1/connectors/client/receptionPlanImports/create/101" \
    --header "Authorization: Bearer {YOUR_AUTH_TOKEN}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"name\": \"TestImportPlan\",
    \"productIdentifierType\": \"barcode\"
}"
import requests
import json

url = 'https://clients.metrica.bg/api/v1/connectors/client/receptionPlanImports/create/101'
payload = {
    "name": "TestImportPlan",
    "productIdentifierType": "barcode"
}
headers = {
  'Authorization': 'Bearer {YOUR_AUTH_TOKEN}',
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}

response = requests.request('POST', url, headers=headers, json=payload)
response.json()

Request      

POST api/v1/connectors/client/receptionPlanImports/create/{receptionPlan_id}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_TOKEN}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

receptionPlan_id   integer   

The reception plan ID. Example: 101

Body Parameters

name   string   

The reception plan import name. Between 5 and 50 characters allowed. Example: TestImportPlan

productIdentifierType   required  optional  

enum(productCode,barcode,externalId) The product identifier type necessary for correctly identifying the product when the reception plan detail is created. Example: barcode

FINISH Reception Plan Import

requires authentication

Finish Reception Plan Import

Throttling: Max 10 requests per minute. (10/1)

Example request:
$client = new \GuzzleHttp\Client();
$url = 'https://clients.metrica.bg/api/v1/connectors/client/receptionPlanImports//finish';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_TOKEN}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://clients.metrica.bg/api/v1/connectors/client/receptionPlanImports//finish"
);

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

fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());
curl --request GET \
    --get "https://clients.metrica.bg/api/v1/connectors/client/receptionPlanImports//finish" \
    --header "Authorization: Bearer {YOUR_AUTH_TOKEN}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
import requests
import json

url = 'https://clients.metrica.bg/api/v1/connectors/client/receptionPlanImports//finish'
headers = {
  'Authorization': 'Bearer {YOUR_AUTH_TOKEN}',
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}

response = requests.request('GET', url, headers=headers)
response.json()

Example response (404):

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

{
    "success": false,
    "error": {
        "message": "Requested Endpoint not found",
        "code": 404
    }
}
 

Request      

GET api/v1/connectors/client/receptionPlanImports/{receptionPlanImport_id}/finish

Headers

Authorization      

Example: Bearer {YOUR_AUTH_TOKEN}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

receptionPlanImport_id   integer   

The reception plan import ID.

DELETE Reception Plan Import

requires authentication

Delete Reception Plan Import by internal id

Throttling: Max 10 requests per minute. (10/1)

Example request:
$client = new \GuzzleHttp\Client();
$url = 'https://clients.metrica.bg/api/v1/connectors/client/receptionPlanImports/1/delete';
$response = $client->delete(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_TOKEN}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://clients.metrica.bg/api/v1/connectors/client/receptionPlanImports/1/delete"
);

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

fetch(url, {
    method: "DELETE",
    headers,
}).then(response => response.json());
curl --request DELETE \
    "https://clients.metrica.bg/api/v1/connectors/client/receptionPlanImports/1/delete" \
    --header "Authorization: Bearer {YOUR_AUTH_TOKEN}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
import requests
import json

url = 'https://clients.metrica.bg/api/v1/connectors/client/receptionPlanImports/1/delete'
headers = {
  'Authorization': 'Bearer {YOUR_AUTH_TOKEN}',
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}

response = requests.request('DELETE', url, headers=headers)
response.json()

Example response (404):


{
    "success": false,
    "error": {
        "message": "Entry for ReceptionPlanImport not found",
        "code": 404
    }
}
 

Request      

DELETE api/v1/connectors/client/receptionPlanImports/{receptionPlanImport_id}/delete

Headers

Authorization      

Example: Bearer {YOUR_AUTH_TOKEN}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

receptionPlanImport_id   integer   

The Reception Plan Import ID. Example: 1

API V1 - Reception Plan Details

Reception Plan Details Endpoints

CREATE Reception Plan Detail

requires authentication

Create a new Reception Plan Detail

Throttling: Max 60 requests per minute. (60/1)

Example request:
$client = new \GuzzleHttp\Client();
$url = 'https://clients.metrica.bg/api/v1/connectors/client/receptionPlanDetails/create/1';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_TOKEN}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'productIdentifier' => 'BARCODE999',
            'externalId' => '1',
            'expiryDate' => '2050-01-01',
            'batch' => 0,
            'quantity' => 15,
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://clients.metrica.bg/api/v1/connectors/client/receptionPlanDetails/create/1"
);

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

let body = {
    "productIdentifier": "BARCODE999",
    "externalId": "1",
    "expiryDate": "2050-01-01",
    "batch": 0,
    "quantity": 15
};

fetch(url, {
    method: "POST",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());
curl --request POST \
    "https://clients.metrica.bg/api/v1/connectors/client/receptionPlanDetails/create/1" \
    --header "Authorization: Bearer {YOUR_AUTH_TOKEN}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"productIdentifier\": \"BARCODE999\",
    \"externalId\": \"1\",
    \"expiryDate\": \"2050-01-01\",
    \"batch\": 0,
    \"quantity\": 15
}"
import requests
import json

url = 'https://clients.metrica.bg/api/v1/connectors/client/receptionPlanDetails/create/1'
payload = {
    "productIdentifier": "BARCODE999",
    "externalId": "1",
    "expiryDate": "2050-01-01",
    "batch": 0,
    "quantity": 15
}
headers = {
  'Authorization': 'Bearer {YOUR_AUTH_TOKEN}',
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}

response = requests.request('POST', url, headers=headers, json=payload)
response.json()

Request      

POST api/v1/connectors/client/receptionPlanDetails/create/{receptionPlanImport_id}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_TOKEN}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

receptionPlanImport_id   integer   

The ID of the receptionPlanImport. Example: 1

receptionPlanImportId   integer   

The reception plan import ID. Example: 395

Body Parameters

productIdentifier   string   

The product identifier necessary for correctly identifying the product. Example: BARCODE999

externalId   string  optional  

The external id of the reception plan line. Example: 1

expiryDate   date  optional  

requiredIf The batch is present and filled. Prohibited for Normal products. Date format: Y-m-d. Example: 2050-01-01

batch   integer  optional  

requiredIf Only if identified product is a food product and the expiryDate is present and filled. Prohibited for Normal products. Example: 0

quantity   integer   

The product quantity. Example: 15

DELETE Reception Plan Detail

requires authentication

Delete Reception Plan Detail by internal id

Throttling: Max 60 requests per minute. (60/1)

Example request:
$client = new \GuzzleHttp\Client();
$url = 'https://clients.metrica.bg/api/v1/connectors/client/receptionPlanDetails/1/delete';
$response = $client->delete(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_TOKEN}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://clients.metrica.bg/api/v1/connectors/client/receptionPlanDetails/1/delete"
);

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

fetch(url, {
    method: "DELETE",
    headers,
}).then(response => response.json());
curl --request DELETE \
    "https://clients.metrica.bg/api/v1/connectors/client/receptionPlanDetails/1/delete" \
    --header "Authorization: Bearer {YOUR_AUTH_TOKEN}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
import requests
import json

url = 'https://clients.metrica.bg/api/v1/connectors/client/receptionPlanDetails/1/delete'
headers = {
  'Authorization': 'Bearer {YOUR_AUTH_TOKEN}',
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}

response = requests.request('DELETE', url, headers=headers)
response.json()

Example response (404):


{
    "success": false,
    "error": {
        "message": "Entry for ReceptionPlanDetail not found",
        "code": 404
    }
}
 

Request      

DELETE api/v1/connectors/client/receptionPlanDetails/{receptionPlanDetail_id}/delete

Headers

Authorization      

Example: Bearer {YOUR_AUTH_TOKEN}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

receptionPlanDetail_id   integer   

The Reception Plan Detail ID. Example: 1

API V1 - Stock

Stock Endpoints

GET All Products Stock By ID

requires authentication

List all products stock by ID.

Throttling: Max 1 request in 5 minutes. (1/5)

Presents all the results (NonPaginated).

This endpoint is recommended to use when there are more than 1000 products to display, because the paginated endpoint can show up to 1000 products per page.

Example request:
$client = new \GuzzleHttp\Client();
$url = 'https://clients.metrica.bg/api/v1/connectors/client/stock/allProducts/byProductId';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_TOKEN}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'untilDate' => '31/12/2020',
            'showNoStock' => 'yes',
            'showOnlyGoodProducts' => 'yes',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://clients.metrica.bg/api/v1/connectors/client/stock/allProducts/byProductId"
);

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

let body = {
    "untilDate": "31\/12\/2020",
    "showNoStock": "yes",
    "showOnlyGoodProducts": "yes"
};

fetch(url, {
    method: "GET",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());
curl --request GET \
    --get "https://clients.metrica.bg/api/v1/connectors/client/stock/allProducts/byProductId" \
    --header "Authorization: Bearer {YOUR_AUTH_TOKEN}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"untilDate\": \"31\\/12\\/2020\",
    \"showNoStock\": \"yes\",
    \"showOnlyGoodProducts\": \"yes\"
}"
import requests
import json

url = 'https://clients.metrica.bg/api/v1/connectors/client/stock/allProducts/byProductId'
payload = {
    "untilDate": "31\/12\/2020",
    "showNoStock": "yes",
    "showOnlyGoodProducts": "yes"
}
headers = {
  'Authorization': 'Bearer {YOUR_AUTH_TOKEN}',
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}

response = requests.request('GET', url, headers=headers, json=payload)
response.json()

Example response (429):

Show headers
cache-control: no-cache, private
content-type: application/json
x-ratelimit-limit: 400
x-ratelimit-remaining: 315
access-control-allow-origin: *
 

{
    "success": false,
    "error": {
        "message": "Too Many Attempts.",
        "code": 429
    }
}
 

Request      

GET api/v1/connectors/client/stock/allProducts/byProductId

Headers

Authorization      

Example: Bearer {YOUR_AUTH_TOKEN}

Content-Type      

Example: application/json

Accept      

Example: application/json

Body Parameters

untilDate   date  optional  

If a date is provided the stock will be calculated until the given date (included). The allowed date format is dd/mm/yyyy. Example: 31/12/2020

showNoStock   string  optional  

If this field is set to "no" then only the products that have "stock" > 0 will be returned. This field accepts only 2 values : yes,no. Example: yes

showOnlyGoodProducts   string  optional  

If this field is set to "yes" then only the products with "damageType" equal to "GOOD" will be returned. This field accepts only 2 values : yes,no. Example: yes

GET All Products Stock Paginated By ID

requires authentication

List all products stock by ID.

Throttling: Max 5 requests per minute. (5/1)

Presents the result with page size and pagination.

Default page size : 1000 records per page.

This endpoint is recommended to use when there are less than 1000 products to display, because the first page can show up to 1000 products.

Example request:
$client = new \GuzzleHttp\Client();
$url = 'https://clients.metrica.bg/api/v1/connectors/client/stock/allProductsPaginated/byProductId';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_TOKEN}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'query' => [
            'page' => '1',
        ],
        'json' => [
            'untilDate' => '31/12/2020',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://clients.metrica.bg/api/v1/connectors/client/stock/allProductsPaginated/byProductId"
);

const params = {
    "page": "1",
};
Object.keys(params)
    .forEach(key => url.searchParams.append(key, params[key]));

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

let body = {
    "untilDate": "31\/12\/2020"
};

fetch(url, {
    method: "GET",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());
curl --request GET \
    --get "https://clients.metrica.bg/api/v1/connectors/client/stock/allProductsPaginated/byProductId?page=1" \
    --header "Authorization: Bearer {YOUR_AUTH_TOKEN}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"untilDate\": \"31\\/12\\/2020\"
}"
import requests
import json

url = 'https://clients.metrica.bg/api/v1/connectors/client/stock/allProductsPaginated/byProductId'
payload = {
    "untilDate": "31\/12\/2020"
}
params = {
  'page': '1',
}
headers = {
  'Authorization': 'Bearer {YOUR_AUTH_TOKEN}',
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}

response = requests.request('GET', url, headers=headers, json=payload, params=params)
response.json()

Example response (200):

Show headers
cache-control: no-cache, private
content-type: application/json
x-ratelimit-limit: 5
x-ratelimit-remaining: 4
access-control-allow-origin: *
 

{
    "data": [],
    "links": {
        "first": "https://clients.metrica.bg/api/v1/connectors/client/stock/allProductsPaginated/byProductId?page=1",
        "last": "https://clients.metrica.bg/api/v1/connectors/client/stock/allProductsPaginated/byProductId?page=1",
        "prev": null,
        "next": null
    },
    "meta": {
        "current_page": 1,
        "from": null,
        "last_page": 1,
        "links": [
            {
                "url": null,
                "label": "« Previous",
                "active": false
            },
            {
                "url": "https://clients.metrica.bg/api/v1/connectors/client/stock/allProductsPaginated/byProductId?page=1",
                "label": "1",
                "active": true
            },
            {
                "url": null,
                "label": "Next »",
                "active": false
            }
        ],
        "path": "https://clients.metrica.bg/api/v1/connectors/client/stock/allProductsPaginated/byProductId",
        "per_page": 1000,
        "to": null,
        "total": 0
    },
    "success": true
}
 

Request      

GET api/v1/connectors/client/stock/allProductsPaginated/byProductId

Headers

Authorization      

Example: Bearer {YOUR_AUTH_TOKEN}

Content-Type      

Example: application/json

Accept      

Example: application/json

Query Parameters

page   integer  optional  

Which page to show. Example: 1

Body Parameters

untilDate   date  optional  

If a date is provided the stock will be calculated until the given date (included). The allowed date format is dd/mm/yyyy. Example: 31/12/2020

API V1 - Bundlers

A bundler is only a product with 'abilities'. Usually a bundler contains children and their children are also products.

The bundle bundler

The stock-parent bundler

Product Bundlers Endpoints

GET All Bundlers

requires authentication

List all product bundlers.

Presents the result with page size and pagination.

Throttling: Max 10 requests per minute. (10/1)

Default page size : 50 records per page.

Example request:
$client = new \GuzzleHttp\Client();
$url = 'https://clients.metrica.bg/api/v1/connectors/client/bundlers';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_TOKEN}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'query' => [
            'page' => '1',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://clients.metrica.bg/api/v1/connectors/client/bundlers"
);

const params = {
    "page": "1",
};
Object.keys(params)
    .forEach(key => url.searchParams.append(key, params[key]));

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

fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());
curl --request GET \
    --get "https://clients.metrica.bg/api/v1/connectors/client/bundlers?page=1" \
    --header "Authorization: Bearer {YOUR_AUTH_TOKEN}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
import requests
import json

url = 'https://clients.metrica.bg/api/v1/connectors/client/bundlers'
params = {
  'page': '1',
}
headers = {
  'Authorization': 'Bearer {YOUR_AUTH_TOKEN}',
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}

response = requests.request('GET', url, headers=headers, params=params)
response.json()

Example response (403):

Show headers
cache-control: no-cache, private
content-type: application/json
x-ratelimit-limit: 10
x-ratelimit-remaining: 9
access-control-allow-origin: *
 

{
    "success": false,
    "error": {
        "message": "Not allowed to access this endpoint.",
        "code": 403
    }
}
 

Request      

GET api/v1/connectors/client/bundlers

Headers

Authorization      

Example: Bearer {YOUR_AUTH_TOKEN}

Content-Type      

Example: application/json

Accept      

Example: application/json

Query Parameters

page   integer  optional  

Which page to show. Example: 1

CREATE Bundler

requires authentication

Create a new Bundler

Throttling: Max 10 requests per minute. (10/1)

Example request:
$client = new \GuzzleHttp\Client();
$url = 'https://clients.metrica.bg/api/v1/connectors/client/bundlers';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_TOKEN}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'bundlerType' => 'bundle',
            'bundlerProductId' => 10999,
            'bundlerProducts' => [
                [],
            ],
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://clients.metrica.bg/api/v1/connectors/client/bundlers"
);

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

let body = {
    "bundlerType": "bundle",
    "bundlerProductId": 10999,
    "bundlerProducts": [
        []
    ]
};

fetch(url, {
    method: "POST",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());
curl --request POST \
    "https://clients.metrica.bg/api/v1/connectors/client/bundlers" \
    --header "Authorization: Bearer {YOUR_AUTH_TOKEN}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"bundlerType\": \"bundle\",
    \"bundlerProductId\": 10999,
    \"bundlerProducts\": [
        []
    ]
}"
import requests
import json

url = 'https://clients.metrica.bg/api/v1/connectors/client/bundlers'
payload = {
    "bundlerType": "bundle",
    "bundlerProductId": 10999,
    "bundlerProducts": [
        []
    ]
}
headers = {
  'Authorization': 'Bearer {YOUR_AUTH_TOKEN}',
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}

response = requests.request('POST', url, headers=headers, json=payload)
response.json()

Request      

POST api/v1/connectors/client/bundlers

Headers

Authorization      

Example: Bearer {YOUR_AUTH_TOKEN}

Content-Type      

Example: application/json

Accept      

Example: application/json

Body Parameters

bundlerType   enum('bundle','stock-parent')   

The bundler type must be one of next possible values: bundle,stock-parent. Example: bundle

bundlerProductId   integer  optional  

The product (internal) ID. This product will be upgraded to a bundler. The value must be a positive integer. Example: 10999

bundlerProducts   object[]   

array of children products for the bundler

products   object  optional  
id   integer   

The product (internal) ID. The id must be unique(distinct) in the products object. Example: 184736

quantity   integer  optional  

requiredIf The product quantity. This field is required only if bundlerType is bundle. The value must be at least 1. Example: 3

priority   integer  optional  

requiredIf The product priority. This field is required only if bundlerType is stock-parent. The value must be at least 1. Example: 3

GET Bundler By ID

requires authentication

Get Bundler information by internal ID

Throttling: Max 40 requests per minute. (40/1)

Example request:
$client = new \GuzzleHttp\Client();
$url = 'https://clients.metrica.bg/api/v1/connectors/client/bundlers/1';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_TOKEN}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://clients.metrica.bg/api/v1/connectors/client/bundlers/1"
);

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

fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());
curl --request GET \
    --get "https://clients.metrica.bg/api/v1/connectors/client/bundlers/1" \
    --header "Authorization: Bearer {YOUR_AUTH_TOKEN}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
import requests
import json

url = 'https://clients.metrica.bg/api/v1/connectors/client/bundlers/1'
headers = {
  'Authorization': 'Bearer {YOUR_AUTH_TOKEN}',
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}

response = requests.request('GET', url, headers=headers)
response.json()

Example response (403):

Show headers
cache-control: no-cache, private
content-type: application/json
x-ratelimit-limit: 40
x-ratelimit-remaining: 38
access-control-allow-origin: *
 

{
    "success": false,
    "error": {
        "message": "Not allowed to access this endpoint.",
        "code": 403
    }
}
 

Example response (404):


{
    "success": false,
    "error": {
        "message": "Entry for Product not found",
        "code": 404
    }
}
 

Request      

GET api/v1/connectors/client/bundlers/{idp}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_TOKEN}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

idp   integer   

Example: 1

id   integer   

The bundler ID. Example: 184742

DELETE Bundler By ID

requires authentication

Delete Bundler by internal id

Throttling: Max 40 requests per minute. (40/1)

Example request:
$client = new \GuzzleHttp\Client();
$url = 'https://clients.metrica.bg/api/v1/connectors/client/bundlers/1';
$response = $client->delete(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_TOKEN}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://clients.metrica.bg/api/v1/connectors/client/bundlers/1"
);

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

fetch(url, {
    method: "DELETE",
    headers,
}).then(response => response.json());
curl --request DELETE \
    "https://clients.metrica.bg/api/v1/connectors/client/bundlers/1" \
    --header "Authorization: Bearer {YOUR_AUTH_TOKEN}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
import requests
import json

url = 'https://clients.metrica.bg/api/v1/connectors/client/bundlers/1'
headers = {
  'Authorization': 'Bearer {YOUR_AUTH_TOKEN}',
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}

response = requests.request('DELETE', url, headers=headers)
response.json()

Example response (404):


{
    "success": false,
    "error": {
        "message": "Entry for Product not found",
        "code": 404
    }
}
 

Request      

DELETE api/v1/connectors/client/bundlers/{idp}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_TOKEN}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

idp   integer   

Example: 1

productId   integer   

The product ID.

GET Bundler By EAN

requires authentication

Get Bundler information by its EAN (barcode)

This endpoint will return the first product found with the given param value!

Throttling: Max 40 requests per minute. (40/1)

Example request:
$client = new \GuzzleHttp\Client();
$url = 'https://clients.metrica.bg/api/v1/connectors/client/bundlers/byEan/4971850911118';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_TOKEN}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://clients.metrica.bg/api/v1/connectors/client/bundlers/byEan/4971850911118"
);

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

fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());
curl --request GET \
    --get "https://clients.metrica.bg/api/v1/connectors/client/bundlers/byEan/4971850911118" \
    --header "Authorization: Bearer {YOUR_AUTH_TOKEN}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
import requests
import json

url = 'https://clients.metrica.bg/api/v1/connectors/client/bundlers/byEan/4971850911118'
headers = {
  'Authorization': 'Bearer {YOUR_AUTH_TOKEN}',
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}

response = requests.request('GET', url, headers=headers)
response.json()

Example response (403):

Show headers
cache-control: no-cache, private
content-type: application/json
x-ratelimit-limit: 40
x-ratelimit-remaining: 39
access-control-allow-origin: *
 

{
    "success": false,
    "error": {
        "message": "Not allowed to access this endpoint.",
        "code": 403
    }
}
 

Example response (404):


{
    "success": false,
    "error": {
        "message": "Entry for Product not found",
        "code": 404
    }
}
 

Request      

GET api/v1/connectors/client/bundlers/byEan/{ean}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_TOKEN}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

ean   string   

The bundler EAN. Example: 4971850911118

GET Bundler By External ID

requires authentication

Get Bundler information by its External ID

This endpoint will return the first product found with the given param value!

Throttling: Max 40 requests per minute. (40/1)

Example request:
$client = new \GuzzleHttp\Client();
$url = 'https://clients.metrica.bg/api/v1/connectors/client/bundlers/byExternalId/105';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_TOKEN}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://clients.metrica.bg/api/v1/connectors/client/bundlers/byExternalId/105"
);

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

fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());
curl --request GET \
    --get "https://clients.metrica.bg/api/v1/connectors/client/bundlers/byExternalId/105" \
    --header "Authorization: Bearer {YOUR_AUTH_TOKEN}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
import requests
import json

url = 'https://clients.metrica.bg/api/v1/connectors/client/bundlers/byExternalId/105'
headers = {
  'Authorization': 'Bearer {YOUR_AUTH_TOKEN}',
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}

response = requests.request('GET', url, headers=headers)
response.json()

Example response (403):

Show headers
cache-control: no-cache, private
content-type: application/json
x-ratelimit-limit: 40
x-ratelimit-remaining: 39
access-control-allow-origin: *
 

{
    "success": false,
    "error": {
        "message": "Not allowed to access this endpoint.",
        "code": 403
    }
}
 

Example response (404):


{
    "success": false,
    "error": {
        "message": "Entry for Product not found",
        "code": 404
    }
}
 

Request      

GET api/v1/connectors/client/bundlers/byExternalId/{externalId}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_TOKEN}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

externalId   string   

The bundler External ID. Example: 105

ADD Product to bundler

requires authentication

ADD a child product using the product internal ID to a bundler

Throttling: Max 10 requests per minute. (10/1)

Example request:
$client = new \GuzzleHttp\Client();
$url = 'https://clients.metrica.bg/api/v1/connectors/client/bundlers/1/addProduct';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_TOKEN}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'productId' => '184736',
            'productQuantity' => 3,
            'productPriority' => 3,
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://clients.metrica.bg/api/v1/connectors/client/bundlers/1/addProduct"
);

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

let body = {
    "productId": "184736",
    "productQuantity": 3,
    "productPriority": 3
};

fetch(url, {
    method: "POST",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());
curl --request POST \
    "https://clients.metrica.bg/api/v1/connectors/client/bundlers/1/addProduct" \
    --header "Authorization: Bearer {YOUR_AUTH_TOKEN}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"productId\": \"184736\",
    \"productQuantity\": 3,
    \"productPriority\": 3
}"
import requests
import json

url = 'https://clients.metrica.bg/api/v1/connectors/client/bundlers/1/addProduct'
payload = {
    "productId": "184736",
    "productQuantity": 3,
    "productPriority": 3
}
headers = {
  'Authorization': 'Bearer {YOUR_AUTH_TOKEN}',
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}

response = requests.request('POST', url, headers=headers, json=payload)
response.json()

Example response (404):


{
    "success": false,
    "error": {
        "message": "Entry for Product not found",
        "code": 404
    }
}
 

Request      

POST api/v1/connectors/client/bundlers/{bundler_idp}/addProduct

Headers

Authorization      

Example: Bearer {YOUR_AUTH_TOKEN}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

bundler_idp   integer   

Example: 1

Body Parameters

productId   string   

The child product (internal) ID. Example: 184736

productQuantity   integer  optional  

requiredIf The child product quantity. This field is required only if the bundler type is bundle. The value must be at least 1. Example: 3

productPriority   integer  optional  

requiredIf The child product priority. This field is required only if the bundler type is stock-parent. The value must be at least 1. Example: 3

REMOVE Product from bundler

requires authentication

REMOVE a child product using the product internal ID from a bundler

Throttling: Max 10 requests per minute. (10/1)

Example request:
$client = new \GuzzleHttp\Client();
$url = 'https://clients.metrica.bg/api/v1/connectors/client/bundlers/1/removeProduct';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_TOKEN}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'productId' => '184736',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://clients.metrica.bg/api/v1/connectors/client/bundlers/1/removeProduct"
);

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

let body = {
    "productId": "184736"
};

fetch(url, {
    method: "POST",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());
curl --request POST \
    "https://clients.metrica.bg/api/v1/connectors/client/bundlers/1/removeProduct" \
    --header "Authorization: Bearer {YOUR_AUTH_TOKEN}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"productId\": \"184736\"
}"
import requests
import json

url = 'https://clients.metrica.bg/api/v1/connectors/client/bundlers/1/removeProduct'
payload = {
    "productId": "184736"
}
headers = {
  'Authorization': 'Bearer {YOUR_AUTH_TOKEN}',
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}

response = requests.request('POST', url, headers=headers, json=payload)
response.json()

Example response (404):


{
    "success": false,
    "error": {
        "message": "Entry for Product not found",
        "code": 404
    }
}
 

Request      

POST api/v1/connectors/client/bundlers/{bundler_idp}/removeProduct

Headers

Authorization      

Example: Bearer {YOUR_AUTH_TOKEN}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

bundler_idp   integer   

Example: 1

Body Parameters

productId   string   

The child product (internal) ID. Example: 184736

API V1 - Courier Status List

Courier Status List Endpoints

GET All Courier Statuses

requires authentication

List all internal courier statuses records.

Throttling: Max 1 request per hour. (1/60)

Information found on fields courierStatusId, status and statusLong come from couriers and might not be up-to-date.

isFinal has only two values: YES,NO. The AWB number/order that have a courier status id with isFinal = YES is considered final and will probably not be changed anymore.

We have knowledge on situations when couriers changed the status of a shipment even after they provided a final status!

Example request:
$client = new \GuzzleHttp\Client();
$url = 'https://clients.metrica.bg/api/v1/connectors/client/couriers/statusList';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_TOKEN}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://clients.metrica.bg/api/v1/connectors/client/couriers/statusList"
);

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

fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());
curl --request GET \
    --get "https://clients.metrica.bg/api/v1/connectors/client/couriers/statusList" \
    --header "Authorization: Bearer {YOUR_AUTH_TOKEN}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
import requests
import json

url = 'https://clients.metrica.bg/api/v1/connectors/client/couriers/statusList'
headers = {
  'Authorization': 'Bearer {YOUR_AUTH_TOKEN}',
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}

response = requests.request('GET', url, headers=headers)
response.json()

Example response (429):

Show headers
cache-control: no-cache, private
content-type: application/json
x-ratelimit-limit: 400
x-ratelimit-remaining: 341
access-control-allow-origin: *
 

{
    "success": false,
    "error": {
        "message": "Too Many Attempts.",
        "code": 429
    }
}
 

Request      

GET api/v1/connectors/client/couriers/statusList

Headers

Authorization      

Example: Bearer {YOUR_AUTH_TOKEN}

Content-Type      

Example: application/json

Accept      

Example: application/json

API V1 - Delete Event

Delete Event Endpoints

There are no delete event records BEFORE 23.05.2024!
The order delete event records are different from the other sources.

GET Deleted Events by CreatedAt Date

requires authentication

Returns a list with all deleted events filtered by the source and the provided date of creation.

Throttling: Max 20 requests per hour. (20/60)

Default page size : 250 records per page.

Presents the result with page size and pagination.

Example request:
$client = new \GuzzleHttp\Client();
$url = 'https://clients.metrica.bg/api/v1/connectors/client/deleteEvents/createdAtDate';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_TOKEN}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'query' => [
            'page' => '1',
        ],
        'json' => [
            'source' => 'product',
            'date' => '2024-05-23',
            'perPage' => 100,
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://clients.metrica.bg/api/v1/connectors/client/deleteEvents/createdAtDate"
);

const params = {
    "page": "1",
};
Object.keys(params)
    .forEach(key => url.searchParams.append(key, params[key]));

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

let body = {
    "source": "product",
    "date": "2024-05-23",
    "perPage": 100
};

fetch(url, {
    method: "POST",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());
curl --request POST \
    "https://clients.metrica.bg/api/v1/connectors/client/deleteEvents/createdAtDate?page=1" \
    --header "Authorization: Bearer {YOUR_AUTH_TOKEN}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"source\": \"product\",
    \"date\": \"2024-05-23\",
    \"perPage\": 100
}"
import requests
import json

url = 'https://clients.metrica.bg/api/v1/connectors/client/deleteEvents/createdAtDate'
payload = {
    "source": "product",
    "date": "2024-05-23",
    "perPage": 100
}
params = {
  'page': '1',
}
headers = {
  'Authorization': 'Bearer {YOUR_AUTH_TOKEN}',
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}

response = requests.request('POST', url, headers=headers, json=payload, params=params)
response.json()

Request      

POST api/v1/connectors/client/deleteEvents/createdAtDate

Headers

Authorization      

Example: Bearer {YOUR_AUTH_TOKEN}

Content-Type      

Example: application/json

Accept      

Example: application/json

Query Parameters

page   integer  optional  

Which page to show. Example: 1

Body Parameters

source   string   

The source field accepts only the following values: product, entry, order. Example: product

date   date  optional  

The date must be today or older than today and not older than 2024-05-23. If not provided, the default is today. The format must be in: yyyy-mm-dd. Example: 2024-05-23

perPage   integer  optional  

Number of records to show per page. The allowed values are between 10 and 1000. If not provided, the default is 250. Example: 100