# Dataset Filter & Converter: JSON to CSV/Excel \[$0.50/1K 💰] (`cybermax/dataset-filter-transform`) Actor

💰 $0.50 per 1,000 rows kept; filtered-out rows and file exports free, no start fee. Filter and transform Apify datasets: keep matching rows, pick and rename fields, flatten nested JSON, split arrays, sort, export CSV or Excel. Cheaper than nerolabs' filter ($1.40–2/1K). New rows only on schedules.

- **URL**: https://apify.com/cybermax/dataset-filter-transform.md
- **Developed by:** [CyberMax](https://apify.com/cybermax) (community)
- **Categories:** Developer tools, Automation, MCP servers
- **Features:** Limited permissions
- **Stats:** 1 total users, 0 monthly users, 0.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

$0.20 / 1,000 rows written

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.

Learn more: https://docs.apify.com/actors/store.md#pay-per-event

## What's an Apify Actor?

An Actor is a serverless cloud program that runs on the Apify platform. It has two run modes.
In Batch mode, an Actor accepts a well-defined JSON input, performs an action which can take anything from a few seconds to a few hours,
and optionally produces a well-defined JSON output, datasets with results, or files in key-value store.
In Standby mode, an Actor provides a web server which can be used as a website, API, or an MCP server.

Apify vocabulary and the platform model are defined once, in the agent quickstart at https://apify.com/agents.md.

## How to integrate an Actor?

If asked about integration, you help developers integrate Actors into their projects.
You adapt to their stack and deliver integrations that are safe, well-documented, and production-ready.

Do not guess an integration path. Every one of them is in the agent quickstart at https://apify.com/agents.md: the Apify MCP server, Agent Skills with the Apify CLI, the JavaScript and Python clients, the REST API, and the account-free path for an agent with no human to sign in. It also carries the rule on stating cost before the first paid run.

For examples already wired to this Actor's own input schema, see the [API](#api) section below.

Each client library has reference documentation the quickstart does not restate: [JavaScript/TypeScript](https://docs.apify.com/api/client/js/docs.md) (`npm install apify-client`) and [Python](https://docs.apify.com/api/client/python/docs.md) (`pip install apify-client`).

# README

## Rowmold: Dataset Filter & Transform, JSON to CSV & Excel

#### Keep only the rows you need, in the shape you need, then export CSV or Excel

Rowmold is a **dataset filter** and transformer for Apify results. Pick any dataset (Google Maps, Shopify, jobs, leads), keep only the rows that match your conditions (**rating ≥ 4, city = Austin, has a website, posted after 2026-11-01**), **pick and rename fields**, **flatten nested JSON** into columns, **split arrays into rows** (one row per email or review), add **computed fields**, **sort**, and export **CSV, Excel (.xlsx), JSON Lines or JSON** in the same run. **Rows you filter out are free; $0.20 per 1,000 rows kept; file exports free.**

**[▶ Try it now](https://cybermaxtools.com/store/c/dev/?soon=dataset-filter-transform)** (run it empty for a free demo) · $0.0002 per row written, no start fee · Apify's free plan includes $5 of credit a month

**Built for:** lead-list builders trimming scraper output to qualified rows before a CRM import · agencies sending clients clean Excel files instead of raw JSON · analysts flattening nested scraper output into spreadsheet columns · automation builders who want a scheduled scraper to pass on only new matching rows

**Real output** (run on Apify, 10 Nov 2026: a 3-row places dataset, filters `totalScore >= 4` and `website notEmpty`, `emails` unwound, fields renamed, flattened, sorted by rating, CSV + Excel exported; 2.0 s):

| name | email | rating | address.city | address.state |
|---|---|---|---|---|
| Blue Bottle Coffee | hello@example.com | 4.6 | Oakland | CA |
| Blue Bottle Coffee | press@example.com | 4.6 | Oakland | CA |
| Intelligentsia | info@example.org | 4.5 | Chicago | IL |

```json
{
  "datasetIds": ["YOUR_DATASET_ID"],
  "filters": [{"field": "totalScore", "op": "gte", "value": 4}, {"field": "website", "op": "notEmpty"}],
  "unwind": "emails",
  "fields": ["title as name", "emails as email", "address", "totalScore as rating"],
  "flatten": true,
  "sortBy": "rating", "sortDesc": true,
  "exportFormats": ["csv", "xlsx"]
}
```

The run's `OUTPUT` record links the files: `export.csv` (UTF-8 with BOM, opens cleanly in Excel) and `export.xlsx`.

### Output

- **A new dataset** with only the rows that passed your filters, in the field order and names you chose (nested fields flattened to `address.city`-style columns when `flatten` is on). Your original datasets are never changed.
- **Files in the run's key-value store** when you pick `exportFormats`: `export.csv` (UTF-8 with BOM, opens cleanly in Excel), `export.xlsx`, JSON Lines and JSON. The run's `OUTPUT` record links each file, so a Make, Zapier or n8n step can fetch it straight away.
- **A run summary** in `OUTPUT`: rows read, rows kept, rows filtered out, and (in monitor mode) rows skipped because an earlier run already sent them.

### How to use it

1. **Datasets:** pick one or more datasets in the form (the results of earlier runs), or pass IDs through the API, e.g. a run's `defaultDatasetId`.
2. **Keep rows where:** a list of conditions such as `{"field": "rating", "op": "gte", "value": 4}`. Use dots for nested fields (`address.city`). Choose AND or OR.
3. **Output fields:** list the fields to keep, in order; rename with `as` (`"title as name"`). Add **computed fields** from templates: `{"label": "{{title}} - {{address.city}}"}`.
4. Optional: flatten, split an array into rows, sort, skip, cap, and export files. Run.

### Filter operators

| Op | Example | Notes |
|---|---|---|
| `equals`, `notEquals` | `{"field": "city", "op": "equals", "value": "Austin"}` | Case-insensitive by default |
| `contains`, `notContains`, `startsWith`, `endsWith` | `{"field": "categories", "op": "contains", "value": "coffee"}` | Arrays match if any item matches |
| `matches` | `{"field": "url", "op": "matches", "value": "\\.edu/"}` | Regular expression |
| `gt`, `gte`, `lt`, `lte` | `{"field": "price", "op": "lte", "value": 50}` | Numbers ("1,250" works) and ISO dates compare as numbers and dates |
| `in`, `notIn` | `{"field": "state", "op": "in", "value": ["CA", "OR", "WA"]}` | Value is a list |
| `isEmpty`, `notEmpty`, `exists`, `notExists` | `{"field": "website", "op": "notEmpty"}` | No value needed |

### Ready-made inputs

| Job | Input |
|---|---|
| **Google Maps leads worth calling** | `{"datasetIds": ["…"], "filters": [{"field": "totalScore", "op": "gte", "value": 4}, {"field": "phone", "op": "notEmpty"}], "fields": ["title", "phone", "website", "address"], "exportFormats": ["xlsx"]}` |
| **One row per email** | `{"datasetIds": ["…"], "unwind": "emails", "fields": ["domain", "emails as email"]}` |
| **Spreadsheet-ready columns** | `{"datasetIds": ["…"], "flatten": true, "joinArrays": ", ", "exportFormats": ["csv"]}` |
| **Cheapest 100 in stock** | `{"datasetIds": ["…"], "filters": [{"field": "available", "op": "equals", "value": true}], "sortBy": "price", "maxItems": 100}` |
| **Jobs posted this week** | `{"datasetIds": ["…"], "filters": [{"field": "postedAt", "op": "gte", "value": "2026-11-03"}]}` |

### Run it on a schedule (only new matching rows)

Chain it after any scraper: in that scraper's **Integrations**, add "Run Actor" → `cybermax/dataset-filter-transform` with

```json
{"datasetIds": ["{{resource.defaultDatasetId}}"], "filters": [{"field": "rating", "op": "gte", "value": 4}], "monitor": true, "monitorKey": "my-leads"}
```

With **monitor mode** on, each run writes only rows it has never sent before, and you pay only for those.

### Integrations

- **API (curl):**
  ```bash
  curl -X POST "https://api.apify.com/v2/acts/cybermax~dataset-filter-transform/run-sync-get-dataset-items?token=YOUR_TOKEN" \
    -H "Content-Type: application/json" -d '{"datasetIds": ["ID"], "filters": [{"field": "rating", "op": "gte", "value": 4}]}'
  ```
- **Python:** `ApifyClient(token).actor("cybermax/dataset-filter-transform").call(run_input={"datasetIds": [run["defaultDatasetId"]], "exportFormats": ["xlsx"]})`
- **Make, Zapier, n8n:** run it after your scraper, then send the rows or the Excel file to Google Sheets, Airtable, HubSpot or email.
- **AI agents (MCP):** `https://mcp.apify.com?actors=cybermax/dataset-filter-transform`.

### Pricing

**$0.0002 per row written ($0.20 per 1,000 rows kept), no start fee.** Rows you filter out, rows already sent in earlier monitor runs, and the CSV, Excel, JSON Lines and JSON exports are free. Examples: trimming a 10,000-row Google Maps scrape to the 1,800 rows worth calling costs $0.36; a daily monitor that passes on 40 new matching rows costs $0.008 a day. Apify's free plan includes $5 of credit a month, enough for about 25,000 kept rows.

### Why Rowmold

| | Rowmold | Typical dataset filter on the Store |
|---|---|---|
| Price | **$0.20 per 1,000 rows kept; filtered-out rows and file exports free** | $1–$2.50 per 1,000 rows kept, file exports up to $0.01 each (Store prices, 10 Nov 2026) |
| Reshaping | Pick, rename, omit, computed fields, flatten, split arrays into rows | Usually filter and pick only |
| Exports | CSV, Excel, JSON Lines, JSON in the same run | Often CSV only |
| Scheduled runs | New-rows-only monitor mode | Rare |
| Access to your datasets | Apify's dataset picker, so it works with today's limited-permission Actors | Some fail when they can't read the dataset |

### When not to use Rowmold

- **Joining or de-duplicating several datasets.** Use [Rowmeld](https://apify.com/cybermax/merge-dedupe-datasets) first, then Rowmold to filter and shape.
- **Sorting or exporting tens of millions of rows in one run.** Filtering streams any size, but sorting and file exports hold rows in memory (about 145,000 rows at 512 MB).
- **Data that isn't in an Apify dataset yet** (a spreadsheet on your computer): import it into a dataset first, or use a spreadsheet tool.
- **SQL-style group-by and totals.** Rowmold keeps and reshapes rows; it does not aggregate them.

### FAQ

**How big can a dataset be?** Millions of rows when you only filter and reshape: rows stream through. Sorting and file exports keep rows in memory, about 145,000 rows at the default 512 MB; give the run more memory for more.

**Does it change my original dataset?** No. It reads the datasets you pick and writes a new one.

**Can I merge or deduplicate datasets too?** Use [Rowmeld](https://apify.com/cybermax/merge-dedupe-datasets) for merging and smart de-duplication, then Rowmold to filter and shape.

**Is my data safe?** Rowmold reads the datasets you pick, writes the result to your own run, and sends nothing anywhere else.

### Also from CyberMax

- [Rowmeld: Merge & Deduplicate Datasets](https://apify.com/cybermax/merge-dedupe-datasets) · one clean list from many runs.
- [Sheetshuck: Excel to JSON Converter](https://apify.com/cybermax/excel-to-json) · bring spreadsheets into Apify.
- [Hookvolley: Bulk HTTP Requests & Webhooks](https://apify.com/cybermax/bulk-http-requests) · send the filtered rows to any API.

Found this useful? A quick rating helps others find it.

© 2026 CyberMax. All rights reserved.

# Actor input Schema

## `datasetIds` (type: `array`):

Pick one or more datasets (e.g. the results of a scraper run). Through the API, pass dataset IDs such as a run's defaultDatasetId. Leave empty for a free demo on sample data.

## `datasetId` (type: `string`):

API alias of "datasetIds" for a single dataset ID. Hidden in the form.

## `filters` (type: `array`):

Conditions, e.g. \[{"field": "rating", "op": "gte", "value": 4}, {"field": "website", "op": "notEmpty"}]. Ops: equals, notEquals, contains, notContains, startsWith, endsWith, matches (regex), gt, gte, lt, lte, in, notIn (value = list), isEmpty, notEmpty, exists, notExists. Dots for nested fields (address.city). Numbers and ISO dates compare as numbers and dates. Empty = keep every row.

## `filterLogic` (type: `string`):

AND or OR across the conditions.

## `caseSensitive` (type: `boolean`):

Off: "Coffee" matches "coffee".

## `fields` (type: `array`):

Keep only these fields, in this order. Rename with "as": "address.city as city", "title as name". Empty = keep all fields.

## `omitFields` (type: `array`):

Fields to drop (after picking/renaming).

## `computed` (type: `object`):

New fields from templates, e.g. {"label": "{{title}} - {{address.city}}", "source": "google-maps"}.

## `unwind` (type: `string`):

Optional array field to split into rows, e.g. emails or reviews. Each copy gets <field>Index. Filters then apply per item.

## `flatten` (type: `boolean`):

{"address": {"city": "Austin"}} becomes {"address.city": "Austin"}: one column per field in CSV and Excel.

## `joinArrays` (type: `string`):

With flatten on: turn \["a","b"] into "a, b" using this separator (e.g. ", "). Empty = keep arrays.

## `trimStrings` (type: `boolean`):

Removes leading/trailing spaces and repeated whitespace.

## `dropEmptyFields` (type: `boolean`):

Leave out fields that are null, empty strings, \[] or {}.

## `sortBy` (type: `string`):

Output field to sort by (use the renamed name if you renamed it). Numbers and dates sort as numbers and dates.

## `sortDesc` (type: `boolean`):

Largest first.

## `skip` (type: `integer`):

Optional, after filtering (and sorting).

## `maxItems` (type: `integer`):

Optional cap on rows written.

## `exportFormats` (type: `array`):

Writes export.csv / export.xlsx / export.jsonl / export.json to the run's key-value store; links are in OUTPUT. Files hold up to about 145,000 rows at 512 MB.

## `monitor` (type: `boolean`):

Remembers every row this watchlist has written; later runs write only new or changed rows. Rows sent before are not charged.

## `monitorKey` (type: `string`):

Optional name for this watchlist's saved state (use one per workflow).

## Actor input object example

```json
{
  "filters": [
    {
      "field": "rating",
      "op": "gte",
      "value": 4
    },
    {
      "field": "website",
      "op": "notEmpty"
    }
  ],
  "filterLogic": "all",
  "caseSensitive": false,
  "fields": [
    "title as name",
    "rating",
    "address.city as city",
    "website"
  ],
  "flatten": false,
  "trimStrings": true,
  "dropEmptyFields": false,
  "sortDesc": false,
  "exportFormats": [],
  "monitor": false
}
```

# Actor output Schema

## `results` (type: `string`):

No description

## `summary` (type: `string`):

No description

# API

You can run this Actor programmatically using our API. Below are code examples in JavaScript, Python, and CLI, as well as the OpenAPI specification and MCP server setup.

## JavaScript example

```javascript
import { ApifyClient } from 'apify-client';

// Initialize the ApifyClient with your Apify API token
// Replace the '<YOUR_API_TOKEN>' with your token
const client = new ApifyClient({
    token: '<YOUR_API_TOKEN>',
});

// Prepare Actor input
const input = {
    "filters": [
        {
            "field": "rating",
            "op": "gte",
            "value": 4
        },
        {
            "field": "website",
            "op": "notEmpty"
        }
    ],
    "fields": [
        "title as name",
        "rating",
        "address.city as city",
        "website"
    ]
};

// Run the Actor and wait for it to finish
const run = await client.actor("cybermax/dataset-filter-transform").call(input);

// Fetch and print Actor results from the run's dataset (if any)
console.log('Results from dataset');
console.log(`💾 Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
const { items } = await client.dataset(run.defaultDatasetId).listItems();
items.forEach((item) => {
    console.dir(item);
});

// 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/js/docs

```

## Python example

```python
from apify_client import ApifyClient

# Initialize the ApifyClient with your Apify API token
# Replace '<YOUR_API_TOKEN>' with your token.
client = ApifyClient("<YOUR_API_TOKEN>")

# Prepare the Actor input
run_input = {
    "filters": [
        {
            "field": "rating",
            "op": "gte",
            "value": 4,
        },
        {
            "field": "website",
            "op": "notEmpty",
        },
    ],
    "fields": [
        "title as name",
        "rating",
        "address.city as city",
        "website",
    ],
}

# Run the Actor and wait for it to finish
run = client.actor("cybermax/dataset-filter-transform").call(run_input=run_input)

# Fetch and print Actor results from the run's dataset (if there are any)
print(f"💾 Check your data here: https://console.apify.com/storage/datasets/{run.default_dataset_id}")
for item in client.dataset(run.default_dataset_id).iterate_items():
    print(item)

# 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/python/docs/quick-start

```

## CLI example

```bash
echo '{
  "filters": [
    {
      "field": "rating",
      "op": "gte",
      "value": 4
    },
    {
      "field": "website",
      "op": "notEmpty"
    }
  ],
  "fields": [
    "title as name",
    "rating",
    "address.city as city",
    "website"
  ]
}' |
apify call cybermax/dataset-filter-transform --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,cybermax/dataset-filter-transform"
        }
    }
}
```

The hosted server signs you in with OAuth on first connect, so no API token belongs in this config. Clients without OAuth support can send an `Authorization: Bearer <APIFY_API_TOKEN>` header instead, using a token from API & Integrations in Apify Console (https://console.apify.com/settings/integrations).

## OpenAPI specification

Download the OpenAPI definition: https://api.apify.com/v2/actors/ug83C4CaYeoQE972P/builds/ZgJ2iUCOYRUqACMrc/openapi.json
