JSON-RPC Interactive Tester
Test JSON-RPC methods directly in your browser. This interactive playground lets you modify requests, change parameters, and see real-time responses from Uniblock’s JSON-RPC endpoints.What is this for?
Use this tester to:- Experiment with JSON-RPC methods before implementing them
- Debug requests by modifying parameters and headers
- Learn JSON-RPC structure and response formats
- Validate your API key and endpoint configuration
For complete JSON-RPC documentation, see the JSON-RPC
Overview or browse chain-specific
methods.
Example: Get Ethereum Balance
This example demonstrates theeth_getBalance method, which returns the balance of an Ethereum address at a specific block.
cURL equivalent
Interactive playground
Understanding the request
Network identifier. Use
1 for Ethereum mainnet. See supported
chains for all chain IDs.Request identifier used to match responses with requests. Can be any number or
string.
JSON-RPC protocol version. Always use
"2.0".The JSON-RPC method to call. In this example,
eth_getBalance returns an
address balance.Method-specific parameters. For
eth_getBalance: - params[0] - Ethereum
address (string) - params[1] - Block identifier: block number (hex),
"latest", "earliest", or "pending"Expected response
result field contains the balance in wei (hexadecimal). Convert to decimal to get the actual value:
0x1bc16d674ec80000= 2,000,000,000,000,000,000 wei = 2 ETH
How to use the tester
- Modify the request body - Edit the JSON in the “Body” textarea to test different methods or parameters
- Update headers - Add your API key:
{"x-api-key": "YOUR_API_KEY", "content-type": "application/json"} - Change the chain - Modify the
chainIdquery parameter in the endpoint URL - Click “Run” - Execute the request and see the response
- Copy results - Use “Copy body” or “Copy response” buttons to save your work
Common methods to try
Ethereum (chainId=1)
eth_getBalance- Get address balanceeth_blockNumber- Get latest block numbereth_getBlockByNumber- Get block detailseth_getTransactionByHash- Get transaction detailseth_call- Execute a contract calleth_estimateGas- Estimate gas for a transaction
Polygon (chainId=137)
Same methods as Ethereum. Just changechainId=137 in the endpoint URL.
Solana (chainId=solana)
getBalance- Get SOL balancegetAccountInfo- Get account informationgetTransaction- Get transaction detailsgetBlock- Get block information
Troubleshooting
401 Unauthorized error
401 Unauthorized error
Invalid JSON error
Invalid JSON error
Check that your request body is valid JSON. Common issues: - Missing quotes
around strings - Trailing commas - Unescaped special characters
Method not found
Method not found
The method name may be incorrect or not supported on this chain. Check the
JSON-RPC documentation for
available methods.
Invalid params
Invalid params
Parameter format or count is incorrect. Each method expects specific parameters:
- Check parameter types (string, number, array)
- Verify parameter order
- Ensure required parameters are included