Marrow
EN
Download

Connect an agent to Marrow

Marrow serves your Apple Health data over the Model Context Protocol, from your own iPhone or your own server. Nine read tools on the phone, thirteen on your own server (four of them answer in the app's own terms, scored against your own normal), twelve write tools behind a switch, bearer-token auth, no account anywhere. This page is the whole setup.

Agent on another machine, or need answers while the phone sleeps? Pair the self-hosted mirror (pip install marrow-mcp): it answers 24/7 for Claude Code, Cursor and OpenClaw. If you came here from the built-in Claude or ChatGPT connector, here is what it does that they don't.

Setup for one app at a time, Claude Code, Cursor, Codex and more, is on its own page under connections.

Let your agent do it

I want to connect my own Apple Health data to you. Marrow is a free iOS app that serves it over MCP, with no account and no subscription needed for this. It is on the App Store: https://apps.apple.com/app/id6800819435. Walk me through the whole thing: installing the app, turning the server on under Export then Local MCP, and adding the URL and bearer token it shows me to your MCP config as a Streamable HTTP server. If you cannot edit that config yourself, tell me the exact file and what to paste. Setup docs: https://marrowhealthapp.com/mcp. When it is connected, call health_summary for the last 7 days and tell me what stands out.

1. Turn the server on

It ships off. In the app: Export → Local MCP, then enable the server. You get a URL, a token, and a QR code. The server binds to your local network only, and the app shows the exact address it is listening on.

2. Point your client at it

Replace <phone-ip> and <token> with what the app shows you.

Claude Code

claude mcp add --transport http marrow \
  http://<phone-ip>:21212/mcp \
  --header "Authorization: Bearer <token>"

Claude Desktop, one click

Download marrow.mcpb on your computer and double-click it. Claude Desktop installs the extension and asks for the URL and token above. No terminal involved.

Claude Desktop (manual), Cursor, or any client using an mcp.json

{
  "mcpServers": {
    "marrow": {
      "type": "http",
      "url": "http://<phone-ip>:21212/mcp",
      "headers": { "Authorization": "Bearer <token>" }
    }
  }
}

Check it by hand

curl -s http://<phone-ip>:21212/mcp \
  -H "Authorization: Bearer <token>" \
  -H "Content-Type: application/json" \
  -d '{"jsonrpc":"2.0","id":1,"method":"tools/list"}'

The tools

Reads are always there. Writes are a second switch. The phone's server lists the same twelve write tools as Cloud MCP (log_meal, log_water, log_weight, log_workout, log_strength, log_sleep, log_symptom, log_mood, edit_entry, delete_entry, set_targets, undo_entry) once you turn on Allow AI write under Local MCP, applied at once on the phone and written to Apple Health, every one of them undoable. Off, the server is read-only.

ToolReturns
health_summaryRecent days across activity, heart, sleep and nutrition
list_metricsEvery metric tracked, with units and coverage
metric_dailyDaily values for any metric, up to 400 days
metric_samplesRaw records with timestamps and source devices
workoutsWorkouts from every source. On the phone, also Marrow strength sessions set by set
nutrition_logFood diary with the full nutrient breakdown
strength_logEvery lifting set with its set type, estimated 1RM per exercise, volume per muscle group. Warm-ups never count toward volume or records
sleep_logOne night per wake day: bedtime, wake time, hours asleep, minutes per stage (self-hosted mirror)
symptoms_and_moodSymptoms with their severity, and State of Mind entries with feelings and what they were about (self-hosted mirror)

Four more on the self-hosted mirror and on Cloud MCP. They start where the raw reads stop: each value is scored against your own trailing normal with the same math the app's Home page uses (the day itself excluded), so an agent begins from a read that is already true for you instead of judging a number against the population.

ToolReturns
daily_briefOne day: each key metric with its value and the app's own phrase (normal for you, above your normal, well below your normal), food and water against your targets, last night's sleep, training done, mood and symptoms, and flags worth mentioning
baselinesYour own normal per metric: mean and spread over the window, the latest value's z and phrase, the 7-day mean and the 90-day trend per month
what_changedThe last week against the four before it: what moved and how notable it is for you, food, training, sleep and bedtime shifts, streams that started or stopped arriving
data_qualityWhat the mirror holds and how fresh it is: per metric the latest day, coverage, cadence, sources and whether it has gone stale, so an agent never mistakes a gap for a fact

The on-device server serves the first seven raw tools plus daily_brief and baselines (nine reads). The self-hosted mirror serves all thirteen, as does the hosted Cloud MCP copy. Every read on the mirror takes days back or from and to on the phone's calendar, and the mirror also offers four prompts (how_am_i_doing, weekly_review, doctor_prep, log_from_text) and four resources to clients that show them. Raw samples carry sleep stages and symptom severities.

There are 172 Apple Health metrics behind list_metrics, plus Marrow-native diary and strength data behind nutrition_log and strength_log, covering activity, heart, sleep, body, respiratory, mobility, hearing, nutrition, mind, symptoms, cycle and habits. Machine-readable version of this page: tools.json.

Keeping it up when the phone is not

The on-device server answers while the app is running. For 24/7 access, pair a self-hosted mirror: one Python stdlib file on a Pi, NAS or old laptop. The phone's background pushes keep it current, and it speaks the same MCP surface at http://<server-ip>:8800/mcp with its own token. The phone's tools use the app's metric keys (active_energy, heart_rate_variability). The server accepts both those and Apple's short names (active_energy_burned), so an agent can move between them without relearning. It is open source and installable:

pip install marrow-mcp
marrow-server

Source: github.com/MarrowHealth/marrow-mcp. Listed in the official MCP registry as tech.skeletonarmy/marrow.

Origin Tech features Marrow, and mcptry lists Cloud MCP.

Do not port-forward either server to the open internet. Both are designed for a LAN or a tailnet. If you need remote access, front it with tailscale serve or an equivalent, so the transport is HTTPS and the device is authenticated before the bearer token is ever seen.

Troubleshooting

Start with the test below, run from the computer your AI runs on. It tells you which side the problem is on. Use the address and token from the connection's page in Marrow, with Marrow open on the phone.

curl -i http://<phone-ip>:21212/mcp \
  -H "Authorization: Bearer <token>" \
  -H "Content-Type: application/json" \
  -d '{"jsonrpc":"2.0","id":1,"method":"tools/list"}'
What you getWhat it means
HTTP/1.1 200 OK and a list of toolsThe phone works. The problem is in your app's settings: the address, the token, or a server type other than HTTP (Streamable HTTP). Fix the config and restart the app.
401 UnauthorizedThe token is wrong, or this connection is off in Marrow. Each connection in Your connections has its own token, and turning one off locks that app out while the others keep working. Switch it on, or copy its token again.
404 Not Found with use POST /mcpThe path is wrong. The address ends in /mcp.
Connection refused, or no answer until it times outThe computer cannot reach the phone. Work through the list below.

Setup and fixes for one app at a time, Claude Code, Cursor, VS Code and more, are under connections.

What this costs

Nothing. Agent access is in the free tier, along with background sync, automated export, CSV and JSON export, and barcode scanning. Health Auto Export shipped an MCP server before Marrow did, and it is good, but theirs requires a Premium subscription. That difference, not primacy, is the claim worth making.

Requirements