Skip to main content
The Sei Model Context Protocol (MCP) Server enables AI assistants to interact with Sei networks through natural language. Built on the Model Context Protocol standard, it provides blockchain tools for AI coding assistants.
The Sei MCP Server is open source. Contribute at github.com/sei-protocol/sei-js. @sei-js/mcp-server@1 requires Node.js 20 or newer.
The server starts in read-only mode. Wallet tools that sign or broadcast are hidden unless you set WALLET_MODE=private-key and PRIVATE_KEY on the default stdio transport.

What is MCP?

The Model Context Protocol is an open standard that connects AI systems with external tools and data sources. It enables:
  • Real-time data access from external services
  • Function execution and operations
  • Context preservation across interactions
  • Specialized capabilities beyond base training
The Sei MCP Server leverages this protocol to bring blockchain functionality directly to your AI assistant.

Capabilities

Setup guide

Cursor Setup

1

Open Settings

Navigate to Cursor → Settings → Cursor Settings → MCP
2

Configure Server

Click “Add new Global MCP server” and add this configuration to mcp.json:
3

Restart

Restart Cursor to activate the MCP server. You’ll see a notification when it’s ready.

Private key setup

The server starts in read-only mode. To enable wallet tools over the default stdio transport, add both variables to the server’s env configuration:
Create a dedicated wallet for MCP operations. Never use your main wallet’s private key. The 0x prefix on PRIVATE_KEY is optional. Wallet mode is blocked on HTTP transports. Startup fails if private-key mode is misconfigured instead of silently disabling wallet tools.
Export your private key from your wallet:
  • Look for Export Private Key or Show Private Key in wallet settings
  • Fund the wallet with small amounts for testing

Features

The Sei MCP Server enables your AI assistant to:
  • Query account balances, tokens, NFTs, blocks, and transactions (read-only)
  • Search the official Sei docs, including @sei-js references (search_docs)
  • Monitor network status for Pacific-1 and Atlantic-2
  • Execute token transfers, NFT transfers, contract writes, and deploys when wallet mode is enabled on stdio

Available tools

Read-only tools stay registered when wallet mode is disabled. Signing and broadcasting tools are hidden until you enable wallet mode on stdio. Network arguments accept sei, sei-testnet, 1329, 1328, 0x531, or 0x530. Unknown networks are rejected. Chain-info responses omit RPC URLs. search_docs queries docs.sei.io. There is no search_sei_js_docs tool.

Core operations

Token management

Reach for get_token_balance and transfer_token. The server also registers aliases for backward compatibility: get_erc20_balance and get_token_balance_erc20 behave like get_token_balance but name the holder argument address instead of ownerAddress, and transfer_erc20 is transfer_token under a different name with the same arguments.

NFT and ERC-1155

NFT ownership lookup failures propagate as errors instead of reporting false. ERC-721 transfers use safeTransferFrom, so contract recipients must implement onERC721Received.

Blocks and transactions

AI prompts

These prompts are always available, including in read-only mode:

explore_block

Analyze block data

analyze_transaction

Break down transaction details

analyze_address

Inspect an address and its activity

analyze_token

Summarize token metadata and balances

interact_with_contract

Walk through calling a contract

explain_evm_concept

Explain an EVM concept in context

compare_networks

Compare Pacific-1 and Atlantic-2
These prompts require wallet mode on the stdio transport:

my_wallet_address

Return the configured wallet address

send_transaction_guidance

Guide you through sending a transaction

token_transfer_guidance

Guide you through a token transfer

Usage examples

Query balance

“What’s my SEI balance?”Calls get_balance and returns the wallet balance and address.

Send transaction

“Send 1 SEI to 0x742d35Cc6634C0532925a3b844Bc454e4438f44e”Calls transfer_sei and returns the transaction hash. Requires wallet mode.

Contract analysis

“Is 0x3894085ef7ff0f0aedf52e2a2704928d1ec074f1 a contract?”Calls is_contract and identifies the contract type and metadata.

Resource URIs

Access blockchain data through standardized URIs:

Configuration

Client-launched servers (npx from Cursor, Claude Desktop, or similar) read variables from the MCP client’s env object. A project-local .env is loaded only when the process starts in a directory that contains one, such as a local checkout.
CLI flags such as --http are not supported. Set SERVER_TRANSPORT instead. Run npx -y @sei-js/mcp-server --help for the current reference.

HTTP server mode

Streamable HTTP is the HTTP transport for new integrations:
Connect to http://127.0.0.1:8080/mcp. Change the listener with SERVER_HOST, SERVER_PORT, and SERVER_PATH. Legacy HTTP/SSE is available for older clients:
For http-sse, GET {SERVER_PATH} is the event stream. Clients POST messages to {SERVER_PATH}/message?sessionId=<id>.
HTTP transports reject wallet mode. They do not authenticate callers or validate Origin/Host. Bind to 127.0.0.1 for local use, and put any public exposure behind an authenticating reverse proxy.

Security guidelines

Use a dedicated wallet with only the funds you need for testing. Set PRIVATE_KEY through environment variables or the MCP client’s env object. Never commit it. Review transaction history on that wallet regularly.
Beyond a throwaway test wallet, treat the signing key as production infrastructure: cap the value any single transaction can move, hold funds in a multi-signature wallet and let the agent operate a low-balance hot wallet, restrict the agent to an allowlist of contract addresses, and rate-limit the tools that sign or broadcast.

Troubleshooting

Connection issues: Verify Node.js 20 or later is installed and restart your AI assistant. Private key errors: Set WALLET_MODE=private-key, provide a valid 32-byte secp256k1 key (0x prefix optional), and use the default stdio transport. Cursor: The model returned an error. Try disabling the MCP servers, or switch models: Disable “Auto” in the model menu and select a specific model e.g. claude-4-sonnet