Connect your agent
Canopy is bring-your-own-agent. You've already built an agent (or you're about to) — these guides show you how to wire it up to Canopy in about five minutes.
Start with MCP if your runtime supports it
Most modern agent runtimes speak MCP. If yours does — claude.ai, ChatGPT, Claude Agent SDK, Claude Desktop, Cursor, VS Code, Zed, Cline, Windsurf — paste Canopy's Remote MCP URL into the host's connector settings and your agent gets policy-gated canopy_pay, canopy_check_url, canopy_discover_services, canopy_approve, and canopy_deny tools with no code changes. One URL, every host.
Use the native SDK adapters below when MCP isn't a fit: backend scripts that call canopy.pay() directly, x402 auto-paying via canopy.fetch(), raw chat.completions.create / messages.create flows, or runtimes without MCP support yet.
Every framework guide walks you through the same six steps:
- Connect your agent in the Canopy dashboard — pick an existing policy or create a new one in the flow
- Copy your org API key and the new agent ID from the dashboard — or run
npx @canopy-ai/sdk connectto do steps 2 and 4 in one browser-based consent. - Install the Canopy package in your project
- Set
CANOPY_API_KEYandCANOPY_AGENT_IDas environment variables - Paste a framework-specific snippet into your existing agent code
- Run your agent — it shows up as connected in the dashboard within a second
Pick your framework:
Don't see your framework?
Canopy works with any agent that can call an HTTP API. Use the TypeScript SDK or Python SDK directly, or call the HTTP API.