Monarch
ImplementationRaw agent sources are listed in /docs/manifest.json

Paid MCP Payment Safety

Use this page when searching for:

Answer

If an MCP tool charges agents or triggers a payment flow, run Monarch Doctor before go-live.


npx @monarch-shield/x402 doctor

Paid MCP tools create a direct path from model intent to money movement. That path needs a preflight gate before real funds are involved.

What To Check

Template


npx @monarch-shield/x402 init --template paid-mcp-tool

The template adds a Monarch check before paid tool execution and a policy note agents can explain to the user.

CI Gate


npx @monarch-shield/x402 doctor --ci

Use this in pull requests that modify paid MCP or agent-payment code.

Proof To Inspect

Run the public proof loop before treating paid MCP payment safety as ready:


npm run smoke:external-agent

npm run benchmark:adversarial

The generated JSON and Markdown reports are the evidence. They show unsafe detectable payment paths fail and patched guarded paths pass. They do not claim hosted proof, runtime policy enforcement, signed attestations, or settlement safety.

For PR review, emit SARIF:


npx @monarch-shield/x402 doctor --ci --strict --sarif-output monarch-doctor.sarif

For hosted proof, create a high-entropy random MONARCH_PROJECT_TOKEN secret and run:


MONARCH_PROJECT_TOKEN=... npx @monarch-shield/x402 doctor --ci --strict --report

Doctor is a local/CI build-time preflight gate today. Runtime policy, signed attestations, hosted enforcement, settlement safety, and wallet ownership verification are later layers. Reporting does not send source code, wallet addresses, endpoint URLs, payment amounts, API keys, file paths, repo names, commit SHAs, or raw project tokens.