Next Commerce
API ReferenceFulfillment

Fulfillment Orders Cancel

Cancel fulfillment order

POST
/fulfillment-orders/{id}/cancel/

Authorization

oauth2 fulfillment_service:write, fulfillment_orders:write
AuthorizationBearer <token>

Generate an Access Token through Settings > API Access for single store access or use the Authorization Code flow with your partner App Client ID. Use required permission scopes for API endpoint access. Example Authorization: Bearer 123

In: header

Scope: fulfillment_service:write, fulfillment_orders:write

Path Parameters

id*integer

A unique integer value identifying this fulfillment order.

Header Parameters

X-29next-API-Version*string
Default"2024-04-01"
Value in"2024-04-01"

Response Body

application/json

curl -X POST "https://example.29next.store/api/admin/fulfillment-orders/0/cancel/" \
  -H "X-29next-API-Version: 2024-04-01" \
  -H "Authorization: Bearer "
{
  "new_fulfillment_order": {
    "assigned_location": {
      "accept_return": true,
      "address": {
        "country": "string",
        "line1": "string",
        "line2": "string",
        "line3": "string",
        "line4": "string",
        "phone_number": "string",
        "postcode": "string",
        "state": "string"
      },
      "callback_url": "http://example.com",
      "id": 0,
      "name": "string"
    },
    "fulfillment_holds": [
      {
        "created_at": "2019-08-24T14:15:22Z",
        "reason": "address_incorrect",
        "reason_message": "string"
      }
    ],
    "id": 0,
    "line_items": [
      {
        "currency": "string",
        "fulfillable_quantity": "string",
        "fulfillment_order_id": 0,
        "id": 0,
        "order_line_id": 0,
        "price_excl_tax": "string",
        "price_incl_tax": "string",
        "product_id": "string",
        "product_image": "http://example.com",
        "product_title": "string",
        "quantity": 2147483647,
        "sku": "string",
        "stockrecord_id": 0,
        "tax_lines": [
          {
            "amount": "string",
            "currency": "string",
            "rate": 0.1,
            "report_values": {
              "amount": "string",
              "currency": "string"
            },
            "source": "string",
            "tax_id": 0,
            "tax_title": "string"
          }
        ],
        "total_discount": "string"
      }
    ],
    "merchant_requests": [
      {
        "message": "string",
        "notify": true,
        "type": "fulfill_request"
      }
    ],
    "order_number": "string",
    "request_status": "pending",
    "shipping_address": {
      "country": "string",
      "first_name": "string",
      "id": 0,
      "last_name": "string",
      "line1": "string",
      "line2": "string",
      "line3": "string",
      "line4": "string",
      "notes": "string",
      "phone_number": "string",
      "postcode": "string",
      "state": "string"
    },
    "shipping_method": {
      "code": "string",
      "name": "string"
    },
    "status": "not_required",
    "supported_actions": [
      null
    ]
  },
  "original_fulfillment_order": {
    "assigned_location": {
      "accept_return": true,
      "address": {
        "country": "string",
        "line1": "string",
        "line2": "string",
        "line3": "string",
        "line4": "string",
        "phone_number": "string",
        "postcode": "string",
        "state": "string"
      },
      "callback_url": "http://example.com",
      "id": 0,
      "name": "string"
    },
    "fulfillment_holds": [
      {
        "created_at": "2019-08-24T14:15:22Z",
        "reason": "address_incorrect",
        "reason_message": "string"
      }
    ],
    "id": 0,
    "line_items": [
      {
        "currency": "string",
        "fulfillable_quantity": "string",
        "fulfillment_order_id": 0,
        "id": 0,
        "order_line_id": 0,
        "price_excl_tax": "string",
        "price_incl_tax": "string",
        "product_id": "string",
        "product_image": "http://example.com",
        "product_title": "string",
        "quantity": 2147483647,
        "sku": "string",
        "stockrecord_id": 0,
        "tax_lines": [
          {
            "amount": "string",
            "currency": "string",
            "rate": 0.1,
            "report_values": {
              "amount": "string",
              "currency": "string"
            },
            "source": "string",
            "tax_id": 0,
            "tax_title": "string"
          }
        ],
        "total_discount": "string"
      }
    ],
    "merchant_requests": [
      {
        "message": "string",
        "notify": true,
        "type": "fulfill_request"
      }
    ],
    "order_number": "string",
    "request_status": "pending",
    "shipping_address": {
      "country": "string",
      "first_name": "string",
      "id": 0,
      "last_name": "string",
      "line1": "string",
      "line2": "string",
      "line3": "string",
      "line4": "string",
      "notes": "string",
      "phone_number": "string",
      "postcode": "string",
      "state": "string"
    },
    "shipping_method": {
      "code": "string",
      "name": "string"
    },
    "status": "not_required",
    "supported_actions": [
      null
    ]
  }
}