Поиск по сайту

API
Главная / API - Cancelling delivery

Cancelling delivery

Обновлено 06.02.2023
151 кб

General information 

The service allows cancelling the delivery from the sender'/to the receiver's address. In case of cancelling the delivery from the sender's address the client will have to place a new order for the delivery from the terminal (see "Placing LTL orders" method). In case of cancelling the delivery to the sender's address the receiver will have to pick up the cargo from Delovye Linii company terminal. It is not possible to cancel the pickup/delivery after 17:00 (local time) on the day preceding the day of pickup/delivery.

To check the possibility of cancelling the delivery from/to the address, use "Checking possibility to change the order" method.

The changes do not come into effect immediately. After further verification the request can be approved or declined. To check the change request status use "Change history" method. 

Cancelling delivery from the sender's address

Method request

Request structure

Method address: https://api.dellin.ru/v3/orders/cancel_pickup.json 

{
   "appkey":"00000000-0000-0000-0000-000000000000",
   "sessionID":"00000000-0000-0000-0000-000000000000",
   "orderID":"00000000",
   "contactIDs":[
      12345678,
      78456123
   ],
   "contactPersons":[
      {
         "name":"Иван Иванович"
      },
      {
         "name":"Петр Петрович"
      }
   ],
   "phoneIDs":[
      98765412,
      65478921
   ],
   "phoneNumbers":[
      {
         "number":"79213332211",
         "ext":"0123"
      }
   ]
}

Method address: https://api.dellin.ru/v3/orders/cancel_pickup.xml

<request>
   <appkey>00000000-0000-0000-0000-000000000000</appkey>
   <sessionID>00000000-0000-0000-0000-000000000000</sessionID>
   <orderID>00000000</orderID>
   <contactIDs>12345678</contactIDs>
   <contactIDs>78456123</contactIDs>
   <contactPersons>
      <name>Иван Иванович</name>
   </contactPersons>
   <contactPersons>
      <name>Петр Петрович</name>
   </contactPersons>
   <phoneIDs>98765412</phoneIDs>
   <phoneIDs>65478921</phoneIDs>
   <phoneNumbers>
      <number>79213332211</number>
      <ext>0123</ext>
   </phoneNumbers>
</request>

Description of parameters

Request
Request
ParameterRequiredTypeDescription

appkey

YesstringApplication key. To get the key, register
sessionIDYesstringSession ID. To get the session ID, use "User authorization" service

orderID

YesstringThe number of the order for which it is necessary to cancel the delivery from the sender's address

contactIDs

No*array of integers

Contact persons IDs from "Address book".

Maximum 3 elements in the array.

*One of the two excluding parameters - "contactIDs" or"contactPersons" - is required

contactPersons

No*array of contactPersons

Contact persons data.

Maximum 3 elements in the array.

*One of the two excluding parameters - "contactIDs" or"contactPersons" - is required

contactPersons.name

YesstringContact person name

phoneIDs

No*array of integers

Phone number IDs from "Address book".

Maximum 3 elements in the array

*One of the two excluding parameters - "phoneIDs" or"phoneNumbers" - is required

phoneNumbers

No*array of phoneNumbers

Phone numbers list.

Maximum 3 elements in the array

*One of the two excluding parameters - "phoneIDs" or"phoneNumbers" - is required

phoneNumbers.number

YesstringPhone number. 15 characters maximum (the only valid non-digit sign is the plus sign at the beginning of the string)

phoneNumbers.ext

NostringExtension phone number. 5 digits maximum

Method response

Response structure

{
   "metadata":{
      "status":200,
      "generated_at":"2019-11-18 12:52:26"
   },
   "data":{
      "status":"success",
      "info": "Запрос принят. По результату его обработки, заказу будет присвоен статус Отклонен."
   }
}
<response>
   <metadata>
      <status>200</status>
      <generated_at>2019-11-18 12:52:26</generated_at>
   </metadata>
   <data>
      <status>success</status>
      <info>Запрос принят. По результату его обработки, заказу будет присвоен статус Отклонен.</info>
   </data>
</response>

Description of parameters

Response
Response
ParameterTypeDescription
metadataobjectSystem information
metadata.statusinteger

Emulated status http-code. If successful, code 200 is returned. In case of error - 400

metadata.generated_atstring

Server response date and time.

Format: YYYY-MM-DD HH:MM:SS

dataobjectSuccess confirmation
data.statusstring

Status in English. Possible value - "success"

"Success" status indicates that the request was accepted. After further verification the request can be approved or declined. To check the change request status use "Change history" method 
data.infostringAdditional information

Error handling

Except for common API errors the method response may contain the following errors:

Error numberhttp-codeError titleError description
TitleTranslationDescriptionTranslation

620001

400По данному заказу отмена доставки груза от адреса недоступнаThe delivery from the address for the order can not be cancelled--

620002

400По данному заказу отмена доставки груза от адреса недоступнаThe delivery from the address for the order can not be cancelledИзменение по данному заказу недоступно в связи с отсутствием доступаIt is not possible to change the order details since there is no access

Cancelling delivery to the receiver's address

Method request

Request structure

Method address: https://api.dellin.ru/v3/orders/cancel_delivery.json 

{
   "appkey":"00000000-0000-0000-0000-000000000000",
   "sessionID":"00000000-0000-0000-0000-000000000000",
   "orderID":"00000000",
   "requester":"customer",
   "contactIDs":[
      12345678,
      78456123
   ],
   "contactPersons":[
      {
         "name":"Иван Иванович"
      },
      {
         "name":"Петр Петрович"
      }
   ],
   "phoneIDs":[
      98765412,
      65478921
   ],
   "phoneNumbers":[
      {
         "number":"79213332211",
         "ext":"0123"
      }
   ]
}

Method address: https://api.dellin.ru/v3/orders/cancel_delivery.xml

<request>
   <appkey>00000000-0000-0000-0000-000000000000</appkey>
   <sessionID>00000000-0000-0000-0000-000000000000</sessionID>
   <orderID>00000000</orderID>
   <requester>customer</requester>
   <contactIDs>12345678</contactIDs>
   <contactIDs>78456123</contactIDs>
   <contactPersons>
      <name>Иван Иванович</name>
   </contactPersons>
   <contactPersons>
      <name>Петр Петрович</name>
   </contactPersons>
   <phoneIDs>98765412</phoneIDs>
   <phoneIDs>65478921</phoneIDs>
   <phoneNumbers>
      <number>79213332211</number>
      <ext>0123</ext>
   </phoneNumbers>
</request>

Description of parameters

Request
Request
ParameterRequiredTypeDescription

appkey

YesstringApplication key. To get the key, register
sessionIDYesstringSession ID. To get the session ID, use "User authorization" service

orderID

YesstringThe number of the order for which it is necessary to cancel the delivery to the receiver's address or the number of the related document - the waybill or the order
requesterYesstring

Role of the user requesting to cancel the delivery.

Possible values:

  • "sender";
  • "receiver";
  • "customer"

contactIDs

No*array of integers

Contact persons IDs from "Address book".

Maximum 3 elements in the array

*If the request to cancel the delivery is submitted by the customer ("requester" parameter value is "customer"), then one of the two excluding parameters - "contactIDs" or"contactPersons" - is required

contactPersons

No*array of contactPersons

Contact persons data.

Maximum 3 elements in the array

*If the request to cancel the delivery is submitted by the customer ("requester" parameter value is "customer"), then one of the two excluding parameters - "contactIDs" or"contactPersons" - is required

contactPersons.name

YesstringContact person name

phoneIDs

No*array of integers

Phone number IDs from "Address book".

Maximum 3 elements in the array

*If the request to cancel the delivery is submitted by the customer ("requester" parameter value is "customer"), then one of the two excluding parameters - "phoneIDs" or"phoneNumbers" - is required

phoneNumbers

No*array of phoneNumbers

Phone numbers list.

Maximum 3 elements in the array

*If the request to cancel the delivery is submitted by the customer ("requester" parameter value is "customer"), then one of the two excluding parameters - "phoneIDs" or"phoneNumbers" - is required

phoneNumbers.number

YesstringPhone number. 15 characters maximum (the only valid non-digit sign is the plus sign at the beginning of the string)

phoneNumbers.ext

NostringExtension phone number. 5 digits maximum

Method response

Response structure

{
   "metadata":{
      "status":200,
      "generated_at":"2019-11-18 12:52:26"
   },
   "data":{
      "status":"success",
      "info": "Запрос принят. По результату его обработки, груз будет доступен для получения на терминале."
   }
}
<response>
   <metadata>
      <status>200</status>
      <generated_at>2019-11-18 12:52:26</generated_at>
   </metadata>
   <data>
      <status>success</status>
      <info>Запрос принят. По результату его обработки, груз будет доступен для получения на терминале.</info>
   </data>
</response>

Description of parameters

Response
Response
ParameterTypeDescription
metadataobjectSystem information
metadata.statusinteger

Emulated status http-code. If successful, code 200 is returned. In case of error - 400

metadata.generated_atstring

Server response date and time.

Format: YYYY-MM-DD HH:MM:SS

dataobjectSuccess confirmation
data.statusstring

Status in English. Possible value - "success"

"Success" status indicates that the request was accepted. After further verification the request can be approved or declined. To check the change request status use "Change history" method 
data.infostringAdditional information

Error handling

Except for common API errors the method response may contain the following errors:

Error numberhttp-codeError titleError description
TitleTranslationDescriptionTranslation

615001

400По данному заказу отмена доставки груза до адреса недоступнаThe delivery to the address for the order can not be cancelled--

615002

400По данному заказу отмена доставки груза до адреса недоступнаThe delivery to the address for the order can not be cancelledИзменение по данному заказу недоступно в связи с отсутствием доступаIt is not possible to change the order details since there is no access

615003

400Указанная роль заказчика для данного заказа недоступнаThe specified requester role is not allowable for the order--

615004

400Нет доступа к контрагенту заказаNo access to the counterparty--

615014

400Ошибка наложенного платежаCash on delivery errorДетальное описание ошибки см. в поле "detail" ответаDetailed error description see in the field "detail" of the response