Orders API
The Carriyo Orders API manages the customer order lifecycle from creation through fulfillment handoff. Create orders with line items and delivery details, split across multiple fulfillment locations, and cancel or update orders before they ship.
Orders
The order object represents a customer order containing one or more items to be fulfilled. Orders serve as the foundation for the fulfillment process in Carriyo.
Key concepts
Order structure
Each order contains:
- Customer information: shipping address, billing address, and customer details.
- Line items: products ordered with quantities and prices.
- Fulfillment orders: groups of line items assigned to specific locations for fulfillment.
- Payment information: payment status and method details.
Order status
Orders progress through the following statuses:
- open: order created, not yet allocated.
- partially_allocated: some items allocated to fulfillment locations.
- allocated: all items allocated to fulfillment locations.
- processing: one or more fulfillment orders are being picked, packed, or shipped.
- fulfilled: all items have been fulfilled.
- cancelled: order has been cancelled.
- closed: order is complete and closed.
Reference keys
Orders can be retrieved using:
order_id: Carriyo's unique identifier for the order.partner_order_reference: your system's order reference (withkey=partner_order_reference).
This allows flexible integration with your existing order management systems.
Fulfillment orders
When an order is created, Carriyo automatically generates fulfillment orders based on:
- Inventory availability across locations
- Location-based allocation rules
- Explicit fulfillment order specifications in the request
Each fulfillment order represents items to be shipped from a single location.
Lifecycle: orders move from open (created, awaiting allocation) to partially_allocated or allocated (fulfillment orders assigned to locations), then processing (items being picked, packed, or shipped), fulfilled, and closed. An order can be cancelled before its items are in transit.
6 operations · 1 object
The Order object
The Order object represents a customer order in Carriyo — line items the customer purchased, shipping and billing addresses, payment, and the references that tie back to your e-commerce or OMS system.
An Order doesn't directly book a shipment. Instead, Carriyo splits the Order into one or more fulfillment orders allocated across your locations, and each fulfillment order produces one or more Shipments. For the full relationship model, see the Domain model.
Properties
- Current status of the order: -
open- Order created, not yet allocated -partially_allocated- Some items allocated to fulfillment locations -allocated- All items allocated to fulfillment locations -processing- One or more fulfillment orders are being processed (picked, packed, shipped or partially fulfilled) -fulfilled- All items have been fulfilled -cancelled- Order has been cancelled -closed- Order is complete and closedValues:openpartially_allocatedallocatedprocessingfulfilledcancelledclosed - The reason for cancellation. Must be one of the following values: -
CUSTOMER_CANCELLATION- Customer requested cancellation -AUTO_ALLOCATION_FAILED- Automatic fulfillment allocation failed -INVENTORY_OUT_OF_STOCK- Items are out of stock -STAFF_ERROR- Staff made an error -PAYMENT_ISSUE- Payment problem occurred -OTHER- Other reasonValues:CUSTOMER_CANCELLATIONAUTO_ALLOCATION_FAILEDINVENTORY_OUT_OF_STOCKSTAFF_ERRORPAYMENT_ISSUEOTHER - Carriyo address object used for customer, billing, delivery and customer-collection addresses. You can either pass a fully free-form address (
contact_name,address1,city,country, etc.) or reference a pre-configured location in Carriyo usingpartner_location_id,partner_location_name, orpartner_location_code.
Related
- Create order — POST /orders
- Get order — GET /orders/{order_id}
- Update order — PUT /orders/{order_id}
- E-commerce orders guide — full integration walkthrough
/ordersCreate order
Creates a new order in Carriyo with the specified line items, customer details, and delivery method.
Order creation flow
When you create an order:
- Carriyo validates the request and creates the order
- Fulfillment orders are generated based on your specifications or automatic allocation
- If inventory management is enabled, inventory is reserved for the allocated items
- Webhooks are triggered to notify your systems
Delivery Method
Each fulfillment order can have one of three delivery methods:
DELIVERY: standard delivery to the customer's address (delivery_address+delivery_schedule).COLLECTION: customer collects from a pickup point (customer_collection_address+customer_collection_schedule).DIGITAL: no physical delivery; fulfilled digitally.
The top-level delivery_method, delivery_type, delivery_address, delivery_schedule, customer_collection_address, and customer_collection_schedule are request-only convenience fields. They are propagated to each auto-allocated fulfillment order and persisted there, but are not stored on the Order itself. To set them per fulfillment order, provide them inside each entry of the fulfillment_orders array.
Fulfillment order allocation
You can control how fulfillment orders are created:
- Automatic: Omit
fulfillment_ordersand Carriyo allocates based on inventory and rules - Manual: Specify
fulfillment_ordersto control which items go to which locations
Line items
Each line item represents a product in the order with:
- Product identification (
id,sku,product_id,barcode) - Quantity ordered
- Pricing information (
unit_price,unit_cost, taxes, duties, discount allocations) - Physical attributes (
weight,dimension,dangerous_goods,battery)
Response
The API returns the complete order object including:
- Generated
order_idfor future reference - Fulfillment orders with their allocations
- Initial order status
Headers
| Name | Value | Required | Description |
|---|---|---|---|
| Authorization | Bearer YOUR-ACCESS-TOKEN | Yes | OAuth 2.0 bearer token obtained from `POST /oauth/token`. |
| x-api-key | YOUR-API-KEY | Yes | Your tenant's API key, issued in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
| tenant-id | YOUR-TENANT-ID | Yes | Your Carriyo tenant ID, shown in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
| Content-Type | application/json | Yes | Media type of the request body. |
Request body
application/jsonSchema: create-order-requestrequired- Carriyo address object used for customer, billing, delivery and customer-collection addresses. You can either pass a fully free-form address (
contact_name,address1,city,country, etc.) or reference a pre-configured location in Carriyo usingpartner_location_id,partner_location_name, orpartner_location_code.
Responses
order- Current status of the order: -
open- Order created, not yet allocated -partially_allocated- Some items allocated to fulfillment locations -allocated- All items allocated to fulfillment locations -processing- One or more fulfillment orders are being processed (picked, packed, shipped or partially fulfilled) -fulfilled- All items have been fulfilled -cancelled- Order has been cancelled -closed- Order is complete and closedValues:openpartially_allocatedallocatedprocessingfulfilledcancelledclosed - The reason for cancellation. Must be one of the following values: -
CUSTOMER_CANCELLATION- Customer requested cancellation -AUTO_ALLOCATION_FAILED- Automatic fulfillment allocation failed -INVENTORY_OUT_OF_STOCK- Items are out of stock -STAFF_ERROR- Staff made an error -PAYMENT_ISSUE- Payment problem occurred -OTHER- Other reasonValues:CUSTOMER_CANCELLATIONAUTO_ALLOCATION_FAILEDINVENTORY_OUT_OF_STOCKSTAFF_ERRORPAYMENT_ISSUEOTHER - Carriyo address object used for customer, billing, delivery and customer-collection addresses. You can either pass a fully free-form address (
contact_name,address1,city,country, etc.) or reference a pre-configured location in Carriyo usingpartner_location_id,partner_location_name, orpartner_location_code.
Need the full machine-readable spec? Download the OpenAPI document →
/orders/{reference}Get order
Retrieves the complete details of an order by its reference.
Reference Types
You can retrieve an order using:
- Carriyo Order ID: The unique identifier generated by Carriyo (default)
partner_order_reference: Your system's order reference by settingkey=partner_order_reference
Response
Returns the full order object including:
- Order details and status
- All fulfillment orders and their current states
- Line item details and fulfillment status
- Customer and address information
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
| reference | string | Yes | The order reference (order_id or partner_order_reference based on the key parameter). |
Query parameters
| Name | Type | Required | Description |
|---|---|---|---|
| key | string | No | Specifies which reference type is being used: - `order_id`: Carriyo's unique order identifier (default) - `partner_order_reference`: Your system's order reference |
Headers
| Name | Value | Required | Description |
|---|---|---|---|
| Authorization | Bearer YOUR-ACCESS-TOKEN | Yes | OAuth 2.0 bearer token obtained from `POST /oauth/token`. |
| x-api-key | YOUR-API-KEY | Yes | Your tenant's API key, issued in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
| tenant-id | YOUR-TENANT-ID | Yes | Your Carriyo tenant ID, shown in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
Responses
order- Current status of the order: -
open- Order created, not yet allocated -partially_allocated- Some items allocated to fulfillment locations -allocated- All items allocated to fulfillment locations -processing- One or more fulfillment orders are being processed (picked, packed, shipped or partially fulfilled) -fulfilled- All items have been fulfilled -cancelled- Order has been cancelled -closed- Order is complete and closedValues:openpartially_allocatedallocatedprocessingfulfilledcancelledclosed - The reason for cancellation. Must be one of the following values: -
CUSTOMER_CANCELLATION- Customer requested cancellation -AUTO_ALLOCATION_FAILED- Automatic fulfillment allocation failed -INVENTORY_OUT_OF_STOCK- Items are out of stock -STAFF_ERROR- Staff made an error -PAYMENT_ISSUE- Payment problem occurred -OTHER- Other reasonValues:CUSTOMER_CANCELLATIONAUTO_ALLOCATION_FAILEDINVENTORY_OUT_OF_STOCKSTAFF_ERRORPAYMENT_ISSUEOTHER - Carriyo address object used for customer, billing, delivery and customer-collection addresses. You can either pass a fully free-form address (
contact_name,address1,city,country, etc.) or reference a pre-configured location in Carriyo usingpartner_location_id,partner_location_name, orpartner_location_code.
Need the full machine-readable spec? Download the OpenAPI document →
/orders/{reference}Update order
Apply partial updates to an order's details, line items, and fulfillment orders.
Important warning
Used incorrectly, this endpoint can destroy data. The fulfillment_orders field is a full replacement: any fulfillment order not included in the request is permanently removed.
Update behaviour
Simple fields (partial update)
The following fields are updated only if provided in the request:
partner_order_reference,order_date,merchant,language,sales_channeltaxes_included,duties_includeddelivery_address,billing_address,customerpayment,discount_applications,shipping_lines
Line items (full replacement)
If line_items is provided, it completely replaces the existing line items. Include every line item you want to keep.
Fulfillment orders (full replacement with preservation rules)
If fulfillment_orders is provided:
- Any FO not included is removed. Always include every FO you want to keep.
- FOs are matched by
fulfillment_order_idorpartner_fulfillment_order_reference. - An FO without a matching ID is created with a new
fulfillment_order_id.
Fulfillment order line items: critical rules
When updating FO line items:
What to include
Only pass line items with pending statuses:
open: items not yet allocated.allocated: items allocated but not fulfilled.
What is preserved automatically
Line items with terminal statuses are preserved without you re-sending them:
fulfilled: items that have been fulfilled.cancelled: items that have been cancelled.closed: items that are closed.
Don't include fulfilled, cancelled, or closed line items in your request; they're preserved automatically and including them may cause unexpected behaviour.
Example scenarios
Scenario 1: adding a new line item to an FO
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: the FO has item-1 (open), item-2 (fulfilled, preserved), item-3 (open).
Scenario 2: removing a pending line item from an FO
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 }
]
}]
}
Scenario 3: moving a line item between FOs
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 }
]
}
]
}
Common mistakes to avoid
- Forgetting to include all FOs. If you include only one FO in the request, every other FO is deleted.
- Including fulfilled or cancelled items. They're preserved automatically; re-sending them may cause unexpected behaviour.
- Not matching FO identifiers. Use
fulfillment_order_idorpartner_fulfillment_order_referenceto match existing FOs. - Treating line items as a partial update. The
line_itemsarray replaces all pending items, so include every pending item you want to keep.
Order status restrictions
An order can be updated in any status except cancelled. That covers open, partially_allocated, allocated, processing, fulfilled, and closed.
Inventory impact
If inventory management is enabled, updating FOs automatically:
- Reserves inventory for new FO allocations.
- Releases inventory for removed FO allocations.
- Adjusts inventory for quantity changes.
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
| reference | string | Yes | The order reference (order_id or partner_order_reference based on the key parameter). |
Query parameters
| Name | Type | Required | Description |
|---|---|---|---|
| key | string | No | Specifies which reference type is being used: - `order_id`: Carriyo's unique order identifier (default) - `partner_order_reference`: Your system's order reference |
Headers
| Name | Value | Required | Description |
|---|---|---|---|
| Authorization | Bearer YOUR-ACCESS-TOKEN | Yes | OAuth 2.0 bearer token obtained from `POST /oauth/token`. |
| x-api-key | YOUR-API-KEY | Yes | Your tenant's API key, issued in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
| tenant-id | YOUR-TENANT-ID | Yes | Your Carriyo tenant ID, shown in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
| Content-Type | application/json | Yes | Media type of the request body. |
Request body
application/jsonSchema: update-order-requestrequired- Carriyo address object used for customer, billing, delivery and customer-collection addresses. You can either pass a fully free-form address (
contact_name,address1,city,country, etc.) or reference a pre-configured location in Carriyo usingpartner_location_id,partner_location_name, orpartner_location_code. - Full replacement with preservation rules. ⚠️ Critical: Any fulfillment order NOT included in this array will be PERMANENTLY REMOVED. For each FO's line_items: - Only include items with pending statuses (
open,allocated,pick_in_progress,picked,pack_in_progress) - Items with terminal statuses (fulfilled,cancelled,closed) are automatically preserved
Responses
order- Current status of the order: -
open- Order created, not yet allocated -partially_allocated- Some items allocated to fulfillment locations -allocated- All items allocated to fulfillment locations -processing- One or more fulfillment orders are being processed (picked, packed, shipped or partially fulfilled) -fulfilled- All items have been fulfilled -cancelled- Order has been cancelled -closed- Order is complete and closedValues:openpartially_allocatedallocatedprocessingfulfilledcancelledclosed - The reason for cancellation. Must be one of the following values: -
CUSTOMER_CANCELLATION- Customer requested cancellation -AUTO_ALLOCATION_FAILED- Automatic fulfillment allocation failed -INVENTORY_OUT_OF_STOCK- Items are out of stock -STAFF_ERROR- Staff made an error -PAYMENT_ISSUE- Payment problem occurred -OTHER- Other reasonValues:CUSTOMER_CANCELLATIONAUTO_ALLOCATION_FAILEDINVENTORY_OUT_OF_STOCKSTAFF_ERRORPAYMENT_ISSUEOTHER - Carriyo address object used for customer, billing, delivery and customer-collection addresses. You can either pass a fully free-form address (
contact_name,address1,city,country, etc.) or reference a pre-configured location in Carriyo usingpartner_location_id,partner_location_name, orpartner_location_code.
error-responseerror-responseNeed the full machine-readable spec? Download the OpenAPI document →
/orders/{reference}/cancelCancel order
Cancels an order and all its associated fulfillment orders.
Status requirements
An order can be cancelled only while it is still in an allocation phase:
- ✅
open: created but not yet allocated. - ✅
partially_allocated: some items allocated to fulfillment locations. - ✅
allocated: all items allocated to fulfillment locations.
Once fulfillment is under way or finished, cancellation is no longer allowed:
- ❌
processing: one or more fulfillment orders are being picked, packed, or shipped. - ❌
fulfilled: all items have been fulfilled. - ❌
closed: order is complete and closed. - ❌
cancelled: order is already cancelled.
Cancellation effects
When an order is successfully cancelled:
- Every line item's quantity is set to 0 and its removed quantity is recorded.
- Every fulfillment order line item is marked
cancelled. - Reserved inventory is released back to stock.
- The order status is updated to
cancelled. - Webhooks fire to notify your systems.
Cancellation reason
Provide a cancellation_reason, one of:
CUSTOMER_CANCELLATION: customer requested cancellation.AUTO_ALLOCATION_FAILED: automatic fulfillment allocation failed.INVENTORY_OUT_OF_STOCK: items are out of stock.STAFF_ERROR: staff made an error.PAYMENT_ISSUE: a payment problem occurred.OTHER: any other reason.
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
| reference | string | Yes | The order reference (order_id or partner_order_reference based on the key parameter). |
Query parameters
| Name | Type | Required | Description |
|---|---|---|---|
| key | string | No | Specifies which reference type is being used: - `order_id`: Carriyo's unique order identifier (default) - `partner_order_reference`: Your system's order reference |
Headers
| Name | Value | Required | Description |
|---|---|---|---|
| Authorization | Bearer YOUR-ACCESS-TOKEN | Yes | OAuth 2.0 bearer token obtained from `POST /oauth/token`. |
| x-api-key | YOUR-API-KEY | Yes | Your tenant's API key, issued in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
| tenant-id | YOUR-TENANT-ID | Yes | Your Carriyo tenant ID, shown in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
| Content-Type | application/json | Yes | Media type of the request body. |
Request body
application/jsonSchema: cancel-order-request- The reason for cancellation. Must be one of the following values: -
CUSTOMER_CANCELLATION- Customer requested cancellation -AUTO_ALLOCATION_FAILED- Automatic fulfillment allocation failed -INVENTORY_OUT_OF_STOCK- Items are out of stock -STAFF_ERROR- Staff made an error -PAYMENT_ISSUE- Payment problem occurred -OTHER- Other reasonValues:CUSTOMER_CANCELLATIONAUTO_ALLOCATION_FAILEDINVENTORY_OUT_OF_STOCKSTAFF_ERRORPAYMENT_ISSUEOTHER
Responses
order- Current status of the order: -
open- Order created, not yet allocated -partially_allocated- Some items allocated to fulfillment locations -allocated- All items allocated to fulfillment locations -processing- One or more fulfillment orders are being processed (picked, packed, shipped or partially fulfilled) -fulfilled- All items have been fulfilled -cancelled- Order has been cancelled -closed- Order is complete and closedValues:openpartially_allocatedallocatedprocessingfulfilledcancelledclosed - The reason for cancellation. Must be one of the following values: -
CUSTOMER_CANCELLATION- Customer requested cancellation -AUTO_ALLOCATION_FAILED- Automatic fulfillment allocation failed -INVENTORY_OUT_OF_STOCK- Items are out of stock -STAFF_ERROR- Staff made an error -PAYMENT_ISSUE- Payment problem occurred -OTHER- Other reasonValues:CUSTOMER_CANCELLATIONAUTO_ALLOCATION_FAILEDINVENTORY_OUT_OF_STOCKSTAFF_ERRORPAYMENT_ISSUEOTHER - Carriyo address object used for customer, billing, delivery and customer-collection addresses. You can either pass a fully free-form address (
contact_name,address1,city,country, etc.) or reference a pre-configured location in Carriyo usingpartner_location_id,partner_location_name, orpartner_location_code.
error-responseNeed the full machine-readable spec? Download the OpenAPI document →
/orders/{reference}/redactRedact order
Anonymises the personal data on an order and propagates the redaction to dropoff fields on every linked shipment. This action is irreversible.
See also: Data Redaction, the full feature page covering order and shipment redaction scope, downstream sync, and GDPR compliance guidance.
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
| reference | string | Yes | The order reference (order_id or partner_order_reference based on the key parameter). |
Query parameters
| Name | Type | Required | Description |
|---|---|---|---|
| key | string | No | Specifies which reference type is being used: - `order_id`: Carriyo's unique order identifier (default) - `partner_order_reference`: Your system's order reference |
Headers
| Name | Value | Required | Description |
|---|---|---|---|
| Authorization | Bearer YOUR-ACCESS-TOKEN | Yes | OAuth 2.0 bearer token obtained from `POST /oauth/token`. |
| x-api-key | YOUR-API-KEY | Yes | Your tenant's API key, issued in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
| tenant-id | YOUR-TENANT-ID | Yes | Your Carriyo tenant ID, shown in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
Responses
order- Current status of the order: -
open- Order created, not yet allocated -partially_allocated- Some items allocated to fulfillment locations -allocated- All items allocated to fulfillment locations -processing- One or more fulfillment orders are being processed (picked, packed, shipped or partially fulfilled) -fulfilled- All items have been fulfilled -cancelled- Order has been cancelled -closed- Order is complete and closedValues:openpartially_allocatedallocatedprocessingfulfilledcancelledclosed - The reason for cancellation. Must be one of the following values: -
CUSTOMER_CANCELLATION- Customer requested cancellation -AUTO_ALLOCATION_FAILED- Automatic fulfillment allocation failed -INVENTORY_OUT_OF_STOCK- Items are out of stock -STAFF_ERROR- Staff made an error -PAYMENT_ISSUE- Payment problem occurred -OTHER- Other reasonValues:CUSTOMER_CANCELLATIONAUTO_ALLOCATION_FAILEDINVENTORY_OUT_OF_STOCKSTAFF_ERRORPAYMENT_ISSUEOTHER - Carriyo address object used for customer, billing, delivery and customer-collection addresses. You can either pass a fully free-form address (
contact_name,address1,city,country, etc.) or reference a pre-configured location in Carriyo usingpartner_location_id,partner_location_name, orpartner_location_code.
error-responseNeed the full machine-readable spec? Download the OpenAPI document →
/orders/bulk/importBulk import orders
Create multiple orders in a single request for batch processing.
Processing
Each order in the batch is processed independently:
- Valid orders are created.
- Invalid orders return error details.
- Processing continues even if some orders fail.
Limits
- Up to 20 orders per request by default (configurable per tenant). Chunk larger imports client-side.
- Each order follows the same validation as single order creation.
Duplicates
Bulk import is create-only; it does not upsert. A row whose partner_order_reference already exists in Carriyo, or that appears more than once within the batch, is rejected rather than updated. The successful rows in the same batch are unaffected.
Response
Returns one entry per input row, in the same order as the request. Each entry carries:
result:SUCCESSwhen the order was created; otherwise an error code such asDUPLICATEorVALIDATION_ERROR.reason: human-readable detail whenresultis notSUCCESS.- The full order object when
resultisSUCCESS.
Treat DUPLICATE as a no-op (the order is already in Carriyo) rather than a retryable failure.
Headers
| Name | Value | Required | Description |
|---|---|---|---|
| Authorization | Bearer YOUR-ACCESS-TOKEN | Yes | OAuth 2.0 bearer token obtained from `POST /oauth/token`. |
| x-api-key | YOUR-API-KEY | Yes | Your tenant's API key, issued in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
| tenant-id | YOUR-TENANT-ID | Yes | Your Carriyo tenant ID, shown in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
| Content-Type | application/json | Yes | Media type of the request body. |
Request body
application/jsonSchema: bulk-order-import-requestrequiredResponses
Need the full machine-readable spec? Download the OpenAPI document →
Fulfillment Orders
Fulfillment orders represent groups of line items from an order that are assigned to a specific location for fulfillment. They enable split-shipment workflows and multi-location fulfillment.
Key concepts
Fulfillment order lifecycle
- Created: when an order is created, fulfillment orders are generated automatically or based on your specifications.
- Pending: items are awaiting fulfillment at the assigned location.
- Fulfilled: items have been picked, packed, and are ready for shipping.
- Shipped: shipments have been created and items are in transit.
- Completed: all items have been delivered.
Operations
Fulfill
Mark items as fulfilled and ready for shipping. This operation:
- Updates line item statuses to fulfilled
- Optionally creates a draft shipment automatically
- Triggers inventory updates
Unfulfill
Reverse a fulfillment when items cannot be shipped. This allows:
- Correcting fulfillment errors
- Handling out-of-stock situations discovered after fulfillment
- Reallocating items to different locations
Split
Divide a fulfillment order when items need to ship from different sources:
- Create a new fulfillment order with selected line items
- Assign to a different location if needed
- Maintain order integrity across splits
Merge
Combine fulfillment orders when consolidation makes sense:
- Reduce shipping costs by combining shipments
- Improve customer experience with fewer deliveries
- Optimize fulfillment operations
Ship
Create shipments for fulfilled items:
- Specify carrier account and parcel details
- Include delivery preferences
- Generate shipping labels through the Carriyo Shipping API
Cancel
Cancel specific line items within a fulfillment order:
- Provide cancellation reason
- Automatically updates inventory
- Triggers order status recalculation
Location management
Fulfillment orders are tied to locations. You can:
- Update the assigned location before fulfillment
- Move items between locations using split and merge operations
- Track inventory across all fulfillment locations
11 operations · 0 objects
/orders/{orderReference}/fulfillment-orders/{fulfillmentOrderId}/fulfillFulfill order
Marks items in a fulfillment order as fulfilled and creates a shipment.
Line item status requirements
Only items in pending status (open or allocated) can be fulfilled:
- ✅
open- Item awaiting allocation - ✅
allocated- Item assigned to a location - ❌
fulfilled- Already fulfilled - ❌
cancelled- Cannot be fulfilled - ❌
closed- Cannot be fulfilled
Fulfillment process
When you fulfill an order, Carriyo:
- Validates that the requested line items exist and are in a pending status.
- Validates that the requested quantities don't exceed available quantities.
- Creates a shipment (unless
skip_shipping=true). - Marks line items as
fulfilledwith a unique fulfillment ID. - Updates the order status based on overall fulfillment progress.
- Fires webhooks.
Line items (required)
Provide a line_items array specifying which items to fulfill. Each entry needs:
id: matching an order line item.quantity: the quantity to fulfill, which must be ≤ the pending quantity.
Shipment creation
Control shipment creation with query parameters:
create_draft_shipment=true: creates a draft shipment for review before carrier booking.skip_shipping=true: fulfills without creating any shipment (items auto-close).
Inventory impact
If inventory management is enabled with stock_reduction_timing = ON_ORDER_FULFILLED, both on_hand and reserved are reduced by the fulfilled quantity.
If shipping is not required (or skip_shipping=true), items are automatically set to closed.
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
| orderReference | string | Yes | The order reference (order_id or partner_order_reference based on the key parameter). |
| fulfillmentOrderId | string | Yes | The unique identifier of the fulfillment order. |
Query parameters
| Name | Type | Required | Description |
|---|---|---|---|
| key | string | No | Specifies which reference type is being used for the order reference. |
| create_draft_shipment | boolean | No | If true, creates a draft shipment instead of immediately booking with a carrier. |
| skip_shipping | boolean | No | If true, fulfills the order without creating a shipment. |
Headers
| Name | Value | Required | Description |
|---|---|---|---|
| Authorization | Bearer YOUR-ACCESS-TOKEN | Yes | OAuth 2.0 bearer token obtained from `POST /oauth/token`. |
| x-api-key | YOUR-API-KEY | Yes | Your tenant's API key, issued in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
| tenant-id | YOUR-TENANT-ID | Yes | Your Carriyo tenant ID, shown in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
| Content-Type | application/json | Yes | Media type of the request body. |
Request body
application/jsonSchema: create-fulfillment-requestResponses
order- Current status of the order: -
open- Order created, not yet allocated -partially_allocated- Some items allocated to fulfillment locations -allocated- All items allocated to fulfillment locations -processing- One or more fulfillment orders are being processed (picked, packed, shipped or partially fulfilled) -fulfilled- All items have been fulfilled -cancelled- Order has been cancelled -closed- Order is complete and closedValues:openpartially_allocatedallocatedprocessingfulfilledcancelledclosed - The reason for cancellation. Must be one of the following values: -
CUSTOMER_CANCELLATION- Customer requested cancellation -AUTO_ALLOCATION_FAILED- Automatic fulfillment allocation failed -INVENTORY_OUT_OF_STOCK- Items are out of stock -STAFF_ERROR- Staff made an error -PAYMENT_ISSUE- Payment problem occurred -OTHER- Other reasonValues:CUSTOMER_CANCELLATIONAUTO_ALLOCATION_FAILEDINVENTORY_OUT_OF_STOCKSTAFF_ERRORPAYMENT_ISSUEOTHER - Carriyo address object used for customer, billing, delivery and customer-collection addresses. You can either pass a fully free-form address (
contact_name,address1,city,country, etc.) or reference a pre-configured location in Carriyo usingpartner_location_id,partner_location_name, orpartner_location_code.
error-responseNeed the full machine-readable spec? Download the OpenAPI document →
/orders/{orderReference}/fulfillment-orders/{fulfillmentOrderId}/unfulfillUnfulfill order
Reverse a previous fulfillment, returning items to allocated status.
When to unfulfill
Use this endpoint when items were fulfilled in error, stock turns out to be unavailable after fulfillment, the fulfillment needs to move to another location, or a shipment was cancelled before pickup.
Request requirements
Provide fulfillment_ids, an array of the fulfillment IDs to reverse. Each must exist among the fulfillment order's fulfilled line items.
Effects
When you unfulfill, Carriyo:
- Cancels associated shipments, if not already cancelled.
- Returns line items to
allocatedstatus. - Clears the fulfillment ID, shipment IDs, and partner reference from the items.
- Merges items that share the same ID and status.
- Recalculates the order status.
- Fires webhooks.
Inventory impact
If inventory management is enabled, on_hand is increased by the unfulfilled quantity, restoring stock.
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
| orderReference | string | Yes | The order reference (order_id or partner_order_reference based on the key parameter). |
| fulfillmentOrderId | string | Yes | The unique identifier of the fulfillment order. |
Query parameters
| Name | Type | Required | Description |
|---|---|---|---|
| key | string | No | Specifies which reference type is being used for the order reference. |
Headers
| Name | Value | Required | Description |
|---|---|---|---|
| Authorization | Bearer YOUR-ACCESS-TOKEN | Yes | OAuth 2.0 bearer token obtained from `POST /oauth/token`. |
| x-api-key | YOUR-API-KEY | Yes | Your tenant's API key, issued in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
| tenant-id | YOUR-TENANT-ID | Yes | Your Carriyo tenant ID, shown in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
| Content-Type | application/json | Yes | Media type of the request body. |
Request body
application/jsonSchema: unfulfill-fulfillment-requestrequiredResponses
order- Current status of the order: -
open- Order created, not yet allocated -partially_allocated- Some items allocated to fulfillment locations -allocated- All items allocated to fulfillment locations -processing- One or more fulfillment orders are being processed (picked, packed, shipped or partially fulfilled) -fulfilled- All items have been fulfilled -cancelled- Order has been cancelled -closed- Order is complete and closedValues:openpartially_allocatedallocatedprocessingfulfilledcancelledclosed - The reason for cancellation. Must be one of the following values: -
CUSTOMER_CANCELLATION- Customer requested cancellation -AUTO_ALLOCATION_FAILED- Automatic fulfillment allocation failed -INVENTORY_OUT_OF_STOCK- Items are out of stock -STAFF_ERROR- Staff made an error -PAYMENT_ISSUE- Payment problem occurred -OTHER- Other reasonValues:CUSTOMER_CANCELLATIONAUTO_ALLOCATION_FAILEDINVENTORY_OUT_OF_STOCKSTAFF_ERRORPAYMENT_ISSUEOTHER - Carriyo address object used for customer, billing, delivery and customer-collection addresses. You can either pass a fully free-form address (
contact_name,address1,city,country, etc.) or reference a pre-configured location in Carriyo usingpartner_location_id,partner_location_name, orpartner_location_code.
error-responseNeed the full machine-readable spec? Download the OpenAPI document →
/orders/{orderReference}/fulfillment-orders/mergeMerge fulfillment orders
Combine line items from one fulfillment order into another.
Merge process
Specify:
- Source: the fulfillment order (with specific line items) to merge from.
- Destination: the fulfillment order to merge into.
After merging, source line items move to the destination fulfillment order. If all items are moved, the source fulfillment order is removed. The order status is recalculated and webhooks fire.
Restrictions
The source and destination fulfillment orders:
- ❌ Cannot contain any fulfilled line items; only pending items can be merged.
- ✅ Must share the same
location_id. - ✅ Must share the same
delivery_type(when specified). - ✅ Must share the same delivery method.
- ❌ Cannot mix items where some require shipping and some don't.
Inventory impact
No inventory changes occur during a merge; items are only reorganised between fulfillment orders.
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
| orderReference | string | Yes | The order reference (order_id or partner_order_reference based on the key parameter). |
Query parameters
| Name | Type | Required | Description |
|---|---|---|---|
| key | string | No | Specifies which reference type is being used for the order reference. |
Headers
| Name | Value | Required | Description |
|---|---|---|---|
| Authorization | Bearer YOUR-ACCESS-TOKEN | Yes | OAuth 2.0 bearer token obtained from `POST /oauth/token`. |
| x-api-key | YOUR-API-KEY | Yes | Your tenant's API key, issued in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
| tenant-id | YOUR-TENANT-ID | Yes | Your Carriyo tenant ID, shown in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
| Content-Type | application/json | Yes | Media type of the request body. |
Request body
application/jsonSchema: merge-fulfillment-order-requestrequiredResponses
order- Current status of the order: -
open- Order created, not yet allocated -partially_allocated- Some items allocated to fulfillment locations -allocated- All items allocated to fulfillment locations -processing- One or more fulfillment orders are being processed (picked, packed, shipped or partially fulfilled) -fulfilled- All items have been fulfilled -cancelled- Order has been cancelled -closed- Order is complete and closedValues:openpartially_allocatedallocatedprocessingfulfilledcancelledclosed - The reason for cancellation. Must be one of the following values: -
CUSTOMER_CANCELLATION- Customer requested cancellation -AUTO_ALLOCATION_FAILED- Automatic fulfillment allocation failed -INVENTORY_OUT_OF_STOCK- Items are out of stock -STAFF_ERROR- Staff made an error -PAYMENT_ISSUE- Payment problem occurred -OTHER- Other reasonValues:CUSTOMER_CANCELLATIONAUTO_ALLOCATION_FAILEDINVENTORY_OUT_OF_STOCKSTAFF_ERRORPAYMENT_ISSUEOTHER - Carriyo address object used for customer, billing, delivery and customer-collection addresses. You can either pass a fully free-form address (
contact_name,address1,city,country, etc.) or reference a pre-configured location in Carriyo usingpartner_location_id,partner_location_name, orpartner_location_code.
error-responseNeed the full machine-readable spec? Download the OpenAPI document →
/orders/{orderReference}/fulfillment-orders/{fulfillmentOrderId}/splitSplit fulfillment order
Split selected line items from a fulfillment order into a new fulfillment order. Use it to ship available items immediately while backordered items wait, to fulfill from multiple locations when only partial inventory exists, or to separate items with different shipping requirements.
Line item status requirements
Only items in a pending status can be split:
- ✅
open: can be split. - ✅
allocated: can be split. - ❌
fulfilled,cancelled,closed: cannot be split.
Split process
Specify:
line_items(required): the items and quantities to move to the new FO.location_id(optional): a location for the split items. Defaults to the original FO's location.partner_fulfillment_order_reference(optional): your reference for the new FO.
After splitting, a new fulfillment order is created with a new fulfillment_order_id, inheriting delivery from the original. Split line items get status allocated when a location is set, otherwise open. The original FO's quantities are reduced (items are removed if their quantity reaches 0). The order status is recalculated and webhooks fire.
Inventory impact
No inventory changes occur during a split; items are only reorganised.
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
| orderReference | string | Yes | The order reference (order_id or partner_order_reference based on the key parameter). |
| fulfillmentOrderId | string | Yes | The unique identifier of the fulfillment order to split. |
Query parameters
| Name | Type | Required | Description |
|---|---|---|---|
| key | string | No | Specifies which reference type is being used for the order reference. |
Headers
| Name | Value | Required | Description |
|---|---|---|---|
| Authorization | Bearer YOUR-ACCESS-TOKEN | Yes | OAuth 2.0 bearer token obtained from `POST /oauth/token`. |
| x-api-key | YOUR-API-KEY | Yes | Your tenant's API key, issued in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
| tenant-id | YOUR-TENANT-ID | Yes | Your Carriyo tenant ID, shown in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
| Content-Type | application/json | Yes | Media type of the request body. |
Request body
application/jsonSchema: split-fulfillment-requestrequiredResponses
order- Current status of the order: -
open- Order created, not yet allocated -partially_allocated- Some items allocated to fulfillment locations -allocated- All items allocated to fulfillment locations -processing- One or more fulfillment orders are being processed (picked, packed, shipped or partially fulfilled) -fulfilled- All items have been fulfilled -cancelled- Order has been cancelled -closed- Order is complete and closedValues:openpartially_allocatedallocatedprocessingfulfilledcancelledclosed - The reason for cancellation. Must be one of the following values: -
CUSTOMER_CANCELLATION- Customer requested cancellation -AUTO_ALLOCATION_FAILED- Automatic fulfillment allocation failed -INVENTORY_OUT_OF_STOCK- Items are out of stock -STAFF_ERROR- Staff made an error -PAYMENT_ISSUE- Payment problem occurred -OTHER- Other reasonValues:CUSTOMER_CANCELLATIONAUTO_ALLOCATION_FAILEDINVENTORY_OUT_OF_STOCKSTAFF_ERRORPAYMENT_ISSUEOTHER - Carriyo address object used for customer, billing, delivery and customer-collection addresses. You can either pass a fully free-form address (
contact_name,address1,city,country, etc.) or reference a pre-configured location in Carriyo usingpartner_location_id,partner_location_name, orpartner_location_code.
error-responseNeed the full machine-readable spec? Download the OpenAPI document →
/orders/{orderReference}/fulfillment-orders/{fulfillmentOrderId}/shipShip fulfillment order
Create a shipment for items in a fulfillment order.
Line item status requirements
Items must be in allocated or fulfilled status:
- ✅
allocated: can be shipped. - ✅
fulfilled: can be shipped (as an additional shipment). - ❌
open: must be allocated first. - ❌
cancelled,closed: cannot be shipped.
Request requirements
Provide line_items, the items to ship with their quantities.
Shipping process
When you ship, Carriyo:
- Validates that the requested items are in
allocatedorfulfilledstatus. - Validates that the requested quantities don't exceed available quantities.
- Creates a draft shipment in the Carriyo Shipping API.
- Confirms the shipment with the carrier (unless
create_draft_shipment=true). - Links the shipment ID to the specified line items.
- Fires webhooks.
Shipment configuration
The request mirrors the Shipping API's create-shipment body. You can set the carrier account (or let automation rules decide), parcels, delivery instructions and scheduling, payment details including cash on delivery, and pre-booking information for externally booked shipments.
Draft shipments
Set create_draft_shipment=true to create a draft for review before booking with the carrier.
Inventory impact
No inventory changes occur here; inventory is managed during the fulfill and cancel operations.
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
| orderReference | string | Yes | The order reference (order_id or partner_order_reference based on the key parameter). |
| fulfillmentOrderId | string | Yes | The unique identifier of the fulfillment order. |
Query parameters
| Name | Type | Required | Description |
|---|---|---|---|
| key | string | No | Specifies which reference type is being used for the order reference. |
| create_draft_shipment | boolean | No | If true, creates a draft shipment instead of immediately booking with a carrier. |
Headers
| Name | Value | Required | Description |
|---|---|---|---|
| Authorization | Bearer YOUR-ACCESS-TOKEN | Yes | OAuth 2.0 bearer token obtained from `POST /oauth/token`. |
| x-api-key | YOUR-API-KEY | Yes | Your tenant's API key, issued in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
| tenant-id | YOUR-TENANT-ID | Yes | Your Carriyo tenant ID, shown in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
| Content-Type | application/json | Yes | Media type of the request body. |
Request body
application/jsonSchema: ship-fo-line-items-requestResponses
order- Current status of the order: -
open- Order created, not yet allocated -partially_allocated- Some items allocated to fulfillment locations -allocated- All items allocated to fulfillment locations -processing- One or more fulfillment orders are being processed (picked, packed, shipped or partially fulfilled) -fulfilled- All items have been fulfilled -cancelled- Order has been cancelled -closed- Order is complete and closedValues:openpartially_allocatedallocatedprocessingfulfilledcancelledclosed - The reason for cancellation. Must be one of the following values: -
CUSTOMER_CANCELLATION- Customer requested cancellation -AUTO_ALLOCATION_FAILED- Automatic fulfillment allocation failed -INVENTORY_OUT_OF_STOCK- Items are out of stock -STAFF_ERROR- Staff made an error -PAYMENT_ISSUE- Payment problem occurred -OTHER- Other reasonValues:CUSTOMER_CANCELLATIONAUTO_ALLOCATION_FAILEDINVENTORY_OUT_OF_STOCKSTAFF_ERRORPAYMENT_ISSUEOTHER - Carriyo address object used for customer, billing, delivery and customer-collection addresses. You can either pass a fully free-form address (
contact_name,address1,city,country, etc.) or reference a pre-configured location in Carriyo usingpartner_location_id,partner_location_name, orpartner_location_code.
error-responseNeed the full machine-readable spec? Download the OpenAPI document →
/orders/{orderReference}/fulfillment-orders/{fulfillmentOrderId}/update-locationUpdate fulfillment order location
Reassign a fulfillment order to a different location, for example to a location with available inventory or one closer to the customer.
Request requirements
Provide location_id, the new location's ID or code.
Location resolution
The value is resolved first by partner_location_id, then, if not found, by location_code for the merchant.
Effects
The fulfillment order's location_id is updated, the order status is recalculated, and webhooks fire.
Inventory impact
No inventory changes occur during a location update. Manage inventory reservations across the location change separately through the Inventory API if you need to.
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
| orderReference | string | Yes | The order reference (order_id or partner_order_reference based on the key parameter). |
| fulfillmentOrderId | string | Yes | The unique identifier of the fulfillment order. |
Query parameters
| Name | Type | Required | Description |
|---|---|---|---|
| key | string | No | Specifies which reference type is being used for the order reference. |
Headers
| Name | Value | Required | Description |
|---|---|---|---|
| Authorization | Bearer YOUR-ACCESS-TOKEN | Yes | OAuth 2.0 bearer token obtained from `POST /oauth/token`. |
| x-api-key | YOUR-API-KEY | Yes | Your tenant's API key, issued in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
| tenant-id | YOUR-TENANT-ID | Yes | Your Carriyo tenant ID, shown in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
| Content-Type | application/json | Yes | Media type of the request body. |
Request body
application/jsonSchema: update-location-requestrequiredResponses
order- Current status of the order: -
open- Order created, not yet allocated -partially_allocated- Some items allocated to fulfillment locations -allocated- All items allocated to fulfillment locations -processing- One or more fulfillment orders are being processed (picked, packed, shipped or partially fulfilled) -fulfilled- All items have been fulfilled -cancelled- Order has been cancelled -closed- Order is complete and closedValues:openpartially_allocatedallocatedprocessingfulfilledcancelledclosed - The reason for cancellation. Must be one of the following values: -
CUSTOMER_CANCELLATION- Customer requested cancellation -AUTO_ALLOCATION_FAILED- Automatic fulfillment allocation failed -INVENTORY_OUT_OF_STOCK- Items are out of stock -STAFF_ERROR- Staff made an error -PAYMENT_ISSUE- Payment problem occurred -OTHER- Other reasonValues:CUSTOMER_CANCELLATIONAUTO_ALLOCATION_FAILEDINVENTORY_OUT_OF_STOCKSTAFF_ERRORPAYMENT_ISSUEOTHER - Carriyo address object used for customer, billing, delivery and customer-collection addresses. You can either pass a fully free-form address (
contact_name,address1,city,country, etc.) or reference a pre-configured location in Carriyo usingpartner_location_id,partner_location_name, orpartner_location_code.
error-responseNeed the full machine-readable spec? Download the OpenAPI document →
/orders/{orderReference}/fulfillment-orders/{fulfillmentOrderId}/update-delivery-methodUpdate fulfillment order delivery method
Switches the delivery method of a fulfillment order between DELIVERY, COLLECTION, and DIGITAL, and updates the corresponding address and schedule in a single call.
Behaviour
Depending on the new delivery_method, the request body fields are interpreted as follows:
New delivery_method |
address is set as |
scheduled_from/scheduled_to are set as |
|---|---|---|
DELIVERY |
delivery_address |
delivery_schedule |
COLLECTION |
customer_collection_address |
customer_collection_schedule |
DIGITAL |
not used | not used |
Switching to a new delivery method clears the address and schedule fields associated with the previous method.
Use cases
- Convert an online order from home delivery to a click-and-collect pickup at a store.
- Switch a fulfillment order from
COLLECTIONback toDELIVERYif the customer changes their mind. - Mark a fulfillment order as
DIGITALwhen no physical delivery is required.
Constraints
This endpoint cannot be called on fulfillment orders that have already started processing (e.g., shipments created, items fulfilled). Use unfulfill or cancel flows first if you need to change the method on an in-progress FO.
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
| orderReference | string | Yes | The order reference (order_id or partner_order_reference based on the key parameter). |
| fulfillmentOrderId | string | Yes | The unique identifier of the fulfillment order. |
Query parameters
| Name | Type | Required | Description |
|---|---|---|---|
| key | string | No | Specifies which reference type is being used for the order reference. |
Headers
| Name | Value | Required | Description |
|---|---|---|---|
| Authorization | Bearer YOUR-ACCESS-TOKEN | Yes | OAuth 2.0 bearer token obtained from `POST /oauth/token`. |
| x-api-key | YOUR-API-KEY | Yes | Your tenant's API key, issued in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
| tenant-id | YOUR-TENANT-ID | Yes | Your Carriyo tenant ID, shown in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
| Content-Type | application/json | Yes | Media type of the request body. |
Request body
application/jsonSchema: update-fulfillment-order-delivery-method-requestrequired- How the order is delivered to the customer: -
DELIVERY: standard delivery to the customer's address (usesdelivery_addressanddelivery_schedule). -COLLECTION: customer collects the order from a specified location (usescustomer_collection_addressandcustomer_collection_schedule). -DIGITAL: no physical delivery; the order is fulfilled digitally.Values:DELIVERYCOLLECTIONDIGITAL
Responses
order- Current status of the order: -
open- Order created, not yet allocated -partially_allocated- Some items allocated to fulfillment locations -allocated- All items allocated to fulfillment locations -processing- One or more fulfillment orders are being processed (picked, packed, shipped or partially fulfilled) -fulfilled- All items have been fulfilled -cancelled- Order has been cancelled -closed- Order is complete and closedValues:openpartially_allocatedallocatedprocessingfulfilledcancelledclosed - The reason for cancellation. Must be one of the following values: -
CUSTOMER_CANCELLATION- Customer requested cancellation -AUTO_ALLOCATION_FAILED- Automatic fulfillment allocation failed -INVENTORY_OUT_OF_STOCK- Items are out of stock -STAFF_ERROR- Staff made an error -PAYMENT_ISSUE- Payment problem occurred -OTHER- Other reasonValues:CUSTOMER_CANCELLATIONAUTO_ALLOCATION_FAILEDINVENTORY_OUT_OF_STOCKSTAFF_ERRORPAYMENT_ISSUEOTHER - Carriyo address object used for customer, billing, delivery and customer-collection addresses. You can either pass a fully free-form address (
contact_name,address1,city,country, etc.) or reference a pre-configured location in Carriyo usingpartner_location_id,partner_location_name, orpartner_location_code.
error-responseNeed the full machine-readable spec? Download the OpenAPI document →
/orders/{orderReference}/fulfillment-orders/{fulfillmentOrderId}/update-addressUpdate fulfillment order address
Updates the address on the fulfillment order according to its current delivery_method:
delivery_method |
address updates |
|---|---|
DELIVERY |
delivery_address |
COLLECTION |
customer_collection_address |
Use Update Delivery Method first if you need to switch between delivery and collection before setting the correct address type.
Not applicable when delivery_method is DIGITAL.
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
| orderReference | string | Yes | The order reference (order_id or partner_order_reference based on the key parameter). |
| fulfillmentOrderId | string | Yes | The unique identifier of the fulfillment order. |
Query parameters
| Name | Type | Required | Description |
|---|---|---|---|
| key | string | No | Specifies which reference type is being used for the order reference. |
Headers
| Name | Value | Required | Description |
|---|---|---|---|
| Authorization | Bearer YOUR-ACCESS-TOKEN | Yes | OAuth 2.0 bearer token obtained from `POST /oauth/token`. |
| x-api-key | YOUR-API-KEY | Yes | Your tenant's API key, issued in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
| tenant-id | YOUR-TENANT-ID | Yes | Your Carriyo tenant ID, shown in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
| Content-Type | application/json | Yes | Media type of the request body. |
Request body
application/jsonSchema: update-fulfillment-order-address-requestrequiredResponses
order- Current status of the order: -
open- Order created, not yet allocated -partially_allocated- Some items allocated to fulfillment locations -allocated- All items allocated to fulfillment locations -processing- One or more fulfillment orders are being processed (picked, packed, shipped or partially fulfilled) -fulfilled- All items have been fulfilled -cancelled- Order has been cancelled -closed- Order is complete and closedValues:openpartially_allocatedallocatedprocessingfulfilledcancelledclosed - The reason for cancellation. Must be one of the following values: -
CUSTOMER_CANCELLATION- Customer requested cancellation -AUTO_ALLOCATION_FAILED- Automatic fulfillment allocation failed -INVENTORY_OUT_OF_STOCK- Items are out of stock -STAFF_ERROR- Staff made an error -PAYMENT_ISSUE- Payment problem occurred -OTHER- Other reasonValues:CUSTOMER_CANCELLATIONAUTO_ALLOCATION_FAILEDINVENTORY_OUT_OF_STOCKSTAFF_ERRORPAYMENT_ISSUEOTHER - Carriyo address object used for customer, billing, delivery and customer-collection addresses. You can either pass a fully free-form address (
contact_name,address1,city,country, etc.) or reference a pre-configured location in Carriyo usingpartner_location_id,partner_location_name, orpartner_location_code.
error-responseNeed the full machine-readable spec? Download the OpenAPI document →
/orders/{orderReference}/fulfillment-orders/{fulfillmentOrderId}/update-scheduleUpdate fulfillment order schedule
Update the delivery schedule window for a fulfillment order, for example when the customer changes their preferred window or a missed delivery needs rescheduling.
Replaces the FO's scheduled_from and scheduled_to, then fires webhooks.
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
| orderReference | string | Yes | The order reference (order_id or partner_order_reference based on the key parameter). |
| fulfillmentOrderId | string | Yes | The unique identifier of the fulfillment order. |
Query parameters
| Name | Type | Required | Description |
|---|---|---|---|
| key | string | No | Specifies which reference type is being used for the order reference. |
Headers
| Name | Value | Required | Description |
|---|---|---|---|
| Authorization | Bearer YOUR-ACCESS-TOKEN | Yes | OAuth 2.0 bearer token obtained from `POST /oauth/token`. |
| x-api-key | YOUR-API-KEY | Yes | Your tenant's API key, issued in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
| tenant-id | YOUR-TENANT-ID | Yes | Your Carriyo tenant ID, shown in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
| Content-Type | application/json | Yes | Media type of the request body. |
Request body
application/jsonSchema: update-fulfillment-order-schedule-requestrequiredResponses
order- Current status of the order: -
open- Order created, not yet allocated -partially_allocated- Some items allocated to fulfillment locations -allocated- All items allocated to fulfillment locations -processing- One or more fulfillment orders are being processed (picked, packed, shipped or partially fulfilled) -fulfilled- All items have been fulfilled -cancelled- Order has been cancelled -closed- Order is complete and closedValues:openpartially_allocatedallocatedprocessingfulfilledcancelledclosed - The reason for cancellation. Must be one of the following values: -
CUSTOMER_CANCELLATION- Customer requested cancellation -AUTO_ALLOCATION_FAILED- Automatic fulfillment allocation failed -INVENTORY_OUT_OF_STOCK- Items are out of stock -STAFF_ERROR- Staff made an error -PAYMENT_ISSUE- Payment problem occurred -OTHER- Other reasonValues:CUSTOMER_CANCELLATIONAUTO_ALLOCATION_FAILEDINVENTORY_OUT_OF_STOCKSTAFF_ERRORPAYMENT_ISSUEOTHER - Carriyo address object used for customer, billing, delivery and customer-collection addresses. You can either pass a fully free-form address (
contact_name,address1,city,country, etc.) or reference a pre-configured location in Carriyo usingpartner_location_id,partner_location_name, orpartner_location_code.
error-responseNeed the full machine-readable spec? Download the OpenAPI document →
/orders/{orderReference}/fulfillment-orders/{fulfillmentOrderId}/update-partner-referencesUpdate fulfillment order partner references
Update partner references on a fulfillment order or its individual fulfillments.
Updatable fields
Provide one of the following per request:
partner_fulfillment_order_reference: your external reference for the FO.fulfillments: an array of{ fulfillment_id, partner_fulfillment_reference }pairs that set references on already-fulfilled line items.
If both are present, only partner_fulfillment_order_reference is applied.
Constraints
The fulfillment order must not have active picks. This endpoint only updates reference fields and makes no inventory changes.
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
| orderReference | string | Yes | The order reference (order_id or partner_order_reference based on the key parameter). |
| fulfillmentOrderId | string | Yes | The unique identifier of the fulfillment order. |
Query parameters
| Name | Type | Required | Description |
|---|---|---|---|
| key | string | No | Specifies which reference type is being used for the order reference. |
Headers
| Name | Value | Required | Description |
|---|---|---|---|
| Authorization | Bearer YOUR-ACCESS-TOKEN | Yes | OAuth 2.0 bearer token obtained from `POST /oauth/token`. |
| x-api-key | YOUR-API-KEY | Yes | Your tenant's API key, issued in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
| tenant-id | YOUR-TENANT-ID | Yes | Your Carriyo tenant ID, shown in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
| Content-Type | application/json | Yes | Media type of the request body. |
Request body
application/jsonSchema: update-fulfillment-order-partner-references-requestrequiredResponses
order- Current status of the order: -
open- Order created, not yet allocated -partially_allocated- Some items allocated to fulfillment locations -allocated- All items allocated to fulfillment locations -processing- One or more fulfillment orders are being processed (picked, packed, shipped or partially fulfilled) -fulfilled- All items have been fulfilled -cancelled- Order has been cancelled -closed- Order is complete and closedValues:openpartially_allocatedallocatedprocessingfulfilledcancelledclosed - The reason for cancellation. Must be one of the following values: -
CUSTOMER_CANCELLATION- Customer requested cancellation -AUTO_ALLOCATION_FAILED- Automatic fulfillment allocation failed -INVENTORY_OUT_OF_STOCK- Items are out of stock -STAFF_ERROR- Staff made an error -PAYMENT_ISSUE- Payment problem occurred -OTHER- Other reasonValues:CUSTOMER_CANCELLATIONAUTO_ALLOCATION_FAILEDINVENTORY_OUT_OF_STOCKSTAFF_ERRORPAYMENT_ISSUEOTHER - Carriyo address object used for customer, billing, delivery and customer-collection addresses. You can either pass a fully free-form address (
contact_name,address1,city,country, etc.) or reference a pre-configured location in Carriyo usingpartner_location_id,partner_location_name, orpartner_location_code.
error-responseNeed the full machine-readable spec? Download the OpenAPI document →
/orders/{orderReference}/fulfillment-orders/{fulfillmentOrderId}/cancelCancel fulfillment order line items
Cancel specific line items within a fulfillment order.
Line item status requirements
Only items in a pending status can be cancelled:
- ✅
open: can be cancelled. - ✅
allocated: can be cancelled. - ❌
fulfilled: cannot be cancelled directly; unfulfill it first. - ❌
cancelled: already cancelled. - ❌
closed: cannot be cancelled.
Request requirements
Both fields are required:
cancellation_reason: one of the values below.line_items: the items to cancel, with quantities.
Cancellation reason values
CUSTOMER_CANCELLATION: customer requested cancellation.AUTO_ALLOCATION_FAILED: automatic fulfillment allocation failed.INVENTORY_OUT_OF_STOCK: items are out of stock.STAFF_ERROR: staff made an error.PAYMENT_ISSUE: a payment problem occurred.OTHER: any other reason.
Cancellation effects
When items are cancelled, Carriyo updates each item's status to cancelled with the reason, updates the order line item's removed_quantities, recalculates the order status, and fires webhooks.
Inventory impact
If inventory management is enabled and the FO has a location_id, reserved is decreased by the cancelled quantity, releasing the reserved stock.
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
| orderReference | string | Yes | The order reference (order_id or partner_order_reference based on the key parameter). |
| fulfillmentOrderId | string | Yes | The unique identifier of the fulfillment order. |
Query parameters
| Name | Type | Required | Description |
|---|---|---|---|
| key | string | No | Specifies which reference type is being used for the order reference. |
Headers
| Name | Value | Required | Description |
|---|---|---|---|
| Authorization | Bearer YOUR-ACCESS-TOKEN | Yes | OAuth 2.0 bearer token obtained from `POST /oauth/token`. |
| x-api-key | YOUR-API-KEY | Yes | Your tenant's API key, issued in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
| tenant-id | YOUR-TENANT-ID | Yes | Your Carriyo tenant ID, shown in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
| Content-Type | application/json | Yes | Media type of the request body. |
Request body
application/jsonSchema: cancel-fo-line-items-request- The reason for cancellation. Must be one of the following values: -
CUSTOMER_CANCELLATION- Customer requested cancellation -AUTO_ALLOCATION_FAILED- Automatic fulfillment allocation failed -INVENTORY_OUT_OF_STOCK- Items are out of stock -STAFF_ERROR- Staff made an error -PAYMENT_ISSUE- Payment problem occurred -OTHER- Other reasonValues:CUSTOMER_CANCELLATIONAUTO_ALLOCATION_FAILEDINVENTORY_OUT_OF_STOCKSTAFF_ERRORPAYMENT_ISSUEOTHER
Responses
order- Current status of the order: -
open- Order created, not yet allocated -partially_allocated- Some items allocated to fulfillment locations -allocated- All items allocated to fulfillment locations -processing- One or more fulfillment orders are being processed (picked, packed, shipped or partially fulfilled) -fulfilled- All items have been fulfilled -cancelled- Order has been cancelled -closed- Order is complete and closedValues:openpartially_allocatedallocatedprocessingfulfilledcancelledclosed - The reason for cancellation. Must be one of the following values: -
CUSTOMER_CANCELLATION- Customer requested cancellation -AUTO_ALLOCATION_FAILED- Automatic fulfillment allocation failed -INVENTORY_OUT_OF_STOCK- Items are out of stock -STAFF_ERROR- Staff made an error -PAYMENT_ISSUE- Payment problem occurred -OTHER- Other reasonValues:CUSTOMER_CANCELLATIONAUTO_ALLOCATION_FAILEDINVENTORY_OUT_OF_STOCKSTAFF_ERRORPAYMENT_ISSUEOTHER - Carriyo address object used for customer, billing, delivery and customer-collection addresses. You can either pass a fully free-form address (
contact_name,address1,city,country, etc.) or reference a pre-configured location in Carriyo usingpartner_location_id,partner_location_name, orpartner_location_code.
error-responseNeed the full machine-readable spec? Download the OpenAPI document →
Order Allocation Rules
Order allocation rules determine how orders are routed to fulfillment locations based on order attributes and constraints.
6 operations · 0 objects
/order-allocation-rulesCreate order allocation rule
Create an order allocation rule. Allocation rules determine how an order is split into one or more fulfillment orders across your fulfillment locations. New rules are ordered by sequence; use Update rule sequence to set their evaluation priority.
Headers
| Name | Value | Required | Description |
|---|---|---|---|
| Authorization | Bearer YOUR-ACCESS-TOKEN | Yes | OAuth 2.0 bearer token obtained from `POST /oauth/token`. |
| x-api-key | YOUR-API-KEY | Yes | Your tenant's API key, issued in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
| tenant-id | YOUR-TENANT-ID | Yes | Your Carriyo tenant ID, shown in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
| Content-Type | application/json | Yes | Media type of the request body. |
Request body
application/jsonrequiredResponses
Need the full machine-readable spec? Download the OpenAPI document →
/order-allocation-rulesList order allocation rules
List the order allocation rules configured for the merchant, ordered by evaluation priority (sequence).
Headers
| Name | Value | Required | Description |
|---|---|---|---|
| Authorization | Bearer YOUR-ACCESS-TOKEN | Yes | OAuth 2.0 bearer token obtained from `POST /oauth/token`. |
| x-api-key | YOUR-API-KEY | Yes | Your tenant's API key, issued in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
| tenant-id | YOUR-TENANT-ID | Yes | Your Carriyo tenant ID, shown in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
Responses
Need the full machine-readable spec? Download the OpenAPI document →
/order-allocation-rules/{rule_id}Get order allocation rule
Return a single order allocation rule by its rule_id.
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
| rule_id | string | Yes | Allocation rule ID. |
Headers
| Name | Value | Required | Description |
|---|---|---|---|
| Authorization | Bearer YOUR-ACCESS-TOKEN | Yes | OAuth 2.0 bearer token obtained from `POST /oauth/token`. |
| x-api-key | YOUR-API-KEY | Yes | Your tenant's API key, issued in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
| tenant-id | YOUR-TENANT-ID | Yes | Your Carriyo tenant ID, shown in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
Responses
Need the full machine-readable spec? Download the OpenAPI document →
/order-allocation-rules/{rule_id}Update order allocation rule
Replace an order allocation rule. The request body fully replaces the existing rule; fields you omit are reset to defaults. The rule's evaluation priority is managed separately via Update rule sequence.
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
| rule_id | string | Yes | Allocation rule ID. |
Headers
| Name | Value | Required | Description |
|---|---|---|---|
| Authorization | Bearer YOUR-ACCESS-TOKEN | Yes | OAuth 2.0 bearer token obtained from `POST /oauth/token`. |
| x-api-key | YOUR-API-KEY | Yes | Your tenant's API key, issued in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
| tenant-id | YOUR-TENANT-ID | Yes | Your Carriyo tenant ID, shown in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
| Content-Type | application/json | Yes | Media type of the request body. |
Request body
application/jsonrequiredResponses
Need the full machine-readable spec? Download the OpenAPI document →
/order-allocation-rules/{rule_id}Delete order allocation rule
Delete an order allocation rule. Orders that would have matched this rule fall through to the next matching rule in evaluation order.
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
| rule_id | string | Yes | Allocation rule ID. |
Headers
| Name | Value | Required | Description |
|---|---|---|---|
| Authorization | Bearer YOUR-ACCESS-TOKEN | Yes | OAuth 2.0 bearer token obtained from `POST /oauth/token`. |
| x-api-key | YOUR-API-KEY | Yes | Your tenant's API key, issued in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
| tenant-id | YOUR-TENANT-ID | Yes | Your Carriyo tenant ID, shown in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
Responses
Need the full machine-readable spec? Download the OpenAPI document →
/order-allocation-rules/sequencesUpdate rule sequence
Set the priority order in which allocation rules are evaluated. Carriyo evaluates rules in this order when splitting an order into fulfillment orders.
Headers
| Name | Value | Required | Description |
|---|---|---|---|
| Authorization | Bearer YOUR-ACCESS-TOKEN | Yes | OAuth 2.0 bearer token obtained from `POST /oauth/token`. |
| x-api-key | YOUR-API-KEY | Yes | Your tenant's API key, issued in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
| tenant-id | YOUR-TENANT-ID | Yes | Your Carriyo tenant ID, shown in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
| Content-Type | application/json | Yes | Media type of the request body. |
Request body
application/jsonrequiredResponses
Need the full machine-readable spec? Download the OpenAPI document →