Incoming messages, reactions, and delivery events arrive as signed HTTPS POSTs to a URL you control. You write the handler once and it runs unchanged in dev and in production.Documentation Index
Fetch the complete documentation index at: https://messages.dev/docs/llms.txt
Use this file to discover all available pages before exploring further.
1. Handle the event
verifyWebhook handles HMAC-SHA256 verification, timing-safe comparison,
and replay protection, then returns a typed discriminated-union event. If
you’re not using the SDK, see the manual verification snippets in
Webhooks › Verifying signatures.
2. Stream events to your handler (local dev)
The fastest way to drive your handler while you’re building is themessages-dev CLI. It POSTs each real account event to a local
URL with the same headers a registered webhook would, so you don’t need a
public URL or a webhook registration.
Install the CLI and authenticate, then:
WEBHOOK_SECRET in your handler, or pin one with
MESSAGES_LISTEN_SECRET=… so it doesn’t rotate between runs.
3. Register a webhook (production)
When you’re ready to deploy, go to the Webhooks page in your dashboard, click Add Webhook, enter your public HTTPS endpoint, and copy the signing secret into your environment asWEBHOOK_SECRET. The handler from step 1 is unchanged.
You can also create webhooks via the API
if you need to provision them programmatically.
Next steps
- Webhooks — full event list, payload shapes, and replay-protection rules.
- CLI reference —
listenfiltering flags, output modes, and other recipes.