json_formatter
Format messy or compact JSON for debugging, API testing, and documentation.
Create an account, generate an API key, and send formatting, validation, minification, and conversion requests from your own apps.
/api/v1/tool/run/ using your key in the Authorization header.API requests require a valid ScriptZip API key. Keys are created per user account and are shown only once when generated.
Authorization: Bearer YOUR_API_KEY
Content-Type: application/json
Accept: application/json
You can also send the key in the X-API-Key header if that is easier for your integration.
The authenticated API uses one clean endpoint. Pass the tool key, the input text, and an optional options object.
{
"tool": "json_formatter",
"input": "{\"name\":\"ScriptZip\"}",
"options": {
"indent": 2
}
}
curl -X POST https://www.scriptzip.io/api/v1/tool/run/ \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"tool": "json_formatter",
"input": "{\"name\":\"ScriptZip\"}",
"options": {"indent": 2}
}'
const response = await fetch("https://www.scriptzip.io/api/v1/tool/run/", {
method: "POST",
headers: {
"Authorization": "Bearer YOUR_API_KEY",
"Content-Type": "application/json"
},
body: JSON.stringify({
tool: "css_minifier",
input: ".card { padding: 16px; color: #ffffff; }"
})
});
const result = await response.json();
import requests
response = requests.post(
"https://www.scriptzip.io/api/v1/tool/run/",
headers={
"Authorization": "Bearer YOUR_API_KEY",
"Content-Type": "application/json",
},
json={
"tool": "html_minifier",
"input": "<div> ScriptZip </div>",
},
timeout=20,
)
print(response.json())
Use the same tool keys that power the public tool pages. Start with the most common formatter, validator, minifier, and converter workflows below.
Format messy or compact JSON for debugging, API testing, and documentation.
Validate JSON and return useful syntax feedback.
Compress valid JSON into a compact payload.
Minify CSS for production stylesheets.
Minify HTML for smaller production markup.
Minify JavaScript before deployment.
Format XML for inspection and debugging.
Return word, character, and line counts from plain text.
Use the public tool pages when you want a fast browser workflow. Use the API when you want to call ScriptZip from your own applications, automations, or internal dashboards.
ScriptZip applies per-account API usage limits. Free accounts currently support a limited number of requests per day and per month. If your request volume exceeds the current limit, the API returns 429 with a clear error message.
API request bodies are processed server-side to return the requested result. Request metadata and byte counts may be logged, but the processor does not create a reusable content record from the submitted source. Use HTTPS, rotate keys when needed, and never expose raw API keys in frontend code.
Explore JSON Formatter, JSON Validator, HTML Minifier or open your developer dashboard to manage keys and usage.