# Shipping & Delivery

> Set shipping zones and rates, offer store pickup, ship orders with Aramex or any carrier, collect cash on delivery, and keep customers updated.

Shipping covers everything after the shopper clicks **Check out**: what delivery costs, how you send the parcel, how the customer tracks it, and which emails they get on the way.

Shipping settings live in **Commerce → Settings → Shipping**. You need the `commerce.manage` permission to change them.

## Shipping zones

A zone is a place you deliver to, with its own rates. When a shopper enters an address, the most specific zone answers:

1. a zone that lists the shopper's **city**;
2. then a zone that lists their **country**;
3. then a zone with no countries, which covers **everywhere else**.

Only one zone answers per address. If shipping is set up and no zone covers the address, checkout refuses the order with "We don't deliver to this address yet".

To add a zone:

1. Under **Shipping zones**, click **Add zone**.
2. Enter a **Name**, such as "Jordan" or "Everywhere else".
3. Pick **Countries**. Leave it empty for every country no other zone covers.
4. Optionally enter **Cities**, separated by commas, to narrow the zone. Cities only work in a zone with one country.
5. Save, then add the zone's rates.

City names match in English or Arabic, whatever the spelling: a zone for "Amman" also covers a shopper whose address says "عمّان", "amman" or "Amman, Jordan". The main cities of Jordan, the Gulf, Egypt, Iraq, Lebanon, Palestine and Morocco are known in both languages. For other cities, the spelling has to match, apart from upper and lower case.

### What shoppers see

Checkout only offers the countries your zones deliver to. If you have a zone for everywhere else, or no zones yet, every country is offered.

In a country where a zone lists cities, shoppers pick their **City** from a list instead of typing it. The list shows the city names in the shopper's language. If other cities in that country are delivered too (by a zone for the whole country, or for everywhere else), the list ends with **Other city**, where they type the name. If not, only your cities can be picked.

A zone without rates shows **No rates yet: customers in this zone can't get delivery.** It doesn't count when checkout works out which countries and cities to offer. Deleting a zone deletes its rates too. Orders that already used a rate keep their shipping cost.

## Shipping rates

Click **Add rate** on a zone. Amounts are in your store's currency.

| Field | What it does |
|---|---|
| **Type** | **Shipping** (sent with a carrier or courier) or **Local delivery** (your own drivers, within the zone) |
| **Name** | What the shopper sees, such as "Standard" |
| **Price** | What delivery costs |
| **Offered for** | **Every order**, **Orders within an amount** (from / up to), or **Orders within a weight** (from / up to, in kg) |
| **Free when the order is at least** | Optional. The rate becomes free over this amount. |
| **Delivery from (days)** / **Delivery up to (days)** | Optional delivery estimate |
| **Note for the customer** | Optional |

The shopper sees every rate of their zone that fits the order. Weight-based rates use the products' weights. If any product has no weight, weight-based rates are skipped for that order.

When your store sells in several [markets](https://workstation.repzo.com/docs/online-store/markets), rates in the store currency are converted to the shopper's currency.

## Store pickup

Under **Store pickup**, click **Add pickup point** to let customers collect their order from one of your locations:

- **Location**: one of your locations. Add locations in **Settings → Locations** first.
- **Name** and **Pickup instructions**, such as "Ready within 2 hours. Bring your order number."

Pickup points are offered wherever the shopper is. A pickup point only shows when its location has the whole order in stock, and a pickup order takes its stock from that location.

## Carriers: Aramex

Under **Carriers**, click **Connect** next to **Aramex** to book shipments, print labels, and track parcels from the order. Fill in your Aramex API account:

- **Account number**, **Account PIN**, **Entity code** (for example AMM), and **Account country**;
- **API user name** and **API password**;
- **Environment**: **Live** (real shipments, billed to your Aramex account) or **Test** (Aramex's test environment);
- under **Advanced**: **Domestic product**, **International product**, and **Label layout ID**. Label 9201 is A4; 9729 is a 4×6 thermal label.

Workstation checks the details with Aramex before saving. The password and PIN are stored encrypted. [Sandboxes](https://workstation.repzo.com/docs/administration/sandboxes) can't connect Aramex.

**Disconnect** stops tracking updates and new Aramex bookings. Shipments already booked keep their labels and tracking numbers.

Any other carrier works too. Add its tracking number when you ship.

## Ship an order

Open an order and click **Ship items** on the **Shipments** card.

1. Under **How are you shipping?**, pick **Aramex** (the default when connected) or **Another carrier or your own drivers**.
2. Set how many of each item to **Ship**. You can ship part of an order and send the rest later.
3. For Aramex, check the **Parcel weight (kg)**. Leave it empty to use the products' weights.
4. For another carrier, enter the **Carrier**, **Tracking number**, and **Tracking link**.
5. Check **Collect on delivery**. It's filled in for unpaid orders. Leave it empty if the order is paid.
6. Click **Ship** or **Book with Aramex**.

Aramex books the pickup from your store's location and makes the label. The order's fulfillment status updates on its own: unfulfilled, partially fulfilled, or fulfilled.

Each shipment on the card shows its status, items, tracking history, and the cash to collect. From a shipment you can:

- **Print label** (when the carrier made one, as Aramex does) and print a **Packing slip**, which lists the items without prices;
- from the shipment's menu: **Mark out for delivery**, **Mark delivered**, **Failed delivery attempt**, or **Returned to sender**;
- **Cancel shipment**.

Aramex shipments update themselves: tracking is read every 30 minutes for shipments up to 60 days old. If tracking can't be read, the card shows the error.

Shipping and delivery updates fire the **Order Shipped**, **Order Out for Delivery**, **Order Delivered**, and **Order Fulfilled** workflow triggers. Use them for WhatsApp updates in [Workflows](https://workstation.repzo.com/docs/administration/workflows).

Stock leaves when the order is invoiced, not when it ships.

## Cash on delivery

When a shipment carries cash to collect, it moves through these steps:

| Step | What happens |
|---|---|
| **Pending** | The courier has the parcel and the amount to collect |
| **Collected** | The parcel was delivered and the courier has the cash. The cash is recorded as a payment on the order's invoice, so the order turns paid. |
| **Received** | The courier handed you the money and you clicked **Cash received from courier** in the shipment's menu |
| **Refused** | The parcel came back. This counts against the customer. |

A delivered shipment is marked collected on its own, whether you click **Mark delivered** or Aramex tracking reports it. You can also click **Cash collected**. A canceled shipment's cash is simply canceled and doesn't count as a refusal.

The cash to collect can't be more than what the order still owes, less what other shipments are collecting. Rules about who can pay on delivery are in [Checkout & Payments](https://workstation.repzo.com/docs/online-store/checkout-and-payments#cash-on-delivery).

## The order status page

Every native order has a private status page (`/o/<token>`) that customers open without signing in. It shows, in English or Arabic:

- the steps: **Order placed**, **Paid**, **Shipped**, **Out for delivery**, **Delivered**;
- each shipment with its tracking history and a link to the carrier's site;
- the items, discounts, shipping, tax, and total;
- **Pay now** while money is still due;
- returns, when you allow them. See [Returns & Order Edits](https://workstation.repzo.com/docs/online-store/returns-and-order-edits).

Click **Customer view** on an order to open its status page. Customer emails link to it.

Customers without the link can use **Find your order** at `/order-status/<store address>`. They enter the order number and the email or phone on the order. Wrong details always get the same "not found" answer, so nobody can guess which orders exist.

## Customer emails

Open **Commerce → Settings → Customer messages**. Under **Order emails to customers**, each email has its own switch. All are on by default.

| Email | Sent when |
|---|---|
| **Order confirmed** | The order is paid, or the customer chooses to pay on delivery. Lists the items and total. |
| **Shipped** | Each shipment goes out, with the carrier and tracking number |
| **Out for delivery** | The courier is on the way |
| **Delivered** | The parcel reaches the customer |
| **Refunded** | The order's payment is refunded |
| **Return request received** | The customer asks for a return |
| **Return approved** | A return is approved, with how to send the items back |
| **Return declined** | A return request is declined, with your reason |
| **Order updated** | You edit an order, with the new totals and a link to pay what's left |

Emails go in your store's language to the email on the order, through your workspace's email settings, and each links to the order's status page. Each email is sent once per order (or per shipment). For WhatsApp, use the order triggers in [Workflows](https://workstation.repzo.com/docs/administration/workflows).

The same tab holds the settings for [abandoned checkouts](https://workstation.repzo.com/docs/online-store/abandoned-checkouts), review requests, and back-in-stock alerts. See [Marketing](https://workstation.repzo.com/docs/online-store/marketing).

## Shipping quotes for AI agents

AI agents with the **Take orders** capability can quote real delivery fees on WhatsApp and in the Inbox with the `quote_shipping` function. It uses the same zones and rates as checkout. See [AI Agents](https://workstation.repzo.com/docs/operations/ai-agents).

> **From the CLI**
>
> Zones, rates, pickup, and customer emails can also be set from the CLI with `repzo store shipping` and `repzo store messages`, and orders shipped with `repzo orders fulfillments`. Connecting Aramex stays in the app. This requires the next CLI release. See [Build a store from the CLI](https://workstation.repzo.com/docs/developers/online-store/cli#shipping).

## Related pages

- [Checkout & Payments](https://workstation.repzo.com/docs/online-store/checkout-and-payments)
- [Returns & Order Edits](https://workstation.repzo.com/docs/online-store/returns-and-order-edits)
- [Markets](https://workstation.repzo.com/docs/online-store/markets)
- [Orders](https://workstation.repzo.com/docs/commerce/orders)
- [Workflows](https://workstation.repzo.com/docs/administration/workflows)
