cURL Examples
Here are some examples of how to use the Konbert API with cURL. These examples demonstrate different conversion scenarios and options.
Convert CSV to Parquet
This example shows how to convert a CSV file to Parquet format using multipart/form-data.
curl -X POST https://konbert.com/api/v1/convert \ -H "Authorization: Bearer ${API_KEY}" \ -F "input[format]=csv" \ -F "input[options][delimiter]=," \ -F "output[format]=parquet" \ -F "sync=true"
Convert JSON URL to CSV
This example demonstrates how to convert a JSON file from a URL to CSV format.
curl -X POST https://konbert.com/api/v1/convert \ -H "Authorization: Bearer ${API_KEY}" \ -F "input[http][url]=https://example.com/data.json" \ -F "input[format]=json" \ -F "output[format]=csv" \ -F "output[options][delimiter]=," \ -F "sync=true"
Convert Inline JSON to SQL
This example shows how to convert inline JSON data to SQL format using a JSON request body.
curl -X POST https://konbert.com/api/v1/convert \ -H "Authorization: Bearer ${API_KEY}" \ -H "Content-Type: application/json" \ -d '{ "input": { "data": [{"name": "John", "age": 30}], "format": "json" }, "output": { "format": "sql", "options": { "create_table": true, "table_name": "users" } }, "sync": true }'