Cancel a delivery
POST
/orders/{external_order_id}/cancel
const url = 'https://api.govza.app/v1/partner/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/partner/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»external_order_id
required
string
Your own identifier for the order.
Request Body
Заголовок раздела «Request Body»Media typeapplication/json
object
reason
string
comment
string
Examplegenerated
{ "reason": "example", "comment": "example"}Responses
Заголовок раздела «Responses»The delivery was cancelled.
Media typeapplication/json
object
success
boolean
data
object
external_order_id
string
order_code
The human-readable Govza order code.
string
status
string
price
number
tracking_url
Public tracking page, safe to forward to the recipient.
string
tracking_urls
Individual tracking pages in dropoff order. Null for a single-dropoff order or when unavailable.
Array<string>
Example
{ "data": { "status": "new" }}The key is missing, malformed, revoked, or its account can no longer create orders.
Media typeapplication/json
object
success
boolean
error
object
id
string
code
string
message
string
details
string
Example
{ "success": false}No order exists for this external_order_id.
Media typeapplication/json
object
success
boolean
error
object
id
string
code
string
message
string
details
string
Example
{ "success": false}