WooCommerce integration
Besides notiwoo/v1, the plugin extends the WooCommerce APIs. This page summarizes what you need to integrate.
Custom order statuses
| Status | ES | EN | Use |
|---|---|---|---|
wc-accepted | Aceptado | Accepted | Order accepted by the store. Not a sale yet. |
wc-shipped | Enviado | Shipped | Order on its way. The tracking link is shown only in this status. |
wc-finalized | Finalizado | Finalized | Delivery or pickup confirmed and payment verified. WooCommerce counts it as paid and includes it in its reports. |
wc-accepting | Aceptando | Accepting | Legacy WooFood flow. |
Flows:
- Delivery:
on-hold → accepted → processing → shipped → completed → finalized - Pickup and dine-in: the same, without
shipped.
The plugin does not move orders through these statuses: the NOTIWOO app does, with PUT /wc/v3/orders/{id} or PUT /notiwoo/v1/orders/{id}. See Statuses and payments.
When an order enters accepted, shipped and finalized, the customer receives the corresponding emails, configured in WooCommerce → Settings → Emails. See Emails.
Webhooks
Notiwoo does not create its own webhooks. Use the standard WooCommerce webhooks (WooCommerce → Settings → Advanced → Webhooks); Notiwoo adds this data to the payload of order webhooks:
| Field | Content |
|---|---|
service_mode | dine_in (at a table), takeaway or empty. |
table | { id, label, zone, released_at } on dine-in orders. |
loyalty | { points_earned, points_redeemed, coupon }. |
meta_data[] → _notiwoo_whatsapp_opt_in | WhatsApp consent, as a boolean. |
Verify each webhook's signature with the secret configured in WooCommerce (X-WC-Webhook-Signature header).
Order metadata
Read from meta_data in wc/v3/orders:
| Key | Content |
|---|---|
_notiwoo_fulfillment_type | Service mode: delivery or pickup. |
_notiwoo_fulfillment_date, _notiwoo_fulfillment_time | Day (YYYY-MM-DD) and time (HH:MM, now or asap). |
_notiwoo_delivery_coordinates | { latitude, longitude } confirmed by the customer on the map. Not used to calculate the fee. |
_notiwoo_service_mode, _notiwoo_table_id, _notiwoo_table_label, _notiwoo_table_zone, _notiwoo_table_released_at | Table service. |
_notiwoo_whatsapp_opt_in, _notiwoo_whatsapp_consent_at | WhatsApp consent. |
_notiwoo_loyalty_points_earned, _notiwoo_loyalty_points_redeemed, _notiwoo_loyalty_coupon | Loyalty. |
_notiwoo_tracking_url | Tracking link. Written by the app. |
On order items, _notiwoo_extras_snapshot stores the chosen extras with their price at the time of purchase. The delivery fee is identified by _notiwoo_delivery_fee = yes, not by its name, so it works in any language.
For compatibility, the plugin also writes the legacy keys woofood_order_type, date_to_deliver, time_to_deliver, minutes_to_arrive and printed.
Block checkout (Store API)
| Extension point | Data |
|---|---|
Checkout → extensions.notiwoo | order_type, fulfillment_date, fulfillment_time, service_mode, table_id |
Checkout → extensions.notiwoo-delivery | latitude, longitude, confirmed |
Cart → extensions.notiwoo-loyalty | enabled, preview, balance (read-only) |
POST /wc/store/v1/cart/add-item | extra_selections, extra_ids, additional_comments in the item data |
| Additional checkout fields | notiwoo/whatsapp-opt-in, notiwoo/referral, notiwoo/latitude, notiwoo/longitude, notiwoo/location-confirmed |
Store URLs
| URL | Use |
|---|---|
https://tienda.example.test/?notiwoo_table=<token> | Entry from a table's QR code. |
https://tienda.example.test/?nw_ref=<code> | Referral link. |
<My account page>/mis-puntos/ | "My points" in My account. |
Shortcode [notiwoo_catalog style="tabs" category="hamburguesas"] | Catalog with category menu. See Catalog menu. |
External services
| Service | Use | Key |
|---|---|---|
| Google Routes API | Delivery distance, calculated on the server. | Server key, restricted by IP. |
| Google Maps JavaScript API | Checkout map. | Browser key, restricted by domain. |
| Notiwoo WhatsApp | Customer notifications. | Configured by Notiwoo; see WhatsApp. |
SMS (BulkGate) and push (FCM) notifications from the previous system remain in the code but are not documented. Push notifications use a Google API retired in 2024 and do not work.