Skip to content

Push notification campaigns for your store's app, from the Laravel admin ​

The app is on the customers' phones, and the first thing its owner wants to do with it is say something: the cider is back, there is ten percent off this week, the shop is closed on Monday. A push does that better than an email — it is read in seconds, on the screen people look at all day.

Then it turns out that sending one is a product of its own. A push service has a dashboard, an SDK to build into the app, and a price per subscriber. The audience — those who bought cider — lives in the shop, so it is exported and uploaded, and is out of date the next day. A tap on the push opens the app's front page, because the service knows nothing of the shop's products. And nobody at the service asks whether the customer agreed to any of it, which Apple does: its review guideline 4.5.4 allows promotional push only to people who opted in through the app's own interface, with a way to opt out in the same place. An app that pushes offers without asking is refused, or removed later.

The shop already has all the pieces: the phones, the customers, their orders, the products and the coupons. Since 1.19.0 kitloom/mobile-apps, the site's side of the kitloom app, sends the message itself.

A message, written where the shop is ​

Mobile app → Messages → New message is one form.

  • Title and text. A phone shows about forty characters of the title and a hundred and fifty of the text, and the form says so under each field. The app's inbox shows all of it.
  • A tap opens a page of the site — a product, a category, a post, a page — found by its title with Find a page. The app opens it as its own screen, not in a browser. Left empty, a tap opens the inbox.
  • A coupon: the code of a coupon published in the shop. The tap puts it into the cart, so the customer types nothing.
  • Who gets it: everyone who said yes, only those signed in to an account, only guests; those who bought a product, or anything from a category (a paid order; a category counts with its subcategories); the phones of one language. The line under the choice says how many phones that is now — 4 phones get it now — and changes as you choose.

Create saves a draft. Nobody gets a draft. Send test to my phone pushes it to the phones where the app is signed in to your own account, so you see it as a customer will: where the title is cut, where the tap leads, whether the coupon lands in the cart. Then Send now, or Schedule for a time in the site's time. The question before it goes names the count once more, and says what is true of every push: once it is out, it cannot be changed or taken back.

Only to those who said yes ​

Whatever the audience, a message reaches only the phones whose person said yes to offers and news in the app. The app asks softly and once — a card after an order, or on the third visit — and before the phone's own permission prompt, so a no costs nothing. The answer is kept with its time, per phone. Account → Offers and news in the app is a switch that takes it back in one tap.

Order notices are apart from this: your order is on its way needs no such yes, and switching offers off does not silence it.

Two settings keep the offers welcome, under Mobile app → Settings → Offers and news:

  • Quiet hours, 21:00 to 09:00 by default, in the site's time. A message due then — scheduled, or sent by hand late in the evening — goes in the morning, and the page says so: Scheduled: goes at 11.11.2026 09:00, after the quiet hours.
  • Offers a phone gets in a week, two by default. A phone that had its share gets the next message in its inbox only, without a push. A shop with three things to say in a week does not become the app people mute.

An inbox, because a push is gone once swiped ​

A notification lives until it is swiped away, and half of them are swiped unread. So the app keeps what it was sent: Account → Messages lists every message, read or not, for ninety days, with the unread count on the tab. A tap there does what the push would have done — the page, the coupon. Signed in, a person sees what their other phones got too.

How it did, in four numbers ​

Each message keeps four numbers, and the page says what each one is, because the names promise more than the phones' makers tell anyone.

NumberWhat it is
PhonesThe phones of the audience when it went
PushedExpo's push service took the push for the phone
DeliveredApple or Google took it for the phone. Not that anyone saw it: neither says whether a notification was shown or swiped away
OpenedThe person tapped the push, or opened the message in the inbox. The app says so; counted once per person

Opened is the only one a person did, so the list shows it with its share of those pushed.

An AI agent drafts; a person sends ​

With kitloom/ai, an agent connected to the site has two tools: mobile_app_messages_list reads the earlier messages and how they did, and mobile_app_messages_draft writes a draft — title, text, link, coupon, audience — and answers how many phones it would reach. Write an offer for the customers who bought cider, like the one that did best in October is a request it can carry out. There is no tool that sends. The draft waits in Messages for someone with the permission Send messages to the app — administrators and editors hold it, and it is apart from managing the app's settings.

For a Laravel developer ​

A message is a row of mobile_messages, written by Messages\MessageWriter with the acting user: create(), update(), schedule($message, $at) — now when no time is given — cancel(), reach($audience), test($message, $actor). A link elsewhere than the site and a coupon the shop does not have are refused at their field.

Messages\Sender sends a hundred phones at a time, which is what Expo takes in one request: a queued SendMessageChunk under a cache lock, each job dispatching the next. A phone gets its row in mobile_message_deliveries before its push goes, so the message is in its inbox whatever becomes of the push, and a chunk that is tried again pushes only to the phones still waiting — nobody is told twice. mobile-apps:send-messages runs every minute, starts what is due and picks up a message a killed worker left half sent. mobile-apps:push-receipts, hourly, reads Expo's receipts: a good one marks the delivery, and a phone Apple or Google no longer know is forgotten.

The app's side is three routes under app/v1: PUT /devices carries the person's answer about offers, GET /messages is the inbox by push token, POST /messages/{id}/opened counts the open. The site lists messages among its features in GET /site, and the app draws the inbox and the question only where it does. The app needed no new native module, so phones got all of this as an over-the-air update, with no store review.

With kitloom/privacy, Export Personal Data lists a person's devices with their answer about offers and the messages their phones got; Erase forgets the phones and their inboxes. Tests fake Expo with Kitloom\MobileApps\Testing\FakesExpo: $this->phone(offers: true), send, and read $this->pushes() back.

Watch it ​

Mobile app: an offer to the phones that said yes

Try it ​

The stand is a real store: Prairie Hops, a craft beer shop, at pantry.kitloom.dev, with the app's Android build for testers. Every option, route and number above is in the Mobile app guide; how the app itself is built from your site's name, icon and colours is in A mobile app for your online store.

Last updated:

kitloom — sites on Laravel, built for you and run with AI.
Contact · Services · License · Refunds · Privacy · Community · YouTube · [email protected]