Updates an existing order with the specified changes. This endpoint allows partial updates to order details, line items, and fulfillment orders.
This endpoint can be dangerous if not used correctly. The fulfillment orders (fulfillment_orders) field behaves as a full replacement - any fulfillment order not included in the request will be permanently removed.
The following fields are updated only if provided in the request:
partner_order_reference, order_date, merchant, language, sales_channeltaxes_included, duties_includedshipping_address, billing_address, customerpayment, discount_applications, shipping_linesIf line_items is provided, it completely replaces the existing line items. Ensure you include all line items you want to keep.
If fulfillment_orders is provided:
fulfillment_order_id or partner_fulfillment_order_referencefulfillment_order_idWhen updating FO line items, you must follow these rules:
Only pass line items with pending statuses:
open - Items not yet allocatedallocated - Items allocated but not fulfilledThe system automatically preserves line items with terminal statuses:
fulfilled - Items that have been fulfilled (will be added back automatically)cancelled - Items that have been cancelled (will be added back automatically)closed - Items that are closed (will be added back automatically)You do NOT need to include fulfilled, cancelled, or closed line items in your request - they will be preserved automatically.
If you have an FO with 2 items (item-1: open, item-2: fulfilled) and want to add item-3:
{
"fulfillment_orders": [{
"fulfillment_order_id": "FO-123",
"line_items": [
{ "id": "item-1", "quantity": 1 },
{ "id": "item-3", "quantity": 2 }
]
}]
}
Result: FO will have item-1 (open), item-2 (fulfilled - preserved), item-3 (open)
If you have an FO with 3 items and want to remove item-2 (which is open):
{
"fulfillment_orders": [{
"fulfillment_order_id": "FO-123",
"line_items": [
{ "id": "item-1", "quantity": 1 },
{ "id": "item-3", "quantity": 1 }
]
}]
}
To move item-2 from FO-A to FO-B:
{
"fulfillment_orders": [
{
"fulfillment_order_id": "FO-A",
"line_items": [{ "id": "item-1", "quantity": 1 }]
},
{
"fulfillment_order_id": "FO-B",
"line_items": [
{ "id": "item-2", "quantity": 1 },
{ "id": "item-3", "quantity": 1 }
]
}
]
}
fulfillment_order_id or partner_fulfillment_order_reference to match existing FOsOrders can only be updated when their status allows it:
open, partially_allocated, allocated, partially_fulfilled, fulfilled, closed - Can be updatedcancelled - Cannot be updatedIf inventory management is enabled, updating FOs will automatically:
Order updated successfully.
Invalid request or order cannot be updated in current status.
Order not found.
Concurrent update detected. Retry the request.
{- "partner_order_reference": "string",
- "order_date": "2019-08-24T14:15:22Z",
- "merchant": "string",
- "language": "string",
- "sales_channel": "string",
- "taxes_included": true,
- "duties_included": true,
- "shipping_address": {
- "name": "string",
- "company": "string",
- "email": "user@example.com",
- "phone": "string",
- "alternate_phone": "string",
- "address1": "string",
- "address2": "string",
- "city": "string",
- "state": "string",
- "postcode": "string",
- "country": "string",
- "coords": "string",
- "what3words": "string"
}, - "billing_address": {
- "name": "string",
- "company": "string",
- "email": "user@example.com",
- "phone": "string",
- "alternate_phone": "string",
- "address1": "string",
- "address2": "string",
- "city": "string",
- "state": "string",
- "postcode": "string",
- "country": "string",
- "coords": "string",
- "what3words": "string"
}, - "customer": {
- "name": "string",
- "company": "string",
- "email": "user@example.com",
- "phone": "string",
- "alternate_phone": "string",
- "address1": "string",
- "address2": "string",
- "city": "string",
- "state": "string",
- "postcode": "string",
- "country": "string",
- "coords": "string",
- "what3words": "string"
}, - "payment": {
- "payment_mode": "prepaid",
- "pending_amount": 0,
- "currency": "string"
}, - "discount_applications": [
- {
- "code": "string",
- "type": "string",
- "value": 0,
- "description": "string"
}
], - "shipping_lines": [
- {
- "code": "string",
- "title": "string",
- "price": 0,
- "currency": "string"
}
], - "line_items": [
- {
- "id": "string",
- "sku": "string",
- "origin_country": "string",
- "description": "string",
- "barcode": "string",
- "requires_shipping": true,
- "quantity": 0,
- "unit_price": 0,
- "unit_cost": 0,
- "discount_allocations": [
- {
- "amount": 0,
- "discount_application_index": 0
}
], - "taxes": [
- {
- "title": "string",
- "rate": 0,
- "amount": 0
}
], - "duties": [
- {
- "title": "string",
- "amount": 0
}
], - "weight": {
- "value": 0,
- "unit": "kg"
}, - "dimension": {
- "length": 0,
- "width": 0,
- "height": 0,
- "unit": "cm"
}, - "image_link": "string",
- "product_ref": "string",
- "product_id": "string",
- "hs_code": "string",
- "manufacturer_id": "string",
- "material_composition": "string",
- "dangerous_goods": true,
- "battery": {
- "type": "string",
- "packing": "string",
- "quantity": 0
}
}
], - "fulfillment_orders": [
- {
- "fulfillment_order_id": "string",
- "partner_fulfillment_order_reference": "string",
- "location_id": "string",
- "delivery": {
- "delivery_type": "string",
- "time_slot": {
- "date": "2019-08-24",
- "from": "string",
- "to": "string"
}, - "instructions": "string"
}, - "line_items": [
- {
- "line_item_id": "string",
- "quantity": 0
}
], - "carriyo_metadata": [
- {
- "key": "string",
- "value": "string"
}
]
}
]
}{- "tenant": "string",
- "order_id": "string",
- "merchant": "string",
- "partner_order_reference": "string",
- "language": "string",
- "order_date": "2019-08-24T14:15:22Z",
- "sales_channel": "string",
- "creation_source": {
- "source": "string",
- "user_id": "string",
- "ip_address": "string"
}, - "update_source": {
- "source": "string",
- "user_id": "string",
- "ip_address": "string"
}, - "carriyo_metadata": [
- {
- "key": "string",
- "value": "string"
}
], - "status": "open",
- "auto_allocation_failed": true,
- "cancellation_reason": "CUSTOMER_CANCELLATION",
- "shipping_address": {
- "name": "string",
- "company": "string",
- "email": "user@example.com",
- "phone": "string",
- "alternate_phone": "string",
- "address1": "string",
- "address2": "string",
- "city": "string",
- "state": "string",
- "postcode": "string",
- "country": "string",
- "coords": "string",
- "what3words": "string"
}, - "billing_address": {
- "name": "string",
- "company": "string",
- "email": "user@example.com",
- "phone": "string",
- "alternate_phone": "string",
- "address1": "string",
- "address2": "string",
- "city": "string",
- "state": "string",
- "postcode": "string",
- "country": "string",
- "coords": "string",
- "what3words": "string"
}, - "customer": {
- "name": "string",
- "company": "string",
- "email": "user@example.com",
- "phone": "string",
- "alternate_phone": "string",
- "address1": "string",
- "address2": "string",
- "city": "string",
- "state": "string",
- "postcode": "string",
- "country": "string",
- "coords": "string",
- "what3words": "string"
}, - "payment": {
- "payment_mode": "prepaid",
- "pending_amount": 0,
- "currency": "string"
}, - "redacted": true,
- "taxes_included": true,
- "duties_included": true,
- "discount_applications": [
- {
- "code": "string",
- "type": "string",
- "value": 0,
- "description": "string"
}
], - "line_items": [
- {
- "line_item_id": "string",
- "sku": "string",
- "product_id": "string",
- "name": "string",
- "description": "string",
- "quantity": 0,
- "price": 0,
- "currency": "string",
- "weight": 0,
- "weight_unit": "kg",
- "image_url": "string",
- "properties": {
- "property1": "string",
- "property2": "string"
}
}
], - "fulfillment_orders": [
- {
- "fulfillment_order_id": "string",
- "partner_fulfillment_order_reference": "string",
- "location_id": "string",
- "delivery": {
- "delivery_type": "string",
- "time_slot": {
- "date": "2019-08-24",
- "from": "string",
- "to": "string"
}, - "instructions": "string"
}, - "line_items": [
- {
- "line_item_id": "string",
- "quantity": 0,
- "status": "open",
- "fulfillment_id": "string",
- "shipment_ids": [
- "string"
]
}
], - "carriyo_metadata": [
- {
- "key": "string",
- "value": "string"
}
]
}
], - "shipping_lines": [
- {
- "code": "string",
- "title": "string",
- "price": 0,
- "currency": "string"
}
], - "error_details": [
- {
- "code": "string",
- "message": "string",
- "field": "string"
}
], - "creation_date": "2019-08-24T14:15:22Z",
- "update_date": "2019-08-24T14:15:22Z"
}