UCAI — ABI-to-MCP Server Generator

SkillSecurity

Guide to UCAI (Universal Contract AI Interface) — the ABI-to-MCP server generator. Point it at any smart contract ABI and get a working MCP server. One command, any contract, Claude speaks it. Supports Uniswap, Aave, ERC20, NFTs, all EVM chains. Security scanner included.

Available today. Use it from your connected AI after setup.

Connect ahel once, and every AI you use reads what you have installed.

Then ask your AI: use the UCAI — ABI-to-MCP Server Generator skill

What this skill tells your AI

The instructions your AI receives, as published by nirholas/three.ws in data/skills/development/abi-to-mcp-guide/SKILL.md and read by ahel’s review.

UCAI (Universal Contract AI Interface) turns any smart contract ABI into a ready-to-use MCP server. One command — any contract on any EVM chain — and your AI agent can interact with it.

The Concept

Smart Contract ABI (JSON)
    │
    ▼
  UCAI CLI
    │
    ▼
MCP Server with tools for every function
    │
    ▼
AI Agent calls contract functions naturally:
  "What's the total supply of this ERC20?"
  "How much can I borrow on Aave?"

Quick Start

Install

pip install abi-to-mcp

Generate MCP Server

# From a verified contract on Etherscan
ucai generate 0xD74f5255D557944cf7Dd0E45FF521520002D5748 --chain arbitrum

# From a local ABI file
ucai generate ./my-contract-abi.json --chain ethereum

# From a well-known protocol
ucai generate uniswap-v3-router --chain ethereum

Use with Claude Desktop

{
  "mcpServers": {
    "my-contract": {
      "command": "ucai",
      "args": ["serve", "0xD74f5255D557944cf7Dd0E45FF521520002D5748", "--chain", "arbitrum"]
    }
  }
}

How It Works

  1. ABI Parsing — Reads contract ABI (from Etherscan, local file, or known protocol)
  2. Tool Generation — Creates one MCP tool per contract function
  3. Type Mapping — Solidity types → JSON Schema types
  4. Read/Write Split — Read functions (view/pure) are safe; write functions need signing
  5. Documentation — Auto-generates descriptions from function signatures and NatSpec

Generated Tool Example

For a function like:

function balanceOf(address account) external view returns (uint256)

UCAI generates:

{
  "name": "balanceOf",
  "description": "Get the token balance of an account",
  "parameters": {
    "account": { "type": "string", "description": "The account address (address)" }
  }
}

Supported Chains

ChainExplorerAuto-ABI Fetch
EthereumEtherscan
ArbitrumArbiscan
BaseBasescan
PolygonPolygonscan
BSCBscScan
OptimismOptimistic Etherscan
AvalancheSnowtrace

Security Scanner

UCAI includes a built-in security scanner that checks:

CheckWhat It Does
ReentrancyDetects reentrancy vulnerabilities
Unlimited ApprovalsFlags functions requesting unlimited token approvals
Admin FunctionsIdentifies privileged/owner-only functions
Proxy PatternsDetects upgradeable proxy contracts
Self-DestructFlags contracts with selfdestruct capability
ucai scan 0x... --chain ethereum

Web Builder

For non-developers, UCAI provides a web interface at mcp.ucai.tech:

  1. Paste contract address
  2. Select chain
  3. Click "Generate"
  4. Download MCP server config

Common Recipes

ERC-20 Token Tools

ucai generate 0x... --chain arbitrum
# → balanceOf, totalSupply, transfer, approve, allowance, etc.

Aave V3 Lending

ucai generate aave-v3-pool --chain arbitrum
# → supply, borrow, repay, withdraw, getUserAccountData, etc.

Sperax USDs

ucai generate 0xD74f5255D557944cf7Dd0E45FF521520002D5748 --chain arbitrum
# → balanceOf, totalSupply, mint, redeem, getCollateralRatio, etc.

The UCAI Standard

UCAI defines a standard for mapping Solidity ABIs to MCP tool definitions:

  • Every view/pure function → read-only MCP tool
  • Every state-changing function → write MCP tool (requires signing)
  • Events → subscription tools (where supported)
  • Structs → nested JSON Schema objects

Links

Signals

GitHub stars
114
Forks
29
Last commit
Sep 2026
Advanced
Catalog kind
skill
Gateway key
abi-to-mcp-guide
Source
github.com/nirholas/three.ws
UCAI — ABI-to-MCP Server Generator (abi-to-mcp-guide) · ahel