Magenta Canon is a verifiable MCP accountability gateway — a chain of custody for AI actions. It sits between an AI agent — Claude Code, Cursor, or your own — and the tools it can call, gating each tools/call against operator-delegated capabilities before it executes, recording every allow and block, and producing cryptographic evidence anyone can verify with a standalone verifier. It answers two questions: was this agent allowed to do this, and can we prove what happened afterward.

  • Gate-first: authorized actions are allowed and over-authority actions are blocked before they reach the tool
  • Recorded: every allow and block becomes a signed, hash-chained receipt on a Merkle transparency log
  • Verifiable: a standalone verifier re-derives the cryptography and shares no code with the server
  • Scope, stated precisely: enforcement covers the MCP tools/call method class; other MCP methods pass through ungated
  • Maturity, in three states: proven today, building now (the multi-tenant Human Plane — not production-active), and roadmap

VERIFIABLE MCP ACCOUNTABILITY GATEWAY

Govern what AI agents may do. Prove what they did.

AI agents increasingly touch real systems. Magenta sits at the tool boundary between the agent and those systems: it allows the actions you delegated, blocks the rest before they reach the tool, records both, and produces evidence anyone can independently check.

A reference implementation you run yourself, under private design-partner evaluation — verify, don't trust.


What Magenta Canon Is

Magenta Canon is a verifiable MCP accountability gateway for AI-agent tool calls — a chain of custody for AI actions. It evaluates each tools/call against the operator-delegated capability at the gate — allowing authorized calls, blocking over-authority calls before they reach the downstream tool, and capturing tamper-evident evidence for both. Enforcement is scoped to that method class; other MCP methods are forwarded ungated.


The Proof Loop

The same demo runs every time: an $89 refund is allowed, a $250 refund is blocked at the gate, the downstream tool's own log shows the blocked call never arrived, the evidence verifies, and one flipped byte makes verification fail.

  • Allowed

    An $89 refund within the delegated ceiling is forwarded to the tool.

  • Blocked

    A $250 refund exceeds the ceiling and is blocked before it reaches the tool.

  • Recorded

    Allow and block alike become signed, hash-chained receipts on a Merkle log.

  • Verified

    A standalone verifier returns VERIFIED — and fails if the evidence is tampered.


Verify, Don't Trust

The standalone verifier re-derives the cryptography and shares no code with the server. A committed sample evidence bundle ships in the repository, so the allow and block decisions can be checked independently — without trusting, or running, the Magenta server.


Where we are today

Three states, never blurred: what is proven now, what is being built now, and what is not built yet.

Proven today

Committed evidence on the main branch — runnable, or exercised by CI. Items marked supported exist but their guarantee depends on how the operator deploys them.

  • Gate-first MCP accountability gateway on tools/call — stdio and Streamable-HTTP self-host
  • Operator-delegated capability grants with hard ceilings, evaluated default-deny
  • Allowed before execution; blocked before the call reaches the downstream tool
  • The downstream tool's own log corroborates that a blocked call never arrived
  • Signed, hash-chained receipts for allow and block alike, on a Merkle transparency log
  • A standalone verifier that shares no code with the server, pinning two separate anchors — the witness key and the ceremony-sourced receipt-issuer key
  • Tamper negative control — one flipped byte makes verification fail
  • Bounded assignment enforcement on the stdio gateway — one agent, one run, one time window: expiry, revocation, agent/run binding, explicit tool denial, grant-id integrity, and a restricting operator-policy overlay, all fail-closed
  • An append-only, hash-chained external STH mirror that detects history rewrite, equivocation, rollback, and mirror tampering once a signed tree head has been mirrored
  • Application-layer organization scoping in the Human Plane (organizations, members, roles, invitations, projects, agents, resources) — supported, environment-gated
  • Durable Postgres and file evidence ledgers, root-authority custody, and replay-nonce continuity — supported, self-host, selector-gated, exercised by CI
  • Committed, reviewable Human-Plane SQL migrations and a provider-neutral PostgreSQL row-level-security isolation substrate — merged and exercised by CI; no shipped code applies the migration or switches the application to a non-owner role, so nothing here puts the policies in force, and this program has applied no production migration
  • Adversarial cross-tenant isolation and schema-parity proofs running in CI against a disposable PostgreSQL instance
  • A transaction-local tenant principal context, designed to receive an already-verified identity — the Wave-2A identity boundary that supplies one has merged, and Wave 2B has since opened that context on the live request path for the converted routes; switching row-level security on is a separate, unbuilt step no shipped code performs
  • A per-request Human-Plane corridor — Track B, Wave 2B PR-1…PR-5: nine read routes and thirteen tenant-scoped mutations execute their storage calls inside one transaction carrying the tenant principal, with the organization-family audit written in that same transaction. Merged and exercised by CI. Carrying the principal is not enforcing a policy: this code switches on no row-level security and applies no migration
  • A provider-neutral identity boundary — Track B, Wave 2A: an opaque, permanent Magenta user identifier and a provider-agnostic identity adapter, merged and exercised by CI
  • Verified-email invitation authority bound to the identity record rather than to a mutable profile field
  • A forward-only Human-Plane identity migration with a definer-owned resolve-or-provision function, and its committed identity-boundary suite
  • First-fact primitives wired and their two routes converted — Track B, Wave 2B PR-6: organization creation and invitation acceptance are single definer-owned database calls, and the application holds no second temporal model of verified-email authority. Merged and exercised by CI on canonical main. It switches on no row-level security and applies no production migration

Building now

Work under way that this page does not represent as proven — not production-active, not available to run, and not to be relied upon. Ordinary active development and work that is complete and awaiting authorization both sit here. This column takes NO position on whether any item's branch has merged; each item's declared lane lifecycle is where that is recorded, and only the Proven column speaks to canonical main. Nothing occupies this state right now.

Next

Roadmap. Not built. Not to be relied upon.

  • Runtime row-level-security activation on the live request path, behind a runtime mode and startup admission — Track B, Wave 2B PR-7
  • Retirement of ordinary direct member addition, once invitation acceptance is the seated path — Track B, Wave 2B PR-8
  • Production identity-provider selection and activation
  • Hosted multi-tenant operation and a managed customer control plane
  • Subscription, entitlements, and billing as a commercial-access boundary
  • Managed KMS / HSM key custody
  • A hosted, managed, independently operated third-party mirror service (the mirror mechanism itself is proven today; what is missing is independent operation of it)
  • Per-request runtime enforcement of assignment authority on the HTTP transport, which today refuses to start rather than run an assignment it cannot enforce
  • A wired human-approval path, so a require-review decision can become an approval instead of a refusal

Not yet production-active. Three Track-B lanes have landed on the main branch and are exercised by CI. Wave 1 is the isolation substrate: committed Human-Plane migrations, provider-neutral PostgreSQL row-level-security policies, transaction-local tenant-context primitives, and adversarial cross-tenant and schema-parity proofs. Wave 2A is the provider-neutral identity boundary: an opaque, permanent Magenta user identifier, a provider-agnostic identity adapter, and verified-email invitation authority. Wave 2B PR-1 through PR-5 is the per-request corridor: nine read routes and thirteen tenant-scoped mutations now execute their storage calls inside one transaction carrying the tenant principal, with the organization-family audit written in that same transaction. PR-1 through PR-5 themselves did not convert the two first-fact routes, organization creation and invitation acceptance — at the PR-1…PR-5 landing state those two routes remained on the compatibility path. Converting them, and wiring their first-fact database primitives, is Wave 2B PR-6, which has since landed on the main branch and is exercised by CI there. NONE of that is activation. Carrying the tenant principal is not enforcing a policy: the row-level-security policies bind only on a database where migration 0002 has been applied and the application runs as a non-owner role, and no shipped code performs either step. This project has applied no production migration, has selected and activated no production identity provider, and operates no hosted multi-tenant service. Wave 2B PR-7 and PR-8 — the runtime mode and startup admission, and the direct-add retirement — are not built, and activation itself remains a separate owner step after them. Because this is self-hostable software, these are statements about this project and this repository; what any independent operator has done on their own database is not something this repository can observe.


Honest Scope

Magenta Canon is a reference implementation you run yourself. The hosted evidence surface is ephemeral unless a durable ledger selector is set, and the demo's witness key is not a production key. Evaluation is private-access and repo-source; there is no public package. Under-claiming is the brand: nothing moves out of roadmap ahead of its evidence.