crypto-knowledge
Enables 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.
README
Crypto-Knowledge
The on-chain brain for autonomous AI agents. An MCP server that lets agents perform complex crypto operations — cross-chain routing, contract decoding, portfolio & allowance management, gas/profit estimation and anti-rug security checks — safely and deterministically.
Keystore-free by design. The server never holds private keys and never signs. Every write action returns an unsigned, ready-to-sign transaction; the agent signs it with its own wallet. The server is multi-tenant and stateless — bring your own address, get back data + unsigned transactions.
Tools (11)
| Tool | What it does |
|---|---|
route |
Best cross-chain route between any chains/tokens (e.g. CRO → SOL). Queries LiFi + deBridge in parallel, compares output, returns the best route plus alternatives, each with a ready-to-sign transaction. |
pumpfun |
Direct on-chain pump.fun reads: live bonding-curve reserves, price, graduation progress, market cap, and resolved IPFS metadata. |
profitability |
EIP-1559 multi-chain gas estimation + net-profit verdict after gas & slippage (arbitrage guard). |
abi |
Fetch any verified EVM contract's ABI (Etherscan V2 / Sourcify), follow EIP-1967 proxies, and tell the agent exactly which parameters each function needs. Decode/encode calldata — decode_calldata even works on unverified contracts via a 4byte-directory selector lookup. Cached. |
portfolio |
Multi-chain balances (native + ERC-20 + SPL) and ERC-20 allowance management (check / approve / revoke) returning unsigned transactions. |
security |
Anti-rug scan via GoPlus + honeypot.is (EVM and Solana): honeypot/non-transferable, taxes, liquidity locks, mint/freeze/blacklist/pause powers, holder concentration → 0-100 risk score with red flags. |
mev_protection |
Private-RPC guidance (Flashbots Protect, MEV Blocker) + per-chain sandwich risk so the agent broadcasts safely. |
whale_watch |
Recent large ERC-20 transfers ("whale moves") for a token over a block window, decoded + sorted. |
solana_swap |
Quote & build same-chain Solana swaps via Jupiter (e.g. SOL→USDC, buy a graduated pump token) — returns a serialized unsigned transaction. |
simulate |
Dry-run an EVM transaction (eth_call) before signing and decode the revert reason (Error/Panic/custom) — never burn gas on a doomed tx. |
catalog |
Discovery: lists every tool, supported chain (id/native asset) and provider mode so an agent can self-configure. |
Supported chains
Ethereum, Base, Arbitrum, Optimism, Polygon, Cronos, ApeChain, BNB Smart Chain, Avalanche, Solana (10). Chain-agnostic by design — adding a chain is a single registry entry (src/registry/chains.ts).
Quick start
npm install
cp .env.example .env # optional keys — everything degrades to public RPC without them
npm test # 31 deterministic unit tests
npm run dev # run the MCP server over stdio
Use it from an MCP client (e.g. Claude Code)
{
"mcpServers": {
"crypto-knowledge": {
"command": "npx",
"args": ["tsx", "/absolute/path/to/Crypto-Knowledge/src/index.ts"]
}
}
}
Provider modes (per call)
The caller chooses how RPC/data is sourced:
open— public RPCs only. Free, but limited data (e.g. no ERC-20 auto-discovery) and lower rate limits.own_key⭐ recommended — pass your own freeheliusKey/alchemyKey. Best performance, your quota. Keys are used transiently and never stored or logged.tool— use the operator's keys (never exposed). Reserved for NFT-holders / paid tier when access gating is enabled.
Get a free key at helius.dev (Solana) and alchemy.com (EVM). The tool will nudge you when you're on a degraded public RPC.
Access & monetization (hosted mode)
When ACCESS_GATING_ENABLED=true (off by default for local stdio use):
- Holder — owns the configured gating NFT (on-chain verified) → free, higher limits, may use the tool's keys.
- Paid — $0.10 per request via x402.
- Free — public-RPC tier with conservative limits.
Architecture
agent ──▶ MCP tools (6 modules)
└─ core: RPC pool · retry/backoff · canonical errors · provider resolver
└─ access: sliding-window rate limit · NFT gate
returns ONLY unsigned tx + data → agent signs locally
See ARCHITECTURE.md for the full design, JSON I/O specs and R&D roadmap.
Security
- No private keys, ever. Read + build-unsigned-tx only.
- Operator keys are server-side only and never echoed to callers.
- Caller-supplied keys are transient (never persisted/logged).
License
MIT
Recommended Servers
playwright-mcp
A Model Context Protocol server that enables LLMs to interact with web pages through structured accessibility snapshots without requiring vision models or screenshots.
Magic Component Platform (MCP)
An AI-powered tool that generates modern UI components from natural language descriptions, integrating with popular IDEs to streamline UI development workflow.
Audiense Insights MCP Server
Enables interaction with Audiense Insights accounts via the Model Context Protocol, facilitating the extraction and analysis of marketing insights and audience data including demographics, behavior, and influencer engagement.
VeyraX MCP
Single MCP tool to connect all your favorite tools: Gmail, Calendar and 40 more.
graphlit-mcp-server
The Model Context Protocol (MCP) Server enables integration between MCP clients and the Graphlit service. Ingest anything from Slack to Gmail to podcast feeds, in addition to web crawling, into a Graphlit project - and then retrieve relevant contents from the MCP client.
Kagi MCP Server
An MCP server that integrates Kagi search capabilities with Claude AI, enabling Claude to perform real-time web searches when answering questions that require up-to-date information.
Neon Database
MCP server for interacting with Neon Management API and databases
E2B
Using MCP to run code via e2b.
Exa Search
A Model Context Protocol (MCP) server lets AI assistants like Claude use the Exa AI Search API for web searches. This setup allows AI models to get real-time web information in a safe and controlled way.
Qdrant Server
This repository is an example of how to create a MCP server for Qdrant, a vector search engine.