Skip to main content

JSON & Data Endpoints

JSON Format​

Format and prettify JSON strings.

POST /api/v1/json-format

Parameters​

NameTypeRequiredDescription
jsonstringYesJSON string to format
indentnumberNoIndentation level (0-8, default 2)

Example​

curl -X POST https://www.toolbox-kit.com/api/v1/json-format \
-H "Content-Type: application/json" \
-H "Authorization: Bearer YOUR_API_KEY" \
-d '{"json": "{\"name\":\"test\"}", "indent": 2}'
{ "result": "{\n \"name\": \"test\"\n}" }

JSON Minify​

Minify JSON by removing all whitespace.

POST /api/v1/json-minify

Parameters​

NameTypeRequiredDescription
inputstringYesJSON string to minify

Example​

curl -X POST https://www.toolbox-kit.com/api/v1/json-minify \
-H "Content-Type: application/json" \
-H "Authorization: Bearer YOUR_API_KEY" \
-d '{"input": "{\n \"name\": \"test\"\n}"}'
{ "result": "{\"name\":\"test\"}", "savings": 18, "savingsPercent": 47 }

JSON Validate​

Validate JSON and return structure details.

POST /api/v1/json-validate

Parameters​

NameTypeRequiredDescription
inputstringYesJSON string to validate

Example​

curl -X POST https://www.toolbox-kit.com/api/v1/json-validate \
-H "Content-Type: application/json" \
-H "Authorization: Bearer YOUR_API_KEY" \
-d '{"input": "[1, 2, 3]"}'
{ "result": { "valid": true, "type": "array", "keys": 0, "depth": 1, "arrayLength": 3 } }

CSV / JSON Convert​

Convert between CSV and JSON formats.

POST /api/v1/csv-json

Parameters​

NameTypeRequiredDescription
modestringYes"csv-to-json" or "json-to-csv"
csvstringNoCSV string (for csv-to-json)
dataarrayNoArray of objects (for json-to-csv)
delimiterstringNoDelimiter character (default ",")

Example​

curl -X POST https://www.toolbox-kit.com/api/v1/csv-json \
-H "Content-Type: application/json" \
-H "Authorization: Bearer YOUR_API_KEY" \
-d '{"mode": "csv-to-json", "csv": "name,age\nAlice,30\nBob,25"}'
{ "result": [{ "name": "Alice", "age": "30" }, { "name": "Bob", "age": "25" }], "rowCount": 2 }