ICON MCP v103 MCP Server

$git clone https://github.com/Traia-IO/icon-mcp-v103-mcp-server.git && cd icon-mcp-v103-mcp-server && export ICON_MCP_V103_API_KEY="your-api-key-here" && ./run_local_docker.sh
README.md

Secure access to ICON MCP v103 API via Bearer tokens or HTTP 402 payments

ICON MCP v103 MCP Server

This is an MCP (Model Context Protocol) server that provides with authentication via Bearer tokens access to the ICON MCP v103 API. It enables AI agents and LLMs to interact with ICON MCP v103 through standardized tools.

Features

  • 🔧 MCP Protocol: Built on the Model Context Protocol for seamless AI integration
  • 🌐 Full API Access: Provides tools for interacting with ICON MCP v103 endpoints
  • 🔐 Secure Authentication: Supports API key authentication via Bearer tokens
  • 💳 HTTP 402 Payment Protocol: Dual-mode operation (authenticated or paid access)
  • 🔗 D402 Integration: Uses traia_iatp.d402 for blockchain payment verification
  • 🐳 Docker Support: Easy deployment with Docker and Docker Compose
  • Async Operations: Built with FastMCP for efficient async handling

API Documentation

Available Tools

This server provides the following tools:

  • example_tool: Placeholder tool (to be implemented)

Note: Replace example_tool with actual ICON MCP v103 API tools based on the documentation.

Installation

Using Docker (Recommended)

  1. Clone this repository:

    git clone https://github.com/Traia-IO/icon-mcp-v103-mcp-server.git
    cd icon-mcp-v103-mcp-server
    
  2. Set your API key:

    export ICON_MCP_V103_API_KEY="your-api-key-here"
    
  3. Run with Docker:

    ./run_local_docker.sh
    

Using Docker Compose

  1. Create a .env file with your configuration:
    
    

Server's internal API key (for payment mode)

ICON_MCP_V103_API_KEY=your-api-key-here

Server payment address (for HTTP 402 protocol)

SERVER_ADDRESS=0x1234567890123456789012345678901234567890

Operator keys (for signing settlement attestations)

MCP_OPERATOR_PRIVATE_KEY=0x1234567890abcdef... MCP_OPERATOR_ADDRESS=0x9876543210fedcba...

Optional: Testing mode (skip settlement for local dev)

D402_TESTING_MODE=false PORT=8000


2. Start the server:
```bash
docker-compose up

Manual Installation

  1. Install dependencies using uv:

    uv pip install -e .
    
  2. Run the server:

    
    

ICON_MCP_V103_API_KEY="your-api-key-here" uv run python -m server


## Usage

### Health Check

Test if the server is running:
```bash
python mcp_health_check.py

Using with CrewAI

from traia_iatp.mcp.traia_mcp_adapter import create_mcp_adapter_with_auth

# Connect with authentication
with create_mcp_adapter_with_auth(
    url="http://localhost:8000/mcp/",
    api_key="your-api-key"
) as tools:
    # Use the tools
    for tool in tools:
        print(f"Available tool: {tool.name}")
        
    # Example usage
    result = await tool.example_tool(query="test")
    print(result)

Authentication & Payment (HTTP 402 Protocol)

This server supports two modes of operation:

Mode 1: Authenticated Access (Free)

Clients with their own ICON MCP v103 API key can use the server for free:

# Request with client's API key
curl -X POST http://localhost:8000/mcp \
  -H "Authorization: Bearer CLIENT_ICON_MCP_V103_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"method":"tools/call","params":{"name":"example_tool","arguments":{"query":"test"}}}'

Flow:

  1. Client provides their ICON MCP v103 API key
  2. Server uses client's API key to call ICON MCP v103 API
  3. No payment required
  4. Client pays ICON MCP v103 directly

Mode 2: Payment Required (Paid Access)

Clients without an API key can pay-per-use via HTTP 402 protocol:

# Request with payment proof (x402/d402 protocol)
curl -X POST http://localhost:8000/mcp \
  -H "X-PAYMENT: <base64_encoded_x402_payment>" \
  -H "Content-Type: application/json" \
  -d '{"method":"tools/call","params":{"name":"example_tool","arguments":{"query":"test"}}}'

Flow:

  1. Client makes initial request without payment
  2. Server returns HTTP 402 with PaymentRequirements (token, network, amount)
  3. Client creates EIP-3009 transferWithAuthorization payment signature
  4. Client base64-encodes payment and sends in X-PAYMENT header
  5. Server verifies payment via traia_iatp.d402.mcp_middleware
  6. Server uses its INTERNAL ICON MCP v103 API key to call the API
  7. Client receives result

D402 Protocol Details

This server uses the traia_iatp.d402 module for payment verification:

  • Payment Method: EIP-3009 transferWithAuthorization (gasless)
  • Supported Tokens: USDC, TRAIA, or any ERC20 token
  • Default Price: $0.001 per request (configurable via DEFAULT_PRICE_USD)
  • Networks: Base Sepolia, Sepolia, Polygon, etc.
  • Facilitator: d402.org (public) or custom facilitator

Environment Variables for Payment Mode

# Required
ICON_MCP_V103_API_KEY=your_internal_icon-mcp-v103_api_key  # Server's API key (for payment mode)
SE

Tools (1)

example_toolPlaceholder tool for interacting with ICON MCP v103 API endpoints.

Environment Variables

ICON_MCP_V103_API_KEYrequiredServer's internal API key for payment mode or client's key for authenticated mode
SERVER_ADDRESSServer payment address for HTTP 402 protocol
MCP_OPERATOR_PRIVATE_KEYOperator keys for signing settlement attestations

Configuration

claude_desktop_config.json
{"mcpServers":{"icon-mcp-v103":{"command":"docker","args":["run","-i","--rm","-e","ICON_MCP_V103_API_KEY","traia-io/icon-mcp-v103-mcp-server"],"env":{"ICON_MCP_V103_API_KEY":"your-api-key-here"}}}}

Try it

Use the ICON MCP v103 tool to fetch the latest market data for my query.
Run a test query through the ICON MCP v103 example tool.
Check the health of the ICON MCP v103 server connection.

Frequently Asked Questions

What are the key features of ICON MCP v103?

Dual-mode operation supporting both authenticated Bearer tokens and HTTP 402 pay-per-use.. Built on FastMCP for efficient asynchronous operations and seamless AI integration.. Integrated with traia_iatp.d402 for gasless EIP-3009 blockchain payment verification.. Full Docker and Docker Compose support for easy deployment and scaling..

What can I use ICON MCP v103 for?

AI agents requiring secure, programmatic access to ICON market data without pre-paid subscriptions.. Developers building LLM applications that need to monetize API access via blockchain payments.. Enterprise environments using Bearer tokens to provide AI models with internal API access..

How do I install ICON MCP v103?

Install ICON MCP v103 by running: git clone https://github.com/Traia-IO/icon-mcp-v103-mcp-server.git && cd icon-mcp-v103-mcp-server && export ICON_MCP_V103_API_KEY="your-api-key-here" && ./run_local_docker.sh

What MCP clients work with ICON MCP v103?

ICON MCP v103 works with any MCP-compatible client including Claude Desktop, Claude Code, Cursor, and other editors with MCP support.

Use ICON MCP v103 with Conare

Manage MCP servers visually, upload persistent context, and never start from zero with Claude Code & Codex.

Try Free