iMessage API delivery status, webhook retries and latency, explained
Seconds until the last webhook retry starts after a fast failure, about
- Webhook timeout
- 10 s
- Retries, after 1 s, 5 s and 20 s
- 3
- Inbound text reaches your webhook
- About 1–2 s
ZeroSettle's iMessage API tells you when the number accepted a send (message.sent) or when it recorded a send attempt the number did not confirm (message.failed). For one-to-one iMessages, a delivery lookup reports delivered, failed, delivered as junk or unconfirmed, and a signed message.read webhook fires when the recipient shares a read receipt. A ZeroSettle send normally returns in 2–5 seconds (at most about 75 for a text and about 105 for a photo or voice message), an inbound text reaches your webhook about 1–2 seconds after the line receives it, and a failed webhook delivery is retried after 1 s, 5 s and 20 s before ZeroSettle records the failure.
Part of iMessage for online stores.
Key takeaways
- What it is: ZeroSettle is an iMessage API: a real phone number on real iMessage, running on Apple hardware we operate for you, that your code texts customers from and hears back on through a bearer token and signed webhooks.
- Status you get:
message.sent(the number accepted the send) andmessage.failed(an attempt the number did not confirm), plusGET /api/imessage/messages/deliveryand themessage.readwebhook for one-to-one iMessages. - Speed: sends normally take 2–5 s; inbound reaches your webhook in about 1–2 s.
- Webhook retries: a 10 s timeout, then 3 retries after 1 s, 5 s and 20 s. Anything missed can be re-read from
GET /api/imessage/messages. - Price and promises: Pro is $49/month for a dedicated iMessage number, for people who text you first; Growth starts at $199/month; Enterprise has custom pricing through sales. ZeroSettle reports 99.9% uptime on its homepage, which is a stat, not an SLA.
What does “sent” mean in ZeroSettle’s API?
In ZeroSettle’s API, “sent” means the number accepted the send and handed the message to Apple; whether Apple then delivered it comes from the delivery lookup. The send call itself blocks until that hand-off, then returns "status": "message_sent" with the stored message id.
| Signal | Where it appears | What it means |
|---|---|---|
200, message_sent | Send response | The line handed the message to Apple. |
message.sent | Webhook, live stream | The number accepted the send (from your code, the console, or MCP). |
message.failed | Webhook, live stream | The API recorded a send attempt the number did not confirm. |
status on the stored row | Send response (record.status), GET /api/imessage/messages | sent or failed for your sends: every attempt is stored. |
delivered, failed, delivered_as_junk, unconfirmed | GET /api/imessage/messages/delivery | What Apple reported for an outbound one-to-one iMessage (delivered comes with its time). Kept 30 days; there is no message.delivered webhook. |
message.read, read_at_ms | Signed webhook, stored message | The recipient shared a read receipt. Read receipts are on for every line. |
Your own sends come back to your webhook as message.sent, so an auto-responder should react only to message.received or it will answer itself.
How do delivery and read receipts work?
For outbound one-to-one iMessages, ZeroSettle reports delivery through a lookup and reads through a webhook. GET /api/imessage/messages/delivery returns each message as delivered (with the time), failed, delivered as junk or unconfirmed; delivery is something you look up, not an event. Read receipts are on for every line: when the recipient shares one, the message gets read_at_ms and a signed message.read webhook fires. The lookup keeps receipts for 30 days, and confirmed read timestamps stay in the message history. SMS, group messages and tapbacks have no receipts.
Treat both as evidence, not proof. ZeroSettle’s iMessage API Terms (section 7) say why:
Delivery of a message does not guarantee that it was read, and the absence of a receipt does not mean a message was not delivered.
ZeroSettle iMessage API Terms, section 7
The same section adds that outputs including “message status, delivery and read receipts, typing indicators” “may be delayed, incomplete, or inaccurate,” and section 2 states that “delivery of any particular message or feature is not guaranteed.” A 200 from the send call is therefore not proof the customer got the message, and a missing read receipt may only mean the recipient doesn’t share them. The dependable signal of attention is an answer: a reply arrives as message.received, and a tapback as reaction.received. Ask for one when it matters. The on-call alert pattern uses a tapback as the acknowledgment and escalates when none arrives.
How fast is a send?
A ZeroSettle send returns once the line has handed the message to Apple: “normally 2–5 seconds and at most about 75 for a text (about 105 for a voice message or photo, which ZeroSettle converts first).” Set your HTTP client timeout above those ceilings; the docs’ examples use 90 seconds for a text and 120 for a photo or voice message.
- One send at a time per line. Concurrent sends “queue behind each other and surface as
line_busyafter ~12 s of waiting.” Retry after 2 seconds. If order matters, send from one worker per line. - Typing is ordered with sends.
POST /api/imessage/typing(ttl_s1–60, default 25) shares the send queue, so the bubble shows before the text, and your next send to that person clears it. It is not stored, not billed and never a new contact, and works only with someone you already have a conversation with (otherwise409 no_conversation).
The first send, end to end, is in how to send an iMessage from code without a Mac.
How fast does a reply reach you?
A customer’s text reaches your ZeroSettle webhook about 1–2 seconds after the line receives it. In the docs’ words, “Inbound is pushed; nothing polls for it, so inbound never delays a send.”
| Channel | How | Timing and notes |
|---|---|---|
| Webhook | Signed POST to the URL you register with PUT /api/imessage/webhook | About 1–2 s; retried 3 times on failure |
| Polling | GET /api/imessage/messages?after_id=… | Inbound appears within about 1–2 s, plus your poll interval |
| Live stream (SSE) | Token from GET /api/imessage/stream-token, then /api/imessage/stream | Events message, delivery, typing, conversation, optout, ai_credits; a : ping after 15 s of silence; the token lives 5 minutes; the console is built on it |
Inbound text reaches your webhook
A send normally takes to return
From the customer’s text to your answer leaving, plus your own lookup or model call
For an auto-reply, the documented figures add up to about 3–7 seconds from the customer’s text reaching the line to your answer leaving it (1–2 s inbound plus a 2–5 s send), plus your own lookup or model call. When that work takes more than a couple of seconds, raise the typing bubble first.
What happens when your webhook is down?
ZeroSettle waits 10 seconds for a 2xx; on a non-2xx or a timeout it retries 3 more times, after 1 s, 5 s and 20 s, then records the failure. Redirects are not followed, so a URL that answers with a redirect fails the same way.
- Attempt 10 s
- Attempt 2about 1 s
- Attempt 3about 6 s
- Attempt 4, the lastabout 26 s
- Failure recordedabout 26 s
| Attempt | Your server errors at once | Every attempt times out |
|---|---|---|
| 1 (first delivery) | 0 s | 0 s |
| 2 | about 1 s | about 11 s |
| 3 | about 6 s | about 26 s |
| 4 (last) | about 26 s | about 56 s |
| Failure recorded | about 26 s | about 66 s |
Network time adds a little to each figure.
So a receiver that refuses connections for more than about 26 seconds, during a deploy for example, can miss the webhook for a message that arrived at the start of that gap. The message itself is still stored. GET /api/imessage/line shows last_delivery (ok, status_code, error, attempts, at), and the live stream sends a delivery event with the same fields. Recover by paging forward with after_id from the cursor your last backfill saved, skipping ids your webhook already handled, and run it every time your receiver starts. Don’t use the highest id your webhook saw as the cursor: events can arrive out of order, so a missed lower id would be skipped.
import os, requests
BASE = "https://portal.zerosettle.io"
TOKEN = os.environ["ZEROSETTLE_TOKEN"]
def backfill(cursor: int) -> int:
while True:
r = requests.get(f"{BASE}/api/imessage/messages",
params={"after_id": cursor, "limit": 500},
headers={"Authorization": f"Bearer {TOKEN}"}, timeout=15)
r.raise_for_status()
page = r.json()
for m in page["messages"]: # both directions, in id order
handle_once(m) # yours: skip ids already handled
if page["next_after_id"] == cursor: # nothing new
return cursor # save it for the next run
cursor = page["next_after_id"]
Signature checks and a complete receiver are in how to receive iMessages with a webhook.
How do you handle duplicates and ordering?
Deduplicate ZeroSettle webhook events on the pair of message.id and event, because a retry carries the same pair. Sort by message.id when order matters, because events for one line are delivered concurrently and can arrive out of order under retries.
A slow handler causes duplicates too: a receiver that works for more than 10 seconds before answering counts as a timeout, and ZeroSettle sends the same event again. Answer 2xx first and queue the work. Delivery is per line, so if two systems need the same messages, fan out from your own receiver. Verifying the X-ZeroSettle-Signature header before any of this is covered in ZeroSettle’s API security explainer.
Which errors mean retry and which mean stop?
Retry ZeroSettle’s busy and temporary-outage errors after a short wait, hold a new-contact send until retry_after_s has passed, and don’t resend the rest unchanged: they fail again until something changes: your input, the subscription, the token, or the recipient (a reply, or START after a STOP). Every error has one shape, {"error": {"code", "message", …}, "detail"}: branch on error.code. Rate-limited responses carry a Retry-After header.
| HTTP and code | Retry? | What to do |
|---|---|---|
429 line_busy | Yes | Retry after 2 s. |
429 new_contact_limit | Later | Wait retry_after_s. On a multi-number account it comes back only when every number is full (or the line you named is). |
503 (line temporarily unreachable or no answer in time) | Yes | Retry with backoff. |
403 recipient_opted_out | No | They opted out by texting STOP or a recognized opt-out phrase like “take me off your list” as the whole message or its first sentence. Only their START (or unstop) opts them back in. |
403 awaiting_reply | After a reply | Every plan: 2 unanswered message bursts to that contact (texts within 5 minutes count as one). Wait for their reply. |
403 attachment_before_reply | After a reply | A photo or voice message to someone who has never replied. Send text until they do. |
422 not_on_imessage | No | A group member must be on iMessage. One-to-one plain text to a phone number can go by SMS when iMessage is unavailable. |
502 error (the iMessage check for a new contact didn’t complete) | Yes | Nothing was sent. Retry in a minute. |
502 send_failed | No | Fix the input (for example, a bad handle). |
402 payment_required | No | The subscription is not active. Subscribe in the console. |
422 invalid_request | No | Fix the fields listed in error.fields. |
401 unauthorized | No | Check the token. Minting another revokes nothing; revoking revokes all. |
- Retry
- Retry later, or after a reply
- Do not retry
A send that fails on the line’s side (busy, temporarily unreachable, or unable to send) keeps a stored record with status failed and reaches your webhook as message.failed, so a send that succeeds on its second try leaves a failed row and then a sent row with a new id. A STOP or awaiting_reply refusal happens before anything is sent or stored. In code:
import os, time, requests
BASE = "https://portal.zerosettle.io"
TOKEN = os.environ["ZEROSETTLE_TOKEN"]
class RetryLater(Exception):
"""Re-queue the send; retry_after_s can be hours away."""
def send(to: str, text: str, tries: int = 4) -> dict:
for attempt in range(tries):
r = requests.post(f"{BASE}/api/imessage/send", json={"to": to, "text": text},
headers={"Authorization": f"Bearer {TOKEN}"}, timeout=90)
if r.ok:
return r.json() # message_sent: the number accepted it
err = r.json()["error"]
if err["code"] == "new_contact_limit":
raise RetryLater(err["retry_after_s"])
if err["code"] == "error": # 502: iMessage check didn't finish; nothing sent
raise RetryLater(60)
if err["code"] not in ("line_busy", "phone_offline", "phone_timeout"):
# 401, 402, 403, 422, 502: resending the same request fails again
raise RuntimeError(f'{r.status_code} {err["code"]}: {err["message"]}')
if attempt + 1 < tries:
if err["code"] == "line_busy":
time.sleep(int(r.headers.get("Retry-After", 2)))
else:
time.sleep(5 * 2 ** attempt) # 5, 10, 20 s
raise RetryLater(60)
How do other iMessage API providers retry webhooks?
Published webhook retry policies range from a single attempt to about three hours of retries, and ZeroSettle’s window is on the short side. Each figure below comes from that provider’s own docs.
| Provider | Retries | Timeout |
|---|---|---|
| ZeroSettle | 3, after 1 s, 5 s and 20 s, on a non-2xx or timeout | 10 s |
| Sendblue | Up to 3, on a 5xx or no response | 45 s |
| Linq | About 10, with exponential backoff, for up to 30 minutes, on a 5xx, 429 or network error | 10 s |
| LoopMessage | Up to 30: ten every 30 s, ten every 3 min, ten every 15 min | 15 s |
| Texting Blue | Four attempts: immediately, then after 10 s, 60 s and 300 s, on a 400+ status or timeout | Not stated (asks for a 200 within 5 s) |
| Project Blue | None: “single-attempt today” | Not stated (asks for a response within about 10 s) |
ZeroSettle’s last retry starts about 26 seconds after a fast failure; Linq retries for 30 minutes, and LoopMessage’s retries span about three hours. On ZeroSettle, a longer outage is covered by the stored history and the after_id cursor, not by more retries. Uptime and spam flags are on the reliability and trust hub. To try it, read the API docs, compare plans, or get a number.
Frequently asked questions
Is the webhook called on a line the hosted AI agent manages?
No. On a line group managed by ZeroSettle’s hosted AI agent, the agent answers inbound texts and the webhook is not called. Your own API and MCP sends from that group still go out, and the agent answers the replies; only Close and HubSpot sends are refused with 403 managed_by_zerosettle.
Do failed sends count against the new-contact limit?
No. A new contact is a handle the line delivers its first message to, and ZeroSettle’s docs say failed sends never count.
Are typing events retried like message events?
No. Inbound typing.started and typing.stopped reach the webhook only if you opt in with "typing_events": true, and they are delivered once with no retries. The live stream always carries them.
How long does ZeroSettle keep messages for a backfill?
ZeroSettle currently keeps messages until you delete the conversation, so a backfill from GET /api/imessage/messages can reach back to the start of the line’s history. The exception is a conversation you deleted: that removes its stored rows.
Does the 99.9% uptime figure mean 99.9% of messages are delivered?
No. ZeroSettle reports 99.9% uptime as a homepage stat; it is not a delivery rate or an SLA. What 99.9% uptime means covers the difference.
Sources
- ZeroSettle iMessage API docs: “Send a message”, “Read messages”, “Typing indicators”, “AI agent”, “Webhooks, step by step”, “Live stream (SSE)” and “Errors, limits, and compliance”, plus the delivery lookup and read receipts. Checked October 12, 2026; receipts checked November 23, 2026.
- ZeroSettle iMessage API Terms, sections 2 and 7. Last modified October 22, 2026.
- ZeroSettle homepage: the “99.9% uptime” stat. Checked October 12, 2026.
- Webhooks, Sendblue docs, “Retry Policy”. Checked October 8, 2026.
- Webhooks guide, Linq docs. Checked October 8, 2026.
- Conversation API webhooks, LoopMessage docs. Checked October 8, 2026.
- Webhooks, Texting Blue docs. Checked October 8, 2026.
- Webhook retries, timeouts and delivery status, Project Blue support. Checked October 8, 2026.
Changelog
- Added the delivery lookup and read receipts (
message.read), corrected whatmessage.sentandmessage.failedmean, and updated the hosted-agent answer and plans. - Updated plan references.
- First published. Reviewed quarterly, and after any incident or change to these figures.