Shipping Options in the Order Automations

The platform supports three advanced shipping options that control how orders are split, routed, and shipped. These options are designed to prevent incorrect partial shipments, handle oversized items correctly, and ensure inventory is sourced from the right warehouse.

The three shipping options are:

  • Ship in Its Own Container (SIOC): value SIOC
  • All or Nothing: value allOrNoneShipping
  • Single Location: value singleLocationShipping

All three options are:

  • Set per line item, in the line item's shippingOptions list.
  • Added by an order automation, before the order is routed.
  • Applied by the order routing engine when it routes the order.

You can't set these options on the order page or in routing rules. Use an automation on the New Orders tab, with either the Update Order Property action (no code) or the Update Order by Code (JavaScript) action. See Adding shipping options with automations below.

The shippingOptions list can also hold packing values, such as polyBagging. This article covers only the three routing options.


Ship in Its Own Container (SIOC)

What SIOC does

Ship in Its Own Container (SIOC) ensures that a line item is shipped by itself and is not combined with any other items in the same shipment.

This option is commonly used for large or oversized products that already have their own packaging and cannot be boxed with other items.

How SIOC works

When a line item is marked as SIOC:

  • The order routing engine creates a separate shipping request (SR) for each unit on that line. If the quantity on the line is 2, the engine creates two shipping requests.
  • No other line items are included in those shipping requests.
  • Items without SIOC that ship from the same location are grouped into one shipping request.

Example:

  • An order contains five line items, each with quantity 1.
  • Two line items are marked as SIOC.
  • All five items ship from the same location.
  • Result:
    • One SR for SIOC item #1
    • One SR for SIOC item #2
    • One SR for the remaining three items

How to configure SIOC

Add SIOC to the line item's shippingOptions list with an automation, before the order is routed.

Common ways to decide which line items get SIOC:

  • A list of SIOC SKUs in the automation rule. This works best for a small number of SKUs.
  • Line item data, such as a custom field that your sales channel sends.
  • Product data from the product catalog, such as custom fields or tags. Use the products evaluation dependency in a code action to read it.

All or Nothing Shipping

What All or Nothing does

All or Nothing prevents a line item from being partially shipped. The engine routes the line only when it can route the full quantity.

All or Nothing works on each line item by itself. It doesn't link line items to each other. To make several line items ship together or not at all, put them in the same shipping group. See Ship several line items together below.

Common use case

A customer orders:

  • One table
  • Six chairs
  • Other items, such as a table runner or plates

Desired behavior:

  • The table and all six chairs ship only if all of them are available.
  • The chairs don't ship without the table.
  • Two chairs don't ship while the other four are out of stock.
  • The other items ship on their own when available.

To get this behavior:

  • Set All or Nothing on the chairs line, so the chairs never ship partially.
  • Put the table line and the chairs line in the same shipping group, so neither ships without the other.
  • Leave the other items without these settings.

How All or Nothing works

For each line item with All or Nothing:

  • The engine adds up the available inventory for that SKU across the locations in the routing rule.
  • If the total is less than the line's quantity, the engine doesn't route the line. The order waits for inventory and is retried later.
  • If the total is enough, the engine routes the line. If the routing rule allows split orders, the line can still be split across locations. To keep it at one location, also set Single Location on the line.

Line items without All or Nothing route as usual.

How to configure All or Nothing

Add allOrNoneShipping to the shippingOptions list of each line item that must not ship partially.


Single Location Shipping

What Single Location does

Single Location makes a line item ship from one warehouse location. The engine never splits that line across locations.

Why Single Location matters

All or Nothing checks that enough inventory exists, but that inventory can be spread across several warehouses. Without Single Location, the line could ship from more than one location.

This can result in:

  • Multiple shipments
  • Increased shipping costs
  • Operational complexity

How Single Location works

When Single Location is set on a line item:

  • The engine routes the line only to a location that has the full quantity available.
  • If no single location has the full quantity, the line isn't routed and no shipment is created for it.

Example:

  • Six chairs are available, but split across three warehouses.
  • Single Location is set on the chairs line.
  • Result: the chairs are not shipped.

When several line items in the same shipping group have Single Location, the group routes only if at least one location has enough inventory for all of them. To keep these line items in one shipment, leave Allow split orders off in the routing rule that routes them.

How to configure Single Location

Add singleLocationShipping to the same shippingOptions list. It's often set on the same line items as All or Nothing, so both availability and location are enforced.


Ship several line items together

To make several line items ship together or not at all, set the same number in the shippingGroup field of each of those line items, for example 1. Use a different number for each group on the order.

  • If every line item in the group can be routed, the group ships.
  • If any line item in the group can't be routed, none of the group ships. The order waits for inventory and is retried later.
  • Line items without a shipping group route as usual, even if a group fails.

You can set shippingGroup only with the Update Order by Code (JavaScript) action.


Adding shipping options with automations

Set shipping options with an automation on the New Orders tab. New Order automations run after the order is pulled into the app and before it's routed.

Steps

  1. Navigate to Automations > Orders, and then select the New Orders tab.
  2. Click New rule.
  3. Enter a Name and Description that explain what the rule does.
  4. (Optional) Add a filter if the rule should only apply to some orders, for example orders from one sales channel.
  5. Add an action. Choose one of these:
    • Update Order Property (no code): select Line Items as the property and Update items as the operation. Choose which line items to update, then add an update for Shipping Options with Add items and select the values, for example SIOC.
    • Update Order by Code (JavaScript): write code that adds the values to each line item's shippingOptions list. See the example below. Set Abort on error according to your operational requirements.
  6. Use the Test code button to check that a code action runs successfully against a sample order.
  7. Click Save.

New Order automations run only the first rule that matches an order. Place this rule above other New Order rules that match the same orders, or add the action to that rule instead.

Don't add an action that changes the order status, such as Set order to Draft. A draft order isn't routed, so the shipping options are never used.

Add an Evaluation Dependency only if your code needs related data, for example products to read product fields. The example below doesn't need one.

Example: set SIOC based on a line item custom field.

order.lineItems?.forEach(lineItem => {
  const isSioc = lineItem.customFields?.some(
    customField => customField.name === 'productoption' && customField.value === 'sioc'
  );
  if (isSioc) {
    const options = lineItem.shippingOptions || [];
    if (!options.includes('SIOC')) {
      lineItem.shippingOptions = [...options, 'SIOC'];
    }
  }
});
return order;

How this example works:

  • The code loops through all line items on the order.
  • It checks each line item's custom fields.
  • If a custom field named productoption has the value sioc, the code adds SIOC to the line item's shippingOptions list. It keeps any options already on the line.
  • The updated order is returned, and the routing engine reads the options when it routes the order.

The values are case-sensitive. Use SIOC, allOrNoneShipping, and singleLocationShipping exactly as written. To set a shipping group in the same code, add a line such as lineItem.shippingGroup = 1; to each line item in the group.


Important implementation notes

  • Shipping options are set on each line item of the order, not in routing rules.
  • Options must be set before routing begins, so use a New Order automation.
  • All or Nothing and Single Location work per line item. Use a shipping group to tie several line items together.

Troubleshooting

  • SIOC items are shipping with other products
    Check that the line item's shippingOptions list contains SIOC in uppercase. A field named shippingOption or the value sioc is ignored. Also check that the rule runs on the New Orders tab and is the first rule that matches the order.
  • Items that should ship together are shipping separately
    All or Nothing doesn't link line items. Give the line items the same shippingGroup number.
  • An All or Nothing line ships from two locations
    The routing rule allows split orders, so the full quantity was split across locations. Also set Single Location on the line, or leave Allow split orders off in the routing rule.
  • Items are not shipping despite being in stock
    Single Location may be set and no one location has the full quantity, or another line item in the same shipping group can't be routed. Check the order's routing run to see which line item couldn't be routed.

Need Help?

If you need additional assistance:

  • Use Ask Pippen, our AI agent, located at the top of the platform page.
  • Submit a support request with as much relevant detail as possible. Learn how to submit a request.

We're here to help you succeed with your operations.

Was this article helpful?
0 out of 0 found this helpful

Comments

0 comments

Article is closed for comments.

Have more questions?
Submit a request
Share it, if you like it.