Deep First Search: safe x402 payments for AI agents
Safe rails for the agent economy. Search deep. Reveal only what you choose.
AI agents now pay for things over x402. Every one of those payments is public, and any agent can be talked into paying the wrong party. Deep First Search makes the model propose payments while the owner's signed policy decides.
Try it in 10 seconds
No keys, no wallet, no chain: a local x402 merchant plays honest and hostile, and you watch the agent pay for data and refuse four attacks.
npx @deepfirstsearch/agent-pay demo
Pick your path
The integrations take the SDK as a peer dependency, so your app always uses a single copy of it. Step-by-step guides for 40 x402 merchants, each tested with a real payment on Base mainnet, are in docs/integrations.
Full developer guide: deepfirstsearch.com/developers · building a wallet, framework or platform? Partners.
What's in this repository
MCP server: let Claude or Cursor pay x402 APIs safely
@deepfirstsearch/agent-pay-mcp is a stdio MCP server. The model gets three tools and nothing that can move money on its own terms:
{ "mcpServers": { "agent-pay": {
"command": "npx", "args": ["-y", "@deepfirstsearch/agent-pay-mcp", "/path/config.json"],
"env": { "AGENT_PAY_AGENT_KEY": "0x…", "AGENT_PAY_BURNER_SEED": "0x…" } } } }
Payees, prices and limits come from the config file and the owner-signed on-chain budget, never from the model or a 402 response, so a prompt-injected agent can't overspend or pay an attacker. Setup, config reference and a 5-minute Base Sepolia demo: integrations/mcp.
Status: pre-launch. Live on Base Sepolia, with a real x402 payment settled (see deployments); unaudited beta on Base mainnet since 2026-10-06 (small amounts, our own funds first, then invited design partners) while we arrange an independent audit; the public launch comes after the audit. No token exists.
Develop on this repository
# Contracts (needs Foundry: curl -L https://foundry.paradigm.xyz | bash && foundryup)
git submodule update --init --recursive
cd contracts && forge test
# SDK
cd ../sdk && npm ci && npm test && npm run demo
# Website
cd ../web && npm ci && npm run dev
Documents
Key decisions
- Ticker:
$DEPTH. - Chain: Base.
- Founder: 12%, nothing for 12 months, then 36 months linear, on-chain; the vesting contract cannot be transferred and the beneficiary is a public Safe.
- Burn: burn-to-claim fee jar (no swaps, oracles or admins), fed only by Agent Safe, SDK and inference fees, never by privacy-pool fees.
- No conference booth until there are users; hackathons instead.
- No own privacy pool: integrate a third-party compliant one (ADR-011). Sales geo-blocked for the US and Argentina (ADR-012).
Using it? Tell us
There's no telemetry in the packages, so we only know who uses them if you say so. If your agent pays with Agent Safe, even once on testnet, tell us in this discussion: what it pays for, what got refused that shouldn't have, and what's missing. We'll test your sellers live and write a verified guide for any that's missing.
Security
See SECURITY.md to report vulnerabilities.
Contact
Built by Nicolas Tursi. General contact: [email protected]. Security reports: see SECURITY.md or write to [email protected].
License
MIT (contracts and SDK).