Build onchain with CDP SDK
Multi-language SDK for managing EVM and Solana wallets with CDP-secured private keys stored in a Trusted Execution Environment.
Quick start
Get up and running with CDP SDK in minutes
Install the SDK
Choose your preferred language and install the CDP SDK package.npm install @coinbase/cdp-sdk
Get your API credentials
Create a CDP API Key in the Coinbase Developer Platform Portal. Save your API Key ID, API Key Secret, and Wallet Secret.export CDP_API_KEY_ID="your-api-key-id"
export CDP_API_KEY_SECRET="your-api-key-secret"
export CDP_WALLET_SECRET="your-wallet-secret"
Initialize the client
Create a CDP client instance and start building. TypeScript
Python
Rust
Go
import { CdpClient } from "@coinbase/cdp-sdk";
const cdp = new CdpClient();
from cdp import CdpClient
cdp = CdpClient()
use cdp_sdk::CdpClient;
let cdp = CdpClient::new()?;
import "github.com/coinbase/cdp-sdk/go/cdp"
client, err := cdp.NewClient()
Create your first account
Create an EVM or Solana account and start transacting.// Create an EVM account
const account = await cdp.evm.createServerAccount({
network: "base-mainnet"
});
console.log("Account address:", account.address);
# Create an EVM account
account = cdp.evm.create_server_account(
network="base-mainnet"
)
print(f"Account address: {account.address}")
Explore by topic
Learn about the core features and capabilities of CDP SDK
EVM accounts
Create and manage accounts on EVM-compatible blockchains like Ethereum, Base, and Polygon.
Solana accounts
Build on Solana with server-managed accounts and secure key storage.
Smart accounts
Leverage ERC-4337 account abstraction for gasless transactions and advanced features.
Token transfers
Send native tokens and ERC-20 assets across supported networks.
Policy management
Control transaction permissions with granular policy rules.
Authentication
Secure your application with CDP API keys and JWT authentication.
Multi-language support
CDP SDK is available for TypeScript, Python, Rust, and Go
Resources
Get help and connect with the community
Examples
Browse runnable code examples for all supported languages.
Discord community
Join the #cdp-sdk channel for questions and support.
GitHub repository
Contribute to the SDK and report issues on GitHub.
Ready to start building?
Create your first onchain application with CDP SDK in minutes. Get your API keys and start transacting on EVM and Solana blockchains.
Get Started