Rpc
About 438 wordsAbout 1 min
2026-09-18
Overview
POST /v1/rpc is a synchronous JSON-RPC proxy endpoint that forwards standard Ethereum JSON-RPC requests to Robinhood Chain and returns the full response. Both single and batch requests are supported.
Request Format
POST /v1/rpc
Content-Type: application/json
X-User-ID: <your-api-key>The request body follows the standard JSON-RPC 2.0 specification:
{
"jsonrpc": "2.0",
"method": "<method-name>",
"params": [],
"id": 1
}Examples
Query Chain ID
curl -X POST https://robinhood-ohio.flashblock.trade/v1/rpc \
-H "Content-Type: application/json" \
-H "X-User-ID: <your-api-key>" \
-d '{"jsonrpc":"2.0","method":"eth_chainId","params":[],"id":1}'Response:
{
"jsonrpc": "2.0",
"id": 1,
"result": "0x1237"
}
0x1237= 4663 (Mainnet),0xb626= 46630 (Testnet)
Query Latest Block Number
curl -X POST https://robinhood-ohio.flashblock.trade/v1/rpc \
-H "Content-Type: application/json" \
-H "X-User-ID: <your-api-key>" \
-d '{"jsonrpc":"2.0","method":"eth_blockNumber","params":[],"id":1}'Response:
{
"jsonrpc": "2.0",
"id": 1,
"result": "0x1a4f5e"
}Query Account Balance
curl -X POST https://robinhood-ohio.flashblock.trade/v1/rpc \
-H "Content-Type: application/json" \
-H "X-User-ID: <your-api-key>" \
-d '{
"jsonrpc": "2.0",
"method": "eth_getBalance",
"params": ["0xYourAddress", "latest"],
"id": 1
}'Send Transaction (Synchronous)
You can also send transactions synchronously through this endpoint (waits for on-chain confirmation):
curl -X POST https://robinhood-ohio.flashblock.trade/v1/rpc \
-H "Content-Type: application/json" \
-H "X-User-ID: <your-api-key>" \
-d '{
"jsonrpc": "2.0",
"method": "eth_sendRawTransaction",
"params": ["0xf86c0a8502540be400..."],
"id": 1
}'For lower perceived latency, consider using the async transaction endpoint /v1/tx which returns immediately without waiting for the upstream response.
Batch Requests
Send multiple JSON-RPC calls in a single request by wrapping them in a JSON array:
curl -X POST https://robinhood-ohio.flashblock.trade/v1/rpc \
-H "Content-Type: application/json" \
-H "X-User-ID: <your-api-key>" \
-d '[
{"jsonrpc":"2.0","method":"eth_chainId","params":[],"id":1},
{"jsonrpc":"2.0","method":"eth_blockNumber","params":[],"id":2},
{"jsonrpc":"2.0","method":"eth_gasPrice","params":[],"id":3}
]'Response:
[
{"jsonrpc":"2.0","id":1,"result":"0x1237"},
{"jsonrpc":"2.0","id":2,"result":"0x1a4f5e"},
{"jsonrpc":"2.0","id":3,"result":"0x3b9aca00"}
]Batch Request Quota
Each element in a batch request consumes 1 quota unit. For example, a batch of 10 requests consumes 10 units at once. If the current quota is insufficient, the entire batch is rejected with 429 rate_limited.
Request Body Limits
- Maximum body size: 1 MiB (1,048,576 bytes)
- Empty body or invalid JSON returns
400 invalid_request
Notes
- Transaction methods (
eth_sendRawTransaction,eth_sendTransaction) sent through this endpoint consume transaction quota rather than query quota. The two quotas are independent. - All standard Ethereum JSON-RPC methods are supported.
- Upstream node failures return
502 upstream_error; timeouts return504 upstream_timeout.