Apify Actor

Messy CSV, JSON, XML or Excel in; the exact JSON, CSV or Excel you want out.

Give one example object; every row is mapped, cleaned and validated against it, and each failed row comes with a reason. Built for customer uploads, scraper output and lead lists.

Price: $0.001 per run + $0.0001 per valid row (1,000 rows ≈ $0.10) + $0.01 per AI mapping. Failed rows are free.

Live demo

Paste your data, write the JSON you want in the output and press Convert.

At most 50 records and 64 KB, 30 tries per hour. Extra columns never reach the output.
Write the fields you want in the output. If you give a real value (email, web address), that field is checked against its rules.

The sample is messy on purpose: ; delimiter, padded cells, one website without https and one bad email.

Call it in 3 steps

  1. Sign up on Apify and get your API token (Settings → API & Integrations). The free plan works; AI mapping runs only on paid Apify plans. Token page →
  2. Send your data and an example of the output you want in one request:
    curl -X POST "https://api.apify.com/v2/acts/forlab~csv-json-schema-formatter/run-sync-get-dataset-items?token=$APIFY_TOKEN" \
      -H 'Content-Type: application/json' \
      --data-binary @- <<'JSON'
    {
      "text": "Company;Website;E-mail\nAcme Logistics;acme.example.com;info@acme.example.com\nDelta Gıda;https://delta.example.net;sales@delta",
      "targetExample": {
        "company": "Acme",
        "website": "https://acme.com",
        "email": "info@acme.com"
      }
    }
    JSON
  3. The reply is a JSON array of the valid rows. Failed rows and their reasons are in the run's OUTPUT record.
    [
      {
        "company": "Acme Logistics",
        "website": "https://acme.example.com",
        "email": "info@acme.example.com"
      }
    ]

Python, JavaScript and CLI examples (Apify Store) · Every input field and the response schema are in the OpenAPI document. openapi.json

What it does

  • In: CSV/TSV, Excel, JSON, NDJSON, XML, YAML and HTML tables; paste, give a file URL or an Apify dataset, merge up to 10 sources. Delimiters, encodings and broken JSON are handled for you.
  • Clean in the same run: filter, dedupe, sort, flatten nested JSON, and select or rename columns.
  • Out: JSON, JSONL, CSV, Excel, Markdown, HTML, SQL INSERT and JSON Schema.