Recipe: Transport statuses and customer notifications

The two ladders

Every order carries a transport_status meta and a location_type meta (delivery or pickup) that selects its ladder. The status button shown on the order in the app is always titled for the current rung; tapping it confirms that rung (firing its customer notification) and advances the order to the next one. Confirming the last rung sets the WooCommerce order status to Completed.

Delivery (location_type = delivery):

# Button transport_status Category in app Notification fired on tap
1 Accept Order accepted_order New Order
2 Starting Order prep_started Preparing
3 Assign to Driver driver_assigned Request Driver mam_wc_delivery_driver_assigned_to_order (customer) + mam_wc_delivery_new_order_for_delivery (driver)
4 Driver Picked Up order_en_route Driver Picked Up wc-delivery-order-enroute (customer)
5 Order Delivered order_completed Completed wc-delivery-order-delivered-customer (customer); order → Completed

Pickup (location_type = pickup):

# Button transport_status Category in app Notification fired on tap
1 Accept Order accepted_order New Order
2 Starting Order prep_started Preparing
3 Order Ready customer_notified Notify Customer wc-delivery-order-ready-pickup-customer (customer)
4 Customer Picked Up order_completed Completed wc-delivery-order-completed-customer (customer); order → Completed

Each advance also stamps a transport_status_<stage> meta with the time and writes a line into the Product Vendors order history (mam_wc_pv_order_history).

At the Assign to Driver rung the vendor picks from their drivers (punched-in drivers show “(Available)”) or dispatches to a third-party service — see DoorDash hand-off below. A driver claiming the order from the available-orders board is the same rung, self-assigned.


Notification slugs to configure

All slugs are registered with the MAM notification manager (Mobile App Manager → Notifications). Replacement variables available: order_id, seller_location, seller_name (plus delivery_time on the due-to-start slug).

Slug Sent to When
wc-delivery-new-order All users Payment completes
wc-delivery-new-order-notification Customer (SMS to billing phone) Payment completes
mam_wc_delivery_new_order_for_delivery Assigned driver Driver assigned/claimed
mam_wc_delivery_driver_assigned_to_order Customer Driver-assignment rung confirmed
wc-delivery-order-enroute Customer Order picked up / en route
wc-delivery-order-delivered-customer Customer Delivery completed
wc-delivery-order-ready-pickup-customer Customer Pickup order ready
wc-delivery-order-completed-customer Customer Pickup order collected
wc-delivery-no-driver-accepted-order Administrators Cron: order waiting too long for a driver
wc-delivery-delivery-assignment-failed Vendor admins + administrators External driver assignment failed/cancelled
wc-delivery-order-due-to-start Vendor admins Cron: order’s delivery window starts soon

DoorDash hand-off

With mam-doordash-delivery active, the Assign to Driver selector includes the external service. Dispatching requires vendor-staff or store-manager rights and fires the mam_wc_delivery_request_driver filter, which the DoorDash plugin consumes to create the delivery. From then on DoorDash webhook updates advance the same ladder server-side via the mam_wc_delivery_set_delivery_status action; a cancelled_by_doordash status rolls the order back to prep_started and sends the assignment-failed notifications. Assigning an in-house driver afterwards clears the DoorDash linkage.


The two cron tasks

Both tasks register with the MAM cron manager (mam_cron_manager); their frequency comes from the Delivery settings (clamped to 1 minute – 1 day, default 5 minutes):

Task Setting that controls it What it does
MAM WC Delivery – No Driver Accepted (mam_wc_delivery_no_driver_accepted) Order Assignment Minute(s) (tsl-setting-deliver_driver_assignment_minutes) Finds processing orders still pending driver assignment older than N minutes and notifies every administrator (wc-delivery-no-driver-accepted-order)
MAM WC Delivery – Start Order (mam_wc_delivery_start_order) Order Due to Start Notification Time (tsl-setting-deliver_driver_start_order_notification_minutes) Finds orders whose delivery date is today and whose delivery time falls within the next N minutes, and notifies the vendor’s admins (wc-delivery-order-due-to-start)

The delivery date/time compared come from the checkout selectors (delivery_date_formatted, delivery_time_range order meta), evaluated in the site timezone.


  • Plugin: mam-woocommerce-delivery
  • Recipe: Set up delivery drivers
  • Hooks: mam_check_in and order advancement
  • Hooks: driver dispatch and cron (mam_wc_delivery_request_driver)

Metadata

Field Value
Article type Recipe
Plugin slug mam-woocommerce-delivery
Applies to plugin version 1.4.1+
Category Building Your App
Audience App builder, store manager
Last verified 2026-06-10
Contents

    Need Support?

    Can't find the answer you're looking for? Don't worry we're here to help!