MCP v0.9.3 · 29 tools · 8 prompts · stdio & streamable HTTP

Apple Health MCP Server — live sleep, HRV, cycle & more for your AI agent

Vaultbeat’s open-source local MCP server gives Claude Code, Cursor, Windsurf, Hermes, OpenClaw, or any MCP client continuous read access to your — and optionally your partner’s — Apple Health data, plus structured logging back into your own account. End-to-end encrypted, decrypted locally on your machine, with zero manual exports.

Requires the Vaultbeat — Health MCP for AI iOS app and uvx (handles Python 3.11+ automatically). Source on GitHub.

Step-by-step

Connect Apple Health to Your AI Agent

1

Get the iPhone app

Install Vaultbeat — Health MCP for AI on your iPhone and sign in. Pairing starts a 30-day free trial of full encrypted cloud history and agent access.

2

Install & pair your computer

On the computer where your agent runs, verify the package via uvx (no git clone, no virtualenv), then run bind:

Check status
shell
uvx vaultbeat-apple-health@latest status
Generate QR code & wait
shell
uvx vaultbeat-apple-health@latest bind

bind is the command that draws the QR code — serve prints nothing at all, so do not wait on it for a QR. In the Vaultbeat iOS app, open MCP tab → Connect an AI server (app 1.2.8 and earlier: Settings → Data & AI) and scan it. Your iPhone seals an encrypted copy of each record for this machine’s public key. The private key never leaves that machine: it lives in your system keyring, or in a 0600 file on a headless box, and is never uploaded anywhere.

3

Register with your AI agent

Claude Code one-liner
shell
claude mcp add vaultbeat-health -- uvx vaultbeat-apple-health@latest serve --transport stdio

Done. Ask your AI: “How did I sleep last night?” Reads are cache-first on your machine (10-minute default TTL), so repeat queries answer in about 0.2 seconds.

Setting this up with an agent? Point it at vaultbeat.app/skill.md — machine-readable instructions your coding agent can follow directly.

Universal MCP Configuration

Cursor, Claude Desktop, Windsurf, Hermes & any MCP client

After binding (steps 1–2 above), add this standard MCP block to claude_desktop_config.json, .cursor/mcp.json, Windsurf, or your own agent harness:

Standard MCP JSON
json
{
  "mcpServers": {
    "vaultbeat-health": {
      "command": "uvx",
      "args": ["vaultbeat-apple-health@latest", "serve", "--transport", "stdio"]
    }
  }
}

Using Hermes, OpenClaw, or a custom harness? Keep command as the bare executable (uvx, or its absolute path) and put every flag inside args as a list. Placing the entire command string inside command makes the server exit immediately, which most hosts misreport as Connection closed.

Subprocess (stdio)

Default

Best for Claude Code, Claude Desktop, Cursor, Windsurf, and CLI harnesses spawning local servers.

stdio transport
shell
uvx vaultbeat-apple-health@latest serve --transport stdio

Streamable HTTP

Loopback-first

Binds to loopback by default and requires a bearer token; non-loopback binds fail closed unless explicitly permitted.

HTTP transport
shell
uvx vaultbeat-apple-health@latest serve --transport http

Published Tool Surface

What your agent can do (29 tools)

The published server exposes 29 tools — 17 that read and analyze, and 12 that write. Every read returns your own data unless your agent passes partner=true — and then only categories your partner explicitly enabled. Sensitive categories stay off by default and are never re-exported.

Read & Analysis (17)

Read-only
ToolReturns
vaultbeat_doctorSelf-diagnosis of this install: pairing state, which data types are unavailable and why
get_sleep_nightsEvery night as one compact row — bed and wake time, stages, awakenings, heart and breathing rate while asleep, naps. A year in one call (server 0.9.0+)
get_sleep_detailOne or two nights in depth: stage bands and per-stage heart and breathing rate — the newest nights, or any night by date (server 0.9.1+)
get_menstrual_cycleopt-in onlyCycle samples plus a next-period prediction
get_symptomsSymptom days from Apple Health (only once you turn that on), and beside them the episodes you reported yourself — type, severity, onset and end, place, suspected triggers
get_state_of_mindopt-in onlyMoods — Apple Health's State of Mind, from Apple Watch, the Health app or other apps, plus the ones your AI recorded: how pleasant each felt, the feeling words and life areas, and a per-day count and average — the 100 newest, or a date range for older ones (server 0.9.3+, app 1.3.0+ for the Apple Health half)
get_notesFree-text day annotations with their writer
get_workoutsWorkout records: type, duration, calories, distance
get_user_profileopt-in onlyBiological sex, age and height — for anything that depends on them (BMR, heart-rate zones, VO₂ max bands). Owner only, never shared with a partner. Needs Vaultbeat for iOS 1.2.9 or later
get_metricAny one-number-per-day series — steps, activity, resting HR, HRV, weight, water, wrist temperature, VO₂ max, basal energy, TDEE, mindfulness, sleep duration, timing, stages and awakenings. One, several or all at once; avg / sum / min / max / latest and weekly, monthly or day-of-week buckets computed server-side (server 0.9.0+)
get_intradaySamples within a day for HRV — hourly buckets or raw per-sample (server 0.9.0+)
get_strength_logStrength-training sessions — exercises, sets, reps and weight per day
get_food_logDaily food logs as plain text, with optional portions and timing — the 14 newest days that have a log, or a date range (server 0.9.0+)
list_metric_seriesEvery series name get_metric and the analysis tools accept, with its unit and how much data backs it (server 0.7.0+)
get_metric_trendLeast-squares trend for one daily series — slope per day, endpoints, spread. Numbers only, no verdict (server 0.7.0+)
compare_metric_periodsTwo periods of a series side by side — the newest N days against the N before, or two named date ranges such as a semester and a summer (server 0.7.0+; date ranges 0.9.0+)
correlate_metric_seriesPearson r between two series over days that have both recorded, with the pair count and a causation caveat; can pair a day with a later one (server 0.7.0+; lag 0.9.0+)

Every read tool returns a coverageblock — distinct days covered, date span, and missing days inside that span — so an agent reports “based on 3 days” instead of presenting a three-day sample as a full month.

Write (12)

Owner account only

Your agent can log six kinds of record — food, strength training, weight, notes, reported symptoms, and moods. Three come in pairs: log_* replaces a day while *_append only adds and cannot delete. Every write is encrypted on your machine before upload, and none accepts an owner argument, so an agent can never write into a partner’s account.

ToolWrites
log_weight_entryRecord a weigh-in. Can also sync into Apple Health — only if you enable "Allow AI to update Apple Health" in the MCP tab (app 1.2.8 and earlier: Settings → Data & AI), off by default
log_food_entryRecord a day's meals as plain text, with optional portions and timing. Replaces the whole day — use log_food_append to add to a day that already has entries
log_food_appendAdd meals to a day already logged, leaving everything else that day untouched. Cannot delete anything — prefer this when the day may not be empty
log_strength_entryRecord a strength session — exercises, sets, reps, weight. Replaces the whole day — use log_strength_append to add to a day that already has entries
log_strength_appendAdd exercises to a day already logged, leaving everything else that day untouched. Cannot delete anything — prefer this when the day may not be empty
log_noteRecord a free-text note for a day, so narrative context sits beside the metrics. Replaces that day's note. Sleep and cycle notes stay iOS-authored and are refused; from server 0.9.3 a feeling goes to log_state_of_mind instead
log_note_appendAdd a line to a day's note, leaving the existing text untouched. Cannot delete anything
log_symptomRecord one symptom you report — type, your own words, severity, when it started and ended, where, what you suspect set it off — as fields a later read can line up with sleep, food and heart rate (server 0.9.0+)
update_symptomChange a reported symptom, usually its end time once it eased. Only the fields passed change, and the old values come back (server 0.9.0+)
delete_symptomErase a symptom logged by mistake; the deleted entry comes back so it can be re-logged (server 0.9.0+)
log_state_of_mindRecord how you say you feel, in Apple Health's own terms — how pleasant, the feeling words, what it was about. Shows in the app's mood calendar; reaches Apple Health only with "Allow AI to update Apple Health" on, off by default (server 0.9.3+, app 1.3.0+)
delete_state_of_mindErase a mood your AI recorded by mistake; your iPhone also removes the copy it wrote into Apple Health (server 0.9.3+)

Only log_weight_entry and log_state_of_mind can optionally write into Apple Health when you switch on MCP tab → “Allow AI to update Apple Health” (app 1.2.8 and earlier: Settings → Data & AI) — off by default. See the Privacy Policy or the GitHub README.

Built-in Guardrails

And 8 prompts, so your agent never guesses how

Tools define what an agent can call; prompts/list teaches it how not to mislead you. Each prompt enforces two rules: state data coverage before drawing conclusions (describe rather than prescribe, invent no arbitrary scores), and never treat an absent reading as zero. Every argument is optional.

PromptWhat it instructs your agent to do
daily_briefThe most recent day, set against the fortnight behind it — and it names the newest date it can actually see before drawing anything from it
sleep_reviewnights (optional)Duration and stages across recent nights. Nights where the watch logged time in bed without ever measuring sleep stay their own category instead of averaging in as zero-minute nights that never happened
energy_balancedays (optional)Calories in against calories out, with the days missing hours of basal data excluded rather than quietly dragging the average down
training_block_reviewdays (optional)Lifting and cardio volume beside the recovery signals from the same weeks — offered as context, never as a verdict on the block
cycle_aware_readmetric (optional)A metric read against the same phase of earlier cycles instead of against last week, which mixes phases and manufactures a trend out of an ordinary rhythm
partner_check_indays (optional)Both of you side by side, read once per person rather than averaged across two bodies — and described rather than assessed, because sharing is a kindness and not a monitoring feature
log_from_conversationentry (optional)Turns something you said in passing into an entry, and asks you for a weight, rep count or portion it was not told rather than reaching for a plausible one
why_is_this_emptycontext (optional)Works out which of the four causes is behind an empty or stale read, then gives the single next step for that one instead of a checklist of all four

Live Sync vs. Static Files

Why not just export my Apple Health XML?

Most Apple Health MCP servers query a manual export snapshot that is stale the moment it lands. Vaultbeat pairs a native iPhone background sync app with a local decrypting MCP server. For a full ecosystem breakdown including MetricBridge, Health Auto Export, HealthMirror, and hosted services, read our honest Apple Health MCP comparison.

DimensionExport-based MCP serversVaultbeat
FreshnessManual XML/CSV export — stale the moment it landsContinuous background sync — always current
WorkflowRe-export, unzip, and point scripts again every weekBind once with a QR scan; your agent just asks
CapabilitiesRead-only file queries17 read & analysis tools + 12 bidirectional writes
PeopleSingle user onlySingle-user first, plus optional per-category encrypted partner sharing
SecurityPlaintext export files sitting on diskAlways-on E2EE — cloud holds ciphertext only; keys stay on your hardware

Cryptography

How the end-to-end encryption works

Every health record is sealed on your iPhone with AES-GCM-256 under a random data key, and that key is wrapped per authorized recipient using Curve25519 ECDH with HKDF-SHA256 — one envelope for you, one for your partner if sharing is enabled, and one for each computer you pair. Our cloud stores and routes ciphertext only; we hold no decryption keys and cannot read your health data — architecturally, not by policy.

When you bind a computer, it generates its own Curve25519 keypair locally. The private key stays in your system keyring (or a 0600 file on headless Linux) and is never uploaded anywhere. The decryption code is open source on GitHub — audit it.

FAQ

Frequently asked questions

My agent suddenly cannot read my health data — what should I check?
Check https://vaultbeat.app/status first. It shows whether the sync endpoint your agent reads through is reachable right now. If a service is degraded, waiting is the fix — do not re-pair, since that means setting your AI connection up again for nothing. If everything there is operational, run `uvx vaultbeat-apple-health@latest doctor`, which walks the whole chain locally: config present, keypair usable, binding valid, cloud reachable, and a real record decrypted end to end.
How is this different from exporting my Apple Health data?
An export is a snapshot: you hand your agent a file, and it is stale from the moment it lands — asking a fresh question next week means repeating the export, the unzip and the file path. Vaultbeat syncs continuously from HealthKit, so your agent reads last night’s sleep without you doing anything. The reason most Apple Health MCP servers work from exports is structural rather than a shortcut: HealthKit is only reachable through an iOS app holding the user’s permission, so a server that installs from npm or PyPI alone has no way to read it directly. Vaultbeat ships that iOS half — and the cloud in between only ever holds ciphertext, because the decryption key never leaves your machine.
Do I need a computer, or does this work from my phone alone?
You need a computer — the same one your AI agent runs on. The MCP server runs locally there, which is exactly what keeps the decryption key off our servers: run `uvx vaultbeat-apple-health@latest bind` on that machine and scan the QR code it prints with the iPhone app to pair them. Your phone records and syncs on its own, but an AI reading that data always happens on hardware you control.
Do I need an Apple Watch?
No. Without a Watch, Vaultbeat uses Apple’s on-device Motion & Fitness inference on your iPhone to record sleep sessions, and your agent reads them the same way. An Apple Watch adds stage-level detail (core, deep, REM) and heart-rate samples during sleep — when both sources exist, Vaultbeat automatically prefers the Watch record.
Can my agent read my partner’s data?
Yes — with their explicit consent, granted per category from their own phone. Vaultbeat is a health app on the App Store designed to be read by your own AI agent, and that extends to partner data: ask Claude Code, Hermes, or OpenClaw how your partner slept, and it answers from the records they chose to share. Sensitive categories are off by default and revocable at any time.
Which plan do I need?
None to start, in Vaultbeat 1.2.3 and later: connecting an AI server is open on every plan, and once your machine is paired you get a 30-day free trial of the full agent interface. (On 1.2.2 and earlier, connecting still requires Pro — update the app first.) After that, continued agent access is Vaultbeat Pro: $9.99/month, $29.99/year, or $74.99 lifetime, which also unlocks full history and trend charts in the app. From app 1.2.9 the cloud is part of a membership: with Pro or a live trial (yours or your partner’s) your whole history is uploaded, and a free account uploads nothing (on app 1.2.8 and earlier, Free and the trial upload the last 7 days).
Is my data used to train AI?
No — and not just as a policy promise: it is impossible by design. The cloud stores ciphertext only, and Vaultbeat holds no decryption keys, so there is nothing readable to train on. Your data is decrypted in exactly three user-chosen places: your own devices, an opted-in partner’s device, and the machine you explicitly paired.

Need help or spot a bug? Check service status, email support@vaultbeat.app, or open an issue on GitHub.