Cancel a shipment order
curl --request DELETE \
--url https://anivahealth.com/api/v1/shipments/P-260415-4821 \
--header 'x-api-key: YOUR_API_KEY'
{
"id": "P-260415-4821",
"status": "cancelled",
"logistics_provider": "go_express",
"tracking_number": "GO1234567890",
"origin": {
"name": "Aniva Berlin Mitte",
"street": "Unter den Linden",
"house_number": "42",
"postal_code": "10117",
"city": "Berlin",
"country": "DE",
"phone": "+4930987654321",
"email": "berlin-mitte@anivahealth.com"
},
"destination": {
"name": "LabClinic GmbH",
"street": "Laborstraße",
"house_number": "10",
"postal_code": "80331",
"city": "München",
"country": "DE",
"phone": null,
"email": null
},
"notes": null,
"shipped_at": null,
"arrived_at": null,
"created_at": "2026-04-03T14:30:00Z",
"updated_at": "2026-04-03T16:45:00Z"
}
cancelled.
409 Conflict.SHIPMENTS_MANAGE scope. Requests made with a key that lacks this scope return 403 Forbidden.P-260415-4821).200 OK with the cancelled shipment object.
cancelled after a successful cancellation.go_express, dhl, or tof.null.null.Show address object
null.null.origin. May be null.null.null.null.null.| Status | Description |
|---|---|
403 | Forbidden — missing SHIPMENTS_MANAGE scope or shipment outside your access context. |
404 | Shipment not found. |
409 | Shipment cannot be cancelled (already picked up, delivered, or cancelled). |
500 | Internal server error. |
curl --request DELETE \
--url https://anivahealth.com/api/v1/shipments/P-260415-4821 \
--header 'x-api-key: YOUR_API_KEY'
{
"id": "P-260415-4821",
"status": "cancelled",
"logistics_provider": "go_express",
"tracking_number": "GO1234567890",
"origin": {
"name": "Aniva Berlin Mitte",
"street": "Unter den Linden",
"house_number": "42",
"postal_code": "10117",
"city": "Berlin",
"country": "DE",
"phone": "+4930987654321",
"email": "berlin-mitte@anivahealth.com"
},
"destination": {
"name": "LabClinic GmbH",
"street": "Laborstraße",
"house_number": "10",
"postal_code": "80331",
"city": "München",
"country": "DE",
"phone": null,
"email": null
},
"notes": null,
"shipped_at": null,
"arrived_at": null,
"created_at": "2026-04-03T14:30:00Z",
"updated_at": "2026-04-03T16:45:00Z"
}
curl --request DELETE \
--url https://anivahealth.com/api/v1/shipments/P-260415-4821 \
--header 'x-api-key: YOUR_API_KEY'
{
"id": "P-260415-4821",
"status": "cancelled",
"logistics_provider": "go_express",
"tracking_number": "GO1234567890",
"origin": {
"name": "Aniva Berlin Mitte",
"street": "Unter den Linden",
"house_number": "42",
"postal_code": "10117",
"city": "Berlin",
"country": "DE",
"phone": "+4930987654321",
"email": "berlin-mitte@anivahealth.com"
},
"destination": {
"name": "LabClinic GmbH",
"street": "Laborstraße",
"house_number": "10",
"postal_code": "80331",
"city": "München",
"country": "DE",
"phone": null,
"email": null
},
"notes": null,
"shipped_at": null,
"arrived_at": null,
"created_at": "2026-04-03T14:30:00Z",
"updated_at": "2026-04-03T16:45:00Z"
}