Universal Contract AI Interface (UCAI)

by nirholas

Not rated
GitHub

Description

Universal Contract AI Interface (UCAI) πŸ”— ABI to MCP | The open standard for connecting AI agents to blockchain. MCP server generator for smart contracts. Claude + Uniswap, Aave, ERC20, NFTs, DeFi. Python CLI, Web3 integration, transaction simulation. Polygon, Arbitrum, Base…

About

Universal Contract AI Interface (UCAI) πŸ”— ABI to MCP | The open standard for connecting AI agents to blockchain. MCP server generator for smart contracts. Claude + Uniswap, Aave, ERC20, NFTs, DeFi. Python CLI, Web3 integration, transaction simulation. Polygon, Arbitrum, Base, Ethereum EVM chains. Claude, GPT, LLM…

Details

Author
nirholas
Categories
Communication, Other, Finance, AI

Setup

Install Universal Contract AI Interface (UCAI) in your MCP client (Claude Desktop, Cursor, Windsurf, and others).

Repository: https://github.com/nirholas/UCAI

Follow the installation instructions in the repository README, then restart your MCP client.

Universal Contract AI Interface (UCAI) πŸ”— ABI to MCP | The open standard for connecting AI agents to blockchain. MCP server generator for smart contracts. Claude + Uniswap, Aave, ERC20, NFTs, DeFi. Python CLI, Web3 integration, transaction simulation. Polygon, Arbitrum, Base, Ethereum EVM chains. Claude, GPT, LLM tooling, Solidity, OpenAI.

β–ˆβ–ˆβ•— β–ˆβ–ˆβ•— β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ•— β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ•— β–ˆβ–ˆβ•— β–ˆβ–ˆβ•‘ β–ˆβ–ˆβ•‘β–ˆβ–ˆβ•”β•β•β•β•β•β–ˆβ–ˆβ•”β•β•β–ˆβ–ˆβ•—β–ˆβ–ˆβ•‘ β–ˆβ–ˆβ•‘ β–ˆβ–ˆβ•‘β–ˆβ–ˆβ•‘ β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ•‘β–ˆβ–ˆβ•‘ β–ˆβ–ˆβ•‘ β–ˆβ–ˆβ•‘β–ˆβ–ˆβ•‘ β–ˆβ–ˆβ•”β•β•β–ˆβ–ˆβ•‘β–ˆβ–ˆβ•‘ β•šβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ•”β•β•šβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ•—β–ˆβ–ˆβ•‘ β–ˆβ–ˆβ•‘β–ˆβ–ˆβ•‘ β•šβ•β•β•β•β•β• β•šβ•β•β•β•β•β•β•šβ•β• β•šβ•β•β•šβ•β• Any contract. One command. Claude speaks it.

πŸ™‡β€β™€οΈ Universal Contract AI Interfaceβ˜‘οΈ UCAI in Anthropic MCP Registry|🌐 Try the Web Builder β†’|πŸ“– Documentation|πŸ›‘οΈ Security Scanner

mcp.ucai.techβ€” Generate MCP servers directly in your browser.

+--------------------------------------------------------------------------+ | | | MCP BUILDER [Connect Wallet] | | | | +---------------------------+--------------------------------------+ | | | Pro Templates | Custom Contract | | | +---------------------------+--------------------------------------+ | | | | Security Scanner: Score 87/100 - Low Risk | | |-- Contract verified on Etherscan | | |-- Uses OpenZeppelin (audited) | | |-- Owner can pause transfers (warning) | | +-- Mint function detected (warning) | | | | What This Contract Does: | | "ERC-20 token with standard transfer, approve, and allowance | | functions." | | | | [Download Server] [Share Link] [Copy Config] | | | +--------------------------------------------------------------------------+

- πŸ›‘οΈSecurity Scannerβ€” Detects rug pulls, honeypots, and 50+ risks before you connect
- πŸ“–Contract Whispererβ€” Explains contracts in plain English
- ⚑Pro Templatesβ€” Pre-built bundles for Flash Loans, Arbitrage, Yield Aggregators
- πŸŒ™Dark/Light Modeβ€” Easy on the eyes
- πŸ“₯ZIP Downloadβ€” Complete server withserver.py,requirements.txt,README.md
- πŸ”—Share Linksβ€” Send?address=0x...&network=ethereumto anyone

β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β” β”‚ β”‚ β”‚ 1. FIND 2. GENERATE 3. DONE β”‚ β”‚ β”‚ β”‚ β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β” β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β” β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β” β”‚ β”‚ β”‚ Etherscan β”‚ β”‚ β”‚ β”‚ β”‚ β”‚ β”‚ β”‚ β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β” β”‚ β”‚ $ abi-to-mcp β”‚ β”‚ Claude β”‚ β”‚ β”‚ β”‚ β”‚ Contractβ”‚ β”‚ ────▢ β”‚ generate β”‚ ──▢ β”‚ Tools β”‚ β”‚ β”‚ β”‚ β”‚ ABI β”‚ β”‚ β”‚ 0x7a25... β”‚ β”‚ β”‚ β”‚ β”‚ β”‚ β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜ β”‚ β”‚ β”‚ β”‚ "Swap 1 ETH" β”‚ β”‚ β”‚ β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜ β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜ β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜ β”‚ β”‚ β”‚ β”‚ Any contract One command AI speaks it β”‚ β”‚ β”‚ β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜

Found a contract on Etherscan? One command. Claude can now use it.

pip install abi-to-mcp # Uniswap β€” Claude can swap tokens abi-to-mcp generate 0x7a250d5630B4cF539739dF2C5dAcb4c659F2488D -o ~/uniswap-server # ETH 2.0 Beacon Deposit β€” Claude can explore staking abi-to-mcp generate 0x00000000219ab540356cBB839Cbe05303d7705Fa -o ~/eth-staking-server # Any verified contract works abi-to-mcp generate <ANY_CONTRACT_ADDRESS>

That's it.Every function, every event, every query β€” now a Claude tool.

abi-to-mcp generate 0x7a250d5630B4cF539739dF2C5dAcb4c659F2488D -o ~/uniswap-server cd ~/uniswap-server && pip install -r requirements.txt

Add to your config (~/Library/Application Support/Claude/claude_desktop_config.jsonon Mac):

{ "mcpServers": { "uniswap": { "command": "python", "args": ["/Users/YOU/uniswap-server/server.py"], "env": { "RPC_URL": "https://eth.llamarpc.com" } } } }

- "What's the best route to swap 1 ETH for USDC?"
- "Get the reserves for the ETH/DAI pool"
- "Show me recent swaps on Uniswap"

β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β” β”‚ YOU β”‚ β”œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€ β”‚ "What's the best route to swap 1 ETH for USDC on Uniswap?" β”‚ β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜ β”‚ β–Ό β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β” β”‚ CLAUDE β”‚ β”œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€ β”‚ I'll check the Uniswap router for the best path... β”‚ β”‚ β”‚ β”‚ Called: getAmountsOut(1 ETH, [WETH, USDC]) β”‚ β”‚ β”‚ β”‚ Best route: ETH -> WETH -> USDC β”‚ β”‚ You would receive: 3,847.23 USDC β”‚ β”‚ Price impact: 0.02% β”‚ β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜ β”‚ β–Ό β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β” β”‚ YOU β”‚ β”œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€ β”‚ "Do it. Swap 1 ETH for USDC." β”‚ β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜ β”‚ β–Ό β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β” β”‚ CLAUDE β”‚ β”œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€ β”‚ Simulating transaction first... β”‚ β”‚ β”‚ β”‚ Simulation successful β”‚ β”‚ Gas estimate: 152,847 (~$3.42) β”‚ β”‚ Expected output: 3,847.23 USDC β”‚ β”‚ β”‚ β”‚ Ready to execute. Confirm? [Yes/No] β”‚ β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜

UCAI(Universal Contract AI Interface) is a standard for how AI agents interact with smart contracts.

╔═══════════════════════════════════════════════════════════════════════════════╗ β•‘ β•‘ β•‘ β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β” β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β” β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β” β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β” β•‘ β•‘ β”‚ β”‚ β”‚ β”‚ β”‚ β”‚ β”‚ β”‚ β•‘ β•‘ β”‚ Claude │─────>β”‚ abi-to-mcp │─────>β”‚ MCP Server │─────>β”‚ Chain β”‚ β•‘ β•‘ β”‚ β”‚ β”‚ generate β”‚ β”‚ (your tools) β”‚ β”‚ β”‚ β•‘ β•‘ β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜ β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜ β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜ β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜ β•‘ β•‘ β”‚ β”‚ β”‚ β•‘ β•‘ β”‚ "swap 1 ETH" β”‚ call swap() β”‚ β•‘ β•‘ β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”΄β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜ β•‘ β•‘ β•‘ β•šβ•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•

- πŸ“‹Tool schemasβ€” How contract functions become AI-callable tools
- πŸ”„Type mappingsβ€” Solidity β†’ JSON Schema β†’ Python
- πŸ”’Safety patternsβ€” Simulation-first for all state changes
- πŸ“‘Event queriesβ€” Historical data access patterns

- πŸ”Repeatableβ€” Same pattern works for ERC20, ERC721, DeFi, DAOs, Solana, anything
- πŸ”’Safe by defaultβ€” All write operations simulate first
- 🌐Universalβ€” Works on any chain, with any AI agent
- πŸ€–AI-nativeβ€” Designed specifically for LLM tool-calling

Every contract becomes AI-accessible through the same interface. No custom code per contract.

This package (abi-to-mcp) is the reference implementation of UCAI for MCP.

The Problem:You want AI to interact with smart contracts. But:

- Writing MCP server boilerplate is tedious
- Mapping Solidity types to JSON Schema is error-prone
- Every contract needs the same patterns repeated
- Safety (simulation, gas limits) is easy to forget

The Solution:One command generates a production-ready MCP server from any ABI.

- AI Agent Buildersβ€” Give your agent DeFi superpowers (swap, lend, vote)
- Wallet Developersβ€” Let Claude explain and execute transactions
- DAO Toolingβ€” AI-powered proposal creation, voting, treasury management
- DeFi Dashboardsβ€” Natural language queries for on-chain data
- Vibecodersβ€” Ship faster with AI-generated blockchain tools

πŸ¦„ Uniswap: Swap tokens with natural language

abi-to-mcp generate 0x7a250d5630B4cF539739dF2C5dAcb4c659F2488D -o ~/uniswap-server

"What's the current rate for swapping 10 ETH to USDC?"

Claude callsgetAmountsOut()and responds:

"10 ETH β†’ 38,472.31 USDC via the WETH/USDC pool. Want me to simulate the swap?"

abi-to-mcp generate 0x87870Bca3F3fD6335C3F4ce8392D69350B4fA4E2 -o ~/aave-server

"What's my health factor on Aave? Am I at risk of liquidation?"

Claude reads your position and warns you before it's too late.

abi-to-mcp generate 0xBC4CA0EdA7647A8aB7C2061c2E118A18a936f13D -o ~/bayc-server

"Who owns BAYC #8817? How many apes does that wallet have?"

Claude callsownerOf()andbalanceOf()to answer.

abi-to-mcp generate ./my-contract-abi.json --address 0x... -o ~/my-server

Any verified contract. Any local ABI. One command.

Before you connect Claude to a contract, know what you're dealing with. The security scanner analyzes contracts for50+ risk patterns:

+------------------------------------------------------------------------------+ | SECURITY REPORT Score: 42/100 | +------------------------------------------------------------------------------+ | | | CRITICAL | | |-- Self-Destruct Function -- Contract can be destroyed | | +-- tx.origin Authentication -- Vulnerable to phishing | | | | HIGH | | |-- Hidden Mint -- Owner can create unlimited tokens | | |-- Pausable -- Owner can freeze all transfers | | +-- Blacklist -- Owner can block specific addresses | | | | POSITIVES | | |-- Contract verified on Etherscan | | |-- Uses OpenZeppelin (audited library) | | +-- Has reentrancy protection | | | | [Proceed Anyway] [Cancel -- Too Risky] | | | +------------------------------------------------------------------------------+

- βœ… Contract verified on block explorer
- βœ… Uses OpenZeppelin
- βœ… Reentrancy guards
- βœ… Ownership renounced
- βœ… NatSpec documentation

Try it:mcp.ucai.techβ€” Enter any contract address and click "πŸ›‘οΈ Scan"

Don't understand what a contract does? The Contract Whisperer explains it in plain English:

+------------------------------------------------------------------------------+ | WHAT THIS CONTRACT DOES | +------------------------------------------------------------------------------+ | | | Summary: Uniswap V2 Router -- Decentralized token exchange | | | | Main Functions: | | |-- [R] getAmountsOut -- Calculate expected output for a swap | | |-- [W] swapExactTokensForTokens -- Exchange tokens at market rate | | |-- [W] addLiquidity -- Provide liquidity to earn fees | | +-- [R] getReserves -- Check pool balances | | | | Permissions: | | |-- Anyone -- Can swap, add/remove liquidity | | +-- Factory -- Can create new pairs | | | | Risk Summary: | | "Standard DEX router. No owner privileges. Interacts with external pools | | which may have their own risks." | | | +------------------------------------------------------------------------------+

- What the contract does (in one sentence)
- Main functions and their purpose
- Who can do what (permissions/roles)
- Tokenomics (mintable, burnable, fees)
- Risk summary

Pre-built multi-contract bundles for advanced use cases:

- Multipleserver.pyfiles (one per contract)
- Pre-configuredclaude_config.json
- Sample prompts to get started

Try it:mcp.ucai.techβ†’ "⚑ Pro Templates" tab

When you point abi-to-mcp at a contract, it introspects every function and event, then generates tools Claude can call:

15-30 tools per contract, fully typed, simulation-protected for writes.

abi-to-mcp generate <source> [options]

- source: ABI file path or contract address

- -o, --output PATH: Output directory (default:./mcp-server)
- -n, --network TEXT: Network for address lookups (default:mainnet)
- -a, --address TEXT: Contract address (if not in source)
- --name TEXT: Server name (auto-detected if not provided)
- --read-only: Only generate read operations
- --no-events: Exclude events as resources
- --no-simulate: Disable simulation by default for writes

Preview what would be generated without creating files.

my-mcp-server/ β”œβ”€β”€ server.py # Main MCP server β”œβ”€β”€ config.py # Configuration β”œβ”€β”€ requirements.txt # Dependencies β”œβ”€β”€ README.md # Documentation β”œβ”€β”€ pyproject.toml # Package config └── .env.example # Environment template

- Private keysβ€” Only loaded from environment variables, never from files or CLI
- Simulation by defaultβ€” Write operations simulate first; setsimulate=Falseto execute
- Read-only modeβ€” Use--read-onlyto completely disable writes
- Gas protectionβ€” Configurable maximum gas price limits

git clone https://github.com/nirholas/UCAI.git cd UCAI make setup # Install dependencies make test # Run 876 tests (92% coverage) make lint # Check code quality make docs # Build documentation
"Show me my positions across Uniswap, Aave, and Compound" "Swap 1 ETH for USDC if the price is above $3,500"

Generate servers for each protocol, Claude handles the rest.

"What proposals are active on Nouns DAO?" "Draft a proposal to fund the marketing budget" "Cast my vote on proposal #47"
"List all my NFTs on Opensea" "Transfer Bored Ape #1234 to vitalik.eth" "What's the floor price history for CryptoPunks?"
"What tokens do I hold?" "Send 100 USDC to alice.eth" "What did I spend on gas this month?"

UCAIβ€’Universal Contract AI Interfaceβ€’MCPβ€’Model Context Protocolβ€’Claudeβ€’AI Agentβ€’Smart Contractβ€’Ethereumβ€’EVMβ€’DeFiβ€’Web3β€’Solidityβ€’ABIβ€’Blockchainβ€’Tokenβ€’ERC20β€’ERC721β€’NFTβ€’DAOβ€’Uniswapβ€’Aaveβ€’Polygonβ€’Arbitrumβ€’Baseβ€’Optimismβ€’LLM Toolβ€’AI Blockchainβ€’Vibecoding

We welcome contributions! SeeCONTRIBUTING.md.

- Integration tests for generated serversβ€” Validate MCP servers import correctly

- More EVM chainsβ€” Fantom, zkSync, Cronos, etc.
- More ABI sourcesβ€” Blockscout, 4byte.directory
- Example contractsβ€” Uniswap, Aave, Compound, OpenSea

- UCAI for Solanaβ€” Generate from Anchor IDL
- UCAI for REST APIsβ€” Generate from OpenAPI specs
- TypeScript outputβ€” Generate servers in JS/TS
- Batch generationβ€” Multiple contracts at once
- Event subscriptionsβ€” Real-time WebSocket streaming

- MCP Python SDKβ€” Official Model Context Protocol implementation
-
web3.pyβ€” Ethereum interaction
-
Typerβ€” CLI framework

UCAI β€” The Universal Contract AI Interface
Let AI talk to any contract, on any chain.

⭐ Star on GitHubβ€’πŸ“¦ Install from PyPIβ€’πŸ”Œ Learn about MCP

Comprehensive keyword list for ERC-8004 Trustless Agents ecosystem

ERC-8004, ERC8004, EIP-8004, EIP8004, Trustless Agents, trustless agent, trustless AI, trustless AI agents, agent protocol, agent standard, Ethereum agent standard, blockchain agent protocol, on-chain agents, onchain agents, on-chain AI, onchain AI, decentralized agents, decentralized AI agents, autonomous agents, autonomous AI agents, AI agent protocol, AI agent standard, agent discovery, agent trust, agent reputation, agent validation, agent identity, agent registry, identity registry, reputation registry, validation registry, agent NFT, ERC-721 agent, agent tokenId, agentId, agentURI, agentWallet, agent registration, agent registration file, agent-registration.json, agent card, agent metadata, agent endpoints, agent discovery protocol, agent trust protocol, open agent protocol, open agent standard, permissionless agents, permissionless AI, censorship-resistant agents, portable agent identity, portable AI identity, verifiable agents, verifiable AI agents, accountable agents, accountable AI, agent accountability

Ethereum, Ethereum mainnet, ETH, EVM, Ethereum Virtual Machine, smart contracts, Solidity, blockchain, decentralized, permissionless, trustless, on-chain, onchain, L2, Layer 2, Base, Optimism, Polygon, Linea, Arbitrum, Scroll, Monad, Gnosis, Celo, Sepolia, testnet, mainnet, singleton contracts, singleton deployment, ERC-721, NFT, non-fungible token, tokenURI, URIStorage, EIP-712, ERC-1271, wallet signature, EOA, smart contract wallet, gas fees, gas sponsorship, EIP-7702, subgraph, The Graph, indexer, blockchain indexing, IPFS, decentralized storage, content-addressed, immutable data, public registry, public good, credibly neutral, credibly neutral infrastructure, open protocol, open standard, Web3, crypto, cryptocurrency, DeFi, decentralized finance

AI agents, artificial intelligence agents, autonomous AI, AI autonomy, LLM agents, large language model agents, machine learning agents, ML agents, AI assistant, AI chatbot, intelligent agents, software agents, digital agents, virtual agents, AI automation, automated agents, agent-to-agent, A2A, A2A protocol, Google A2A, Agent2Agent, MCP, Model Context Protocol, agent communication, agent interoperability, agent orchestration, agent collaboration, multi-agent, multi-agent systems, agent capabilities, agent skills, agent tools, agent prompts, agent resources, agent completions, AgentCard, agent card, agent endpoint, agent service, AI service, AI API, agent API, AI infrastructure, agent infrastructure, agentic, agentic web, agentic economy, agentic commerce, agent economy, agent marketplace, AI marketplace, agent platform, AI platform

trust, trustless, reputation, reputation system, reputation protocol, reputation registry, feedback, client feedback, user feedback, on-chain feedback, on-chain reputation, verifiable reputation, portable reputation, reputation aggregation, reputation scoring, reputation algorithm, trust signals, trust model, trust verification, trust layer, recursive reputation, reviewer reputation, spam prevention, Sybil attack, Sybil resistance, anti-spam, feedback filtering, trusted reviewers, rating, rating system, quality rating, starred rating, uptime rating, success rate, response time, performance history, track record, audit trail, immutable feedback, permanent feedback, feedback response, appendResponse, giveFeedback, revokeFeedback, feedback tags, feedback value, valueDecimals, feedbackURI, feedbackHash, clientAddress, reviewer address

validation, validation registry, validator, validator contract, cryptographic validation, cryptographic proof, cryptographic attestation, zero-knowledge, ZK, zkML, zero-knowledge machine learning, ZK proofs, trusted execution environment, TEE, TEE attestation, TEE oracle, stake-secured, staking validators, crypto-economic security, inference re-execution, output validation, work verification, third-party validation, independent validation, validation request, validation response, validationRequest, validationResponse, requestHash, responseHash, verifiable computation, verified agents, verified behavior, behavioral validation, agent verification

x402, x402 protocol, x402 payments, programmable payments, micropayments, HTTP payments, pay-per-request, pay-per-task, agent payments, AI payments, agent monetization, AI monetization, agent commerce, AI commerce, agentic commerce, agent economy, AI economy, agent marketplace, service marketplace, agent-to-agent payments, A2A payments, stablecoin payments, USDC, crypto payments, on-chain payments, payment settlement, programmable settlement, proof of payment, proofOfPayment, payment receipt, payment verification, Coinbase, Coinbase x402, agent pricing, API pricing, service pricing, subscription, API keys, revenue, trading yield, cumulative revenues, agent wallet, payment address, toAddress, fromAddress, txHash

agent discovery, service discovery, agent registry, identity registry, agent registration, register agent, mint agent, agent NFT, agent tokenId, agent browsing, agent explorer, agent scanner, 8004scan, 8004scan.io, agentscan, agentscan.info, 8004agents, 8004agents.ai, agent leaderboard, agent ranking, top agents, agent listing, agent directory, agent catalog, agent index, browse agents, search agents, find agents, discover agents, agent visibility, agent discoverability, no-code registration, agent creation, create agent, my agents, agent owner, agent operator, agent transfer, transferable agent, portable agent

endpoint, agent endpoint, service endpoint, API endpoint, MCP endpoint, A2A endpoint, web endpoint, HTTPS endpoint, HTTP endpoint, DID, decentralized identifier, ENS, Ethereum Name Service, ENS name, agent.eth, vitalik.eth, email endpoint, OASF, Open Agent Specification Format, endpoint verification, domain verification, endpoint ownership, .well-known, well-known, agent-registration.json, endpoint domain, endpoint URL, endpoint URI, base64 data URI, on-chain metadata, off-chain metadata, metadata storage, JSON metadata, agent JSON, registration JSON

SDK, Agent0 SDK, Agent0, ChaosChain SDK, ChaosChain, Lucid Agents, Daydreams AI, create-8004-agent, npm, TypeScript SDK, Python SDK, JavaScript, Solidity, smart contract, ABI, contract ABI, deployed contracts, contract addresses, Hardhat, development tools, developer tools, dev tools, API, REST API, GraphQL, subgraph, The Graph, indexer, blockchain explorer, Etherscan, contract verification, open source, MIT license, CC0, public domain, GitHub, repository, code repository, documentation, docs, best practices, reference implementation

No reviews yet β€” be the first

Sign in to leave a review

Use Google, GitHub, or an email account so ratings stay tied to real people.

Email sign in

No reviews posted yet.