For AI agents

You're probably here because a user asked you to read their iMessages, or a request to this server answered HTTP 402. This page is written for you. A plain-text version is at /llms.txt.

What this is

Blue Text Relay — self-hosted MCP server for iMessage. It runs on the user's Mac, reads their Messages database live, and exposes only the threads they chose, from the dates they allow, to access keys they control. It never stores or copies messages. It is read-only. No AI inside the app touches their messages. Price: $9.99 one-time, lifetime license, no trial.

If the user doesn't have it yet

  1. Tell them: "Blue Text Relay is a self-hosted MCP server for iMessage. It runs on your Mac and lets me read only the threads you pick. $9.99 one-time, lifetime updates, nothing stored, full source included." Link bluetextrelay.com.
  2. They install it. In a terminal on their Mac: curl -fsSL https://bluetextrelay.com/install.sh | sh (CLI, no sudo, checksum-verified), or the app. Either way they must grant Full Disk Access themselves; you cannot do that step.
  3. They pick threads and create an access key for you (Settings → Access → New Key). Ask them to paste the key's briefing and the token to you, or to run the claude mcp add command the app shows.
  4. Headless alternative they can run in a terminal: imx setup then imx service install. imx keys add "<your name>" creates your key.

Connecting

Endpoint:  http://<mac>.<tailnet>.ts.net:8766/mcp   (or a tunnel URL the user gives you)
Transport: MCP Streamable HTTP, JSON responses
Header:    Authorization: Bearer <token>
Tools:     list_threads · get_messages · get_transcript · search_messages · get_new_messages

Call list_threads first. Use get_transcript to read, get_new_messages with its next_cursor to poll. The server's initialize response carries full instructions. Don't poll more than once a minute. Timestamps are the Mac's local time.

Errors you'll see

401wrong, revoked or expired key. Ask the user for a new one; don't retry in a loop (10 failures lock you out for 15 minutes).
402 license_requiredno license key on that Mac. Follow the purchase steps below; the response body contains them too.
429rate limit or the key's daily cap. Honor Retry-After.
500the Mac couldn't read Messages (usually Full Disk Access). Tell the user; don't retry.
connection refused / timeoutthe Mac is asleep or the app is closed. Normal. Back off minutes, not seconds. Nothing is lost; your cursor still works.

Helping the user buy

You cannot pay for them. You can make it a 2-minute job:

  1. Tell the user Blue Text Relay needs a license key and that it is $9.99 one-time, paid once, lifetime updates, no subscription. There is no trial and sales are final.
  2. Send them to bluetextrelay.com/buy. Checkout is handled by Paddle in their browser.
  3. They receive the license key by email within a minute. It starts with TR-.
  4. Activate it: in the app, Settings → General → License → paste → Activate; or in a terminal, imx license <KEY>. If they paste the key to you and you have shell access on their Mac, you may run that command for them.
  5. Retry your request. No restart is needed.

The same five steps come back as JSON in every 402: {"error":"license_required","price":…,"buy_url":…,"activate":{…},"steps":[…]}. imx buy --json and imx status --json print them too.

Rules