Frequently Asked Questions
Everything you need to know about x402Guard, the x402 protocol, and non-custodial AI agent security.
About x402Guard
What is x402Guard?
x402Guard is a non-custodial safety proxy for autonomous AI agents that make DeFi payments using the x402 protocol. It enforces spend limits, contract whitelists, and session keys on every payment — without ever taking custody of your funds.
What is the x402 protocol?
x402 is an HTTP payment protocol that allows AI agents to make machine-to-machine micropayments using stablecoins (primarily USDC). When an agent requests a paid API, the server responds with HTTP 402 "Payment Required" and the agent fulfills the payment automatically.
Is x402Guard open-source?
Yes. x402Guard is fully open-source under the MIT License. The Rust proxy, Next.js dashboard, Solana program, and all framework plugins are on GitHub at DzikPasnik/x402Guard. You can audit, fork, and self-host it.
Security model
Is x402Guard custodial? Does it hold my funds?
No. x402Guard is fully non-custodial. It never holds your private keys or funds. It acts as a proxy that intercepts payment requests and enforces your rules before forwarding approved payments. Your wallet and keys remain entirely under your control.
How does the non-custodial model work technically?
Your AI agent signs payment authorizations using its own private key. x402Guard validates the authorization, checks it against your guardrail rules (spend limit, whitelist, session key validity), and either forwards or rejects it. At no point does x402Guard sign anything or hold funds.
Can x402Guard be bypassed by a compromised agent?
x402Guard is a mandatory proxy layer — your agent routes payments through it. The session key design limits what an agent can sign even if compromised, and the whitelist prevents payments to unknown addresses regardless of how the agent is instructed.
Guardrail features
How do spend limits work?
Two layers: a per-transaction cap (max USDC per single payment) and a daily cap (max total USDC per 24-hour window). Both are checked atomically before any payment is forwarded, preventing race conditions where two simultaneous payments could both slip under the cap.
What is a contract whitelist?
A list of approved smart contract addresses your agent is allowed to pay. Any payment to an unlisted address is blocked before it reaches the blockchain. x402Guard validates both the payment authority and the destination address.
What are EIP-7702 session keys?
Temporary, limited-scope signing keys that give your agent permission to sign transactions for a defined period. When the session expires, the key is automatically revoked — your main wallet private key is never exposed to the agent.
Is there an audit log?
Yes. Every payment attempt — approved or blocked — is written to an immutable audit log. The log is append-only with a database-level trigger that prevents updates or deletes. You can query the full history from the dashboard.
Integration
Which AI agent frameworks does x402Guard support?
x402Guard has official plugins for ElizaOS, Virtuals Protocol, Cod3x, and OpenClaw. Any agent using the x402 protocol can also be secured by routing payments through the x402Guard proxy endpoint.
Which blockchains are supported?
Base (EVM, including EIP-7702 session keys) and Solana (via Anchor program). Support for additional EVM chains is planned.
How long does integration take?
For ElizaOS, Virtuals, Cod3x, or OpenClaw: install the plugin, set your proxy URL and guardrail config — about 5 minutes. For custom agents: configure your agent to route x402 payments through the x402Guard proxy endpoint instead of directly to the network.
Still have questions?
Open an issue on GitHub or check the full documentation.