What it can do
- Validate JSON syntax
- Indent nested values
- Sort object keys
How the recipe works
JSON Beautify
Parse the JSON, sort object keys, and emit two-space indentation.
Demonstration
Sample input
{"z":1,"a":{"ok":true,"items":[3,2,1]}}Expected result
A multi-line JSON document whose top-level a key appears before z.When to use it
- API debugging
- Configuration review
- Preparing stable diffs
Adapt it
Disable key sorting when original property order is meaningful to the investigation.
Source and verification
Adapted from GCHQ CyberChef Node API examples. The explanation and sample are written for Serialize, use synthetic or documentation-safe data, and are checked against the current operation catalogue. The workflow runs locally without an external API call.