工作流示例 1
Input example
Compact response: {"status":"ok","data":{"id":42,"items":[{"sku":"A1","qty":2}]}}
Output example
Readable response: {
"status": "ok",
"data": {
"id": 42,
"items": [
{
"sku": "A1",
"qty": 2
}
]
}
}
JSON 格式化工具 processes this example in the browser and lets you inspect the result before copying it.
工作流示例 2
Input example
Broken JSON: {"name":"LumaTool", "enabled": true,}
Output example
Validation result: Error: trailing commas are not valid JSON.
JSON 格式化工具 processes this example in the browser and lets you inspect the result before copying it.
工作流示例 3
Input example
JSON text: {"message":"Hello \n world"}
Output example
String literal: "{\"message\":\"Hello \\n world\"}"
JSON 格式化工具 processes this example in the browser and lets you inspect the result before copying it.
工作流示例 4
Input example
Unsorted config: {"timeout":30,"apiKey":"demo","baseUrl":"https://api.example.com"}
Output example
Sorted keys: {
"apiKey": "demo",
"baseUrl": "https://api.example.com",
"timeout": 30
}
JSON 格式化工具 processes this example in the browser and lets you inspect the result before copying it.
工作流示例 5
Input example
Pretty payload: {
"query": "tools",
"limit": 10
}
Output example
Minified payload: {"query":"tools","limit":10}
JSON 格式化工具 processes this example in the browser and lets you inspect the result before copying it.