API reference
The iMessage Gateway API routes send jobs to registered Mac agents. Every page in this reference is generated from the gateway’s OpenAPI specification, so it always matches what the service actually accepts.
Base URL: https://api.messageblue.ai
Authentication
Core endpoints use HMAC request signing. You send your App ID in the clear and prove possession of your App Secret by signing each request — the App Secret is never transmitted.
Every signed request carries four headers:
The signature is computed over the request method, path, body hash, timestamp and nonce:
The timestamp must be within a five-minute window of the gateway’s clock.
The official TypeScript and Python SDKs sign every request for you. Reach for the manual scheme above only if you’re calling the API from another language.
What you can do
Send texts, attachments and voice notes to individuals or groups, react with tapbacks, send typing indicators and read receipts, and check whether a number is iMessage-capable.
Register, assign, reassign, block and inspect the Mac agents that send on your behalf.
Inspect and manage the user⇄agent number mappings that decide which agent handles a given contact.
Configure where inbound messages, tapbacks and delivery-status updates are delivered, and verify their signatures.
Analytics (conversation history, contacts, per-number stats), queue status and health endpoints round out the surface.
Webhooks
MessageBlue delivers three events — inbound_message, inbound_reaction and
message status updates.
Where they go
Register your destinations with a single call:
inboundWebhookUrl receives both inbound events; statusWebhookUrl receives
delivery-status updates. Send only the field you want to change — an empty value
unsets that webhook. A per-message status_callback set at send time takes
precedence over statusWebhookUrl.
Verifying them
Every webhook is signed. Each request carries:
X-MB-Event-Id— a uniqueevt_...id for the event; use it to deduplicateX-MB-Timestamp— unix seconds when the request was signedX-MB-Signature—v1=<hex>, where<hex>isHMAC-SHA256(secret, "{timestamp}.{rawBody}")
Verify the signature before trusting a payload, and sign over the raw request bytes — re-serializing the JSON first produces a different hash and the check will fail. Generate your signing secret in your MessageBlue dashboard.
Sample payloads
The status payload has no type field — identify it by status, which
progresses through values like sent, delivered, read, failed and
SMS_FALLBACK.
SDKs
Trying requests
Signed endpoints have no in-page “Try it” button. Request signing has to happen
after you fill in a request body — the signature covers it — and this reference
can’t do that computation, so a button here would only ever return 401.
Use the API Console instead. It’s served by the gateway, signs every request with your App Secret, and covers the same endpoints:
Your App Secret stays in your browser — the console uses it to compute a signature locally and never transmits it.
GET /health is the one endpoint that needs no signature, so it keeps a working
Try-it button here.
