Convert JSON rows (objects) to CSV

Converts an array of JSON objects to CSV text. The columns are the union of all keys. Returns text/csv.

Request

POSThttps://data-tools.p.apihiver.com/v1/json-to-csv

JSON object. Required: rows.

Request Body

Edit the values below to test different scenarios.

Parameters and body structure are inherited from this endpoint's definition. Changes here only apply to this test run.

Language
Client
1curl --request POST \
2  --url https://data-tools.p.apihiver.com/v1/json-to-csv \
3  --header 'Accept: application/json' \
4  --header 'Content-Type: application/json' \
5  --header 'X-API-Key: YOUR_API_KEY' \
6  --data '{
7  "rows": [
8    {
9      "age": 30,
10      "name": "Asha"
11    }
12  ]
13}'

Convert JSON rows (objects) to CSV: Data Tools API reference

Converts an array of JSON objects to CSV text. The columns are the union of all keys. Returns `text/csv`. This endpoint is part of the Data Tools API: Convert CSV ⇄ JSON, generate realistic fake test data (including Indian names and addresses), and create UUIDs in bulk.

Example response (200, text/csv)

The CSV text.

Errors

  • 400 — A required parameter is missing or a value has the wrong format.
    1{
    2  "error": {
    3    "code": "INVALID_INPUT",
    4    "message": "rows: Field required"
    5  }
    6}

Gateway errors (missing key, no subscription, rate limits) are listed in Error codes.