comecerodocs
Settings reference

Shipping by quantity

Price a shipping method by the number of physical items in the order, with a price per item and flat prices for quantity ranges, in one or more currencies.

A shipping method priced by quantity charges by the total number of physical items in the order. Set it up in the dashboard under Store > Shipping Methods, or with quantity_config in Create a shipping method.

How the price is worked out

  1. Comecero adds up the quantities of the physical items. Digital items and services do not count. It is the total quantity, not the number of lines: 1 of product A and 2 of product B is a quantity of 3.
  2. If that quantity falls in one of your ranges (rules), the price is that range's flat price.
  3. Otherwise the price is the price per quantity (prices_per_quantity) times the quantity.

With no ranges, the price is always the price per quantity times the quantity.

{
  "description": "Standard Shipping",
  "countries": ["US"],
  "quantity_config": {
    "prices_per_quantity": [{ "price": 5, "currency": "USD" }],
    "rules": [
      { "minimum": 1, "maximum": 5, "prices": [{ "price": 15, "currency": "USD" }] },
      { "minimum": 6, "maximum": 10, "prices": [{ "price": 25, "currency": "USD" }] }
    ]
  }
}
Total quantityPriceWhy
3$15In the 1 to 5 range
8$25In the 6 to 10 range
11$55In no range: $5 x 11

Ranges

  • Ranges must not overlap. A range that starts where another ends, such as 1 to 5 and 5 to 10, is refused.
  • List them from lowest to highest. When saved, the lowest range starts at 1 and a gap is closed by moving the next range's minimum to the previous maximum plus 1.
  • Add as many ranges as you need.

Currencies

Give the price per quantity, and each range's price, in one or more currencies. Each currency may appear once in a list. When the shopper pays in a currency you gave, that price is used. Otherwise the first price in the list is converted to the shopper's currency with your pricing settings' exchange rates and rounding.

After the price is found, any adjustment for the shopper's state or province is applied, then tax and shipping promotions.

On this page