Skip to main content

JSON-RPC Tester – Build and Validate JSON-RPC 2.0 Requests

Build, validate, and inspect JSON-RPC 2.0 request payloads in your browser. Use templates for common patterns, edit in raw mode, and reference standard error codes — no external network requests sent in v1.

  • Structured Builder: Form-based input for method, params, and id.
  • Raw Editor: Edit the full JSON payload directly.
  • Templates: Request, notification, batch, success, and error response.
  • Error Reference: Standard JSON-RPC error codes with explanations.
v1 scope: This tool builds and validates payloads locally. Live endpoint sending is out of scope for this version — use the generated payload with your own HTTP client (curl, Postman, fetch).
Reference guide

JSON-RPC 2.0 Quick Reference

Request Structure

{
  "jsonrpc": "2.0",
  "method": "subtract",
  "params": [42, 23],
  "id": 1
}

Omit id for a notification (no response expected).

Error Codes

-32700 Parse error
-32600 Invalid Request
-32601 Method not found
-32602 Invalid params
-32603 Internal error

Batch Request

[
  { "jsonrpc": "2.0", "method": "add", "params": [1, 2], "id": 1 },
  { "jsonrpc": "2.0", "method": "notify", "params": ["hello"] }
]

JSON-RPC vs REST

JSON-RPC uses a single endpoint and encodes the action as a method name in the body, rather than distributing it across HTTP verbs and URL paths. It is common in Ethereum node APIs (eth_getBalance), LSP (Language Server Protocol), and some internal microservice transports. For building and applying document diffs in an API context, see our JSON Patch tool. For validating API JSON payloads before integration, use the JSON validator.


Frequently Asked Questions

Is my data safe with this JSON tool?

Yes. This tool uses 100% client-side processing. Your JSON data never leaves your browser and is never sent to our servers, ensuring maximum privacy and security.

Does this tool work offline?

Once the page has loaded, all processing happens locally in your browser. You can disconnect from the internet and the tool will continue to work — no server connection is required to format, validate, or convert your JSON.

Is there a file size limit?

No server-side limits apply because everything runs in your browser. Practical limits depend on your device's memory, but modern browsers handle JSON files of tens of megabytes without issue.

What is JSON-RPC 2.0?

JSON-RPC 2.0 is a lightweight remote procedure call protocol that uses JSON for encoding. A request contains a 'jsonrpc' version string, a 'method' name, optional 'params', and an 'id'. Notifications omit the 'id'. Responses contain either a 'result' or an 'error' object.

What is the difference between a request and a notification?

A request includes an 'id' field and expects a response. A notification omits the 'id' field — the server processes it but does not return a response. Use notifications for fire-and-forget operations where you don't need to confirm success.

What are batch requests?

A JSON-RPC batch request is an array of request or notification objects sent in a single call. The server processes all items and returns an array of responses (one per request, none for notifications). Batching reduces round-trips for multiple operations.

Does this tool send requests to an endpoint?

No — v1 of this tool is a builder and validator only. It constructs and validates JSON-RPC payloads in your browser but does not make any outbound network requests. Use the generated payload with your preferred HTTP client (curl, Postman, fetch) to send it.

What are the standard JSON-RPC error codes?

Standard error codes: -32700 (Parse error), -32600 (Invalid Request), -32601 (Method not found), -32602 (Invalid params), -32603 (Internal error). Codes from -32099 to -32000 are reserved for server-defined errors.