Cancel a delivery
const url = 'https://api.govza.app/v1/delivery/orders/example/cancel';const options = { method: 'POST', headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'}, body: '{"reason":"example","comment":"example"}'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request POST \ --url https://api.govza.app/v1/delivery/orders/example/cancel \ --header 'Authorization: Bearer <token>' \ --header 'Content-Type: application/json' \ --data '{ "reason": "example", "comment": "example" }'Authorizations
Заголовок раздела «Authorizations»Parameters
Заголовок раздела «Parameters»Path Parameters
Заголовок раздела «Path Parameters»Your own identifier for the order.
Request Body
Заголовок раздела «Request Body»object
Examplegenerated
{ "reason": "example", "comment": "example"}Responses
Заголовок раздела «Responses»The delivery was cancelled.
object
object
The human-readable Govza order code.
Public tracking page, safe to forward to the recipient. Expires 24
hours after the order is delivered or cancelled. Present on
create; when reading or listing, null if the order has no link yet
— reads never create one. Use
POST /orders/{external_order_id}/tracking_link to issue one.
Individual tracking pages, one per dropoff in your order, whatever order they are visited in. Null for a single-dropoff order or when unavailable.
Zero-based positions in your dropoffs array, in the order the courier
visits them. Everything else stays in your order: quote legs,
tracking_urls and index in PATCH.
Example
{ "data": { "status": "new", "visit_order": [ 2, 0, 1 ] }}The key is missing, malformed, revoked, or its account can no longer create orders.
object
object
Example
{ "success": false}No order exists for this external_order_id.
object
object
Example
{ "success": false}