PaymentsSeptember 14, 2026by
Empoorio Apps
Empoorio Apps

The Riders Partner API: Letting Any Business Dispatch to the Fleet

The most valuable thing a delivery network owns is the fleet. Empoorio Riders opens that fleet to other businesses through a Partner API — a restaurant with its own app, a shop with an online store, a marketplace, a dropshipper — without giving anyone access to the internal database. This is how it works and how it was verified.

The contract

Base URL: https://europe-west1-empooriofood.cloudfunctions.net/partnerApi/v1

EndpointWhat it does
POST /quotesReturns a real quote based on couriers connected right now
POST /deliveriesCreates the delivery and dispatches it to a courier
GET /deliveries/:idStatus and tracking
POST /deliveries/:id/cancelCancels
/admin/partnersPartner registration, key rotation, activate/deactivate — protected by an admin secret held in a secrets manager

Each partner has its own API key. Requests are authenticated per partner; a deactivated key is refused. Partners never touch the datastore directly.

How dispatch works

The API uses the same mechanism the in-app flow and the Warehouse app use: it writes a dispatch to the chosen courier's record. The courier's app already listens for that record. So a delivery created by an external partner is indistinguishable, to the courier, from one created by Empoorio Eats — and the Riders app needed zero changes to support the API.

Verified, not just deployed

On 12 August 2026 the full path was exercised against production:

  1. Register a test partner → 201.
  2. Request a quote → 200, with real couriers connected at that moment.
  3. Deactivate the partner → 200.
  4. Retry with the deactivated key → 403.

One real deployment lesson came out of it: setting a secret with echo piped into the secrets CLI left a trailing newline in the value, so every admin request returned 401 with no hint why. The fix — generate secrets with printf '%s', and redeploy the specific function after correcting a secret — is written in the API documentation so the next operator does not lose an afternoon to it.

Pricing and settlement

Quotes and settlement are in fiat today, like the rest of the apps. The chain-side design routes a partner delivery through pallet-logistics (the handoff record), pallet-escrow (funds released on confirmed delivery) and DUSD as the pricing unit — with the partner paying gas-free through pallet-paymaster if Empoorio chooses to sponsor it. None of that is switched on for partners yet.

What is pending

No code. The mechanism is live and tested; what remains is commercial — onboarding real partners as agreements are reached. The full contract is in docs/PARTNER_API.md in the Riders repository.

Based on the Partner API deployment and live verification of 2026-08-12.

Share this article