Claude Code Setup
This guide covers setting up WalletAgent specifically for Claude Code, Anthropic's official CLI for Claude.
Prerequisites
Claude Code CLI installed and configured (installation guide)
Node.js 18+ or Bun runtime
Installation
Add WalletAgent to Claude Code using bunx (or npx as fallback):
# Using bunx (recommended)
claude mcp add wallet-agent bunx wallet-agent@latest
# Using npx (fallback if bunx not available)
claude mcp add wallet-agent npx wallet-agent@latestThis command:
Downloads the latest version of WalletAgent
Configures it as an MCP server
Makes it available in all Claude Code sessions
💡 Performance Tip: bunx provides faster startup times and better performance than npx.
Verification
Check MCP Status
Verify WalletAgent is installed and running:
You should see output like:
Test Basic Functionality
Try a simple command to ensure everything works:
Expected response:
Configuration Options
Private Key Security: For real wallet operations, use WalletAgent's encrypted keystore or import features.
Claude Code Features
Prompts
Claude Code excels at interpreting prompts. You can use conversational commands:
Context Awareness
Claude Code maintains context across commands:
Error Handling and Guidance
When things go wrong, Claude Code provides helpful explanations:
Workflow Integration
With Code Projects
Claude Code can help integrate WalletAgent into your development workflow:
With Documentation
Ask Claude Code to explain and document your Web3 operations:
Advanced Features
Custom Instructions
Create a ~/.claude/instructions.md file to customize WalletAgent behavior:
Project-Specific Configuration
Create .claude/instructions.md in your project:
Best Practices
Development Workflow
Start with Mock Mode: Always begin with safe test wallets
Test Thoroughly: Use contract simulation before real transactions
Environment Isolation: Keep testnet and mainnet configurations separate
Security First: Never share private keys in chat
Using Claude Code Effectively
Be Specific: "Send 100 USDC to 0x123..." vs "send tokens"
Ask for Explanations: "Explain what this transaction does"
Request Validations: "Check if this is safe before executing"
Use Context: Reference previous operations naturally
Error Recovery
Read Error Messages: Claude Code explains Web3 errors clearly
Ask for Help: "Why did this transaction fail?"
Try Alternatives: "Is there another way to do this?"
Check Status: "What's the current state of my wallet?"
Next Steps
Now that WalletAgent is configured with Claude Code:
Try the Quick Start Guide - Learn basic operations
Explore User Operations - Master wallet management
Developer Features - Smart contract development
Advanced Topics - Real wallets and custom chains
Getting Help
Resources
FAQ - Common questions
GitHub Issues - Bug reports
Ready to explore Web3 with Claude Code and WalletAgent? Let's begin.
Last updated
