CancelShip

DELETE /ship/{carrier}/order/{seller_order_ref}

Attempts to cancel a created waybill, success will depend on carrier support.

Path parameters

  • carrier string Required

    Carrier name to ship, e.g. samarkand.sfexpress.test

  • seller_order_ref string Required

    Order reference number from retailers, e-commerce platform, e.g. Youzan, Little Red

Responses

  • 200 object

    Success

    • code integer(int32)
    • message string
    • data object
      • Logistics company waybill no.

      • orderSn string Deprecated

        Deprecated. Replaced by 'orderRef'.

      • orderRef string

        Order reference number. Default is from Odoo.

      • Order reference number. Also could be from retailers, e.g. Youzan.

      • the domestic delivery vender for sinotrans

      • The delivery status of one package

        Values are PREPARE_ORDER, SORT_ORDER, PACK_ORDER, ORDER_OUTBOUND, DELIVERY, FLIGHT_DEPARTURE, FLIGHT_ARRIVE, CUSTOM_CLEAR, CUSTOM_CLEAR_COMPLETE, CUSTOM_CLEAR_FAILURE, DOMESTIC_DELIVERY, DOMESTIC_IN_TRANSIT, DOMESTIC_SIGNING, DOMESTIC_SUCCESS, DOMESTIC_RETURNED, or DOMESTIC_FAILURE.

      • A note marked by the carrier, could be changed at any time.

      • The URL of delivery slip.

      • The URL of waybill tracking.

      • checkPoints array[string]

        The details of express checkpoints.

      • Comparison of gross weight with expected weight(the sum of net weight of items * 1.2 + 1)

        Default value is false.

      • Error code, returning if waybill creation failed. Available codes which will be progressively clarified: PRODUCT_NOT_EXIST, ORDER_NOT_EXIST, AREA_RESTRICTED, PRODUCT_ERROR, CUSTOMER_ERROR, ADDRESS_ERROR, LOGISTIC_ERROR, OTHERS

      • Error message, which will be progressively clarified

    • connectorResponses array[object]
    • responseTime integer(int32)

      The response time of current NomadOperation request, including sub-NomadOperation. The time unit is millisecond.

  • 500 object

    Failed

    • code integer(int32)
    • message string
    • data object
      • Logistics company waybill no.

      • orderSn string Deprecated

        Deprecated. Replaced by 'orderRef'.

      • orderRef string

        Order reference number. Default is from Odoo.

      • Order reference number. Also could be from retailers, e.g. Youzan.

      • the domestic delivery vender for sinotrans

      • The delivery status of one package

        Values are PREPARE_ORDER, SORT_ORDER, PACK_ORDER, ORDER_OUTBOUND, DELIVERY, FLIGHT_DEPARTURE, FLIGHT_ARRIVE, CUSTOM_CLEAR, CUSTOM_CLEAR_COMPLETE, CUSTOM_CLEAR_FAILURE, DOMESTIC_DELIVERY, DOMESTIC_IN_TRANSIT, DOMESTIC_SIGNING, DOMESTIC_SUCCESS, DOMESTIC_RETURNED, or DOMESTIC_FAILURE.

      • A note marked by the carrier, could be changed at any time.

      • The URL of delivery slip.

      • The URL of waybill tracking.

      • checkPoints array[string]

        The details of express checkpoints.

      • Comparison of gross weight with expected weight(the sum of net weight of items * 1.2 + 1)

        Default value is false.

      • Error code, returning if waybill creation failed. Available codes which will be progressively clarified: PRODUCT_NOT_EXIST, ORDER_NOT_EXIST, AREA_RESTRICTED, PRODUCT_ERROR, CUSTOMER_ERROR, ADDRESS_ERROR, LOGISTIC_ERROR, OTHERS

      • Error message, which will be progressively clarified

    • connectorResponses array[object]
    • responseTime integer(int32)

      The response time of current NomadOperation request, including sub-NomadOperation. The time unit is millisecond.

DELETE /ship/{carrier}/order/{seller_order_ref}
curl \
 -X DELETE https://nomad.samarkand-global.cn/pilot/ship/{carrier}/order/{seller_order_ref} \
 -H "x-ca-key: $API_KEY"
Response example (200)
{
  "code": 42,
  "message": "string",
  "data": {
    "shipmentId": "string",
    "scanFormId": "string",
    "scanFormUrl": "string",
    "trackingReference": "string",
    "waybillId": "string",
    "orderSn": "string",
    "orderRef": "string",
    "sellerOrderRef": "string",
    "domesticDeliveryCompany": "YTO",
    "deliveryStatus": "DELIVERY",
    "deliveryNote": "string",
    "deliverySlipUrl": "string",
    "trackingUrl": "string",
    "checkPoints": [
      "@accept_time 2020-05-01 04:59:38; @accept_address 伦敦; @remark 寄方准备快件中,当前地点: 【GB London Delivery Centre (英國倫敦收派中心)】; @opcode 647; @zoneGmt 1",
      "...",
      "@accept_time 2020-05-13 09:10:49; @accept_address 江门市;  @remark 在官网'运单资料&签收图',可查看签收人信息; @opcode 8000; @stayWhyCode  1; @zoneGmt 8"
    ],
    "weightFailed": false,
    "errorCode": "string",
    "errorMessage": "string"
  },
  "connectorResponses": [
    {
      "input": "{\"product_id\": 12121}",
      "mappingName": "GetProductOp",
      "api": [
        "string"
      ],
      "httpRequestRawData": "-",
      "code": 42,
      "response": "string",
      "responseEn": "string",
      "platform": "youzan",
      "requestCount": 1,
      "responseTime": 1000
    }
  ],
  "responseTime": 1000
}
Response example (500)
{
  "code": 42,
  "message": "string",
  "data": {
    "shipmentId": "string",
    "scanFormId": "string",
    "scanFormUrl": "string",
    "trackingReference": "string",
    "waybillId": "string",
    "orderSn": "string",
    "orderRef": "string",
    "sellerOrderRef": "string",
    "domesticDeliveryCompany": "YTO",
    "deliveryStatus": "DELIVERY",
    "deliveryNote": "string",
    "deliverySlipUrl": "string",
    "trackingUrl": "string",
    "checkPoints": [
      "@accept_time 2020-05-01 04:59:38; @accept_address 伦敦; @remark 寄方准备快件中,当前地点: 【GB London Delivery Centre (英國倫敦收派中心)】; @opcode 647; @zoneGmt 1",
      "...",
      "@accept_time 2020-05-13 09:10:49; @accept_address 江门市;  @remark 在官网'运单资料&签收图',可查看签收人信息; @opcode 8000; @stayWhyCode  1; @zoneGmt 8"
    ],
    "weightFailed": false,
    "errorCode": "string",
    "errorMessage": "string"
  },
  "connectorResponses": [
    {
      "input": "{\"product_id\": 12121}",
      "mappingName": "GetProductOp",
      "api": [
        "string"
      ],
      "httpRequestRawData": "-",
      "code": 42,
      "response": "string",
      "responseEn": "string",
      "platform": "youzan",
      "requestCount": 1,
      "responseTime": 1000
    }
  ],
  "responseTime": 1000
}