Skip to main content

Stream Order Status Updates

Overview

Stream sends order status updates to your POS system throughout the lifecycle of an order. These updates inform your POS of changes to the order state, delivery progress, and driver information as the order moves through fulfillment. Not all DSPs provide full status updates, so the availability of certain statuses may vary by order source.

Receiving Status Updates

When an order is updated within Stream or by the DSP, you will receive an order.updated event to the Handle Order (Stream -> POS) endpoint.

Event Structure:

{
"type": "order.updated",
"object": {
"location_id": "pos_location_456",
"order_id": "pos_order_123",
"status": "out_for_delivery",
"delivery_status": "enroute_to_dropoff",
"driver_details": {
"source": "doordash",
"name": "John Driver",
"phone": {
"number": "+15555551234",
"code": "123"
},
"vehicle_info": {
"make": "Toyota",
"model": "Camry",
"color": "Silver",
"license_plate": "ABC1234"
}
}
}
}

Order Status Values

The status field indicates the overall state of the order:

StatusDescription
in_progressOrder is being prepared
ready_for_pickupOrder is prepared and ready for driver/customer pickup
out_for_deliveryOrder has been picked up and is being delivered
completedOrder has been delivered or picked up - fulfillment complete
failedOrder could not be fulfilled
merchant_canceledOrder was canceled by the merchant
dsp_canceledOrder was canceled by the DSP or customer

Delivery Status Values

For delivery orders, the delivery_status field provides detailed tracking of the delivery progression:

Pre-Pickup Statuses

StatusDescription
pendingDelivery is in quoted state, not yet confirmed
pending_driver_confirmationWaiting for a driver to be assigned to the order
enroute_to_pickupDriver is on the way to the restaurant to pick up the order
arrived_at_pickupDriver has arrived at the restaurant

Post-Pickup Statuses

StatusDescription
enroute_to_dropoffDriver has picked up the order and is heading to customer
arrived_at_dropoffDriver has arrived at the customer's location
completedOrder has been successfully delivered

Failure Statuses

StatusDescription
failed_to_assign_driverNo driver could be assigned to the order
failed_to_pickupDriver was unable to pick up from restaurant
failed_to_deliverDriver was unable to deliver to customer
failedGeneral delivery failure
merchant_canceledMerchant canceled the order during delivery

Return Statuses

StatusDescription
enroute_to_returnDriver is returning the order to the restaurant
arrived_at_returnDriver has arrived back at the restaurant
returnedOrder has been returned to the restaurant

Driver Details

When a driver is assigned to an order, the driver_details object provides information about the driver and their vehicle:

{
"driver_details": {
"source": "doordash",
"name": "John Driver",
"phone": {
"number": "+15555551234",
"code": "123"
},
"picture_url": "https://example.com/driver.jpg",
"vehicle_info": {
"make": "Toyota",
"model": "Camry",
"color": "Silver",
"license_plate": "ABC1234",
"is_autonomous": false
},
"handoff_instructions": "Meet driver at front entrance",
"passcode": "1234"
}
}

Field Descriptions:

  • source : The delivery platform providing the driver
  • name : Driver's name
  • phone : Driver's contact number with optional masking code
  • picture_url : URL to driver's profile picture
  • vehicle_info : Details about the delivery vehicle
    • make: Vehicle manufacturer
    • model: Vehicle model
    • color : Vehicle color
    • license_plate : License plate number
    • is_autonomous: true if the delivery is by robot/autonomous vehicle
  • handoff_instructions : Instructions for handing off the order
  • passcode : Passcode to verify the driver's identity

Example Status Updates

Driver Assigned and En Route

{
"type": "order.updated",
"object": {
"location_id": "pos_location_456",
"order_id": "pos_order_123",
"status": "out_for_delivery",
"delivery_status": "enroute_to_pickup",
"driver_details": {
"source": "uber",
"name": "Jane Driver",
"phone": {
"number": "+15555555678"
},
"vehicle_info": {
"make": "Honda",
"model": "Civic",
"color": "Blue"
}
}
}
}

Driver Arrived at Restaurant

{
"type": "order.updated",
"object": {
"location_id": "pos_location_456",
"order_id": "pos_order_123",
"status": "ready_for_pickup",
"delivery_status": "arrived_at_pickup",
"driver_details": {
"source": "uber",
"name": "Jane Driver",
"passcode": "5678"
}
}
}

Order Out for Delivery

{
"type": "order.updated",
"object": {
"location_id": "pos_location_456",
"order_id": "pos_order_123",
"status": "out_for_delivery",
"delivery_status": "enroute_to_dropoff"
}
}

Order Completed

{
"type": "order.updated",
"object": {
"location_id": "pos_location_456",
"order_id": "pos_order_123",
"status": "completed",
"delivery_status": "completed"
}
}

Autonomous Delivery (Robot)

{
"type": "order.updated",
"object": {
"location_id": "pos_location_456",
"order_id": "pos_order_123",
"status": "out_for_delivery",
"delivery_status": "enroute_to_pickup",
"driver_details": {
"source": "kiwibot",
"name": "Kiwi Robot #42",
"vehicle_info": {
"make": "Kiwibot",
"model": "K3",
"color": "Green",
"is_autonomous": true
},
"handoff_instructions": "Place order in robot's compartment",
"passcode": "9876"
}
}
}

Delivery Failed

{
"type": "order.updated",
"object": {
"location_id": "pos_location_456",
"order_id": "pos_order_123",
"status": "failed",
"delivery_status": "failed_to_deliver"
}
}

Order Canceled by DSP

{
"type": "order.updated",
"object": {
"location_id": "pos_location_456",
"order_id": "pos_order_123",
"status": "dsp_canceled"
}
}