Small tasks. A little easier.126 tools · No account required

Find your next tool

Search all 126 tools and their practical guides.

Developer

Format an API response without changing identifier meaning

Validate JSON syntax, choose readable indentation, and recognize precision and schema limits before copying an API response.

ERITHRA editorial3 min read

Make structure visible before editing values

A compact API response can be valid while remaining difficult to inspect. The JSON Formatter & Validator parses your input and serializes the result with two spaces, four spaces, or no optional whitespace. Formatting helps you follow arrays and nested objects, but the parser also determines which values survive the round trip.

Paste the JSON into Input, choose Pretty (2 spaces), then select Process input. Double quotes are required around object keys and string values. Trailing commas, JavaScript comments, and single-quoted strings will produce an error. Fix the first syntax problem and run the formatter again; a later error may become visible only after the earlier one is resolved.

Try a small response

Use this input:

{ "order": "00042", "items": [{ "sku": "A7", "quantity": 2 }], "paid": false }

The expected result is an object with order, items, and paid on separate lines. The item remains inside an array, quantity remains the number 2, and the order identifier remains the string "00042". Change Formatting to Compact to return a single-line representation of the same parsed data. Downloading produces formatted.json.

An identifier is often better represented as a string even when it contains only digits. Leading zeros express a fixed identifier format, not arithmetic. The browser’s JSON number parser can also lose precision for sufficiently large integer literals. Converting a rounded number back to a string afterward cannot restore the original digits.

Check meaning separately from syntax

A successful result says the input is syntactically valid JSON. It does not establish that an API requires these fields, that a date is real, or that a quantity is allowed. Validate those rules against the receiving system’s schema. Duplicate object keys are another reason to retain the original response: parsing may replace an earlier value with a later one.

Use up to 250,000 input characters per operation. Processing happens in this browser; the tool does not need to submit your response to an ERITHRA processing service. Still remove access tokens and personal records from examples you plan to share, including screenshots and downloaded files.

For tabular input, start with CSV to JSON. For an export to a spreadsheet workflow, use JSON to CSV after deciding which fields belong in flat columns.

JSONAPIsvalidation

Put it into practice

Keep reading