https://delivery.econt.com/services
generated at 2024-08-13 10:06
<?php
const SHOP_ID = 5080473; // ID на магазина в "Достави с Еконт"
const SHIPPMENT_CALC_URL = 'https://delivery.demo.econt.com/customer_info.php'; // URL визуализиращ форма за доставка
const SHOP_CURRENCY = 'BGN'; // валута на магазина (валута на наложения платеж)
const UPDATE_ORDER_ENDPOINT = 'https://delivery.econt.com/services/OrdersService.updateOrder.json'; // Ендпойнта на услугата създаване или редактиране на поръчка
const PRIVATE_KEY = 'ххххххххххххххх'; // Код за свързване
Чрез формата, клиента на електронния магазин ще уточни мястото на доставка на пратката и след потвърждение ще се генерира цена за доставка.
<?php
// ИМПЛЕМЕНТИРАНЕ НА ФОРМАТА ЗА ДОСТАВКА
// параметри за конфигуриране на формата за изчисляване на цена за доставка
$shippmentCalcUrlParams = [
// Задължителни параметри:
'id_shop' => SHOP_ID, // ID на електронния магазин
'order_total' => 62.00, // Стойност на поръчката (количество за наложен платеж по пратката)
'order_currency' => SHOP_CURRENCY, // валута на наложения платеж
'order_weight' => 3.500, // общо тегло на пратката
// Незадължителни параметри (попълнените параметри ще запълнят автоматично полетата във формата за изчисляване на цена)
'customer_company' => '', // име / фирма
'customer_name' => '', // лице
'customer_phone' => '', // телефон
'customer_email' => '', // имейл
'customer_country' => '', // държава
'customer_zip' => '', // зип код
'customer_city_name' => '', // населено място
'customer_post_code' => '', // пощенски код
'customer_address' => '', // адрес
'confirm_txt' => 'Потвърди' ,// текст за потвърждаващия бутон
];
$shippmentCalcUrl = SHIPPMENT_CALC_URL . '?' . http_build_query($shippmentCalcUrlParams, null, '&');
<!-- ФОРМА ЗА ДОСТАВКА -->
<iframe src="<?=$shippmentCalcUrl?>"></iframe>
<!-- В това поле ще се запзаи уникален индентификатор на адреса за доставка. Попълва се от Java Script функцията която 'слуша' съобщенията от формата за доставка -->
<input type="hidden" name="customerInfo[id]">
// Елемент от кода, където е указано дали стоката ще се заплаща с НП или не
var codInput = document.getElementsByName('cod')[0];
//Елемент от формата в който ще се постави уникалното ID на адрес за доставката
var customerInfoIdInput = document.getElementsByName('customerInfo[id]')[0];
//Формата в която се съдържат данните по поръчката в магазина и същата трябва да се подаде
var confirmForm = document.getElementById('confirm-form');
// добавяне на функция, която 'слуша' данни връщани от формите за доставка
window.addEventListener('message', function(message) {
// Данни връщани от формата за доставка:
// id: уникално ID на адреса. Това поле трябва да бъде поставено в скритото customerInfo[id]
// id_country: ID на държавата
// zip: зип код на населеното място
// post_code: пощенски код на населеното място
// city_name: населено място
// office_code: код на офиса на Еконт ако бъде избран такъв
// address: адрес
// name: име / фирма
// face: лице
// phone: телефон
// email: имейл
// shipping_price: цена на пратката без НП
// shipping_price_cod: цена на пратката с НП
// shipping_price_cod_e: цена на пратката с НП събран електронно
// shipping_price_currency: валута на калкулираната цена
// shipment_error: поясняващ текст ако е възникнала грешка
var data = message['data'];
// възможно е да възникнат грешки при неправилно конфигурирани настройки на електронния магазин които пречат за калкулацията
if (data['shipment_error'] && data['shipment_error'] !== '') alert('Възникна грешка при изичисляване на стройноста на пратката');
// формата за калкулация връща цена с НП и такава без
// спрямо избора на клиента в "Заплащане чрез НП" показваме правилната цена
var shippmentPrice;
if (codInput.checked) shippmentPrice = data['shipping_price_cod'];
else shippmentPrice = data['shipping_price'];
var confirmMessage = "Куриеркста ви услуга е на стройност " + shippmentPrice + ' ' + data['shipping_price_currency'] + ' потвърждавате ли покупката?';
if (confirm(confirmMessage)) {
customerInfoIdInput.value = data['id'];
confirmForm.submit();
}
}, false);
Услугата може да бъде извикана в следните случай:
- При завършване на поръчката от клиента;
- При редактиране на поръчката от търговеца в рамките на административния си панел;
<?php
// Иницииране на обект за извикване на отдалечена услуга
$curl = curl_init();
curl_setopt($curl, CURLOPT_URL, UPDATE_ORDER_ENDPOINT);
curl_setopt($curl, CURLOPT_RETURNTRANSFER, true);
curl_setopt($curl, CURLOPT_SSL_VERIFYPEER, false);
curl_setopt($curl, CURLOPT_SSL_VERIFYHOST, false);
curl_setopt($curl, CURLOPT_HTTPHEADER, [
'Content-Type: application/json',
'Authorization: ' . PRIVATE_KEY
]);
curl_setopt($curl, CURLOPT_POST, true);
curl_setopt($curl, CURLOPT_POSTFIELDS, json_encode($_POST));
curl_setopt($curl, CURLOPT_TIMEOUT, 10);
// Изпращане на заявката
$response = curl_exec($curl);
// Визуализиране на върнатия резултат
var_dump($response);
var_dump(curl_error($curl));
{
id_shop:8423174,//идентификатор на магазина
currency:'BGN',//валута на поръчката
items:[//списък с продуктите в количката
{
name:'Product name 1',//Име на продукта
SKU:'ITM1',//Код на продукта (опционално)
URL:'http://example.org/shop/product-name-1',//адрес на продукта в магазина (опционално)
imageURL:'http://example.org/shop/product-images/product-name-1.jpg',//адрес картинка на продукта (опционално)
count:2,//закупени бройки (опционално, 1 по подразбиране)
totalWeight:1.4,//общо тегло (тегло * брой)
totalPrice:50.6//обща цена (ед. цена * брой)
},
{
name:'Product name 2',//Име на продукта
SKU:'ITM1',//Код на продукта (опционално)
URL:'http://example.org/shop/product-name-2',//адрес на продукта в магазина (опционално)
imageURL:'http://example.org/shop/product-images/product-name-2.jpg',//адрес картинка на продукта (опционално)
count:1,//закупени бройки (опционално, 1 по подразбиране)
totalWeight:0.7,//общо тегло (тегло * брой)
totalPrice:25.3//обща цена (ед. цена * брой)
}
]
}
function genDeliverWithEcontURL(orderParams) {
orderParams.id_shop = DELIVERY_ECONT_SHOP_ID;//добавяне на идентификатора на магазина
return 'http://delivery.econt.com/checkout.php?'+jQuery.param(orderParams);
}
<?php
function genDeliverWithEcontURL($orderParams) {
$orderParams['id_shop'] = DELIVERY_ECONT_SHOP_ID;//добавяне на идентификатора на магазина
return 'http://delivery.econt.com/checkout.php?'.http_build_query($orderParams,null,'&');
}
<a style="user-select: none;display: inline-block;text-decoration: none;background-color: #234182;border-radius: 40px;line-height: 43px;padding: 0 40px;color: #fff;font-weight: 400;font-size: 15px;box-shadow: 0 2px 2px 0 rgba(33,33,33,.24);"
href="javascript:window.open('<?php echo genDeliverWithEcontURL([
'currency' => $product['currency'],//
'items' => [[
'name' => $product['name'],
'SKU' => $product['sku'],
'URL' => $product['url'],
'imageURL' => $product['image'],
'totalWeight' => $product['weight'],
'totalPrice' => $product['price'],
]]
])?>','econt-delivery-order','width=600,height=840')"
class="buy-with-econt"
>Достави с Еконт</a>
The office locator is deployed on STAGING and PRODUCTION environments. Integrators are strongly advised to use the respective office locator URL when integrating in their own stage/test and production environments. This enables better internal testing, since fixes and improvements in the office locator will be deployed to STAGING first for internal testing and validation.
Environment URLs for the Econt Office Locator:
https://staging.officelocator.econt.com/
https://salmon-bay-01cca7d03.1.azurestaticapps.net/
https://officelocator.econt.com/
https://agreeable-forest-09fdc1003.1.azurestaticapps.net/
https://example.staging.officelocator.econt.com/
https://kind-mushroom-0f190ca03.1.azurestaticapps.net/
Integrators should use the custom Econt URL when integrating in their applications.
To integrate the office locator inside a web app the developer must use an iframe. The iframe's url points to the office locator url and passes the relevant query parameters. The office locator accepts the following query parameters:
Here is a code example:
<iframe title="Econt Office Locator" allow="geolocation;" src="https://staging.officelocator.econt.com?shopUrl=https://example.staging.officelocator.econt.com&city=Sofia&address=ul. rezbarska 5&officeType=office&lang=bg" style="width: 100%; height: 90vh; border-width: 0px;"> </iframe>
It's important to note the allow="geolocation;" attribute. Without it the iframe won't be able to request the user location.
Listening for office locator messages works by attaching an event listener for the window's 'message' event. The event.data.office property will contain the selected office object from the office locator.
Code example:
<script> function displayMessage(event) { if (event.data?.office === undefined) { return; } alert(JSON.stringify(event.data.office, null, 2)); } if (window.addEventListener) { window.addEventListener('message', displayMessage); } else { window.attachEvent("onmessage", displayMessage); } </script>
Sample output of event.data.office:
{ "id": 1029, "code": "1127", "name": "София", "address": { "city": { "id": 41, "name": "София", "nameEn": "Sofia", "postCode": "1000", "searchField": "София Sofia", "searchableType": 2 }, "fullAddress": " София жк Хаджи Димитър ул. Резбарска №11 След магазин Кауфланд до гараж Малашевци", "location": { "latitude": 42.715536272615, "longitude": 23.359397797821, "confidence": 3 }, "quarter": "жк Хаджи Димитър", "street": "ул. Резбарска", "streetNumber": "11" } }
Начинът на имплементиране в дадено приложение е, чрез добавянето на iframe
<iframe src="линк" allow="фукнции"></iframe>
src
- указва адреса на документа за вграждане.
allow
- определя какви функции са достъпни за <iframe> (например достъп до микрофона, камерата, батерията, уеб споделяне и т.н.).
Примерен код за вграждане:
<iframe src="https://offices.econt.com/?lang=&city=&country=source_url=" allow="geolocation 'self' https://offices.econt.com/"></iframe>
Параметри към линка в атрибута "src":
Незадължителниlang (език)
- Език на приложението. Възможни езици са български(bg), гръцки(gr), румънски(ro) и английски(en). При неуточнение на езика, по подразбиране е на български.
city (населено място)
- Посредством ID, пощенски код или име на населено място, автоматично се генерира репорта за откритите селища отговарящи на критерия.
country (държава)
- Двубуквен код за държава. По подразбиране е bg - България.
source_url
- системата в която е имплементирано приложението.
Достъпни функции в параметъра allow
geolocation 'self' https://offices.econt.com/
разрешава използването на геолоциране от браузъра
<?php
const SHOP_ID = 5080473; // ID of the online shop
const SHIPPMENT_CALC_URL = 'https://delivery-demo.econt.com/customer_info.php'; // URL for visualization of the delivery form
const SHOP_CURRENCY = 'BGN'; // shop currency (Cash On Delivery (COD) currency)
const UPDATE_ORDER_ENDPOINT = 'https://delivery-demo.econt.com/services/OrdersService.updateOrder.json'; // Endpoint for creating/editing an order
const PRIVATE_KEY = 'ххххххххххххххх'; // Connection code
The form is used to validate the delivery details (address, office etc.) of the end customer and after confirmation it calculates the delivery price.
<?php
// Implementation of the delivery form
// configuration parameters for the delivery form
$shippmentCalcUrlParams = [
// Mandatory parameters:
'id_shop' => SHOP_ID, // ID of the online shop
'order_total' => 62.00, // Order total value (COD amount)
'order_currency' => SHOP_CURRENCY, // COD currency
'order_weight' => 3.500, // Total shipment weight
// Optional parameters (values will automatically fill-in the fields in the delivery form)
'customer_company' => '', // Personal name or Company name
'customer_name' => '', // Contact person (mandatory when the client is commercial (Company)
'customer_phone' => '', // phone
'customer_email' => '', // email
'customer_country' => '', // country
'customer_zip' => '', // zip code
'customer_city_name' => '', // city
'customer_post_code' => '', // post code
'customer_office_code' => '', // office code
'customer_address' => '', // address
'confirm_txt' => 'Confirm' // text value for the confirmation button
'ignore_history' => 0, // turning on/off the automatic field history (0 = ON, 1 = OFF)
];
$shippmentCalcUrl = SHIPPMENT_CALC_URL . '?' . http_build_query($shippmentCalcUrlParams, null, '&');
<!-- Delivery Form -->
<iframe src="<?=$shippmentCalcUrl?>"></iframe>
<!-- In this field, a unique address identifier will be saved. It is entered from a Java Script function that "listens" the delivery form messages-->
<input type="hidden" name="customerInfo[id]">
// Part of the code, which defines whether the order will be paid with or without COD
var codInput = document.getElementsByName('cod')[0];
//Form element, where the unique address identifier is placed
var customerInfoIdInput = document.getElementsByName('customerInfo[id]')[0];
//Form containing the order data in the online shop and should be sent
var confirmForm = document.getElementById('confirm-form');
// creating a function, that "listens" for data returned from the delivery form
window.addEventListener('message', function(message) {
// Data returned from the delivery form:
// id: unique address identifier. This value should be provided in the hidden customerInfo[id]
// id_country: ID of the country
// zip: zip code of the city
// post_code: post code of the city
// city_name: city name
// office_code: office code (if such is selected)
// address: address
// name: Personal name / Company name
// face: Contact person
// phone: phone
// email: email
// shipping_price: delivery price without COD
// shipping_price_cod: delivery price with COD
// shipping_price_cod_е: delivery price with COD collected digitally
// shipping_price_currency: shipping price currency
// shipment_error: error message if an error occurs
var data = message['data'];
// It is possible that errors occur due to incorrect configuration of the online shop in the Econt Delivery application
if (data['shipment_error'] && data['shipment_error'] !== '') alert('Error calculating shipment price');
// the calculation form returns two prices - one with COD and one without COD
// depending on the end customer's selection of payment method, we show the correct price
var shippmentPrice;
if (codInput.checked) shippmentPrice = data['shipping_price_cod'];
else shippmentPrice = data['shipping_price'];
var confirmMessage = "You delivery price is: " + shippmentPrice + ' ' + data['shipping_price_currency'] + ' do you confirm?';
if (confirm(confirmMessage)) {
customerInfoIdInput.value = data['id'];
confirmForm.submit();
}
}, false);
The service can be used in the following cases:
- When the customer confirms the order;
- When the shop administrator edits the order from the admin panel of the shop;
<?php
// Initiating an object to call a remote service
$curl = curl_init();
curl_setopt($curl, CURLOPT_URL, UPDATE_ORDER_ENDPOINT);
curl_setopt($curl, CURLOPT_RETURNTRANSFER, true);
curl_setopt($curl, CURLOPT_SSL_VERIFYPEER, false);
curl_setopt($curl, CURLOPT_SSL_VERIFYHOST, false);
curl_setopt($curl, CURLOPT_HTTPHEADER, [
'Content-Type: application/json',
'Authorization: ' . PRIVATE_KEY
]);
curl_setopt($curl, CURLOPT_POST, true);
curl_setopt($curl, CURLOPT_POSTFIELDS, json_encode($_POST));
curl_setopt($curl, CURLOPT_TIMEOUT, 10);
// Sending the request
$response = curl_exec($curl);
// Visualizing the response
var_dump($response);
var_dump(curl_error($curl));
<?php
// Example for initiating an object to call a remote service
$curl = curl_init();
curl_setopt($curl, CURLOPT_URL, 'http://delivery.econt.com/services/OrdersService.updateOrder.json');
curl_setopt($curl, CURLOPT_RETURNTRANSFER, true);
curl_setopt($curl, CURLOPT_SSL_VERIFYPEER, false);
curl_setopt($curl, CURLOPT_SSL_VERIFYHOST, false);
curl_setopt($curl, CURLOPT_HTTPHEADER, [
'Content-Type: application/json',
'Authorization: Identification Code'
]);
curl_setopt($curl, CURLOPT_POST, true);
curl_setopt($curl, CURLOPT_POSTFIELDS, json_encode(array( // Type: Order -> http://delivery.econt.com/services/#Order
'id' => '', // If "ID" is provided, the system will check for existing order and, if such is found, the system will update it. If no such order is found, the system creates new order.
'orderNumber' => '',
'status' => '',
'orderTime' => '',
'orderSum' => '',
'cod' => '',
'partialDelivery' => '',
'currency' => '',
'shipmentDescription' => '',
'shipmentNumber' => '',
'customerInfo' => array( // Type: CustomerInfo -> http://delivery.econt.com/services/#CustomerInfo
'id' => '',
'name' => '',
'face' => '',
'phone' => '',
'email' => '',
'countryCode' => '',
'cityName' => '',
'postCode' => '',
'officeCode' => '',
'zipCode' => '',
'address' => '',
'priorityFrom' => '',
'priorityTo' => ''
),
'items' => array(
0 => array( // Type: OrderItem -> http://delivery.econt.com/services/#OrderItem
'name' => '',
'SKU' => '',
'URL' => '',
'count' => '',
'hideCount' => '', // accepted values are 0 and 1. It is used as an option to hide the form for changing the quantity.
'totalPrice' => '',
'totalWeight' => ''
),
1 => array(
'name' => '',
'SKU' => '',
'URL' => '',
'count' => '',
'hideCount' => '', // accepted values are 0 and 1. It is used as an option to hide the form for changing the quantity
'totalPrice' => '',
'totalWeight' => ''
)
// ...
)
)));
curl_setopt($curl, CURLOPT_TIMEOUT, 10);
// Sending the request
$response = curl_exec($curl);
// Visualization of the response
var_dump($response);
var_dump(curl_error($curl));
{
id_shop:8423174,//shop identifier
currency:'BGN',//order currency
items:[//list of products in the shopping cart
{
name:'Product name 1',//name of the product
SKU:'ITM1',//Product code (optional)
URL:'http://example.org/shop/product-name-1',//Product link (optional)
imageURL:'http://example.org/shop/product-images/product-name-1.jpg',//Product picture link (optional)
count:2,//purchased quantity (optional, 1 by default)
hideCount:1,//accepted values are 0 and 1. It is used as an option to hide the form for changing the quantity.
totalWeight:1.4,//общо тегло (тегло * брой)
totalPrice:50.6//total price (unit price * quantity)
},
{
name:'Product name 2',//Product name
SKU:'ITM1',//Product code (optional)
URL:'http://example.org/shop/product-name-2',//Product link (optional)
imageURL:'http://example.org/shop/product-images/product-name-2.jpg',//Product picture link (optional)
count:1,//purchased quantity (optional, 1 by default)
hideCount:1,//accepted values are 0 and 1. It is used as an option to hide the form for changing the quantity.
totalWeight:0.7,//total weight (weight * quantity)
totalPrice:25.3//total price (unit price * quantity)
}
]
}
function genDeliverWithEcontURL(orderParams) {
orderParams.id_shop = DELIVERY_ECONT_SHOP_ID;//adding the shop identifier
return 'http://delivery.econt.com/checkout.php?'+jQuery.param(orderParams);
}
<?php
function genDeliverWithEcontURL($orderParams) {
$orderParams['id_shop'] = DELIVERY_ECONT_SHOP_ID;//adding the shop identifier
return 'http://delivery.econt.com/checkout.php?'.http_build_query($orderParams,null,'&');
}
<a style="user-select: none;display: inline-block;text-decoration: none;background-color: #234182;border-radius: 40px;line-height: 43px;padding: 0 40px;color: #fff;font-weight: 400;font-size: 15px;box-shadow: 0 2px 2px 0 rgba(33,33,33,.24);"
href="javascript:window.open('<?php echo genDeliverWithEcontURL([
'currency' => $product['currency'],//
'items' => [[
'name' => $product['name'],
'SKU' => $product['sku'],
'URL' => $product['url'],
'imageURL' => $product['image'],
'totalWeight' => $product['weight'],
'totalPrice' => $product['price'],
]]
])?>','econt-delivery-order','width=600,height=840')"
class="buy-with-econt"
>Econt Delivery</a>
The office locator is deployed on STAGING and PRODUCTION environments. Integrators are strongly advised to use the respective office locator URL when integrating in their own stage/test and production environments. This enables better internal testing, since fixes and improvements in the office locator will be deployed to STAGING first for internal testing and validation.
Environment URLs for the Econt Office Locator:
https://staging.officelocator.econt.com/
https://salmon-bay-01cca7d03.1.azurestaticapps.net/
https://officelocator.econt.com/
https://agreeable-forest-09fdc1003.1.azurestaticapps.net/
https://example.staging.officelocator.econt.com/
https://kind-mushroom-0f190ca03.1.azurestaticapps.net/
Integrators should use the custom Econt URL when integrating in their applications.
To integrate the office locator inside a web app the developer must use an iframe. The iframe's url points to the office locator url and passes the relevant query parameters. The office locator accepts the following query parameters:
Here is a code example:
<iframe title="Econt Office Locator" allow="geolocation;" src="https://staging.officelocator.econt.com?shopUrl=https://example.staging.officelocator.econt.com&city=Sofia&address=ul. rezbarska 5&officeType=office&lang=bg" style="width: 100%; height: 90vh; border-width: 0px;"> </iframe>
It's important to note the allow="geolocation;" attribute. Without it the iframe won't be able to request the user location.
Listening for office locator messages works by attaching an event listener for the window's 'message' event. The event.data.office property will contain the selected office object from the office locator.
Code example:
<script> function displayMessage(event) { if (event.data?.office === undefined) { return; } alert(JSON.stringify(event.data.office, null, 2)); } if (window.addEventListener) { window.addEventListener('message', displayMessage); } else { window.attachEvent("onmessage", displayMessage); } </script>
Sample output of event.data.office:
{ "id": 1029, "code": "1127", "name": "София", "address": { "city": { "id": 41, "name": "София", "nameEn": "Sofia", "postCode": "1000", "searchField": "София Sofia", "searchableType": 2 }, "fullAddress": " София жк Хаджи Димитър ул. Резбарска №11 След магазин Кауфланд до гараж Малашевци", "location": { "latitude": 42.715536272615, "longitude": 23.359397797821, "confidence": 3 }, "quarter": "жк Хаджи Димитър", "street": "ул. Резбарска", "streetNumber": "11" } }
The way to implement it in an application is by adding an iframe
<iframe src="link" allow="functions"></iframe>
src
- specifies the address of the document to embed.
allow
- determines what features are available for <iframe> (for example, access to the microphone, camera, battery, web sharing, etc.).
Sample embed code:
<iframe src="https://offices.econt.com/?lang=&city=&country=source_url=" allow="geolocation 'self' https://offices.econt.com/"></iframe>
Parameters to the link in the attribute "src":
Optionallang
- Application language. Possible languages are Bulgarian(bg), Greek(gr), Romanian(ro) and English(en). If the language is not specified, by default it is in Bulgarian.
city
- ID, postal code or name of a settlement, the report is automatically generated for the settlements found meeting the criteria.
country
- Two-letter country code. Default is bg - Bulgaria.
source_url
- the system in which an application is implemented.
Available functions in the parameter allow
geolocation 'self' https://offices.econt.com/
allows the use of geolocation by the browser
Status of the shipment Status of the shipment
Name | Type | Multiplicity | Description |
---|---|---|---|
shipmentNumber | string | [0..1] | Shipment number Shipment number |
storageOfficeName | string | [0..1] | Storage office name Storage office name |
storagePersonName | string | [0..1] | Storage person name Storage person name |
createdTime | dateTime | [0..1] | Created time Created time |
sendTime | dateTime | [0..1] | The time when the shipment is sent The time when the shipment is sent |
deliveryTime | dateTime | [0..1] | Delivery time Delivery time |
shipmentType | string | [0..1] | Shipment type Shipment type |
packCount | int | [0..1] | Count of packs Count of packs |
weight | double | [0..1] | Weight Weight |
shipmentDescription | string | [0..1] | Shipment description Shipment description |
senderDeliveryType | string | [0..1] | Sender delivery type - door or office Sender delivery type - door or office |
senderOfficeCode | string | [0..1] | The office code of the sender The office code of the sender |
receiverDeliveryType | string | [0..1] | Receiver delivery type - door or office Receiver delivery type - door or office |
receiverOfficeCode | string | [0..1] | The office code of the receiver The office code of the receiver |
cdCollectedAmount | double | [0..1] | Collected "cash on delivery" amount Collected "cash on delivery" amount |
cdCollectedCurrency | string | [0..1] | Collected "cash on delivery" currency Collected "cash on delivery" currency |
cdCollectedTime | dateTime | [0..1] | Collected "cash on delivery" time Collected "cash on delivery" time |
cdPaidAmount | double | [0..1] | "Cash on delivery" paid amount "Cash on delivery" paid amount |
cdPaidCurrency | string | [0..1] | "Cash on delivery" paid currency "Cash on delivery" paid currency |
cdPaidTime | dateTime | [0..1] | Paid "cash on delivery" time Paid "cash on delivery" time |
totalPrice | double | [0..1] | The total price of the shipment The total price of the shipment |
currency | string | [0..1] | Currency Currency |
discountPercent | double | [0..1] | Discount percentage Discount percentage |
discountAmount | double | [0..1] | Amount of discount Amount of discount |
discountDescription | string | [0..1] | Description of the discount Description of the discount |
senderDueAmount | double | [0..1] | Due amount from the sender Due amount from the sender |
receiverDueAmount | double | [0..1] | Due amount from the receiver Due amount from the receiver |
otherDueAmount | double | [0..1] | Other due amounts Other due amounts |
deliveryAttemptCount | int | [0..1] | Count of delivery attempts Count of delivery attempts |
services | ShipmentStatusService | [0..n] | Services Services |
trackingEvents | ShipmentTrackingEvent | [0..n] | Shipment tracking events Shipment tracking events |
pdfURL | string | [0..1] | URL for the label PDF URL for the label PDF |
expectedDeliveryDate | date | [0..1] | Expected delivery date Expected delivery date |
payAfterAccept | boolean | [0..1] | |
payAfterTest | boolean | [0..1] | |
partialDelivery | boolean | [0..1] | |
alertRedirected | string | [0..1] | |
packingListPDFURL | string | [0..1] | URL for the packing list PDF URL for the packing list PDF |
returnShipmentURL | string | [0..1] | Return shipment form URL Return shipment form URL |
notApplicableServices | string | [0..1] | Not applicable services for the zones Not applicable services for the zones |
This is a service for requesting the delivery status of a shipment
Name | Type | Multiplicity | Description |
---|---|---|---|
type | string | [0..1] | Type Type |
description | string | [0..1] | Description Description |
count | double | [0..1] | Shipment status count Shipment status count |
paymentSide | string | [0..1] | Indicates the payment side (sender, receiver, other) Indicates the payment side (sender, receiver, other) |
price | double | [0..1] | Price Price |
currency | string | [0..1] | Currency Currency |
Provides information about the whereabouts of a shipment
Name | Type | Multiplicity | Description |
---|---|---|---|
time | string | [0..1] | Time Time |
isReceipt | boolean | [0..1] | Indicates if the event is of a return receipt (DC) Indicates if the event is of a return receipt (DC) |
destinationType | string | [0..1] | Destination type Destination type |
destinationDetails | string | [0..1] | Destination details Destination details |
destinationDetailsEn | string | [0..1] | Destination details (en) Destination details (en) |
officeName | string | [0..1] | Office name Office name |
officeNameEn | string | [0..1] | Office name (en) Office name (en) |
cityName | string | [0..1] | City name City name |
cityNameEn | string | [0..1] | International city name International city name |
countryCode | string | [0..1] | Three-letter ISO Alpha-3 code of the country (e.g. AUT, BGR, etc.) Three-letter ISO Alpha-3 code of the country (e.g. AUT, BGR, etc.) |
Order information including parameters below Some html description with multiple lines
Name | Type | Multiplicity | Description |
---|---|---|---|
id | int | [0..1] | ID |
orderNumber | string | [0..1] | Order number the order number |
status | string | [0..1] | Status |
orderTime | dateTime | [0..1] | Time of order |
orderSum | double | [0..1] | |
cod | boolean | [0..1] | Amount for cash on delivery |
declaredValue | double | [0..1] | |
partialDelivery | boolean | [0..1] | Indicates if Partial Delivery is selected |
currency | string | [0..1] | Currency |
shipmentDescription | string | [0..1] | Description of the shipment |
shipmentNumber | string | [0..1] | Shipment number |
senderInfo | CustomerInfo | [0..1] | |
customerInfo | CustomerInfo | [0..1] | Customer information |
items | OrderItem | [0..n] | Products for delivery |
packCount | int | [0..1] | Pack count |
receiverShareAmount | string | [0..1] | |
paymentToken | string | [0..1] | |
paymentSide | string | [0..1] | Override payment settings (sender, receiver, default: as shop settings) Override payment settings (sender, receiver, default: as shop settings) |
Detailed information about the customer
Name | Type | Multiplicity | Description |
---|---|---|---|
id | string | [0..1] | ID |
name | string | [0..1] | Name |
face | string | [0..1] | Responsible person |
phone | string | [0..1] | Phone |
string | [0..1] | ||
countryCode | string | [0..1] | Country code |
cityName | string | [0..1] | City name |
postCode | string | [0..1] | Post code |
officeCode | string | [0..1] | Office code |
zipCode | string | [0..1] | Zip code |
address | string | [0..1] | Address |
quarter | string | [0..1] | |
street | string | [0..1] | |
num | string | [0..1] | |
other | string | [0..1] | |
priorityFrom | string | [0..1] | Earliest time for collection |
priorityTo | string | [0..1] | Latest time for collection |
Product
Name | Type | Multiplicity | Description |
---|---|---|---|
name | string | [0..1] | Product name |
variants | string | [0..1] | |
SKU | string | [0..1] | Product unique code |
URL | string | [0..1] | URL |
count | int | [0..1] | Number of products |
totalPrice | double | [0..1] | Total price |
totalWeight | double | [0..1] | Total weight |
additionalInfo | string | [0..1] | |
alternativeDepartment | string | [0..1] | Alternative department payment to be used Alternative department payment to be used |
Name | Type | Multiplicity | Description |
---|---|---|---|
destinationOfficeCode | string | [0..1] | destination office for the group shipment destination office for the group shipment |
preparedGroupShipments | int | [0..n] | prepared group shipments numbers prepared group shipments numbers |
shipmentsData | ShipmentForGroupData | [0..n] | some information about the shipments available for grouping some information about the shipments available for grouping |
Name | Type | Multiplicity | Description |
---|---|---|---|
id | int | [0..1] | |
number | int | [0..1] | shipment number shipment number |
shipmentPackCount | int | [0..1] | shipment packs amount shipment packs amount |
weight | double | [0..1] | shipment weight shipment weight |
destinationCityName | string | [0..1] | shipment destination city shipment destination city |
shipmentDescription | string | [0..1] | shipment description shipment description |
Parameters | |||
---|---|---|---|
Name | Type | Multiplicity | Description |
Order | Order information some order data |
Result | |||
---|---|---|---|
Name | Type | Multiplicity | Description |
ShipmentStatus |
Faults | |
---|---|
Type | Description |
Parameters | |||
---|---|---|---|
Name | Type | Multiplicity | Description |
Order | Update order |
Result | |||
---|---|---|---|
Name | Type | Multiplicity | Description |
Order |
Faults | |
---|---|
Type | Description |
Parameters | |||
---|---|---|---|
Name | Type | Multiplicity | Description |
Order | Create AWB |
Result | |||
---|---|---|---|
Name | Type | Multiplicity | Description |
ShipmentStatus |
Faults | |
---|---|
Type | Description |
Parameters | |||
---|---|---|---|
Name | Type | Multiplicity | Description |
Order | Get tracking info |
Result | |||
---|---|---|---|
Name | Type | Multiplicity | Description |
ShipmentStatus |
Faults | |
---|---|
Type | Description |
Parameters | |||
---|---|---|---|
Name | Type | Multiplicity | Description |
Order |
Result | |||
---|---|---|---|
Name | Type | Multiplicity | Description |
boolean |
Faults | |
---|---|
Type | Description |
Parameters | |||
---|---|---|---|
Name | Type | Multiplicity | Description |
order | Order | [0..1] | Order data or id/number |
shopName | string | [0..1] | Optional display name Optional display name |
Result | |||
---|---|---|---|
Name | Type | Multiplicity | Description |
paymentURI | string | [0..1] | URI to send the customer to URI to send the customer to |
paymentIdentifier | string | [0..1] |
Faults | |
---|---|
Type | Description |
Parameters | |||
---|---|---|---|
Name | Type | Multiplicity | Description |
paymentIdentifier | string | [0..1] |
Result | |||
---|---|---|---|
Name | Type | Multiplicity | Description |
paymentToken | string | [0..1] |
Faults | |
---|---|
Type | Description |
Get shipments available for grouping Get shipments available for grouping
Parameters | |||
---|---|---|---|
Name | Type | Multiplicity | Description |
timePeriod | string | [0..1] | when the shipments were created 'today' | 'last_2_days' | 'last_3_days' | 'last_7_days' when the shipments were created 'today' | 'last_2_days' | 'last_3_days' | 'last_7_days' |
Result | |||
---|---|---|---|
Name | Type | Multiplicity | Description |
shipments | ShipmentsForGroup | [0..n] | information about prepared group shipments and those available for grouping information about prepared group shipments and those available for grouping |
Faults | |
---|---|
Type | Description |
Put shipments into a new group or an existing one Put shipments into a new group or an existing one
Parameters | |||
---|---|---|---|
Name | Type | Multiplicity | Description |
groupShipmentNumber | int | [0..1] | existing group shipment existing group shipment |
destinationOfficeCode | string | [0..1] | destination for the new group shipment destination for the new group shipment |
shipmentNumbers | int | [0..n] | shipments to be grouped shipments to be grouped |
Result | |||
---|---|---|---|
Name | Type | Multiplicity | Description |
destinationOfficeCode | string | [0..1] | destination office for the group shipment destination office for the group shipment |
groupShipmentNumber | int | [0..1] | group shipment number group shipment number |
groupedAmount | int | [0..1] | amount of shipments in the group amount of shipments in the group |
Faults | |
---|---|
Type | Description |