All work

Smart Web Agency, for Virtuous Restaurants

Restaurant payouts on Stripe Connect, with no one doing them by hand

Virtuous Restaurants took orders through GloriaFood and payments through Stripe, and nothing joined the two. I built a Laravel 12 system that matches every order to its payment, works out the fees and pays each restaurant on a schedule, by itself.

Payouts automated
100%
Manual steps per payout
None
Every order matched to
Its Stripe charge

How the payouts work

The problem

There was no system

The group’s restaurants took orders through GloriaFood, Oracle’s online ordering service, and payments through Stripe. Nothing connected an order to its payment, or worked out what each restaurant was owed.

Step one

Every order, matched to its payment

I built a Laravel 12 app that receives GloriaFood webhooks, so every order from every outlet syncs in real time. Each order is linked to its Stripe charge and payment intent, so any payment can be traced back to the order behind it.

Step two

Fees, worked out for every order

For each order the app takes off the Stripe processing fee and the platform’s commission, and what is left is the restaurant’s share. Every calculation is kept in a payment log for auditing and reconciliation.

Step three

Payouts on a schedule

Each restaurant has a Stripe Connect account. Scheduled jobs send its share with the Stripe Transfer API once the payout delay has passed, and the delay is set from the admin panel, not in code.

The result

Payouts nobody has to touch

A reporting dashboard shows revenue, fees and payouts, split by pickup, delivery and dine-in, so each restaurant sees where its money comes from. Payouts are 100% automated, with no manual steps.

Before and after

Before

  • Orders in GloriaFood, payments in Stripe, nothing joining them
  • No record of what each restaurant was owed
  • Payouts with no system behind them

After

  • Every order linked to its Stripe charge and payment intent
  • Fees and commission calculated and logged for every order
  • 100% of payouts sent on schedule, with no manual steps

The work

Built at
Smart Web Agency, for Virtuous Restaurants, a multi-restaurant group
Integrations
GloriaFood webhooks, Stripe Connect and the Stripe Transfer API
My part
The order sync, payment matching, fee engine, scheduled payouts and the reporting dashboard
  • Laravel
  • Stripe
  • Stripe Connect
  • MySQL
  • GloriaFood
  • CRON