Onesource MCP
@one-source/mcp
Unified MCP server for OneSource — 27 tools for blockchain data and live chain queries in a single server.
What is MCP? The Model Context Protocol lets AI assistants call tools and access data sources. This server exposes both the OneSource blockchain API and its documentation as tools.
Quick Start
Claude Code
claude mcp add onesource -- npx -y @one-source/mcp@latestClaude Desktop / Cursor
Add to your MCP config:
{
"mcpServers": {
"onesource": {
"command": "npx",
"args": ["-y", "@one-source/mcp@latest"]
}
}
}Any MCP Client (stdio)
npx -y @one-source/mcp@latestHTTP Server (self-hosted)
npx -y @one-source/mcp@latest --http
npx -y @one-source/mcp@latest --http --port=8080Then connect your MCP client to http://localhost:3000/.
Health check: GET http://localhost:3000/health
Related MCP server: sui-analytics-mcp
Tools (27)
Blockchain API — Live Chain (12 tools)
Tool | Description |
| ERC20 allowance check |
| Contract type detection via ERC165 |
| ERC1155 balance via RPC |
| ERC20 balance via balanceOf |
| ERC20 Transfer logs via eth_getLogs |
| ERC721 token enumeration |
| Event logs via eth_getLogs |
| ETH + multiple ERC20 balances |
| NFT metadata via tokenURI |
| NFT owner via ownerOf |
| Token total supply |
| Transaction + receipt via RPC |
Blockchain API — Chain Utilities (13 tools)
RPC only.
Tool | Description |
| Block details by number via RPC |
| Latest block number |
| EIP-155 chain ID |
| Contract bytecode |
| ENS name/address resolution |
| Gas estimation |
| Chain ID, block number, gas price |
| Transaction count |
| Pending block from mempool |
| Proxy contract detection |
| Simulate eth_call |
| Read storage slot |
| Transaction receipt |
Setup & Ops (2 tools)
No authentication required.
Tool | Purpose | When to use |
| Server health, version, auth status, setup instructions | First thing to call — checks if everything is configured |
| Report bugs to Slack (or GitHub Issues fallback) | When a tool errors or user wants to report an issue |
Networks
All blockchain API tools accept an optional network parameter:
Network | Description |
| Ethereum mainnet (default) |
| Ethereum Sepolia testnet |
| Avalanche C-Chain |
Authentication
Blockchain API tools require authentication. Two options are available — if both are set, API key takes priority.
Method | Variable | Description |
API key |
| Unlimited calls, no per-call cost |
x402 micropayments |
| Pay-per-call via USDC on Base, no account required |
Option 1: API Key
Go to app.onesource.io and create an account.
Subscribe to a developer plan (Stripe checkout).
Navigate to API Keys and generate a key.
Copy the key — it starts with
sk_.
Claude Code
claude mcp add onesource -e ONESOURCE_API_KEY=<key> -- npx -y @one-source/mcp@latestClaude Desktop / Cursor
Add the env block to your MCP config:
{
"mcpServers": {
"onesource": {
"command": "npx",
"args": ["-y", "@one-source/mcp@latest"],
"env": {
"ONESOURCE_API_KEY": "<key>"
}
}
}
}Any MCP Client (stdio)
ONESOURCE_API_KEY=<key> npx -y @one-source/mcp@latestAfter adding, reload the MCP server and call 1s_setup_check — it should show Status: Configured (API key).
Option 2: x402 Micropayments
Blockchain API endpoints are priced in USDC on Base via x402. When you set X402_PRIVATE_KEY, the server automatically handles payments — tool calls are paid and retried transparently without any extra work from the agent.
Get an EVM private key — export one from MetaMask, Coinbase Wallet, or any EVM wallet, or generate a fresh one. The key is a 64-character hex string. The
0xprefix is optional — both formats are accepted.Pass the key to the server using one of the methods below.
Reload and find your wallet address — reload the MCP server, then call
1s_setup_check. It will show the wallet address derived from your key under "Wallet address".Fund that address with USDC on Base — send USDC to the address shown in
1s_setup_check, on the Base network. A few dollars ($1–5 USDC) is enough for hundreds of calls. If your USDC is on Ethereum mainnet, bridge it using the Base Bridge.Verify — call
1s_network_infofor ethereum. If it returns chain data (block number, gas price), x402 payments are working end-to-end.
Claude Code
claude mcp add onesource -e X402_PRIVATE_KEY=<key> -- npx -y @one-source/mcp@latestClaude Desktop / Cursor
Add the env block to your MCP config:
{
"mcpServers": {
"onesource": {
"command": "npx",
"args": ["-y", "@one-source/mcp@latest"],
"env": {
"X402_PRIVATE_KEY": "<key>"
}
}
}
}Any MCP Client (stdio)
X402_PRIVATE_KEY=<key> npx -y @one-source/mcp@latestConfig File Locations
If you prefer editing the config file directly instead of using CLI commands:
Client | Config file path |
Claude Code | Run |
Claude Desktop (macOS) |
|
Claude Desktop (Windows) |
|
Cursor (macOS) |
|
Cursor (Windows) |
|
Add the onesource entry inside "mcpServers" using the JSON block shown above.
Alternative: Set as an Environment Variable
Instead of the env config block, you can set either variable as a shell or system environment variable: export ONESOURCE_API_KEY=<key> (bash/zsh) or $env:ONESOURCE_API_KEY = "<key>" (PowerShell). Set it at the OS level for persistence across sessions.
Security
Never commit keys to source control. Use environment variables, a .env file (excluded from git), or a secrets manager.
After any config change: Run
/reload-pluginsin Claude Code, or restart Claude Desktop / Cursor. The MCP server must be reloaded to pick up new environment variables.
Environment Variables
Variable | Default | Description |
| — | OneSource API key for Bearer token auth. Takes priority over x402. |
| — | EVM private key (64-char hex, |
|
| API base URL |
| — | Set to |
| — | Dashboard endpoint for analytics |
| — | API key for dashboard analytics |
Troubleshooting
1s_setup_check shows "Not configured"
Set either ONESOURCE_API_KEY or X402_PRIVATE_KEY. Reload the MCP server after setting either variable (see note above). If the key still isn't reaching the server, set it as a shell environment variable directly.
Getting 403 / wrong key active despite correct setup
A key set in your shell profile (e.g. ~/.zshrc, ~/.bash_profile) is picked up by the MCP server process even if it isn't in your Claude MCP config. Run echo $ONESOURCE_API_KEY in your terminal to check. If it prints a value you didn't intend, unset it (unset ONESOURCE_API_KEY) or explicitly clear it when adding the server: claude mcp add onesource -e ONESOURCE_API_KEY= -e X402_PRIVATE_KEY=<key> -- npx -y @one-source/mcp@latest. 1s_setup_check shows the first 6 characters of whichever key is active so you can confirm which one the server is using.
Instructions show wrong auth method after reinstall
/reload-plugins in Claude Code reconnects tools but may not refresh the system prompt the LLM sees. If you switch auth method (e.g. API key → x402), do a full Claude Code restart to ensure the instructions reflect the new auth.
"MCP server onesource already exists" error
Run claude mcp remove onesource first, then re-add with your updated config.
Windows: npx requires cmd /c wrapper
Claude Code's /doctor command may warn about this. Update your MCP config to use "command": "cmd" with "args": ["/c", "npx", "-y", "@one-source/mcp@latest"].
npx hangs with no output
That's normal — stdio mode waits for JSON-RPC input on stdin. Use --http if you want an HTTP server you can curl.
Port already in use
Specify a different port: npx -y @one-source/mcp@latest --http --port=8080
Registry Publishing
This package is listed on the official MCP Registry under the verified namespace io.onesource/mcp and on Glama. When releasing a new version, update both registries.
MCP Registry
First-Time Setup
1. Install Go
Download the installer for your platform from go.dev/dl and run it. Verify:
go version2. Install mcp-publisher
go install github.com/modelcontextprotocol/registry/cmd/mcp-publisher@latestIf the Go module path has changed and the command fails, download the binary directly from the mcp-publisher GitHub releases page instead.
On Windows, add Go's bin directory to your PATH if the command isn't recognized:
$env:PATH += ";$env:USERPROFILE\go\bin"Verify:
mcp-publisher --help3. DNS Authentication (already done)
The onesource.io domain has a DNS TXT record that proves ownership of the io.onesource namespace. This is already configured — you don't need to redo it.
The record is on the root domain (onesource.io, not _mcp-registry.onesource.io):
v=MCPv1; k=ed25519; p=7D3U5rufgNXb/lH2MthTRZdDzEGeE7/Jvg8YkiArQc8=You can verify it resolves:
nslookup -type=TXT onesource.io 8.8.8.84. Get the Private Key
Authentication requires the ed25519 private key in hex format that corresponds to the public key in the DNS record. Ask the team lead for this key — it's stored in the team's password manager / vault.
If you need to regenerate the keypair (this invalidates the current DNS record and requires updating it):
Generate a new ed25519 keypair (e.g.,
openssl genpkey -algorithm Ed25519 -out key.pem)Extract the raw 32-byte private key seed and convert to hex:
openssl pkey -in key.pem -outform DER | tail -c 32 | xxd -p -c 32Extract the public key in base64 for the DNS TXT record:
openssl pkey -in key.pem -pubout -outform DER | tail -c 32 | base64Update the DNS TXT record on
onesource.iowith the new public key:v=MCPv1; k=ed25519; p=<base64-public-key>Wait for DNS propagation before attempting to log in.
Publishing a New Version
Every time you release a new npm version, update the MCP Registry:
Publish to npm (the registry validates the package exists, so this must happen first):
npm run build npm publish --access publicUpdate
server.json— set bothversionfields to match the new npm version:{ "version": "x.y.z", ... "packages": [{ "version": "x.y.z", ... }] }The
mcpNamefield inpackage.jsonmust be"io.onesource/mcp"and must match thenamefield inserver.json. This is already set — don't remove it.Authenticate (tokens expire, so do this each time):
mcp-publisher login dns --domain onesource.io --private-key <ed25519-hex-private-key>Publish to the registry:
mcp-publisher publishVerify:
curl "https://registry.modelcontextprotocol.io/v0.1/servers?search=onesource"
Glama
Glama auto-syncs from the GitHub repo daily. No manual steps needed after a release — just make sure changes are pushed to main. The glama.json file in the repo root controls ownership. Manual re-sync is available from the Glama admin panel after claiming the server.
License
Apache 2.0 — see LICENSE for details.
Available Tools
27 tools1s_allowance_liveA
Check ERC20 token allowance (approved spending amount) via the allowance(owner,spender) RPC call. Use this before executing transferFrom or to verify approvals. Returns the allowance amount in raw token units.
Inputs: owner (required), spender (required), token (required), network.
1s_block_by_numberA
Get full block details by block number via RPC. Returns transactions, gas used, miner, timestamp, and other header fields. Accepts decimal (e.g. "21000000") or hex (e.g. "0x1406F40") block numbers.
Inputs: number (required), network.
1s_block_numberA
Get the latest block number for a network. Returns the current chain head as a hex-encoded value. Use 1s_network_info to also get chain ID and gas price in the same call.
Inputs: network.
1s_chain_idA
Get the EIP-155 chain ID for a network as a hex-encoded value. Use this to verify the network before signing transactions. Use 1s_network_info to get chain ID, block number, and gas price together.
Inputs: network.
1s_contract_codeA
Get the deployed bytecode of a contract via eth_getCode. Returns '0x' for EOA (non-contract) addresses. Bytecode can be very large for complex contracts. Prefer 1s_proxy_detect or 1s_contract_info_live for type checks without fetching full bytecode.
Inputs: address (required), network.
1s_contract_info_liveA
Detect contract type and supported interfaces via eth_getCode and ERC165 supportsInterface. Returns detected standards (ERC20, ERC721, ERC1155, ERC165).
Inputs: address (required), network.
1s_ens_resolveA
Resolve ENS names to addresses (forward) or addresses to ENS names (reverse). Accepts either a .eth name or a 0x address. Only works on networks with ENS registry deployed (mainnet, sepolia).
Inputs: input (required), network.
1s_erc1155_balance_liveA
Get real-time ERC1155 token balance via balanceOf(address,uint256) RPC call. Returns the raw balance as a numeric string.
Inputs: account (required), contract (required), token_id (required), network.
1s_erc20_balance_liveA
Get real-time ERC20 token balance directly from the blockchain via balanceOf. Use this for pre-transaction checks or when zero indexing delay is needed. Returns raw token units (divide by 10^decimals); non-standard tokens may return empty name/symbol.
Inputs: account (required), token (required), network.
1s_erc20_transfers_liveA
Query ERC20 Transfer(from, to, value) event logs via eth_getLogs directly from the node. Filter by token contract and/or wallet address. Block params are hex-encoded (e.g. 0x1234). Returns decoded transfer events with sender, recipient, and value. WARNING: Keep block ranges small (10 blocks or fewer) to avoid huge responses. Omitting from_block/to_block queries only the latest block.
Inputs: token, wallet, from_block, to_block, +1 more.
1s_erc721_tokens_liveA
Enumerate ERC721 tokens owned by an address via ERC721Enumerable. Only works for contracts that implement the Enumerable extension. Returns token IDs owned by the address.
Inputs: owner (required), contract (required), network.
1s_estimate_gasA
Estimate gas required for a transaction via eth_estimateGas. Use this before sending transactions to set appropriate gas limits. Returns the estimated gas as a hex value; reverts return the revert reason.
Inputs: to (required), data, from, value, +1 more.
1s_events_liveA
Query raw event logs via eth_getLogs directly from the node. Filter by contract address and/or topic0 (keccak256 hash of event signature, e.g. Transfer(address,address,uint256)). Block params are hex-encoded (e.g. 0x1234). Returns raw log entries with topics, data, and block context. WARNING: Keep block ranges small (10 blocks or fewer) to avoid huge responses. Always specify a contract address when possible. Omitting from_block/to_block queries only the latest block.
Inputs: contract, topic, from_block, to_block, +1 more.
1s_multi_balance_liveA
Get ETH and multiple ERC20 balances in a single batched RPC call. Use this to check a wallet's holdings across multiple tokens efficiently. Individual token errors are returned per-token without failing the entire request.
Inputs: address (required), tokens, network.
1s_network_infoA
Get basic network information: chain ID, latest block number, and current gas price. Use this to verify which chain you are connected to or to check current gas conditions. Returns hex-encoded values; gas price is in wei.
Inputs: network.
1s_nft_metadata_liveA
Fetch NFT metadata directly from the blockchain via tokenURI/uri RPC call. Resolves all URI formats: ipfs://, ar://, data: URIs, bare CIDs, and ERC1155 {id} templates.
Inputs: contract (required), token_id (required), network.
1s_nft_owner_liveA
Get the current NFT owner via ownerOf(tokenId) RPC call. Only works for ERC721 tokens.
Inputs: contract (required), token_id (required), network.
1s_nonceA
Get the transaction count (nonce) for an address via eth_getTransactionCount. Use this to set the correct nonce when constructing transactions. Returns the count as a hex value.
Inputs: address (required), network.
1s_pending_blockA
Get the current pending block from the mempool. Use this to see transactions waiting for inclusion. WARNING: Response can be very large (1MB+) on mainnet as it includes all pending transactions. Prefer 1s_network_info for chain status or 1s_tx_details_live for specific transactions. Not all nodes expose pending block data; results vary by RPC provider.
Inputs: network.
1s_proxy_detectA
Detect if a contract is a proxy and read its implementation address. Checks EIP-1967 (transparent/UUPS/beacon) storage slots. Returns the proxy type, implementation address, and admin if applicable.
Inputs: address (required), network.
1s_report_bugA
Report a bug or issue to the OneSource team. Use when a tool returns an unexpected error or when the user asks to report a problem. Free, no payment required.
Inputs: description (required), tool_name, error_message, severity, +2 more.
1s_setup_checkA
Check OneSource MCP server health — version (current vs latest), authentication status (API key or x402), API connectivity, and setup instructions if anything is missing. Free, no authentication required. Call this first when troubleshooting.
Inputs: no named parameters.
1s_simulate_callA
Simulate a contract call via eth_call without sending a transaction. Use this to preview call results, decode return data, or check for reverts before sending. Returns the raw hex result or revert reason.
Inputs: to (required), data (required), from, value, +2 more.
1s_storage_readA
Read a raw storage slot from a contract via eth_getStorageAt. Use this for low-level state inspection (e.g. reading proxy implementation slots, packed storage). Slot must be a hex-encoded 32-byte value.
Inputs: contract (required), slot (required), network.
1s_total_supply_liveA
Get the total supply of an ERC20 or ERC721 token via totalSupply() RPC call. Use this for real-time supply data. Returns raw token units for ERC20 (divide by 10^decimals) or total count for ERC721.
Inputs: contract (required), network.
1s_tx_details_liveA
Get full transaction data and receipt directly from the RPC node. Returns both transaction fields and receipt (status, gas used, logs).
Inputs: hash (required), network.
1s_tx_receiptA
Get a transaction receipt via RPC. Returns status (1=success, 0=revert), gas used, logs, and contract address if deployment. Use 1s_tx_details_live for both transaction data and receipt together.
Inputs: hash (required), network.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
TDQS
Scored across 27 tools
Most tools have distinct purposes, e.g., 1s_allowance_live vs 1s_erc20_balance_live, 1s_tx_details_live vs 1s_tx_receipt. Some overlap exists (e.g., 1s_network_info includes block number and chain ID) but descriptions guide usage clearly.
All tools share the '1s_' prefix and use snake_case. Names are descriptive, though patterns vary (e.g., verb_noun in 1s_estimate_gas, noun_adjective in 1s_allowance_live). Minor inconsistency but overall readable.
27 tools for an Ethereum RPC server is slightly above average but each covers a specific RPC endpoint or operation. The scope is broad, so the count is reasonable and not excessive.
The tool set covers nearly all important Ethereum interactions: balances, transactions, events, ENS, contract inspection, gas estimation, and more. A setup check and bug report tool add to completeness. No major gaps for the domain.
Maintenance
Related MCP Connectors
Free MCP server of security & dev API tools -- supply-chain, CVE, DNS, WHOIS, OFAC, Cosmos SDK.
Self-hosted MCP server: 26 deterministic dev, security, and EVM tools.
Crypto market intelligence, token rug-checks, and wallet verification in one MCP server.
MCP server connecting AI agents to non-custodial staking data across 130+ networks.
Related MCP Servers
- AlicenseAqualityCmaintenanceA Bitcoin Ordinals MCP server with 24 tools covering inscriptions, runes, BRC-20 tokens, collections, rare sats, and marketplace data, aggregating Hiro, Ordiscan, and Magic Eden APIs with intelligent caching and automatic failover.2460 npm2MIT
- AlicenseAqualityBmaintenanceRead-only MCP server for Sui blockchain analytics with 44 tools covering wallets, DeFi, NFTs, token prices, transactions, fund tracing, pools, staking, Move decompilation, and MVR name resolution.19291 npm3MIT

Octav API MCP Serverofficial
AlicenseAqualityBmaintenanceMCP server for querying cryptocurrency portfolio data, transaction history, net worth, and historical snapshots across 20+ blockchains via the Octav API.32131 npm1MIT- AlicenseAqualityDmaintenanceA read-only MCP server that queries multichain EVM on-chain data through Blockscout REST API, providing tools for address info, transactions, logs, and more.1620 npmMIT