> For the complete documentation index, see [llms.txt](https://docs.luganodes.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.luganodes.com/rpc/mcp-server.md).

# MCP server

Read-only blockchain tools for AI agents on Ethereum, Bitcoin and Tron

***

### Overview

The Luganodes RPC MCP server gives AI agents read-only access to Ethereum Mainnet, Ethereum Beacon, Bitcoin and Tron. Connect it to any Model Context Protocol (MCP) client and ask questions in plain language, such as "Why is my Bitcoin transaction still pending?"

* **Read-only.** No tool can sign, send or broadcast, and every tool is marked with MCP's `readOnlyHint` annotation. Simulations and estimates commit nothing.
* **Purpose-built.** Tools validate inputs, cap outputs and decode amounts, transfers and fees. There is no raw RPC passthrough.
* **Same key and plan as RPC.** Each call draws compute units (CU) from your plan and reports its cost as `cu_charged`.

### Supported networks

| Chain              | Network | Tools | Minimum plan |
| ------------------ | ------- | ----- | ------------ |
| Ethereum Mainnet   | Mainnet | 18    | Free         |
| Ethereum Beacon    | Mainnet | 7     | Growth       |
| Bitcoin            | Mainnet | 12    | Free         |
| Tron               | Mainnet | 13    | Free         |
| Platform (account) |         | 1     | Free         |

### Connect your client

The server runs at `https://mcp.rpc.luganodes.com/mcp` over Streamable HTTP and authenticates with your Luganodes API key, sent as a Bearer header. Clients that support remote servers need no local install.

**Before you start.** Sign up at [rpc.luganodes.com](https://rpc.luganodes.com/sign-up) and copy the API key from your app page.

{% tabs %}
{% tab title="Claude code" icon="claude" %}

1. Set your API key in your shell:

```bash
export LUGANODES_API_KEY='<API_KEY>'
```

2. Add the server, on one line:

{% code overflow="wrap" %}

```bash
claude mcp add --scope user --transport http luganodes https://mcp.rpc.luganodes.com/mcp --header "Authorization: Bearer $LUGANODES_API_KEY"
```

{% endcode %}

3. Restart Claude Code, or start a new conversation.
4. Run `/mcp`. You should see `luganodes` connected.
   {% endtab %}

{% tab title="Cursor" icon="cursor" %}

1. Set your API key in your shell:

```bash
export LUGANODES_API_KEY='<API_KEY>'
```

2. Add to `~/.cursor/mcp.json` for all projects, or `.cursor/mcp.json` for one project:

```json
{
  "mcpServers": {
    "luganodes": {
      "url": "https://mcp.rpc.luganodes.com/mcp",
      "headers": { "Authorization": "Bearer ${env:LUGANODES_API_KEY}" }
    }
  }
}
```

3. Start Cursor from a terminal where `LUGANODES_API_KEY` is set (`open -a Cursor`), or set the variable in your shell profile.
4. Open **Cursor Settings > MCP**. You should see `luganodes` listed.
   {% endtab %}

{% tab title="Claude Desktop" icon="claude" %}

1. Open **Settings > Developer > Edit Config** and add to `claude_desktop_config.json`:

```json
{
  "mcpServers": {
    "luganodes": {
      "command": "npx",
      "args": ["-y", "mcp-remote", "https://mcp.rpc.luganodes.com/mcp",
               "--header", "Authorization:${AUTH_HEADER}"],
      "env": { "AUTH_HEADER": "Bearer <API_KEY>" }
    }
  }
}
```

`mcp-remote` substitutes `AUTH_HEADER` into the header. It needs Node.js.

2. Quit and reopen Claude Desktop.
3. In **Settings > Developer**, `luganodes` should show as running.
   {% endtab %}

{% tab title="VS Code Copilot" icon="vscode" %}

1. Add to `.vscode/mcp.json`:

   ```json
   {
     "servers": {
       "luganodes": {
         "type": "http",
         "url": "https://mcp.rpc.luganodes.com/mcp",
         "headers": { "Authorization": "Bearer ${input:luganodes-api-key}" }
       }
     },
     "inputs": [
       { "type": "promptString", "id": "luganodes-api-key", "description": "Luganodes API key", "password": true }
     ]
   }
   ```
2. Click **Start** above `luganodes` in the file, or run **MCP: List Servers**, and enter your API key when prompted. VS Code stores it securely, and the file then shows **Running**.
3. Open Copilot Chat in a **Local** session in **Agent** mode, and ask: "Use the luganodes tool `luga_get_account` to show my plan." Approve the tool call when prompted.

{% hint style="info" %}
VS Code does not pass servers that use `${input:...}` to Copilot CLI or cloud sessions. Use a Local session.
{% endhint %}
{% endtab %}

{% tab title="Any other client" icon="link-simple" %}
Point it at `https://mcp.rpc.luganodes.com/mcp` using Streamable HTTP, and send `Authorization: Bearer <API_KEY>` on every request. Clients that only launch local servers can bridge with `mcp-remote`, as in the Claude Desktop setup.
{% endtab %}
{% endtabs %}

### Limit what agents can do

The MCP server respects your app’s access controls, so you can limit which methods an agent can call, how many compute units it can use each day, and how many requests it can make per second.

### Getting started

Once the server is connected, there is nothing to sign in to or select: your API key already ties the server to your app and plan. The typical workflow is:

1. Check the connection, for example "Use `luga_get_account` to show my plan."
2. Ask your agent, for example "What tokens does vitalik.eth hold?" or "Why is my Bitcoin transaction still pending?"

### Bitcoin tools

<table><thead><tr><th width="270.15234375">TOOL</th><th>DESCRIPTION</th></tr></thead><tbody><tr><td><code>btc_get_chain_status</code></td><td>Height, best block, sync progress, pruning</td></tr><tr><td><code>btc_get_block</code></td><td>Time, transaction count, size, total fees, fee rate percentiles, optional header</td></tr><tr><td><code>btc_get_fee_estimates</code></td><td>Fee rate in sat/vB per confirmation target</td></tr><tr><td><code>btc_get_chain_statistics</code></td><td>Difficulty, hash rate in EH/s, transaction throughput</td></tr><tr><td><code>btc_get_mempool</code></td><td>Mempool size and minimum fee rate, or one transaction's fee rate, wait time, ancestors and descendants</td></tr><tr><td><code>btc_get_transaction</code></td><td>Inputs with values, outputs, fee, confirmations</td></tr><tr><td><code>btc_get_utxo</code></td><td>Whether an output is unspent, with its value and address</td></tr><tr><td><code>btc_decode_transaction</code></td><td>Decoded raw transaction: txid, inputs, outputs, sizes</td></tr><tr><td><code>btc_inspect_psbt</code></td><td>PSBT inputs, outputs, fee, next role and what each input is missing</td></tr><tr><td><code>btc_validate_address</code></td><td>Validity and type: P2PKH, P2SH, P2WPKH, P2WSH, P2TR or witness_unknown</td></tr><tr><td><code>btc_verify_message</code></td><td>Whether a signed message matches a legacy (1…) address</td></tr><tr><td><code>btc_verify_transaction_proof</code></td><td>Whether a Merkle proof is valid on the active chain, and the txids it proves</td></tr></tbody></table>

### Ethereum Mainnet tools

<table><thead><tr><th width="270.140625">TOOL</th><th>DESCRIPTION</th></tr></thead><tbody><tr><td><code>eth_get_chain_status</code></td><td>Chain ID, latest block, sync state</td></tr><tr><td><code>eth_get_block</code></td><td>Time, miner, gas, base fee, up to 50 transaction hashes</td></tr><tr><td><code>eth_get_gas_prices</code></td><td>Gas price, next base fee, priority fee percentiles and blob base fee, in gwei</td></tr><tr><td><code>eth_get_balance</code></td><td>ETH balance</td></tr><tr><td><code>eth_get_address_info</code></td><td>Contract or account, nonce, EIP-7702 delegate</td></tr><tr><td><code>eth_get_token_balances</code></td><td>Balances of up to 20 ERC-20 tokens in one Multicall3 read</td></tr><tr><td><code>eth_get_token_info</code></td><td>Name, symbol, decimals, total supply</td></tr><tr><td><code>eth_get_token_allowance</code></td><td>Amount a spender may move, and whether it is unlimited</td></tr><tr><td><code>eth_get_nft_info</code></td><td>ERC-721 or ERC-1155 owner or balance, approval, metadata URI</td></tr><tr><td><code>eth_get_storage</code></td><td>One raw storage slot, with presets for EIP-1967 proxy implementation, admin and beacon</td></tr><tr><td><code>eth_get_transaction</code></td><td>From, to, value, status, fee, decoded ERC-20 transfers</td></tr><tr><td><code>eth_call_contract</code></td><td>Decoded result of a read only contract call</td></tr><tr><td><code>eth_estimate_gas</code></td><td>Gas a proposed transaction would use</td></tr><tr><td><code>eth_get_block_receipts</code></td><td>Every receipt in a block: status, gas and log count, first 100 in detail</td></tr><tr><td><code>eth_get_logs</code></td><td>Up to 500 logs from up to 5 contracts over at most 1,000 blocks, with Transfer events decoded</td></tr><tr><td><code>eth_simulate_transactions</code></td><td>Status, gas and return data for up to 10 calls run in sequence</td></tr><tr><td><code>eth_get_txpool_status</code></td><td>Pending and queued transaction counts, never contents</td></tr><tr><td><code>eth_trace_transaction</code></td><td>Internal call tree, up to 200 frames, with revert reasons</td></tr></tbody></table>

### Ethereum Beacon tools

<table><thead><tr><th width="270.12109375">TOOL</th><th>DESCRIPTION</th></tr></thead><tbody><tr><td><code>beacon_get_chain_status</code></td><td>Genesis, sync status, head slot, justified and finalized epochs</td></tr><tr><td><code>beacon_get_block</code></td><td>Header with slot, proposer and roots; optional summary of attestations, sync participation, blobs and the execution block</td></tr><tr><td><code>beacon_get_chain_config</code></td><td>Spec values, fork schedule or deposit contract</td></tr><tr><td><code>beacon_get_validators</code></td><td>Status, balance, effective balance, slashed flag and withdrawal credentials for 1 to 50 validators</td></tr><tr><td><code>beacon_get_validator_duties</code></td><td>Proposer duties for an epoch, or attester and sync duties for up to 100 validators</td></tr><tr><td><code>beacon_get_validator_rewards</code></td><td>Block proposer reward, or attestation and sync committee rewards for up to 100 validators, in ETH</td></tr><tr><td><code>beacon_get_committees</code></td><td>Attestation committees for a slot, or the sync committee, with membership lists capped</td></tr></tbody></table>

### Tron tools

<table><thead><tr><th width="269.75">TOOL</th><th>DESCRIPTION</th></tr></thead><tbody><tr><td><code>tron_get_account</code></td><td>Activation, TRX balance, staked and unstaking TRX, bandwidth and energy</td></tr><tr><td><code>tron_get_block</code></td><td>Time, producer, transaction count, up to 50 transaction IDs</td></tr><tr><td><code>tron_get_transaction</code></td><td>Status, type, from and to, TRX amount, fee, energy and bandwidth, decoded TRC-20 transfers</td></tr><tr><td><code>tron_get_chain_parameters</code></td><td>Fee and protocol parameters such as the energy fee and unfreeze delay</td></tr><tr><td><code>tron_get_token_balances</code></td><td>Balances of up to 10 TRC-20 tokens</td></tr><tr><td><code>tron_get_token_info</code></td><td>Name, symbol, decimals, total supply</td></tr><tr><td><code>tron_get_token_allowance</code></td><td>Amount a spender may move</td></tr><tr><td><code>tron_get_contract_info</code></td><td>Deployer, energy sharing, energy factor and the first 100 function signatures</td></tr><tr><td><code>tron_call_contract</code></td><td>Decoded result and energy used, or a revert flag with the revert reason</td></tr><tr><td><code>tron_estimate_energy</code></td><td>Energy a proposed contract call would consume</td></tr><tr><td><code>tron_get_staking_info</code></td><td>TRX staked for bandwidth and energy, pending unstakes, unstake slots left, withdrawable TRX</td></tr><tr><td><code>tron_get_delegated_resources</code></td><td>Accounts it delegates to and receives from, first 50 each; with a counterparty, amounts and lock expiry</td></tr><tr><td><code>tron_get_logs</code></td><td>Up to 500 logs from up to 5 contracts over at most 1,000 blocks, with TRC-20 transfers decoded</td></tr></tbody></table>

### Platform tool

<table><thead><tr><th width="269.80859375">TOOL</th><th>DESCRIPTION</th></tr></thead><tbody><tr><td><code>luga_get_account</code></td><td>Plan, chains the app can use, throughput limit, CU used this cycle and today, and whether access controls are set</td></tr></tbody></table>

### How it works

The MCP server is hosted remotely at `https://mcp.rpc.luganodes.com/mcp`, uses Streamable HTTP, and authenticates with your Luganodes API key sent as a Bearer header. When your AI assistant gets a question, it picks the right tool, the server fetches and decodes the data, and the assistant answers in plain language.

* **Chain tools** send RPC requests to Luganodes nodes using your app’s key. They follow your app’s access controls and return decoded results. Each tool is charged for the RPC methods it calls, at the rates in the [CU tables](/rpc/compute-units/ethereum-mainnet-cu-table.md), and every result shows the total as `cu_charged`.
* **luga\_get\_account** reads your plan, enabled chains and usage directly from your Luganodes account. It costs 0 CU.

Before any request reaches a node, the server checks your inputs, your plan and the chains enabled for your app. A tool outside your plan is refused with a message naming the plan it needs.

Every tool is read-only. There are no write operations: nothing can sign, send or broadcast a transaction, and simulations and estimates commit nothing to the chain.
