POST
/
api-order
/
orders
/
bulk-cancel
Bulk cancel orders
curl --request POST \
  --url https://prod01-apigw.{customer_name}.fabric.zone/api-order/orders/bulk-cancel \
  --header 'Content-Type: application/json' \
  --header 'x-site-context: <x-site-context>' \
  --data '[
  {
    "cancellationCode": "123",
    "orderId": "2947-5955-82579",
    "returnMessage": "Customer not interested"
  }
]'
[
  {
    "orderId": "2566-5214-47418",
    "status": "Error",
    "code": "ORDER_NOT_FOUND",
    "message": "Order ID Not Found"
  },
  {
    "orderId": "8426-1549-34543",
    "status": "Successfully cancelled order"
  }
]

Headers

x-api-key
string
Example:

"0LybWR49k95cCwYh3cu0waCYoh4H2Eux2J52wn4k"

x-site-context
string
required

The x-site-context header is a JSON object that contains information about the source you wish to pull from. The mandatory account is the 24 character identifier found in Copilot. The channel (Sales channel ID), stage (environment name), and date attributes can be used to further narrow the scope of your data source.

Example:

"{\"date\": \"2023-01-01T00:00:00.000Z\", \"channel\": 12, \"account\": \"1234abcd5678efgh9ijklmno\",\"stage\":\"production\"}"

Body

application/json · object[]
cancellationCode
string
Example:

"123"

orderId
string
Required string length: 15
Example:

"2947-5955-82579"

returnMessage
string
Example:

"Customer not interested"

Response

Successfully cancel orders

orderId
string
status
string