BNOD

← Todas las plantillas
datajsoncsvetl

JSON feed → CSV exporter

Fetch a JSON endpoint that returns an array, download as CSV. Default is jsonplaceholder posts (stable demo endpoint, no auth).

Instalar en BNOD

Instalar en BNOD

Opens BNOD sidepanel with this template installed. Requires BNOD extension.

You found a public JSON endpoint that returns an array of objects — an API, an open-data feed, a CMS export — and you want it in a spreadsheet so non-technical teammates can pivot it. Curl-to-jq-to-CSV pipelines work but they're command-line and not portable. This template fetches any JSON-array endpoint and downloads the result as a clean CSV. The default points at jsonplaceholder for safe testing; swap the URL and it works against any equivalent endpoint. Useful for analysts, data journalists, or anyone doing exploratory work who'd rather skip writing a script.

How this workflow works

Three blocks. This is the leanest possible ETL pipeline: extract (HTTP), transform (auto-flatten), load (browser download).

  1. manual_trigger — Sidepanel Run. Exposes two inputs: endpoint (default https://jsonplaceholder.typicode.com/posts) and outfile (default posts.csv). You're prompted to confirm or override these per run.
  2. http_request — A GET against {{vars.input.endpoint}}. timeoutMs: 10000 caps the request at 10 seconds; responseType: "json" tells the block to parse the response body. The parsed body — assumed to be an array of objects — is exposed as $('Fetch JSON feed').body.
  3. export_data — Takes that body, generates a CSV with column headers derived from the keys of the first object, and triggers a browser download with filename {{vars.input.outfile}}. Nested objects and arrays inside the JSON get JSON-stringified into single CSV cells.

The whole thing runs in 1-3 seconds against a fast endpoint. Output is a standard UTF-8 CSV with comma separator, which opens cleanly in Excel, Numbers, and Google Sheets.

Customising it for your case

The template is intentionally generic — most customisation lives in the inputs and the JSON shape.

Common gotchas

Three honest pitfalls. First: the template assumes the response is a top-level JSON array. If the API wraps results in {data: [...]} or {posts: [...]}, the export_data block won't auto-flatten — it'll try to CSV-ify the wrapper object, producing one row. Insert a set_variable block to extract the inner array: {{$('Fetch JSON feed').body.data}}. Second: rate limits. Public APIs throttle aggressively — running this every minute on jsonplaceholder is fine, but most production APIs cap unauthenticated requests at 60/hour or less. Third: nested objects (e.g. {user: {name: "X", id: 1}}) get JSON-stringified into one cell. If you want them flattened (user.name as a column), you'll need a transform step.

FAQ

Do I need an API key? Not for the default endpoint (jsonplaceholder is public, unauthenticated). For real endpoints, store the key in env and reference it via {{env.KEY_NAME}} in the request headers.

How is this different from curl | jq | csvkit? Same end result, no command line. This template lives in your browser, can be saved and shared, and triggers a real browser download — handy if you want non-developer teammates to run the same pipeline.

What if the API returns paginated results? This template only handles a single page. For pagination, you'll need a loop block that increments a page query param and accumulates results in a set_variable array, then exports the merged set. Automa and n8n have built-in "pagination" handling; in BNOD you wire it up explicitly, which is more verbose but easier to reason about.

Bloques utilizados

  • manual_trigger
  • http_request
  • export_data

Funciona en

Cualquier sitio

Instalar en BNOD

Free. No signup required.

Plantillas relacionadas