Placing LTL orders
General information
This service allows ordering/pre-ordering (see below) shipping. The method is available to both authorized and unauthorized users. Authorized users can use the address book data as well as update it with the data entered when creating an order.
Below is the description of all method parameters, for the requests and the responses examples see the relevant section.
Less then truckload shipments
Method request
Request example
Method address: https://api.dellin.ru/v2/request.json
{ "appkey":"00000000-0000-0000-0000-000000000000", "sessionID":"00000000-0000-0000-0000-000000000000", "inOrder":true, "delivery":{ "deliveryType":{ "type":"avia" }, "packages":[ { "uid":"0xA0A820F33B2F93FE44C8058B65C77D0F", "payer":"sender" }, { "uid":"0x947845D9BDC69EFA49630D8C080C4FBE", "payer":"sender", "count":3 } ], "accompanyingDocuments":[ { "action":"send", "payer":"sender" }, { "action":"return", "payer":"sender" } ], "derival":{ "produceDate":"2018-02-15", "pickupParams":{ "derivalDriverPass":24, "shipmentRegister":true, "paidEntry":{ "cost":100, "type":1 }, "shipmentDerival":"АБ1000222", "priorCall":true, "noNeedAgreement":true, "documentsForReceive":[ "0x90bc42c2d8cf7c1c47a40fc1ccfb54d5", "0x9c65f346435836584a8345ade132df00" ] }, "variant":"terminal", "payer":"sender", "terminalID":"23", "addressID":457824578, "address":{ "search":"Омск, Ленина, 5", "street":"5500000100005970000000000", "house":"5", "building":"1", "structure":"лит.А", "flat":"214а", "save":true }, "additionalAddress":{ "addressID":457824578, "address":{ "search":"Омск, Ленина, 5", "street":"5500000100005970000000000", "house":"5", "building":"1", "structure":"лит.А", "flat":"214а", "save":true }, "payer":"sender" }, "time":{ "worktimeStart":"09:00", "worktimeEnd":"18:00", "breakStart":"12:30", "breakEnd":"13:30", "exactTime":true }, "handling":{ "freightLift":true, "toFloor":10, "carry":50, "payer":"third" }, "requirements":[ "0x9951e0ff97188f6b4b1b153dfde3cfec", "0xabb9c63c596b08f94c3664c930e77778" ] }, "arrival":{ "variant":"terminal", "payer":"sender", "terminalID":"23", "addressID":457824578, "address":{ "search":"59.924501, 30.241762", "street":"7800000000005550000000000", "house":"40", "building":"1", "structure":"лит.А", "flat":"214а", "save":true }, "city":"7800000000000000000000000", "time":{ "worktimeStart":"09:00", "worktimeEnd":"18:00", "breakStart":"12:30", "breakEnd":"13:30", "exactTime":true }, "handling":{ "freightLift":true, "toFloor":10, "carry":50, "payer":"third" }, "requirements":[ "0x9951e0ff97188f6b4b1b153dfde3cfec", "0xabb9c63c596b08f94c3664c930e77778" ] }, "smsback":"79213332211", "comment":"комментарий к отправке" }, "members":{ "requester":{ "role":"payer", "uid":"f969722a-cca3-49ed-85ff-b6be9e904b94", "email":"test@mail.ru" }, "sender":{ "counteragentID":456783515, "counteragent":{ "form":"0x8F51001438C4D49511DBD774581EDB80", "customForm":{ "formName":"ОБРУГ", "countryUID":"0x00000000000000000000000000000000", "juridical":true }, "document":{ "type":"passport", "serial":"0000", "number":"123456" }, "name":"Ромашка", "inn":"1234567890", "juridicalAddress":{ "search":"Омск, Ленина, 5", "street":"5500000100005970000000000", "house":"5", "building":"1", "structure":"3А", "flat":"Б-234" }, "save":true }, "contactIDs":[ 12345678, 78456123 ], "contactPersons":[ { "name":"Иван Иванович", "save":true }, { "name":"Петр Петрович", "save":false } ], "phoneIDs":[ 98765412, 65478921 ], "phoneNumbers":[ { "number":"79213332211", "ext":"0123", "save":true } ], "email":"test@mail.ru", "dataForReceipt":{ "send":true, "phone":"+79999999999", "email":"test@mail.ru" } }, "receiver":{ "counteragentID":456783515, "counteragent":{ "form":"0x8F51001438C4D49511DBD774581EDB80", "customForm":{ "formName":"ОБРУГ", "countryUID":"0x00000000000000000000000000000000", "juridical":true }, "document":{ "type":"passport", "serial":"0000", "number":"123456" }, "isAnonym":false, "phone":"79998887766", "name":"Ромашка", "inn":"1234567890", "juridicalAddress":{ "search":"Омск, Ленина, 5", "street":"5500000100005970000000000", "house":"5", "building":"1", "structure":"3А", "flat":"Б-234" }, "save":true }, "contactIDs":[ 12345678, 78456123 ], "contactPersons":[ { "name":"Иван Иванович", "save":true }, { "name":"Петр Петрович", "save":false } ], "phoneIDs":[ 98765412, 65478921 ], "phoneNumbers":[ { "number":"79213332211", "ext":"0123", "save":true } ], "email":"test@mail.ru", "dataForReceipt":{ "send":true, "phone":"+79999999999", "email":"test@mail.ru" } }, "third":{ "counteragentID":456783515, "counteragent":{ "form":"0x8F51001438C4D49511DBD774581EDB80", "customForm":{ "formName":"ОБРУГ", "countryUID":"0x00000000000000000000000000000000", "juridical":true }, "document":{ "type":"passport", "serial":"0000", "number":"123456" }, "name":"Ромашка", "inn":"1234567890", "juridicalAddress":{ "search":"Омск, Ленина, 5", "street":"5500000100005970000000000", "house":"5", "building":"1", "structure":"3А", "flat":"Б-234" }, "save":true }, "contactIDs":[ 12345678, 78456123 ], "contactPersons":[ { "name":"Иван Иванович", "save":true }, { "name":"Петр Петрович", "save":false } ], "phoneIDs":[ 98765412, 65478921 ], "phoneNumbers":[ { "number":"79213332211", "ext":"0123", "save":true } ], "email":"test@mail.ru", "dataForReceipt":{ "send":true, "phone":"+79999999999", "email":"test@mail.ru" } } }, "cargo":{ "quantity":1, "length":0.42, "width":0.18, "height":0.3, "weight":25.0, "totalVolume":0.02, "totalWeight":0.02, "oversizedWeight":25.0, "oversizedVolume":0.02, "hazardClass":2.1, "insurance":{ "statedValue":11220.50, "payer":"sender", "term":true }, "freightUID":"0x9c2acaea110d75ba48fdc7a83c976269" }, "payment":{ "type":"cash", "promocode":"promo123", "primaryPayer":"sender", "paymentCity":"5500000100000000000000000", "paymentCitySearch":{ "search":"Омск" }, "cashOnDelivery":[ { "orderNumber":"123456", "orderDate":"2018-04-09", "paymentType":"cash", "products":[ { "productName":"Кофеварка BRAUN", "productCode":"K-2300", "productAmount":"1", "costWithVAT":"17800", "VATRate":18 } ] } ] }, "cargoCode":"1234" }
Method address: https://api.dellin.ru/v2/request.xml
<request> <appkey>00000000-0000-0000-0000-000000000000</appkey> <sessionID>00000000-0000-0000-0000-000000000000</sessionID> <inOrder>true</inOrder> <delivery> <deliveryType> <type>avia</type> </deliveryType> <packages> <uid>0xA0A820F33B2F93FE44C8058B65C77D0F</uid> <payer>sender</payer> </packages> <packages> <uid>0x947845D9BDC69EFA49630D8C080C4FBE</uid> <payer>sender</payer> <count>3</count> </packages> <accompanyingDocuments> <action>send</action> <payer>sender</payer> </accompanyingDocuments> <accompanyingDocuments> <action>return</action> <payer>sender</payer> </accompanyingDocuments> <derival> <produceDate>2018-02-15</produceDate> <pickupParams> <derivalDriverPass>24</derivalDriverPass> <shipmentRegister>true</shipmentRegister> <paidEntry> <cost>100</cost> <type>1</type> </paidEntry> <shipmentDerival>АБ1000222</shipmentDerival> <priorCall>true</priorCall> <noNeedAgreement>true</noNeedAgreement> <documentsForReceive>0x90bc42c2d8cf7c1c47a40fc1ccfb54d5</documentsForReceive> <documentsForReceive>0x9c65f346435836584a8345ade132df00</documentsForReceive> </pickupParams> <variant>terminal</variant> <payer>sender</payer> <terminalID>23</terminalID> <addressID>457824578</addressID> <address> <search>Омск, Ленина, 5</search> <street>5500000100005970000000000</street> <house>5</house> <building>1</building> <structure>лит.А</structure> <flat>214а</flat> <save>true</save> </address> <additionalAddress> <addressID>457824578</addressID> <address> <search>Омск, Ленина, 5</search> <street>5500000100005970000000000</street> <house>5</house> <building>1</building> <structure>лит.А</structure> <flat>214а</flat> <save>true</save> </address> <payer>sender</payer> </additionalAddress> <time> <worktimeStart>09:00</worktimeStart> <worktimeEnd>18:00</worktimeEnd> <breakStart>12:30</breakStart> <breakEnd>13:30</breakEnd> <exactTime>true</exactTime> </time> <handling> <freightLift>true</freightLift> <toFloor>10</toFloor> <carry>50</carry> <payer>third</payer> </handling> <requirements>0x9951e0ff97188f6b4b1b153dfde3cfec</requirements> <requirements>0xabb9c63c596b08f94c3664c930e77778</requirements> </derival> <arrival> <variant>terminal</variant> <payer>sender</payer> <terminalID>23</terminalID> <addressID>457824578</addressID> <address> <search>59.924501, 30.241762</search> <street>7800000000005550000000000</street> <house>40</house> <building>1</building> <structure>лит.А</structure> <flat>214а</flat> <save>true</save> </address> <city>7800000000000000000000000</city> <time> <worktimeStart>09:00</worktimeStart> <worktimeEnd>18:00</worktimeEnd> <breakStart>12:30</breakStart> <breakEnd>13:30</breakEnd> <exactTime>true</exactTime> </time> <handling> <freightLift>true</freightLift> <toFloor>10</toFloor> <carry>50</carry> <payer>third</payer> </handling> <requirements>0x9951e0ff97188f6b4b1b153dfde3cfec</requirements> <requirements>0xabb9c63c596b08f94c3664c930e77778</requirements> </arrival> <smsback>79213332211</smsback> <comment>комментарий к отправке</comment> </delivery> <members> <requester> <role>payer</role> <uid>f969722a-cca3-49ed-85ff-b6be9e904b94</uid> <email>test@mail.ru</email> </requester> <sender> <counteragentID>456783515</counteragentID> <counteragent> <form>0x8F51001438C4D49511DBD774581EDB80</form> <customForm> <formName>ОБРУГ</formName> <countryUID>0x00000000000000000000000000000000</countryUID> <juridical>true</juridical> </customForm> <document> <type>passport</type> <serial>0000</serial> <number>123456</number> </document> <name>Ромашка</name> <inn>1234567890</inn> <juridicalAddress> <search>Омск, Ленина, 5</search> <street>5500000100005970000000000</street> <house>5</house> <building>1</building> <structure>3А</structure> <flat>Б-234</flat> </juridicalAddress> <save>true</save> </counteragent> <contactIDs>12345678</contactIDs> <contactIDs>78456123</contactIDs> <contactPersons> <name>Иван Иванович</name> <save>true</save> </contactPersons> <contactPersons> <name>Петр Петрович</name> <save>false</save> </contactPersons> <phoneIDs>98765412</phoneIDs> <phoneIDs>65478921</phoneIDs> <phoneNumbers> <number>79213332211</number> <ext>0123</ext> <save>true</save> </phoneNumbers> <email>test@mail.ru</email> <dataForReceipt> <send>true</send> <phone>+79999999999</phone> <email>test@mail.ru</email> </dataForReceipt> </sender> <receiver> <counteragentID>456783515</counteragentID> <counteragent> <form>0x8F51001438C4D49511DBD774581EDB80</form> <customForm> <formName>ОБРУГ</formName> <countryUID>0x00000000000000000000000000000000</countryUID> <juridical>true</juridical> </customForm> <document> <type>passport</type> <serial>0000</serial> <number>123456</number> </document> <isAnonym>false</isAnonym> <phone>79998887766</phone> <name>Ромашка</name> <inn>1234567890</inn> <juridicalAddress> <search>Омск, Ленина, 5</search> <street>5500000100005970000000000</street> <house>5</house> <building>1</building> <structure>3А</structure> <flat>Б-234</flat> </juridicalAddress> <save>true</save> </counteragent> <contactIDs>12345678</contactIDs> <contactIDs>78456123</contactIDs> <contactPersons> <name>Иван Иванович</name> <save>true</save> </contactPersons> <contactPersons> <name>Петр Петрович</name> <save>false</save> </contactPersons> <phoneIDs>98765412</phoneIDs> <phoneIDs>65478921</phoneIDs> <phoneNumbers> <number>79213332211</number> <ext>0123</ext> <save>true</save> </phoneNumbers> <email>test@mail.ru</email> <dataForReceipt> <send>true</send> <phone>+79999999999</phone> <email>test@mail.ru</email> </dataForReceipt> </receiver> <third> <counteragentID>456783515</counteragentID> <counteragent> <form>0x8F51001438C4D49511DBD774581EDB80</form> <customForm> <formName>ОБРУГ</formName> <countryUID>0x00000000000000000000000000000000</countryUID> <juridical>true</juridical> </customForm> <document> <type>passport</type> <serial>0000</serial> <number>123456</number> </document> <name>Ромашка</name> <inn>1234567890</inn> <juridicalAddress> <search>Омск, Ленина, 5</search> <street>5500000100005970000000000</street> <house>5</house> <building>1</building> <structure>3А</structure> <flat>Б-234</flat> </juridicalAddress> <save>true</save> </counteragent> <contactIDs>12345678</contactIDs> <contactIDs>78456123</contactIDs> <contactPersons> <name>Иван Иванович</name> <save>true</save> </contactPersons> <contactPersons> <name>Петр Петрович</name> <save>false</save> </contactPersons> <phoneIDs>98765412</phoneIDs> <phoneIDs>65478921</phoneIDs> <phoneNumbers> <number>79213332211</number> <ext>0123</ext> <save>true</save> </phoneNumbers> <email>test@mail.ru</email> <dataForReceipt> <send>true</send> <phone>+79999999999</phone> <email>test@mail.ru</email> </dataForReceipt> </third> </members> <cargo> <quantity>1</quantity> <length>0.42</length> <width>0.18</width> <height>0.3</height> <weight>25</weight> <totalVolume>0.02</totalVolume> <totalWeight>0.02</totalWeight> <oversizedWeight>25</oversizedWeight> <oversizedVolume>0.02</oversizedVolume> <hazardClass>2.1</hazardClass> <insurance> <statedValue>11220.5</statedValue> <payer>sender</payer> <term>true</term> </insurance> <freightUID>0x9c2acaea110d75ba48fdc7a83c976269</freightUID> </cargo> <payment> <type>cash</type> <promocode>promo123</promocode> <primaryPayer>sender</primaryPayer> <paymentCity>5500000100000000000000000</paymentCity> <paymentCitySearch> <search>Омск</search> </paymentCitySearch> <cashOnDelivery> <orderNumber>123456</orderNumber> <orderDate>2018-04-09</orderDate> <paymentType>cash</paymentType> <products> <productName>Кофеварка BRAUN</productName> <productCode>K-2300</productCode> <productAmount>1</productAmount> <costWithVAT>17800</costWithVAT> <VATRate>18</VATRate> </products> </cashOnDelivery> </payment> <cargoCode>1234</cargoCode> </request>
Description of parameters
Request
Request | |||
---|---|---|---|
Parameter | Required | Type | Description |
appkey | Yes | string | The application key. To get the key, register |
sessionID | No | string | To get the session ID, use the "User Authorization" method |
inOrder | No | boolean | If the value is "false", then the order is saved, but is not processed (is necessary in case the order will be included into a multi-request). Default value: "true". If user is not authorized, then the parameter is ignored |
delivery | Yes | object | Delivery parameters |
delivery.deliveryType | Yes | DeliveryType | Delivery type for terminal-to-terminal shipping |
delivery.packages | No | array of Packages | List of required packages |
delivery.accompanyingDocuments | No | array of AcDocs | Accompanying documents |
delivery.derival | Yes | DerivalArrival | Delivery from the address |
delivery.arrival | Yes | DerivalArrival | Delivery to the address |
delivery.smsback | No | string | Phone number for SMS-notifications. Format: "7XXXXXXXXXX" (11 figures, starts with 7) |
delivery.comment | No | string | Comment to the order. Maximum field length: 500 characters When processing a request, some special characters from the comment text are replaced with their html counterparts (for example, the character " is replaced by """). As a result, it is possible to exceed the 500 character limit and get error #130009 (see "Errors of API methods") |
members | Yes | object | Shipping members |
members.requester | Yes | Requester | Order requester |
members.sender | Yes | Member | Sender |
members.receiver | Yes | Member | Receiver |
members.third | No | Member | Third party |
cargo | Yes | Cargo | Cargo characteristics |
payment | Yes | Payment | Payment parameters |
cargoCode | No | string | Client waybill number. Maximum string length - 100 characters Client waybill number is used for batch orders |
DeliveryType
DeliveryType | |||
---|---|---|---|
Parameter | Required | Type | Description |
type | Yes | string | Delivery type. Available values:
Small size cargo is the cargo with parameters that do not exceed the following values:
|
Packages
Packages | |||
---|---|---|---|
Parameter | Required | Type | Description |
uid | Yes | string | Package UID from "Directory of Additional Services" |
payer | No | string | Payer for the service. Available values:
If parameter is not passed, then it takes the value of the parameter "request.payment.primaryPayer" |
count | No* | integer | Number of bags or boxes. *Parameter is required if one of the next types of package is selected: "bag" ("Упаковка мешок"), "carton box" ("Картонная коробка"), "special package for car glasses" ("Спец. упаковка для автостекол"), "special package for car spare parts" ("Спец. упаковка для автозапчастей") |
AcDocs
AcDocs | |||
---|---|---|---|
Parameter | Required | Type | Description |
action | Yes | string | Action over accompanying documents. Available values:
The accompanying documents return is not available if the receiver is "anonymous" that is if "members.receiver.counteragent.isAnonym" parameter value is "true". "Anonymous" receiver is a receiver on whom minimum information is provided (only name and phone number is provided |
payer | No* | string | Payer for the service. Available values:
*If parameter is not passed, then it takes the value of the parameter "request.payment.primaryPayer" |
DerivalArrival
DerivalArrival | |||
---|---|---|---|
Parameter | Required | Type | Description |
produceDate | Yes | string | Date of cargo transfer to the terminal of departure or date of truck arrival to the sender. Format: YYYY-MM-DD To get the list of dates for which the pickup can be scheduled use "Dispatch dates" service. Passing the current date as the parameter value, consider that pickup on the day of ordering is possible only if the order is placed on a weekday before 16:00 local time and if in the settlement there is a Delovye Linii company terminal which works two or more hours from the moment of placing an order, and the dimensions of the cargo do not exceed:
Only for "request.delivery.derival" object |
pickupParams | No | PickupParams | Additional parameters of cargo delivery from the address Only for "request.delivery.derival" object |
variant | Yes | string | Shipping method. Available values:
For "request.delivery.derival" only: If delivery from the address is ordered, then the order is placed, if delivery from the terminal - then pre-order |
payer | No | string | Payer for the service. Available values:
If parameter is not passed, then it takes the value of the parameter "request.payment.primaryPayer" |
terminalID | No* | string | Terminal ID from the "Terminals" directory. In case of express delivery ("delivery.deliverуType.type" request parameter value is "express") the terminal should accept/give out express cargoes: in "Terminals directory" the selected terminal should have "Worktables.Worktable.department" parameter with "Приём груза к экспресс-перевозке" value (in case of "request.delivery.derival" object)/"Выдача грузов экспресс-перевозки" (in case of "request.delivery.arrival" object). *One of the excluding parameters is required: "terminalID", "addressID", "address", "city" |
addressID | No* | integer | Address ID from the "Address book". If user is not authorized, then the parameter is ignored. *One of the excluding parameters is required: "terminalID", "addressID", "address", "city" |
address | No* | Address | Address. *One of the excluding parameters is required: "terminalID", "addressID", "address", "city" |
city | No* | string | CLADR code of the city. It's possible to get CLADR code using the services presented on the page "CLADR search". The parameter is not allowed if "variant" parameter value is "address". If the parameter is passed the arrival terminal is determined automatically *One of the excluding parameters is required: "terminalID", "addressID", "address", "city" Only for "request.delivery.arrival" object |
additionalAddress | No | object | Picking up the cargo at an additional address Only for "request.delivery.derival" object |
additionalAddress.addressID | No | integer | Address ID from the "Address book". If user is not authorized, then the parameter is ignored. Only one of the following parameters is allowed: "addressID" or "address" |
additionalAddress.address | No | Address | Address as a set of parameters. Only one of the following parameters is allowed: "addressID" or"address" |
additionalAddress.payer | No | string | Payer for the service. Available values:
If parameter is not passed, then it takes the value of the parameter "request.payment.primaryPayer" |
time | No* | object | Time of cargo hand over at the address. *If "variant" parameter value is "address", then parameter is required |
time.worktimeStart | Yes | string | Period start. Format: HH:MM |
time.worktimeEnd | Yes | string | Period end. Format: HH:MM |
time.breakStart | No | string | Break start. Format: HH:MM |
time.breakEnd | No | string | Break end. Format: HH:MM |
time.exactTime | No | boolean | Delivery at the exact time. Default value: "false" |
handling | No | object | Loading and unloading works at the address |
handling.freightLift | No | boolean | Flag indicating that there is a service lift. Default value: "false" |
handling.toFloor | No | integer | Number of the floor to which the cargo is to be lifted/from which the cargo is to be carried downstairs. Maximum number of characters - 5 |
handling.carry | No | integer | Distance to which the cargo is to be carried, m. Maximum number of characters - 5 |
handling.payer | No | string | Payer for the service. Available values:
If parameter is not passed, then it takes the value of the parameter "request.payment.primaryPayer" |
requirements | No | array of strings | Array of UID's of special requirements for transport from the "Directory of special transport requirements" and from the "Directory of vehicle loading types". Special requirements include type of truck loading (side, rear, etc.) and other requirements: manipulator, tenting removal, etc. |
PickupParams
PickupParams | |||
---|---|---|---|
Parameter | Required | Type | Description |
derivalDriverPass | No | integer | Parameter determining the need to order a pass by the driver of DL to enter the territory of the sender and time that it takes. Available values:
|
shipmentRegister | No | boolean | Parameter determining the need to make an appointment by the driver of DL to pick-up the cargo at the sender's address. Default value: "false" |
paidEntry | No | object | Parameter determining the need to pay the entry fee by the driver of DL when entering the territory of the sender to pick-up the cargo |
paidEntry.cost | No | float | Amount, rub. |
paidEntry.type | No | integer | Reimbursement method. Available values:
|
shipmentDerival | No | string | Parameter determining the need to provide the pick-up number by the driver of DL in order to pick-up the cargo at the sender's territory. Parameter should contain the pick-up number. Maximum number of characters - 30 |
priorCall | No | boolean | Parameter determining the need of advance call from the driver of DL to the sender before the picking-up of the cargo. Default value: "false" |
noNeedAgreement | No | boolean | Parameter determining the need to agree the order for shipment with the sender. Available values:
|
documentsForReceive | No | array of strings | List of the documents that the driver of DL has to have in order to pick-up the cargo at the sender's territory. Should be specified using the "Documents for receipt of cargo" directory |
Address
Address | |||
---|---|---|---|
Parameter | Required | Type | Description |
search | No (1) | string | Address as a string. It is possible to pass address as text or as coordintaes. The coordinates should not be used to pass the information about the juridical address, that is in blocks "juridicalAddress" of class "Counteragent". When passing address as a text along with the address it is necessary to pass the name of the city, the address elements should be separated by comma, for example "Омск, Ленина, 5". The coordinates should be separated by comma as well, the first number - latitude "59.924501, 30.241762". Minimum 2 symbols, maximum 1024 (2) |
street | No (1) | string | CLADR code of the street. It's possible to get CLADR code using the services presented on the page "CLADR search" (2) |
house | No (1) | string | House (2). Maximum number of characters - 7 |
building | No | string | Building (2). Maximum number of characters - 5 |
structure | No | string | Structure (2). Maximum number of characters - 7 |
flat | No | string | Apartment/office (2). Maximum number of characters - 5 |
save | No | boolean | Indicator of saving the object in the address book. Default value: "false". Parameter is not used in blocks "juridicalAddress" of class "Counteragent". If user is not authorized, then the parameter is ignored |
Notes:
|
Requester
Requester | |||
---|---|---|---|
Parameter | Required | Type | Description |
role | Yes | string | Role in shipping. Available values:
|
uid | No* | string | Counterparty UID from the "List of available counterparties". *Parameter is not required and ignored if the user is not authorized and in case of absence of the full access to the counterparties |
No | string | Email of the order requester |
Member
Member | |||
---|---|---|---|
Parameter | Required | Type | Description |
counteragentID | No* | integer | Counterparty ID from the "Address book". *If the user is unauthorized, then parameter is ignored. For authorized users one of the excluding parameters is required: "counteragentID" or "counteragent" |
counteragent | No* | Counteragent | Counterparty as a set of parameters. *The parameter is required for unauthorized users. For authorized users one of the excluding parameters is required: "counteragentID" or "counteragent" |
contactIDs | No* | array of integers | List of ID's of contact persons from the "Address book". Maximum 3 elements in the array. *The parameter is ignored for counterparty that is an "anonymous" receiver (1). It is as well ignored if the user is unauthorized. For authorized users in case the counterparty is not an an "anonymous" receiver one of the excluding parameters is required: "contactID" or "contactPersons" |
contactPersons | No* | array of ContactPersons | List of contact persons. Maximum 3 elements in the array for authorized users, 1 - for unauthorized. *The parameter is ignored for counterparty that is an "anonymous" receiver (1). For unauthorized users it is required. For authorized users in case the counterparty is not an an "anonymous" receiver one of the excluding parameters is required: "contactID" or "contactPersons" |
contactPersons.name | Yes | string | Name of contact person |
contactPersons.save | No | boolean | Indicator of saving the object in the address book. Default value: "false". Parameter is ignored for the third party. The parameter is ignored for unauthorized users |
phoneIDs | No* | array of integers | List of ID's of phone numbers from the "Address book". Maximum 3 elements in the array. *The parameter is ignored for counterparty that is an "anonymous" receiver (1). It is as well ignored if the user is unauthorized. For authorized users in case the counterparty is not an an "anonymous" receiver one of the excluding parameters is required: "phoneIDs" or "phoneNumbers" |
phoneNumbers | No* | array of PhoneNumbers | List of phone numbers. Maximum 3 elements in the array for authorized users, 1 - for unauthorized. *The parameter is ignored for counterparty that is an "anonymous" receiver (1). For unauthorized users it is required. For authorized users in case the counterparty is not an an "anonymous" receiver one of the excluding parameters is required: "phoneIDs" or "phoneNumbers" |
phoneNumbers.number | Yes | string | Phone number. Only digits and plus sign are allowed (plus can only be passed at the beginning of the string that starts with 7 or 375) |
phoneNumbers.ext | No | string | Extension. Maximum 5 digits |
phoneNumbers.save | No | boolean | Indicator of saving the object in the address book. Default value: "false". Parameter is ignored for the third party. The parameter is ignored for unauthorized users |
No | string | Email for sending notifications to the participants of transportation (sender, receiver or third party) | |
dataForReceipt | No* | object | Contact information for sending an electronic payment receipt to the payer that is a physical party *Parameter is required for the counterparty, that is a physical party and is not an "anonymous" receiver. Otherwise, parameter is not required and ignored (1) |
dataForReceipt.send | Yes | boolean | Consent to receive an electronic payment receipt. Available values:
|
dataForReceipt.phone | No* | string | Phone number to send payment receipt. Format: "+79XXXXXXXXX" (12 figures, starts with "+79" and then 9 digits) *If "send" = "true", then at least one of the parameters is required: "phone" or "email" *If "send" = "false", then parameter is ignored |
dataForReceipt.email | No* | string | Email to send payment receipt *If "send" = "true", then at least one of the parameters is required: "phone" or "email" *If "send" = "false", then parameter is ignored |
Notes:
|
Counteragent
Counteragent | |||
---|---|---|---|
Parameter | Required | Type | Description |
form | No* | string | UID of legal form of organization. Use "Search of forms of organization" or "Counterparties search" method to find the form UID. "Counterparties search" method is available for unathorised users and allows to searcha among USRLE (1) and USRIE (2) data. When passing data about the "anonymous" (1) receiver ("isAnonym" parameter value is "true") it is necessary to pass UID of individual in Russian Federation ("0xAB91FEEA04F6D4AD48DF42161B6C2E7A"). *One of the parameters: "form" or "customForm" is required. "customForm" parameter should be used only if it is not possible to find "form" parameter in the directory |
customForm | No* | object | Legal form of organization as a set of parameters. *One of the parameters: "form" or "customForm" is required. "customForm" parameter should be used only if it is not possible to find "form" parameter in the directory |
customForm.formName | Yes | string | Name of legal form of organization. Maximum number of characters - 35 |
customForm.countryUID | Yes | string | Country UID, see "Countries search" |
customForm.juridical | Yes | boolean | Indicator of juridical party |
document | No* | object | Personal identification document *Parameter is required only if both of parameters "customForm.juridical" and "isAnonym" are passed with the value "false" |
document.type | Yes | string | Document type. Available values:
The value "foreignPassport" is unavailable for some countries |
document.serial | Yes* | string | Serial of the document. *Parameter is not required and ignored for some countries |
document.number | Yes | string | Document number. Format depends on the country |
isAnonym | No | boolean | Flag indicating that counterparty is an "anonymous" receiver, that is minimal information about the receiver is provided, this service is called simplified shipment (3). It's possible to pass this parameter with value "true" only for the receiver. Default value: "false" |
phone | No* | string | Phone number of counterparty that is an "anonymous" receiver (3). Format: "7ХХХХХХХХХХ" (11 digits, starts with "7"). *Parameter is required only for counterparty that is an "anonymous" receiver |
name | Yes | string | Name of counterparty |
inn | No* | string | Counterparty TIN (taxpayer identification number). Maximum number of characters depends on the country and legal form of organization *Parameter is required only for juridical party (parameter "form" has value that is an UID of legal form or organization of juridical party or "customForm.juridical" = "true") |
juridicalAddress | No | Address | Juridical address. Parameter is used only for juridical party (parameter "form" has value that is an UID of legal form or organization of juridical party or "customForm.juridical" = "true") |
save | No | boolean | Indicator of saving the object in the address book. Default value: "false". The parameter is ignored for unauthorized users |
Notes:
|
Cargo
Cargo | |||
---|---|---|---|
Parameter | Required | Type | Description |
quantity | No | integer | Quantity of cargo pieces, pcs. Default value: "1". If delivery type is "letter" ("request.delivery.deliveryType.type" = "letter"), then the passed value is ignored, parameter takes the default value ("1") |
length | Yes* | float | Length of the longest cargo piece, m. *If delivery type is "letter" ("request.delivery.deliveryType.type" = "letter"), then this parameter is not required, passed value is ignored, parameter takes the value "0.3" |
width | Yes* | float | Width of the widest cargo piece, m. *If delivery type is "letter" ("request.delivery.deliveryType.type" = "letter"), then this parameter is not required, passed value is ignored, parameter takes the value "0.21" |
height | Yes* | float | Height of the highest cargo piece, m. *If delivery type is "letter" ("request.delivery.deliveryType.type" = "letter"), then this parameter is not required, passed value is ignored, parameter takes the value "0.01" |
weight | No* | float | Weight of the heaviest cargo piece, kg. *If quantity of cargo pieces > 1 ("request.cargo.quantity" > 1), then this parameter is required. Otherwise, this parameter takes the value of the parameter "totalWeight". *If delivery type is "letter" ("request.delivery.deliveryType.type" = "letter"), then this parameter is not required, passed value is ignored, parameter takes the value "0.5" |
totalVolume | Yes* | float | Total cargo volume, cub. m. *If delivery type is "letter" ("request.delivery.deliveryType.type" = "letter"), then this parameter is not required, passed value is ignored, parameter takes the value "0.001" |
totalWeight | Yes* | float | Total cargo weight, kg. *If delivery type is "letter" ("request.delivery.deliveryType.type" = "letter"), then this parameter is not required, passed value is ignored, parameter takes the value "0.5" |
oversizedWeight | No* | float | Weight of oversized cargo places, kg (1). *If delivery type is "letter" ("request.delivery.deliveryType.type" = "letter"), then this parameter is ignored. *If according to the weight-dimensional characteristics it is determined that the cargo is oversized, then this parameter is required |
oversizedVolume | No* | float | Volume of oversized cargo places, cub. m (1). *If delivery type is "letter" ("request.delivery.deliveryType.type" = "letter"), then this parameter is ignored. *If according to the weight-dimensional characteristics it is determined that the cargo is oversized, then this parameter is required |
hazardClass | No | float | Hazard class of cargo. Default value: "0" |
insurance | No | object | Information about cargo insurance |
insurance.statedValue | No | float | Declared value of the cargo, rub. Maximum number of characters - 12 |
insurance.payer | No | string | Payer for the service. Available values:
If parameter is not passed, then it takes the value of the parameter "request.payment.primaryPayer" |
insurance.term | No | boolean | Flag of insurance of delivery time. Default value: "true" |
freightUID | Yes | string | UID of nature of cargo from the "Nature of cargo" directory. To search for UID by the name of cargo use the "Nature of cargo: search by the string (groupage cargo transportation)" method. If "request.delivery.deliveryType.type" parameter values is "letter", then the passed value is ignored, the nature of cargo is considered to be documents |
Notes: 1. An oversized cargo place is:
2. A rigid packaging is ordered if the identifier of one of the following package types is passed in the request.delivery.packages.uid parameter (see "Directory of additional services"):
|
Payment
Payment | |||
---|---|---|---|
Parameter | Required | Type | Description |
type | Yes | string | Payment type (1). Available values:
|
promocode | No | string | Promo code |
primaryPayer | Yes | string | Default payer. Specified party pays for the main service (terminal-to-terminal shipping) and all other services, unless other payers are specified for them. Available values:
|
paymentCity | No* | string | CLADR code of the city of payment (1). It's possible to get CLADR code using the services presented on the page "Using CLADR codes" (CLADR - Classifier of Addresses of Russian Federation). *If one of the payers is the third party then one of the excluding parameters - "paymentCity" or "paymentCitySearch" is required, in other cases the parameter is ignored |
paymentCitySearch | No* | object | City of payment as a string (1). *If one of the payers is the third party then one of the excluding parameters - "paymentCity" or "paymentCitySearch" is required, in other cases the parameter is ignored |
paymentCitySearch.search | Yes | string | City as a string. Maximum 1024 symbols. Along with the name of the city it is possible to pass the name of the country, region or district - this will allow refining the search and eliminating errors that may occur since the cities can have the identical names |
cashOnDelivery | No | array of CashOnDelivery | Cash on delivery. Cash on delivery is only possible if the following requirements are met:
In case of cash on delivery it is not possible to order the delivery to the airport / to the receiver's address from the airport . It's possible to pass only one item of array currently. Other passed elements are ignored. The parameter is ignored for unauthorized users |
cashOnDelivery.orderNumber | No | string | Client internal order number (for example Client online order number). The parameter may be used for passing the internal order number not only in case of cash on delivery. In this case it is not necessary to meet the requirements listed in the description of "cashOnDelivery" parameter, see example 2 on Example request: Order page |
cashOnDelivery.orderDate | No | date | Order date. Format: "YYYY-MM-DD" |
cashOnDelivery.paymentType | No | string | Payment type. Available values:
|
cashOnDelivery.products | No | array of Products | List of products |
Notes:
|
Products
Products | |||
---|---|---|---|
Parameter | Required | Type | Description |
productName | Yes | string | Product name |
productCode | No | string | Product code |
productAmount | Yes | integer | Quantity |
costWithVAT | Yes | float | Cost with VAT, rub. |
VATRate | No | integer | VAT rate, %. Available values:
If the goods are not subject to VAT, then you should not transfer a zero value, but simply do not pass the parameter |
Notes:
|
Method response
Response example
{ "metadata":{ "status":200, "generated_at":"2015-06-18 12:37:28" }, "data":{ "state":"success", "requestID":3954004, "information":[ "Промокод нельзя применить в заказе" ], "barcode":"41508460D0905400400000014", "addressBook":{ "sender":{ "counteragent":{ "id":2132424, "state":"existed" }, "address":{ "id":89985444, "state":"new" }, "contactPersons":[ { "id":78436784, "state":"existed", "value":"Иван Иванович" }, { "id":3778489, "state":"new", "value":"Петр Петрович" } ], "phoneNumbers":[ { "id":6543687564, "state":"existed", "value":"795545785587" }, { "id":4574583767, "state":"new", "value":"0127588848887588" } ] } }, "foundAddresses": [ { "field": "delivery.derival.address", "source": "Омск, Ленина, 5", "result": "Россия, Омская обл, г Омск, ул Ленина, д 5" }, { "field": "delivery.derival.additionalAddress.address", "source": "Омск, Ленина, 5", "result": "Россия, Омская обл, г Омск, ул Ленина, д 5" }, { "field": "delivery.arrival.address", "source": "199106, Россия, Санкт-Петербург, Санкт-Петербург, Кожевенная линия, дом 40", "result": "199106, Россия, г Санкт-Петербург, линия Кожевенная, дом 40" }, { "field": "members.sender.counteragent.juridicalAddress", "source": "Омск, Ленина, 5", "result": "Россия, Омская обл, г Омск, ул Ленина, д 5" }, { "field": "members.receiver.counteragent.juridicalAddress", "source": "Омск, Ленина, 5", "result": "Россия, Омская обл, г Омск, ул Ленина, д 5" }, { "field": "members.third.counteragent.juridicalAddress", "source": "Омск, Ленина, 5", "result": "Россия, Омская обл, г Омск, ул Ленина, д 5" }, { "field": "payment.paymentCitySearch", "source": "Омск", "result": "Россия, Омская обл, г Омск" } ] } }
<response> <metadata> <status>200</status> <generated_at>2015-06-18 12:37:28</generated_at> </metadata> <data> <state>success</state> <requestID>3954004</requestID> <information>Промокод нельзя применить в заказе</information> <barcode>41508460D0905400400000014</barcode> <addressBook> <sender> <counteragent> <id>2132424</id> <state>existed</state> </counteragent> <address> <id>89985444</id> <state>new</state> </address> <contactPersons> <id>78436784</id> <state>existed</state> <value>Иван Иванович</value> </contactPersons> <contactPersons> <id>3778489</id> <state>new</state> <value>Петр Петрович</value> </contactPersons> <phoneNumbers> <id>6543687564</id> <state>existed</state> <value>795545785587</value> </phoneNumbers> <phoneNumbers> <id>4574583767</id> <state>new</state> <value>0127588848887588</value> </phoneNumbers> </sender> </addressBook> <foundAddresses> <field>delivery.derival.address</field> <source>Омск, Ленина, 5</source> <result>Россия, Омская обл, г Омск, ул Ленина, д 5</result> </foundAddresses> <foundAddresses> <field>delivery.derival.additionalAddress.address</field> <source>Омск, Ленина, 5</source> <result>Россия, Омская обл, г Омск, ул Ленина, д 5</result> </foundAddresses> <foundAddresses> <field>delivery.arrival.address</field> <source>199106, Россия, Санкт-Петербург, Санкт-Петербург, Кожевенная линия, дом 40</source> <result>199106, Россия, г Санкт-Петербург, линия Кожевенная, дом 40</result> </foundAddresses> <foundAddresses> <field>members.sender.counteragent.juridicalAddress</field> <source>Омск, Ленина, 5</source> <result>Россия, Омская обл, г Омск, ул Ленина, д 5</result> </foundAddresses> <foundAddresses> <field>members.receiver.counteragent.juridicalAddress</field> <source>Омск, Ленина, 5</source> <result>Россия, Омская обл, г Омск, ул Ленина, д 5</result> </foundAddresses> <foundAddresses> <field>members.third.counteragent.juridicalAddress</field> <source>Омск, Ленина, 5</source> <result>Россия, Омская обл, г Омск, ул Ленина, д 5</result> </foundAddresses> <foundAddresses> <field>payment.paymentCitySearch</field> <source>Омск</source> <result>Россия, Омская обл, г Омск</result> </foundAddresses> </data> </response>
Description of parameters
Response
Response | ||
---|---|---|
Parameter | Type | Description |
metadata | object | System information about the order |
metadata.status | integer | Emulated http-code of status. In case of success the code "200" returns |
metadata.generated_at | string | Date and time of the server response generation. Format: "YYYY-MM-DD HH:MM:SS" |
data | object | Information about the order |
data.state | string | Request processing status |
data.requestID | integer | Number of created order or pre-order |
data.information | array of strings | Info message stating that it is impossible to apply the passed promo code for some reason. Possible values:
|
data.barcode | string | Barcode according to algorithm Code 128 (for pre-order, that is in case "delivery.derival.variant" request parameter value is "terminal") |
data.addressBook | AddressBook | Information about saving data in the address book. The parameter is ignored for unauthorized users |
data.foundAddresses | array of FoundAddresses | Data on found addresses/cities. The parameter is present in the response if "search" parameter of the "Address" class or "paymentCitySearch.search" parameter was passed in the request |
AddressBook
AddressBook | ||
---|---|---|
Parameter | Type | Description |
sender | Member | Sender |
receiver | Member | Receiver |
third | Member | Third party |
Member
Member | ||
---|---|---|
Parameter | Type | Description |
counteragent | BookItem | Information about counteragent |
address | BookItem | Information about address |
contactPersons | array of BookItem | List of contact persons |
phoneNumbers | array of BookItem | List of phone numbers |
BookItem
BookItem | ||
---|---|---|
Parameter | Type | Description |
id | integer | ID of the new/updated object of address book |
state | string | Object status. Possible values:
|
value | string | Phone number (in case of "phoneNumbers" object)/contact person name (in case of "contactPersons" object) The parameter is not used for "counteragent" and "address" objects |
FoundAddresses
FoundAddresses | ||
---|---|---|
Parameter | Type | Description |
field | string | The parent object that was used to pass the "search" parameter |
source | string | Entered value |
result | string | Address/city found |
Error handling
Except for common API errors the method response may contain the following errors:
Error number | http-code | Error title | Error description | ||
---|---|---|---|---|---|
Title | Translation | Description | Translation | ||
609013 | 400 | Ошибка параметров оплаты | Payment parameters error | Детальное описание ошибки см. в поле "detail" ответа | Detailed error description see in the field "detail" of the response |
609014 | 400 | Ошибка наложенного платежа | Cash on delivery error | Детальное описание ошибки см. в поле "detail" ответа | Detailed error description see in the field "detail" of the response |
609016 | 400 | Ошибка при сохранении заявки | Saving order error | Невозможно сохранить заявку | Unable to save order |