Table of Contents

Cancel Shipment API

DELETE /api/v3/shipments

Overview

The Cancel Shipment API removes an existing shipment from Fredi. This endpoint allows systems to cancel or remove shipments that were created but should no longer be processed.

Deleting a shipment prevents further carrier processing and removes the shipment from active shipment records.

Important

Shipments that have already been processed by the carrier may not be deletable depending on carrier restrictions!

Endpoint

DELETE /api/v3/shipments

Authentication

All requests must include a valid Bearer token.

Header Required Description
Authorization Yes Bearer {access_token}
Content-Type Yes application/json

See: Authentication section for token generation.

Request Body

The Cancel Shipment API expects a JSON payload containing a list of shipment references to be deleted.

{
  "shipmentDetails": [
    {
      "shipmentReference": "SHIP122358"
    }
  ]
}
Note

Multiple shipments can be deleted in a single request using the shipmentDetails[] array!

shipmentDetails

Represents an array of shipment identifiers that should be deleted. Each object in the array contains the unique shipment reference used to locate the corresponding shipment record in the system. If multiple shipments are provided, the deletion operation is performed for each shipment individually.

Structure

Note

The schema tree below is automatically generated from the OpenAPI specification!

📋 Click a field to see its JSON path

Loading schema…

Note

The example below is automatically generated from the OpenAPI specification!

Sample Request

Show Sample Request
{
  "shipmentDetails": [
    {
      "shipmentReference": "SHIP122358"
    },
    {
      "shipmentReference": "SHIP122359"
    }
  ]
}

Responses

Code Description
200 Shipment deleted successfully
400 Invalid request payload
401 Unauthorized
404 Shipment not found
422 Validation error
500 Internal server error

Example Response

200 Success – Shipment deleted successfully
{
  "type": "https://tools.ietf.org/html/rfc9110#section-15.3.1",
  "title": "Shipment deleted successfully",
  "status": 200,
  "data": {
    "deletedShipments": [
      {
        "shipmentReference": "SHIP122358",
        "status": "DELETED"
      }
    ]
  }
}

Important Notes

  • Only shipments that are not yet processed by the carrier can be deleted.
  • Carrier-integrated shipments may require carrier cancellation first.
  • Deleting a shipment permanently removes it from the system.
Back to top ↑