> ## Documentation Index
> Fetch the complete documentation index at: https://docs.tenderly.co/llms.txt
> Use this file to discover all available pages before exploring further.

# Run Graph Node on Tenderly Node RPC

> Point a self-hosted Graph Node at Tenderly Node RPC to index subgraphs on public networks, including call handlers that need trace_filter.

Graph Node indexes subgraphs from any Ethereum JSON-RPC endpoint. Point it at a [Node RPC](/node-rpc/overview) endpoint to index a public network with event handlers, call handlers, and contract calls in mappings.

This page was tested with Graph Node 0.45.0 on Ethereum mainnet: a subgraph with an event handler, a call handler on USDC `transfer(address,uint256)`, and a `balanceOf` call in its mapping indexed from a recent block and stayed within one block of the chain head. To index a forked copy of a network instead, see [Index a Virtual Environment with The Graph](/virtual-environments/develop/thegraph).

## Before you begin

* A Node RPC URL for your network, from the **Integrate** view of Node RPC in the [Tenderly Dashboard](https://dashboard.tenderly.co)
* A subgraph and the `docker-compose.yml` that `graph init` generates for it (see [Set up Graph Node and the subgraph](/virtual-environments/develop/thegraph#set-up-graph-node-and-the-subgraph); the scaffolding steps are the same for a public network)

## Configure the Ethereum provider

In the generated `docker-compose.yml`, set `ethereum` in the `graph-node` service to `<network>:archive,traces:<Node RPC URL>`. The network name before the first colon must match `network` in `subgraph.yaml`.

```yaml title="docker-compose.yml (graph-node environment)" highlight={7} theme={"theme":{"light":"catppuccin-latte","dark":"catppuccin-mocha"}}
    environment:
      postgres_host: postgres
      postgres_user: graph-node
      postgres_pass: let-me-in
      postgres_db: graph-node
      ipfs: "ipfs:5001"
      ethereum: "mainnet:archive,traces:https://mainnet.gateway.tenderly.co/${TENDERLY_NODE_ACCESS_KEY}"
      GRAPH_LOG: info
```

Docker Compose substitutes `${TENDERLY_NODE_ACCESS_KEY}` from your shell, so the access key stays out of the file:

```bash theme={"theme":{"light":"catppuccin-latte","dark":"catppuccin-mocha"}}
export TENDERLY_NODE_ACCESS_KEY=<your-access-key>
docker compose up -d
docker compose logs -f graph-node
```

On startup, Graph Node logs `capabilities: archive, traces` for the provider and `Provider supports block receipts`, which means it fetches all receipts of a block with one `eth_getBlockReceipts` request.

| Capability | Enables | Node RPC methods |
| - | - | - |
| `archive` | Contract calls in mappings (`ethereum.call`) at historical blocks | `eth_call`, `eth_getBalance`, `eth_getCode` at a block hash |
| `traces` | Call handlers (`callHandlers`) and block handlers with a `call` filter | `trace_filter` |

Graph Node assumes both capabilities when the `ethereum` value has none (`mainnet:<url>`). Declare them explicitly so the configuration shows what the subgraph relies on.

Keep `ETHEREUM_REORG_THRESHOLD` at its default of `250` on public networks. Graph Node uses it to roll back blocks when the network reorganizes, so don't copy the value of `1` from a Virtual Environment setup.

## Check that your network serves trace\_filter

Call handlers need `trace_filter`, which not every network on Node RPC serves. Request one recent block:

```bash theme={"theme":{"light":"catppuccin-latte","dark":"catppuccin-mocha"}}
URL=https://mainnet.gateway.tenderly.co/$TENDERLY_NODE_ACCESS_KEY
BLOCK=$(cast block-number --rpc-url $URL)
curl -s $URL \
  -H 'content-type: application/json' \
  -d "{\"jsonrpc\":\"2.0\",\"id\":1,\"method\":\"trace_filter\",\"params\":[{\"fromBlock\":\"$(cast to-hex $BLOCK)\",\"toBlock\":\"$(cast to-hex $BLOCK)\"}]}"
```

An array in `result` means call handlers work on that network. An error such as `the method trace_filter does not exist/is not available` or `Method not found` means they don't; index the contract's events with `eventHandlers` instead. Pass block numbers as hex, because `trace_filter` rejects the `latest` tag with `Invalid params`.

## Requests Graph Node sends

Graph Node polls Node RPC continuously, so every indexed network uses requests even when no subgraph has new events. See [Node RPC pricing](/node-rpc/pricing) for the cost of each request category.

| Graph Node activity | Methods |
| - | - |
| Poll for the latest block, every `ETHEREUM_POLLING_INTERVAL` (default `1000` ms) | `eth_getBlockByNumber` |
| Load new blocks and their receipts | `eth_getBlockByHash`, `eth_getBlockReceipts` |
| Find events for event handlers | `eth_getLogs` |
| Contract calls in mappings | `eth_call` (Compute) |
| Call handlers and `call` block filters | `trace_filter` (Debug and Trace) |

Call handlers are the most expensive part of a typical subgraph on Node RPC, because a trace request costs more than a read or a contract call. When the contract emits an event for the same action, index the event instead. Raise `ETHEREUM_POLLING_INTERVAL` to poll less often when a few seconds of indexing delay are acceptable.

## Troubleshooting

| Symptom | Cause | Fix |
| - | - | - |
| `Trying again after trace_filter RPC call ... failed` and the subgraph stops advancing | The network doesn't serve `trace_filter`. | [Check trace support](#check-that-your-network-serves-trace_filter) and use event handlers on networks without it. |
| `network not supported by registrar: no network base found on chain ethereum` on `graph deploy` | `network` in `subgraph.yaml` doesn't match the network name in `ethereum`. | Use the same name in both. |
| `Receipt for tx ... unavailable, block was likely uncled` repeats for the same block | Graph Node couldn't load the block's receipts. | Graph Node retries automatically. If the same block keeps failing, email `support@tenderly.co` with the network and block hash. |

## Related

* [Node RPC overview](/node-rpc/overview)
* [Node RPC pricing](/node-rpc/pricing)
* [RPC reference](/node-rpc/rpc-reference?method=trace_filter) for `trace_filter`
* [Index a Virtual Environment with The Graph](/virtual-environments/develop/thegraph) for indexing a forked network


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.