Skip to main content

Delivery states

A delivery job moves only along the paths below. Any other move is refused with INVALID_DELIVERY_STATE, and every move is checked against the job as the database holds it at that moment, then written with an event in the job's history.

These are the internal states that the API returns as status. People see the simpler tracking statuses instead. Relays between riders are not states: the delivery keeps its state while custody passes from one rider to another.

States​

StateMeaning
PENDING_DELIVERYBooked and priced; not yet released to dispatch.
DELIVERY_REQUESTEDReleased to dispatch; IDM is looking for a rider.
OFFEREDAn offer is open to a rider and has not been answered yet.
ASSIGNEDA rider accepted and is heading to the pickup.
ARRIVED_AT_PICKUPThe rider is at the pickup, waiting for the sender to hand over.
PICKED_UPThe sender confirmed the handover; the rider has the item.
ON_THE_WAYThe rider is travelling to the drop-off.
ARRIVED_AT_DESTINATIONThe rider is at the drop-off, waiting for the recipient.
RECEIPT_CONFIRMEDThe recipient confirmed receipt; the rider completes the delivery next.
DELIVEREDCompleted. The end state of a successful delivery.
CANCELLEDCancelled before pickup. An end state.
DELIVERY_EXCEPTIONSomething stopped the delivery; an operator or the system resolves it.
RECOVERY_REQUIREDBeing recovered: it goes back to dispatch without changing its original facts.
FAILEDEnded without reaching the recipient. An end state.

Allowed moves​

FromToWho can make it
PENDING_DELIVERYDELIVERY_REQUESTEDTenant (API), Sender
DELIVERY_REQUESTEDOFFEREDIDM, Operator, Delivery company
OFFEREDASSIGNEDRider
OFFEREDDELIVERY_REQUESTEDIDM
ASSIGNEDARRIVED_AT_PICKUPRider
ARRIVED_AT_PICKUPPICKED_UPSender
PICKED_UPON_THE_WAYRider
ON_THE_WAYARRIVED_AT_DESTINATIONRider
ARRIVED_AT_DESTINATIONRECEIPT_CONFIRMEDRecipient
RECEIPT_CONFIRMEDDELIVEREDRider, Operator, Tenant (API)
DELIVERY_EXCEPTIONRECOVERY_REQUIREDOperator, IDM
DELIVERY_EXCEPTIONON_THE_WAYOperator, IDM
DELIVERY_EXCEPTIONFAILEDOperator, IDM
RECOVERY_REQUIREDDELIVERY_REQUESTEDIDM
PENDING_DELIVERY, DELIVERY_REQUESTED, OFFERED, ASSIGNED, ARRIVED_AT_PICKUPCANCELLEDTenant (API), Sender, Operator
ASSIGNED, ARRIVED_AT_PICKUP, PICKED_UP, ON_THE_WAY, ARRIVED_AT_DESTINATIONDELIVERY_EXCEPTIONRider, Delivery company, Operator, IDM
ASSIGNED, ARRIVED_AT_PICKUPDELIVERY_REQUESTEDIDM

What the moves mean in practice​

  • Only an accepted offer assigns a rider. No delivery is ever given to a rider who did not accept it.
  • Handover is the sender's act. PICKED_UP happens only when the sender confirms it.
  • Receipt is the recipient's act. RECEIPT_CONFIRMED happens only from the recipient's own secure link.
  • Cancellation stops at pickup. After the item is with a rider, the way forward is an exception and recovery, never cancellation.
  • Recovery never rewrites history. Places, vehicle, price and earlier events stay as they were; recovery adds events.