Tracking

Get the same tracking information you see in your panel. Fetch it to show customers in your app or to update your order management system.

Tracking Numbers

Every order is assigned a unique tracking number when created:

4N YYYYMMDD NNNN
  • 4N — prefix for regular orders. SH is used for orders that start from a blank label scanned by a driver in the field ("shell" orders) and keep that prefix for life.
  • YYYYMMDD — the creation date.
  • NNNN — a 4-digit code, randomly assigned. Don't infer volume or sequence from it.

For example, 4N202512310001 is an order created on 2025-12-31. Tracking numbers are always 14 characters: the two-letter prefix plus 12 digits. The tracking endpoint rejects any other shape with a 422.

Each package inside an order has its own tracking number, built from the order's: 4N202512310001-001, 4N202512310001-002, and so on.

Delivery states

The delivery_state field is the order's current position in the flow. These are the possible values:

PendingPicked UpIn TransitOut for DeliveryPartially DeliveredDeliveredReturned to SenderFailedCancelled
StateMeaning
pendingCreated, waiting for pickup
picked_upCollected from the sender
in_transitMoving through the network
out_for_deliveryOn a vehicle heading to the recipient
partially_deliveredSome packages were delivered, others not yet
deliveredAll packages delivered — final
closed_with_returnClosed; undelivered packages returned to the sender — final
failedThe last delivery attempt failed; a new attempt may follow
nulledCancelled — final

See Orders for how an order moves between these states.

Timeline events

You get the same timeline you see when clicking an order in your panel — one entry per state change, oldest first. The first entry is always pending at the order's creation time.

FieldTypeDescription
statestringThe delivery state reached at this point
timestampdatetimeWhen it happened
typestringOnly on failure entries: always failure
failure_infoobjectOnly on failure entries: type, reason, notes (see below)

A failed delivery attempt produces two entries at (almost) the same time: a failed entry carrying type: "failure" and failure_info with the details, and the resulting failed state change. Use the one with failure_info to tell your customer what happened.

Failure info

FieldTypeDescription
typestring|nullA human-readable label for what failed (delivery or pickup), in the platform's language. Display only
reasonstringThe failure reason. Normally one of the codes below; branch on this field
notesstring|nullFree-text notes from the driver

Reason codes: not_home, refused, wrong_address, inaccessible, business_closed, pending_stock_break, no_cargo_ready, no_cargo_to_ship, customer_unavailable, other.

Example Timeline

{
  "timeline": [
    { "state": "pending", "timestamp": "2025-02-03T10:00:00.000000Z" },
    { "state": "picked_up", "timestamp": "2025-02-03T14:30:00.000000Z" },
    { "state": "in_transit", "timestamp": "2025-02-03T18:00:00.000000Z" },
    { "state": "out_for_delivery", "timestamp": "2025-02-04T08:00:00.000000Z" },
    {
      "state": "failed",
      "timestamp": "2025-02-04T11:05:00.000000Z",
      "type": "failure",
      "failure_info": {
        "type": "Entrega fallida",
        "reason": "not_home",
        "notes": "Nobody answered the door"
      }
    },
    { "state": "failed", "timestamp": "2025-02-04T11:05:01.000000Z" },
    { "state": "out_for_delivery", "timestamp": "2025-02-05T08:30:00.000000Z" },
    { "state": "delivered", "timestamp": "2025-02-05T11:30:00.000000Z" }
  ]
}

Package progress

Orders with several packages can be delivered in parts. The tracking response gives you both the counters and the per-package detail:

CounterMeaning
packages_countTotal packages in the order
picked_up_packages_countPackages collected from the sender
pending_pickup_packages_countPackages not yet collected
delivered_packages_countPackages handed to the recipient
failed_packages_countPackages whose last attempt failed
returned_packages_countPackages returned to the sender
pending_packages_countPackages with no delivery outcome yet

Each entry in packages[] has:

FieldTypeDescription
tracking_numberstringPackage tracking number ({order}-NNN)
delivery_statestringpending, delivered, failed or returned
picked_up_atdatetime|nullWhen it was collected
delivered_atdatetime|nullWhen it was delivered
returned_atdatetime|nullWhen it was returned to the sender

Delivery attempts

delivery_attempts[] lists every visit to the recipient, in order, with its outcome and evidence — the same cards you see in the panel. Each attempt has:

FieldTypeDescription
attemptinteger1 for the first visit, 2 for the second, …
outcomestringsuccess or failed
recipient_namestring|nullWho received the package (successful attempts)
recipient_rutstring|nullTheir Chilean ID, if captured
recipient_rolestring|nullmerchant_staff, recipient, operator or other
locationobject|nulllatitude / longitude where the attempt was recorded
notesstring|nullDriver notes
photosarrayurl and preview_url pairs, signed links valid for 2 hours
packagesarrayPer-package outcome: tracking_number, delivered (boolean), failure_reason (code or null)
created_atdatetimeWhen the attempt was recorded

Proofs

Three evidence blocks share the same core shape — location, notes, photos[] (url + preview_url) and created_at — and differ in when they're present:

BlockPresent whenExtra fields
delivery_proofdelivery_state is delivered or partially_delivered and the driver recorded a proofrecipient_name, recipient_rut, recipient_role
pickup_proofA photographed pickup proof exists (from pickup onwards). null before that—
failure_proofdelivery_state is failed and the failed attempt has photos. null otherwise— (it documents the scene, not a signee)

recipient_role is one of merchant_staff, recipient, operator or other.

Location Object

{
  "location": {
    "latitude": -33.4489,
    "longitude": -70.6693
  }
}

Photos Array

{
  "photos": [
    {
      "url": "https://storage.example.com/proofs/abc123.jpg?signature=...",
      "preview_url": "https://storage.example.com/proofs/abc123-preview.jpg?signature=..."
    }
  ]
}

Photo links in the proof blocks are signed and valid for 60 minutes; the ones inside delivery_attempts[] last 2 hours. Fetch the tracking again to get fresh links — don't store them.

Full event history

The tracking timeline shows delivery states only. For the complete step-by-step history of an order — every change, who made it and when — use GET /orders/{reference}/events. It accepts either the tracking number or your own external_reference, so you can look an order up without storing our number first.

Get updates automatically

Instead of checking your panel or calling the API repeatedly, set up webhooks to get notified when orders move.

When to use what

ApproachBest for
WebhooksUpdating your system automatically when status changes
Tracking APIShowing customers their order status on demand
Order eventsAudits, support tooling, reconciling with your own records

See the Webhooks documentation for setup.

Was this page helpful?