A full-stack blockchain development agent powered by the Claude Agent SDK. This agent provides expert guidance on smart contract development, blockchain architecture, security auditing, and decentralized application (dApp) implementation across multiple blockchain platforms.
- Multi-Platform Support: Ethereum, Solana, Polygon, Arbitrum, Optimism, BSC, NEAR, and more
- Smart Contract Development: Solidity, Rust, Vyper, Move
- Security Auditing: Comprehensive vulnerability detection and best practices
- Gas Optimization: Expert techniques for reducing transaction costs
- DeFi Expertise: AMMs, lending protocols, staking, yield farming
- NFT Standards: ERC-721, ERC-1155, royalty systems
- Web3 Integration: ethers.js, web3.js, wagmi integration guidance
- Node.js (v18 or later recommended)
- npm or yarn
- Anthropic API key from console.anthropic.com
-
Install dependencies:
npm install
-
Set up your API key:
cp .env.example .env
Then edit
.envand add your Anthropic API key:ANTHROPIC_API_KEY=your-actual-api-key-here -
Run the agent:
npm start
Example 1: Get started with blockchain development
npm startThis runs the default example that provides an overview of dApp development on Ethereum.
Example 2: Audit a smart contract
npm start "<task_type>audit</task_type>
<blockchain_platform>ethereum</blockchain_platform>
<context>Please audit this ERC-20 token contract for security vulnerabilities</context>
<code>
// Your Solidity code here
</code>"Example 3: Design a blockchain architecture
npm start "<task_type>architecture</task_type>
<blockchain_platform>ethereum</blockchain_platform>
<context>Design a scalable NFT marketplace with royalty distribution</context>"Run TypeScript type checking:
npm run typecheckBlockchain-Engineer/
├── src/
│ └── index.ts # Main agent implementation
├── .env.example # Environment variable template
├── .gitignore # Git ignore rules
├── package.json # Project dependencies
├── tsconfig.json # TypeScript configuration
└── README.md # This file
The Blockchain Engineer agent can help with:
- Write secure, gas-optimized smart contracts
- Implement token standards (ERC-20, ERC-721, ERC-1155, etc.)
- Build DeFi protocols and mechanisms
- Create DAO governance systems
- Identify common vulnerabilities (reentrancy, front-running, etc.)
- Access control validation
- Oracle manipulation detection
- Flash loan attack prevention
- Gas optimization techniques
- Storage pattern optimization
- Batch processing strategies
- Upgrade mechanisms (UUPS, Transparent Proxy)
- Blockchain platform selection
- Layer 2 solution recommendations
- Cross-chain bridge design
- Web3 frontend integration
The agent supports multiple API providers:
- Anthropic API (default): Set
ANTHROPIC_API_KEY - Amazon Bedrock: Set
CLAUDE_CODE_USE_BEDROCK=1and configure AWS credentials - Google Vertex AI: Set
CLAUDE_CODE_USE_VERTEX=1and configure Google Cloud credentials - Microsoft Foundry: Set
CLAUDE_CODE_USE_FOUNDRY=1and configure Azure credentials
You can customize the agent behavior in src/index.ts:
{
systemPrompt: BLOCKCHAIN_ENGINEER_PROMPT, // Custom system prompt
allowedTools: [...], // Available tools
model: "claude-sonnet-4-5-20250929", // Claude model
permissionMode: "bypassPermissions", // Permission handling
maxBudgetUsd: 1.0, // Budget limit
}When interacting with the agent, structure your requests as:
<task_type>
[audit | develop | optimize | architecture | debug | explain]
</task_type>
<blockchain_platform>
[ethereum | solana | polygon | arbitrum | optimism | etc.]
</blockchain_platform>
<context>
[Describe your project or problem]
</context>
<code>
[Optional: Your smart contract code]
</code>
<specific_requirements>
[Optional: Specific requirements or constraints]
</specific_requirements>This agent provides security guidance and recommendations, but:
- Always conduct professional audits for production smart contracts
- Test thoroughly on testnets before mainnet deployment
- Never deploy contracts handling real funds without comprehensive testing
- The agent's suggestions should be validated by experienced developers
ISC
This is a personal blockchain development agent. Feel free to fork and customize for your own needs!
Built with ❤️ using the Claude Agent SDK