MCP Directory

Coinbase AgentKit MCP Extension

Official

Coinbase's AgentKit MCP extension for onchain actions: transfers, swaps, and contract calls.

Verified
stdio (local)
API key
TypeScript

Add to your client

Copy the config for your MCP client and paste it into its config file.

Install / run
npm install @coinbase/agentkit @coinbase/agentkit-model-context-protocol @modelcontextprotocol/sdk

Paste into ~/Library/Application Support/Claude/claude_desktop_config.json

{
  "mcpServers": {
    "coinbase-agentkit-mcp-extension": {
      "command": "node",
      "args": [
        "/absolute/path/to/your-agentkit-mcp-server.js"
      ],
      "env": {
        "CDP_API_KEY_NAME": "<your-cdp-api-key-name>",
        "CDP_API_KEY_PRIVATE_KEY": "<your-cdp-api-private-key>"
      }
    }
  }
}

Step-by-step guides: Add to Claude Desktop · Add to Cursor · Add to Windsurf

Before you start

  • Node.js 18 or higher
  • A CDP (Coinbase Developer Platform) API key — create one at portal.cdp.coinbase.com/access/api (used as cdpApiKeyId / cdpApiKeySecret)
  • Install `@coinbase/agentkit-model-context-protocol`, `@coinbase/agentkit`, and `@modelcontextprotocol/sdk`
  • A wallet/wallet provider configured in AgentKit (testnet recommended to start)

About Coinbase AgentKit MCP Extension

The Coinbase AgentKit MCP extension (@coinbase/agentkit-model-context-protocol) is an adapter that turns AgentKit's onchain actions into Model Context Protocol tools. Unlike a turnkey server, you write a tiny stdio server: initialize an AgentKit instance with a wallet and action providers, call getMcpTools(agentKit) to get { tools, toolHandler }, then register those with the MCP SDK's ListToolsRequestSchema and CallToolRequestSchema handlers.

Because the exposed tools are whatever AgentKit action providers you configure, the surface is flexible. Out of the box the default WalletActionProvider gives you get_wallet_details, get_balance, and native_transfer; adding providers like ERC20, ERC721, WETH, Morpho, Pyth, WOW, OpenSea, and the CDP wallet/API providers expands this to 50+ onchain actions (transfers, swaps, token approvals, NFT mints/transfers, faucet funding, price feeds, and more).

This is the write-capable counterpart to read-only data servers: with a funded wallet configured, an agent can actually move assets and call contracts. Scope the wallet and providers carefully, and prefer testnets and spend limits when experimenting.

Tools & capabilities (9)

get_wallet_details

Return the connected wallet's address and details (default WalletActionProvider)

get_balance

Get the native asset balance of the wallet (default)

native_transfer

Transfer the native asset between addresses (default)

erc20 actions

Get token balance, transfer, approve, and check allowance for ERC-20 tokens (ERC20 action provider)

erc721 actions

Get NFT balance, mint, and transfer ERC-721 tokens (ERC721 action provider)

request_faucet_funds

Request testnet funds via the CDP faucet (CDP action provider)

swap / trade actions

Token swaps via DEX/aggregator providers (e.g. ZeroX, Jupiter, Sushi) when those providers are enabled

DeFi protocol actions

Supply/borrow/earn via providers such as Morpho, Compound, Moonwell, and Superfluid

price feed actions

Fetch on-chain prices via the Pyth action provider

When to use it

  • Use it when you want an MCP agent that can actually execute onchain actions, not just read data
  • Use it when building a wallet/transfer assistant — checking balances and sending native or ERC-20 tokens
  • Use it when integrating DeFi actions (swaps, lending via Morpho/Compound) into an agent workflow
  • Use it when you already use AgentKit and want to expose its actions to any MCP client (Claude Desktop, Cursor)
  • Use it when prototyping on testnets with faucet funding before moving to mainnet

Quick setup

  1. 1Create a CDP API key at portal.cdp.coinbase.com/access/api
  2. 2Install the three packages: agentkit-model-context-protocol, agentkit, and the MCP SDK
  3. 3Write a small stdio server: initialize AgentKit with your wallet + action providers and credentials
  4. 4Call `getMcpTools(agentKit)` and wire `tools`/`toolHandler` into ListTools and CallTool request handlers
  5. 5Connect the server over StdioServerTransport, then point your MCP client at it and restart
  6. 6Verify with a read action like `get_wallet_details` before enabling transfers

Security notes

Configured with a CDP-managed wallet it can sign and broadcast onchain transactions that move real assets; use a CDP wallet funded with minimal value while testing. Keep CDP_API_KEY_NAME and CDP_API_KEY_PRIVATE_KEY out of source control.

Coinbase AgentKit MCP Extension FAQ

Is this a ready-to-run server or a library?

It's an adapter/library. You write a short stdio MCP server that calls `getMcpTools(agentKit)`; the AgentKit repo includes an example (model-context-protocol-smart-wallet-server) you can copy.

What tools does it expose?

Whatever AgentKit action providers you enable. The default WalletActionProvider gives get_wallet_details, get_balance, and native_transfer; adding providers unlocks 50+ actions across ERC20/721, DeFi, swaps, and price feeds.

Can it move real funds?

Yes — with a funded mainnet wallet, configured actions can send tokens and call contracts. Use testnets, limited wallets, and spend caps while developing.

What credentials do I need?

A Coinbase Developer Platform (CDP) API key passed as cdpApiKeyId/cdpApiKeySecret, plus a wallet provider. Node.js 18+ is required.

Which is more featureful, the TypeScript or Python version?

The TypeScript/Node.js AgentKit supports more crypto-specific actions than Python (50+ vs 30+). The MCP extension is part of the TypeScript framework extensions.

Alternatives to Coinbase AgentKit MCP Extension

Compare all alternatives →

Official Stripe server for payments, customers, subscriptions, invoices, and billing via natural language.

Featured
Verified
stdio (local)
API key
TypeScript
12 tools
Updated 1 month agoRepo

Alpaca's official trading server for stocks, ETFs, options, and crypto in plain English.

Verified
stdio (local)
API key
Python
12 tools
Updated 26 days agoRepo

Interact with 60+ EVM chains: balances, transfers, contracts, ENS, and ABI fetching.

Verified
stdio (local)
API key
Stale
TypeScript
12 tools
Updated 6 months agoRepo