Abstraxn Public Web3 MCP

Abstraxn Public Web3 MCP

A free public MCP server for Web3 data, providing live chain info, token prices, market data, wallet/token lookups, and travel search, with optional pay-per-call tools settled via x402.

Category
访问服务器

README

Abstraxn Public Web3 MCP Service

License: MIT Node

A free, public MCP (Model Context Protocol) server for Web3 data. Point any MCP client — Claude Desktop, Cursor, your own agent — at it and it can read live chain data (block height, gas, transaction status, ERC-20 info, spot prices) and, for a handful of pay-per-call tools, look up market data, wallets/tokens/ENS, and travel search.

No API key, no account, no signup. Free tools are open to anyone; paid tools are settled directly from the caller's own wallet via the x402 payment protocol — this service never holds or signs funds on your behalf.

Built on the official @modelcontextprotocol/sdk and NestJS 11.

Contents


Quick start

git clone https://github.com/Abstraxn-Labs/abstraxn-agent-layer.git
cd abstraxn-agent-layer
npm install
cp .env.example .env
# Edit .env: Postgres connection + UPSTREAM_RELAY_BASE_URL (required for the 3 paid tools)
npm run start:dev
  • Health check: GET http://localhost:3011/health
  • MCP endpoint: POST http://localhost:3011/mcp
  • API docs (health only): http://localhost:3011/api/docs

Database migrations run automatically on boot — no separate CLI step needed.

Use it from Claude Desktop / Cursor

Add this to your MCP client's config (e.g. claude_desktop_config.json or Cursor's mcp.json):

{
  "mcpServers": {
    "abstraxn-public-web3": {
      "url": "http://localhost:3011/mcp"
    }
  }
}

Restart the client and the tools below become available to it — no further setup.

Available tools

Tool Paid? What it does
network.blocknumber No Current EVM block number or Solana slot. Query one chain or all at once.
network.transaction_status No Look up a transaction/signature by hash on EVM or Solana.
network.gas_info No Current gas price + EIP-1559 fee hints for an EVM chain.
network.token_info No ERC-20 name / symbol / decimals / total supply.
network.token_price No Spot price via CoinGecko (defaults to ETH/USD).
market.crypto Yes Crypto market-data lookups (CoinGecko-sourced), 6 actions.
web3.lookup Yes Multi-chain wallet / token / ENS / tx-simulation lookups, 7 actions.
travel.search Yes Flight and hotel search, 2 actions.

Tools are namespaced by area (network.*, market.*, web3.*, travel.*) so an MCP client can browse them as a tree rather than a flat list.

How paid tools work: call one with no payment, and you get back a paymentRequired challenge (not an error). Your wallet client signs it and retries the same call with paymentPayload set — your wallet pays directly; this service only relays the request.

Calling tools directly (curl)

Most people will use an MCP client (above), but the endpoint is plain JSON-RPC over HTTP if you want to script against it directly:

BASE=http://localhost:3011
ACCEPT='Accept: application/json, text/event-stream'   # required by the MCP spec

# 1. Initialize a session
curl -s -X POST "$BASE/mcp" -H 'Content-Type: application/json' -H "$ACCEPT" \
  -d '{"jsonrpc":"2.0","id":1,"method":"initialize","params":{"protocolVersion":"2025-06-18","capabilities":{},"clientInfo":{"name":"my-client","version":"1.0"}}}'

# 2. List available tools
curl -s -X POST "$BASE/mcp" -H 'Content-Type: application/json' -H "$ACCEPT" \
  -d '{"jsonrpc":"2.0","id":2,"method":"tools/list"}'

# 3. Call a tool
curl -s -X POST "$BASE/mcp" -H 'Content-Type: application/json' -H "$ACCEPT" \
  -d '{"jsonrpc":"2.0","id":3,"method":"tools/call","params":{"name":"network.token_price","arguments":{"symbol":"bitcoin"}}}'

GET /mcp returns 405 by design — every call is stateless, so there's no session to resume.

Configuration

Copy .env.example to .env. Everything has a safe default except the one marked required:

Variable Required Description
PORT No HTTP port (default 3011)
POSTGRES_HOST / PORT / USER / PASSWORD / DB No Postgres connection, used only for abuse tracking
PUBLIC_MCP_RATE_LIMIT_PER_MIN / _WINDOW_MS No Global per-IP rate limit (default 30/min)
CHAIN_RPC_* No Per-chain EVM RPC overrides — public defaults are used if unset (see src/mcp/utils/chain-registry.util.ts)
SOLANA_RPC_URL / SOLANA_DEVNET_RPC_URL No Solana cluster RPC overrides
UPSTREAM_RELAY_BASE_URL Yes Base URL for the upstream relay behind the 3 paid tools — no default is committed, so market.crypto / web3.lookup / travel.search fail until this is set

There is no auth-related variable — there's nothing to authenticate on a service with no accounts or API keys.

How it works

MCP client (Claude Desktop, Cursor, your agent)
    → POST /mcp  (this service, stateless — a fresh McpServer per request)
    → free tools: direct chain RPC / CoinGecko calls
    → paid tools: relayed upstream, settled by the caller's wallet via x402

This is a single, standalone deployable — it doesn't share a workspace or database with any other Abstraxn service. That's deliberate: several MCP registries expect a public MCP server to live in its own repo with one route and one fixed tool set, reviewable end to end.

Stack: Node.js 20+ · NestJS 11 · @modelcontextprotocol/sdk ^1.30.0 (official SDK) · PostgreSQL + TypeORM · @x402/core · viem (EVM) + raw JSON-RPC (Solana) · helmet, @nestjs/throttler

Database

Postgres is used for abuse tracking only — no tenant, policy, or config tables exist:

Table Purpose
observed_ips One row per caller IP, with a running call count and last-seen time.
observed_wallets One row per wallet address seen paying via x402.
public_mcp_transactions Append-only history of completed paid calls.

If Postgres is unreachable, a call still succeeds — tracking writes are best-effort and never block or fail a real MCP request.

Security

Since anyone can call this service with no key, a few invariants matter:

  • No SSRF surface: every outbound URL (chain RPC, upstream relay, CoinGecko) comes from server-side config — no tool accepts a caller-supplied URL.
  • Rate limiting is global and IP-keyed — the only lever available with no accounts. If you deploy behind a reverse proxy, set app.set('trust proxy', ...) in main.ts, or the limiter ends up rate-limiting the proxy instead of real callers.
  • No secrets beyond the DB password, which is env-only and never logged.
  • CORS is wildcard by design — nothing tenant-specific ever crosses an origin here.

Found a security issue? See CONTRIBUTING.md before opening a public issue.

Scripts

Script Description
npm run start:dev Run in watch mode
npm run build Compile to dist/
npm run start:prod Run the compiled build (dist/main)
npm run lint ESLint
npm test Jest — unit, SDK-level integration, and HTTP smoke tests

Contributing

Issues and PRs are welcome — see CONTRIBUTING.md for how to add a new tool and the project's definition of done.

License: MIT

推荐服务器

Baidu Map

Baidu Map

百度地图核心API现已全面兼容MCP协议,是国内首家兼容MCP协议的地图服务商。

官方
精选
JavaScript
Playwright MCP Server

Playwright MCP Server

一个模型上下文协议服务器,它使大型语言模型能够通过结构化的可访问性快照与网页进行交互,而无需视觉模型或屏幕截图。

官方
精选
TypeScript
Magic Component Platform (MCP)

Magic Component Platform (MCP)

一个由人工智能驱动的工具,可以从自然语言描述生成现代化的用户界面组件,并与流行的集成开发环境(IDE)集成,从而简化用户界面开发流程。

官方
精选
本地
TypeScript
Audiense Insights MCP Server

Audiense Insights MCP Server

通过模型上下文协议启用与 Audiense Insights 账户的交互,从而促进营销洞察和受众数据的提取和分析,包括人口统计信息、行为和影响者互动。

官方
精选
本地
TypeScript
VeyraX

VeyraX

一个单一的 MCP 工具,连接你所有喜爱的工具:Gmail、日历以及其他 40 多个工具。

官方
精选
本地
graphlit-mcp-server

graphlit-mcp-server

模型上下文协议 (MCP) 服务器实现了 MCP 客户端与 Graphlit 服务之间的集成。 除了网络爬取之外,还可以将任何内容(从 Slack 到 Gmail 再到播客订阅源)导入到 Graphlit 项目中,然后从 MCP 客户端检索相关内容。

官方
精选
TypeScript
Kagi MCP Server

Kagi MCP Server

一个 MCP 服务器,集成了 Kagi 搜索功能和 Claude AI,使 Claude 能够在回答需要最新信息的问题时执行实时网络搜索。

官方
精选
Python
e2b-mcp-server

e2b-mcp-server

使用 MCP 通过 e2b 运行代码。

官方
精选
Neon MCP Server

Neon MCP Server

用于与 Neon 管理 API 和数据库交互的 MCP 服务器

官方
精选
Exa MCP Server

Exa MCP Server

模型上下文协议(MCP)服务器允许像 Claude 这样的 AI 助手使用 Exa AI 搜索 API 进行网络搜索。这种设置允许 AI 模型以安全和受控的方式获取实时的网络信息。

官方
精选