data

Use this when you need to convert tabular data between JSON (array of objects), CSV, TSV, and XML instead of hand-transforming it.

Use this when you need to convert tabular data between JSON (array of objects), CSV, TSV, and XML instead of hand-transforming it. Deterministic: same input, same output. Handles quoted CSV fields (embedded commas, escaped "" quotes), flattens nested objects into dotted keys (b.x), and takes the union of keys across all rows so ragged data still lines up in columns. CSV/TSV input needs a header row plus at least one data row; JSON input must be an array of objects. Example: {from:'csv', to:'json'} on "name,age\nAda,36\nGrace,45" -> rowCount 2 and an output JSON array of two objects. Returns the input/output formats, the parsed row count, and the serialized output document as a string.

post/v1/convert_data

Request

  • Base URL: https://api.clean.tools
  • URL: https://api.clean.tools/v1/convert_data
  • Auth: none declared

Request body

datastring required

The source document as text.

from'json' | 'csv' | 'tsv' | 'xml' required

Input format.

to'json' | 'csv' | 'tsv' | 'xml' required

Output format.

Response

Structured tool result.

toolstring

Changes

No recorded changes to this operation across all 1 revision of this API.