Dispatch
Notes from running other people's messages
What we have learned building and operating WhatsApp, Facebook and Instagram messaging for businesses: the error codes, the limits with their real numbers, and the failures that only show up in production. Every article here has to contain something that cost somebody an afternoon to find out.
The handover: what the next shift needs that the system does not store
Open conversations, promises made, and the customer who is angry. The three things a queue cannot tell the next person.
How many people a messaging queue actually needs
Concurrency, not volume. Why messaging staffing is unlike phone and email, and how to work out the number from your own data.
The five numbers worth putting on a wall
Unanswered now, oldest unanswered, median and 90th first reply, resolution rate and reopens. Why averages hide the failure.
Your webhook endpoint is a public API. Treat it like one
Signature verification is the start. Replay windows, size limits, timeouts and SSRF are the four that get skipped.
Where a message goes when it cannot be sent and cannot be dropped
A failure that is not retryable is not the same as a failure nobody needs to know about. What a good parking lot looks like.
Multi-tenancy: the query that eventually forgets the tenant
Every leak is one query missing one clause. How to make the isolation structural rather than a thing every developer must remember.
Idempotency keys: where to put them and who generates them
The caller generates it, the database enforces it, and the response to a repeat is the original result. Getting any of the three wrong loses.
Timezones: store UTC, decide in theirs
UTC everywhere except the two places it is wrong: quiet hours and anything a person reads. Plus the DST bug that sends at 3am.
Media: the part of a messaging system that fills the disk
Provider-hosted media expires. What to copy, how to serve it without proxying every byte, and the permissions bug that leaks files.
The four alerts a messaging system actually needs
Error rate is the least useful signal. Queue age, silence, failure mix and per-identity health are the ones that fire before customers notice.
An audit log somebody can actually use
Who did what, to what, when, and what it was before. The four fields that separate an audit log from a pile of events.
Testing something that sends real messages to real people
Fakes at the boundary, a guard against real numbers, and the one test that has to hit the real API.
API keys: hashing, scoping, and showing them once
Store a hash, show the key once, scope it narrowly, and make rotation something a customer can do without a support ticket.
Search that finds the message somebody half remembers
People search for a fragment, a number or a name, usually misspelled. What to index, and why substring search stops working.
Articles 43 to 56 of 98. New ones are announced on WhatsApp, or take the feed.