Skip to main content

Delete Order

Permanently deletes an order.

HTTP Request​

  • URL: /orders/{id}
  • Method: DELETE
  • Headers:
    • accessToken: Required. Your API access token.
  • Required scope: READ_WRITE_ORDER

Path Parameters​

ParameterTypeDescription
idStringRequired. The ID of the order to delete.

cURL Example​

curl --location --request DELETE '<BASE_URL>/orders/664f2310d5775459152d6dd8' \
--header 'accessToken: <ACCESS_TOKEN>'

Response​

  • 200 OK: The order was deleted. If no order exists with this ID, the response has "success": false.
  • 400 Bad Request: The access token is missing or invalid, or the order ID is not valid.

Sample JSON Response​

{
"success": true,
"message": "Order deleted successfully"
}

Response Details​

Result Data​

FieldTypeDescription
successBooleanWhether the order was deleted.
messageStringResult message.

Notes​

  • Deleting an order cannot be undone. To keep the order on record, set its status to cancelled with Update Order instead.
  • Payments and invoices linked to the order are kept.