AgentKit supports multiple wallet providers, with the CDP Wallet API being the default implementation. It supports the following operations, alongside compatibility with the full suite of CDP products including Onramp, onchain reputation score, and Commerce:

Wallet Configuration

You can configure AgentKit to use a CDP wallet or a custom wallet provider.

The CDP Wallet v2 API is the recommended wallet provider for AgentKit. It supports both EVM and Solana chains, seamlessly and securely handles private keys, and is compatible with viem.

import {
  AgentKit,
  CdpV2WalletProvider,
  CdpV2EvmWalletProvider, // for evm
  CdpV2SolanaWalletProvider, // for solana
} from "@coinbase/agentkit";

// Configure CDP Wallet Provider
const cdpWalletConfig = {
  apiKeyId: process.env.CDP_API_KEY_ID, // from https://portal.cdp.coinbase.com , see v2 wallet quickstart for more details
  apiKeySecret: process.env.CDP_API_KEY_SECRET,
  walletSecret: process.env.CDP_WALLET_SECRET,
  idempotencyKey: process.env.IDEMPOTENCY_KEY, // optional, used for account creation
  address: process.env.ADDRESS as `0x${string}` | undefined, // optional, used for existing account
  networkId: process.env.NETWORK_ID, // e.g. "base", "base-sepolia", "solana"
};

const walletProvider = await CdpV2WalletProvider.configureWithWallet(cdpWalletConfig);

// ...
// Initialize AgentKit
const agentkit = await AgentKit.from({
  walletProvider,
  actionProviders: [],
});

Default Operations

By default, AgentKit supports the following basic wallet operations:

  • get_wallet_details - Get details about the Wallet, like the address
  • transfer - Transfer assets between addresses
  • get_balance - Get the balance of an asset

You can add additional actions or action providers upon agent instantiation.