{
  "markdown": "# DarkMatter MCP Server\n\nUniversal MCP server that emits [Context Passport](https://contextpassport.com) records for AI agent decisions and actions. Drop into any MCP-compatible client (Claude Code, Cursor, Cline, Continue, ChatGPT Desktop, Zed, Goose, and others) to give your agent a `commit / verify / replay / export` toolset for verifiable, tamper-evident records.\n\n**Built by [DarkMatter](https://darkmatterhub.ai). Implements [Context Passport v2.0](https://github.com/contextpassport/spec), an open CC0 standard. Records emitted by this server use RFC 8785 (JCS) canonicalization and are byte-equivalent across the Python and TypeScript reference SDKs.**\n\n## Install\n\nIn your MCP client's config (`claude_desktop_config.json`, Cursor's `mcp.json`, etc.):\n\n```json\n{\n  \"mcpServers\": {\n    \"darkmatter\": {\n      \"command\": \"npx\",\n      \"args\": [\"-y\", \"@darkmatterhub/mcp-server\"]\n    }\n  }\n}\n```\n\nRestart the client. Five tools become available to your agent:\n\n- `darkmatter_commit` — record an agent decision or action\n- `darkmatter_verify` — check that the chain has not been tampered with\n- `darkmatter_replay` — walk the full chain in order\n- `darkmatter_export` — produce a portable proof bundle\n- `darkmatter_list_sessions` — see what sessions exist locally\n\n## Bundles explain themselves\n\n`darkmatter_export` produces a bundle that a stranger can act on. Alongside the\nrecords it carries the format name, a link to the specification, whether the\nchain was intact at export time, and the exact command to verify it in Python or\nTypeScript, plus what a failure looks like.\n\nThat matters because the bundle is the artifact that leaves your machine. It\ngoes to an auditor, a regulator or a counterparty who has never heard of this\nformat, and the whole claim is that they can check it without trusting whoever\nsent it. A bundle that does not say how is asking to be trusted.\n\n## Local by default, published when you ask\n\nWith no configuration the server keeps every record on your own disk. The\nchain verifies offline through `darkmatter_verify`, so you can evaluate the\nwhole idea without an account.\n\nSet an API key to publish records and get a link somebody else can check:\n\n| Variable | Effect |\n|---|---|\n| `DARKMATTER_API_KEY` | Publishes each record to DarkMatter and returns a `verify_url`. Get one at [darkmatterhub.ai](https://darkmatterhub.ai). |\n| `DARKMATTER_SHARE` | Set to `true` to make published records readable by anyone with the link. Off by default, because publishing is not something to do to your records without being asked. |\n| `DARKMATTER_API_URL` | Override the API host. Defaults to `https://darkmatterhub.ai`. |\n| `DARKMATTER_MCP_STORE_DIR` | Where local records are written. |\n\n`commit` reports which of the two happened, in the `storage` field. If\npublishing fails the record is still committed locally and the error is\nreturned alongside it, so a network problem cannot cost you the record.\n\n> **Changed in 0.3.0.** Earlier versions returned a\n> `https://darkmatterhub.ai/r/{id}` link for every commit while making no\n> network calls at all, so the link always 404ed. A verification URL is now\n> returned only when there is a published record behind it.\n\n## What gets captured\n\nWhatever the agent (or user) explicitly invokes via `darkmatter_commit`. Auto-capture of every tool call without explicit invocation is a separate component (see [Auto-capture](#auto-capture) below).\n\nExample agent flow:\n\n```\nUser:    Approve the refund for order #1247 and record the decision.\nAgent:   Calls refund_order(1247).\nAgent:   Calls darkmatter_commit({\n           input: \"Approve refund for order #1247\",\n           output: \"Approved. $84.00 refunded to original payment method.\",\n           role: \"compliance\",\n           event_type: \"commit\"\n         })\nResult:  { ok: true, passport: {...}, storage: \"local\", verify_url: null,\n           note: \"Saved locally and verifiable offline...\" }\n```\n\nThe passport is signed (if a key is configured), hash-chained to the previous commit in the session, and stored locally at `~/.darkmatter/mcp/<session_id>/chain.jsonl`.\n\n## Storage\n\nDefault: local-only. Passports never leave the machine.\n\n```\n~/.darkmatter/mcp/\n├── default/\n│   ├── chain.jsonl        # append-only stream of all commits\n│   └── latest.json        # most recent passport (used as parent for the next)\n└── <other-session-id>/\n    └── ...\n```\n\nTo forward each passport to a DarkMatter receiving server in addition to local storage, set:\n\n```bash\nexport DARKMATTER_API_KEY=\"dm_sk_...\"\n```\n\nThe forwarding is best-effort and never blocks the agent's tool call. Local storage remains the source of truth.\n\n## Auto-capture\n\nThe MCP server captures only what the agent explicitly invokes. To auto-capture every tool call and turn boundary in a specific dev tool (without the agent having to remember to call `darkmatter_commit`), install one of the dev-tool-specific adapters:\n\n- [darkmatter-hub/claude-code](https://github.com/darkmatter-hub/claude-code) — auto-capture for Claude Code (Anthropic)\n- Cursor adapter — planned\n- OpenAI Codex adapter — planned\n- Aider adapter — community-built welcome\n\nEach adapter hooks into its specific dev tool's event lifecycle and routes events through this MCP server's `darkmatter_commit` tool. One canonical endpoint, many capture surfaces.\n\n## Verification\n\nRecords are valid Context Passport v2.0 artifacts. Verify with any conformant implementation:\n\n```bash\npip install context-passport context-passport-conformance\ncontext-passport-conformance --level signed     # 9/9 vectors, no --vectors-dir needed\n```\n\nThe conformance package ships its vectors inside the wheel, so this is a one-line check against the public reference suite.\n\nOr use the offline reference verifier directly on the JSONL file:\n\n```python\nimport json\nfrom context_passport import verify_chain\n\nwith open(\"~/.darkmatter/mcp/default/chain.jsonl\") as f:\n    chain = [json.loads(line) for line in f]\n\nprint(verify_chain(chain))  # True if intact, False if tampered\n```\n\n## Why MCP\n\nMCP (Model Context Protocol) is becoming the universal interop layer for AI tools. Writing this server once means it works in every MCP-compatible client without per-client integration code. See the [Context Passport for MCP proposal](https://github.com/contextpassport/spec/blob/main/proposals/context-passport-for-mcp.md) for the broader architectural rationale.\n\n## License\n\nApache-2.0. See `LICENSE`.\n\nThe Context Passport schema this server implements is released separately under CC0 1.0 at [github.com/contextpassport/spec](https://github.com/contextpassport/spec).\n\n## Related repositories\n\n- [github.com/contextpassport/spec](https://github.com/contextpassport/spec) — the open standard\n- [github.com/contextpassport/python](https://github.com/contextpassport/python) — Python reference SDK\n- [github.com/contextpassport/typescript](https://github.com/contextpassport/typescript) — TypeScript reference SDK\n- [github.com/darkmatter-hub/claude-code](https://github.com/darkmatter-hub/claude-code) — auto-capture for Claude Code\n- [github.com/darkmatter-hub/darkmatter](https://github.com/darkmatter-hub/darkmatter) — DarkMatter receiving server\n",
  "bytes": 7186,
  "sha": "191114deb2d827a644ec75e0094bf1bd53c85b2a4b6685195544ba4e65e4f924",
  "repo_slug": "darkmatter-hub/mcp",
  "fonte": "repo",
  "truncated": false,
  "api": "https://agentalog.com/api/listings/mcp_io_github_darkmatter_hub_mcp_server_4a5ef046/readme"
}