apple-docs-mcp

An MCP server and CLI that searches Apple Developer Documentation from Xcode's on-disk index — fully offline, no network calls.

Why it exists

Coding agents recall Apple APIs from training data that lags the installed SDK. Xcode already ships a local copy of the documentation, but the prose cannot be read where it sits: index.json holds navigation nodes with no prose at all, cache.db stores compressed blobs whose header decodes under none of LZ4, LZFSE, zlib, LZMA or LZBITMAP, and documentation-db/index.sql is a vector store for Xcode's own semantic search rather than text. This server exposes the real text — signatures, availability and code examples.

What it does

Stack

Usage

claude mcp add apple-docs --scope user -- \
  uv run --quiet --project /path/to/apple-docs-mcp apple-docs-mcp
apple-docs search "SwiftData model inheritance" --framework SwiftData
apple-docs search "AVAudioSession category" --json
apple-docs frameworks
apple-docs status

Engineering notes

Measured behaviour of the bridge it wraps: 19–20 documents per query with full contents and code examples, roughly 0.4 s median latency, and zero bytes of network traffic. The awkward part is documented rather than hidden — search_docs drives mcpbridge, so Xcode must be running with an approved workspace, approval is granted per process rather than per user, and it expires after 24 hours. Every failure returns a typed error with a remedy, and the tool never returns an empty list to signal a problem, because an empty result is indistinguishable from the API not existing: the exact confusion the project was written to remove. Unit tests need no Xcode, and integration tests skip themselves when the bridge is absent or unapproved.

Limitations

Source: Ahmetshbzz/apple-docs-mcp