ChainVault MCP
Deploys and interacts with smart contracts, reads chain state, gets balances, simulates transactions, and queries events on Ethereum mainnet and Sepolia testnet (and other EVM chains).
Deploys and interacts with smart contracts, reads state, gets balances, and queries events on Optimism mainnet and Optimism Sepolia.
Deploys and interacts with smart contracts, reads state, gets balances, and queries events on Polygon mainnet and Polygon Amoy.
Compiles Solidity source code (via the compile_contract tool using solc) to produce bytecode for contract deployment.
This server does not currently have a deployable release on Glama. Follow the repository's setup instructions to install and configure it for your MCP client, including any required credentials and local dependencies.
ChainVault MCP
Your AI agent gets blockchain superpowers without ever touching a private key.
ChainVault MCP is a secure Model Context Protocol server that acts as a gateway between AI agents and EVM blockchains. It provides vault-based key management, rule-enforced access control, and API proxying -- so your agent can deploy contracts, read chain state, and query block explorers without direct access to any secret.
Architecture
+----------------+ MCP (stdio) +------------------------------------------+
| AI Agent |<-------------------->| ChainVault MCP |
| (Claude, | Tools: deploy, | |
| GPT, etc.) | read, simulate... | +---------+ +----------+ +--------+ |
+----------------+ | | Rules | | Vault | | Audit | |
| | Engine | | Manager | | Logger | |
| +----+-----+ +----+-----+ +--------+ |
| | deny? | decrypt |
| v v |
| +---------+ +----------+ |
| | Chain | | API | |
| | Adapter | | Proxy | |
| +----+-----+ +----+-----+ |
+-------+-----------+-+--------------------+
| |
v v
EVM RPCs Block Explorer APIs
(Ethereum, (Etherscan, etc.)
Sepolia...)Related MCP server: ows-mcp-wallet
Why ChainVault?
The problem: Giving an AI agent a private key is like giving a stranger your house keys. One prompt injection, one hallucination, one misconfigured tool -- and your funds are gone.
The solution: ChainVault uses a zero-knowledge agent architecture:
Without ChainVault | With ChainVault |
Private key in env var or prompt | Private key encrypted in vault, never exposed |
Agent has unlimited access | Rules engine enforces chain, tx type, and spend limits |
No audit trail | Every action logged (approved and denied) |
API keys in plaintext | API keys encrypted with same vault treatment |
No rate limiting | Per-second and daily rate limits on API calls |
The agent never sees a private key. It holds a vault key (an AES encryption key to its own isolated vault), not a blockchain private key. Even if the agent is compromised, it can only perform actions within its pre-configured rules.
Quick Start
npm install -g @chainvault/mcp
chainvault init # create master vault (prompted for password)
chainvault key add my-wallet # prompted for private key, never in args
chainvault agent create deployer # interactive setup via TUI
chainvault serve # start MCP serverAdd to your MCP client config (Claude Desktop, Cursor, etc.):
{
"mcpServers": {
"chainvault": {
"command": "chainvault",
"args": ["serve"],
"env": {
"CHAINVAULT_VAULT_KEY": "cv_agent_<your-agent-vault-key>"
}
}
}
}Compiler Setup (Optional)
To enable Solidity compilation via the compile_contract MCP tool:
# Pull the solc Docker image (default: 0.8.20)
chainvault solc pull
# Or pull a specific version
chainvault solc pull 0.8.26Requires Docker. Alternatively, install solc locally.
Supported Chains
14 EVM chains with built-in public RPCs (via PublicNode) -- no API key required.
Chain | ID | Type | Currency | Faucet |
Ethereum Mainnet |
| Mainnet | ETH | -- |
Sepolia |
| Testnet | ETH | |
Polygon |
| Mainnet | POL | -- |
Polygon Amoy |
| Testnet | POL | |
Arbitrum One |
| Mainnet | ETH | -- |
Arbitrum Sepolia |
| Testnet | ETH | |
Optimism |
| Mainnet | ETH | -- |
Optimism Sepolia |
| Testnet | ETH | |
Base |
| Mainnet | ETH | -- |
Base Sepolia |
| Testnet | ETH | |
BNB Smart Chain |
| Mainnet | BNB | -- |
BSC Testnet |
| Testnet | BNB | |
Avalanche C-Chain |
| Mainnet | AVAX | -- |
Avalanche Fuji |
| Testnet | AVAX |
MCP Tools
19 tools across 5 categories. All tools return structured JSON, never raw RPC responses.
Contract Lifecycle
Tool | Description |
| Deploy compiled bytecode to a blockchain |
| Call a state-changing function on a deployed contract |
| Verify source code on a block explorer (Etherscan, etc.) |
| Compile Solidity source code using solc |
Chain Reading
Tool | Description |
| Get native token balance for an address |
| Call read-only functions on a smart contract |
| Dry-run a transaction without sending |
| Query contract event logs with filters |
| Get transaction details and receipt by hash |
Vault Management
Tool | Description |
| Show which chains this agent has access to |
| Show allowed actions, tx types, and limits |
| Get wallet address for a chain (public key only) |
API Proxy
Tool | Description |
| Query block explorer APIs (Etherscan, etc.) |
| Get token price data from CoinGecko |
Chain Registry
Tool | Description |
| List all supported chains with RPC and faucet status |
| Request testnet tokens from a faucet |
TUI
Running chainvault with no arguments launches an interactive terminal UI built with Ink (React for CLI). The TUI provides six screens: Dashboard (vault status, active agents, recent activity), Keys (add, remove, view wallet addresses), Agents (create, configure permissions, rotate keys, revoke), Services (manage API keys and RPC endpoints), Logs (live audit log, filterable by agent and status), and Rules (edit agent rules with guided prompts). All secret inputs are prompted interactively and never appear in shell history.
Security Model
Zero-knowledge agent -- the agent never sees any raw secret
Least privilege -- each agent gets only the keys and permissions it needs
Defense in depth -- rules engine blocks + vault doesn't contain unauthorized keys (double barrier)
Instant revocation -- rotate or delete a vault key and the agent is locked out immediately
Threat Model
Threat | Mitigation |
Prompt injection extracts keys | Keys never in agent context -- vault returns results, not secrets |
Agent tries unauthorized chain | Rules engine denies before vault decryption + key not in vault |
Agent exceeds spending limits | Per-tx, daily, and monthly spend tracking with hard caps |
Compromised agent vault key | Rotate key instantly; old key becomes useless. Limited blast radius |
API key abuse | Rate limiting, endpoint whitelisting, per-agent usage tracking |
See SECURITY.md for the full security model.
Contributing
See CONTRIBUTING.md for development setup, testing, and contribution guidelines.
This project follows the Contributor Covenant Code of Conduct.
License
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
This server cannot be deployed
Maintenance
Related MCP Connectors
Verified EVM, Aptos and finance tools for AI agents; gas for 14 chains. Pay per call (x402).
Give your AI hands. Identity, credential vault, and API gateway for autonomous agents.
Agentic AI runtime: persistent memory, vault, autonomous agents, deep research, DeFi execution.
Manage your blockchain infrastructure across 80+ chains with your agents.
Related MCP Servers
- FlicenseCqualityBmaintenanceEnables AI agents to interact with any EVM-compatible blockchain through natural language, supporting token swaps, cross-chain bridges, staking, lending, governance, gas optimization, and portfolio tracking across networks like Ethereum, BSC, Polygon, Arbitrum, and more.10041 npm44-
- AlicenseAqualityDmaintenanceEnables AI agents to check balances and send transactions across multiple blockchains with automatic spending limit protection and policy enforcement.3MIT
- AlicenseNot gradedqualityDmaintenanceEnables AI agents to perform complex crypto operations like cross-chain routing, contract decoding, portfolio management, and anti-rug security checks, returning unsigned transactions for safe signing by the agent.MIT
- FlicenseNot gradedqualityDmaintenanceEnables AI agents to safely interact with Ethereum by providing structured tools for reading blockchain state, simulating transactions, and drafting transactions that require human-in-the-loop approval.1-