Cancel Sales Order B2C

Last Updated: 16 August 2022

Cancel Sales Order B2C

Shipper API gives interface access to our clients for canceling Sales Order from their own system to Shipper Warehouse Management System.

Sales Order only able to cancel if WMS has not allocated any stock to that Sales Order

PATCH Cancel Sales Order B2C

MethodEndpoint
PATCHv3/fulfillment/outbound/oms/cancel

Body Request Parameter

FieldData TypeDescriptionNote
order_nostring(50)Sales Order No

Example: TEST-OUTBOUND-OMS-1
Mandatory
warehouse_idstring(20)Warehouse ID Given by Shipper

Example: WH-TGR04
Mandatory
cancel_reasonString(50)Cancellation Reason

Example: “Cancelled from marketplace”
Mandatory

Sample Body Request

HeaderHow to Fill
x-api-keyShipper API Key
{
  "data": {
    "cancellation": {
      "order_no": "KZFILN0HRC9RDXJTZBJS",
      "cancel_reason": "cancel aja",
      "warehouse_id": "PMU"
    }
  }
}

Sample Response

{
    "metadata": {
        "path": "/v3/fulfillment/outbound/oms/cancel",
        "http_status_code": 200,
        "http_status": "OK",
        "timestamp": 1637907242
    }
}
{
  "metadata": {
    "path": "/v3/fulfillment/outbound/oms/cancel",
    "http_status_code": 400,
    "http_status": "Bad Request",
    "errors": [
      {
        "code": 810,
        "message": "Invalid Input. Please Validate Your Input."
      }
    ],
    "timestamp": 1637907103
  }
}
{
  "metadata": {
    "path": "/v3/fulfillment/outbound/oms/cancel",
    "status_code": 401,
    "status": "Unauthorized",
    "message": "PATCH /v1/fulfillment/outbound/oms/cancel [401] Unauthorized",
    "error": {
      "code": 802,
      "message": "Unauthorized Access. You are not authorized to access this resource."
    },
    "timestamp": "2022-05-12T04:04:19Z"
  }
}
{
  "metadata": {
    "path": "/v3/fulfillment/outbound/oms/cancel",
    "http_status_code": 500,
    "http_status": "Internal Server Error",
    "errors": [
      {
        "code": 803,
        "message": "Internal Server error."
      }
    ],
    "timestamp": 1652326659
  }
}
StatusReason
200Cancel sales order success
400Please check your input.
Make sure the JSON payload is correct
Make sure the requested input are valid.
401Please check whether your API Key is valid and still active.
500Something wrong with Shipper application.
Please contact Shipper representative.