๐Ÿ‡ฌ๐Ÿ‡ง EN
๐Ÿ‡ฎ๐Ÿ‡น IT

๐Ÿ“„ CSV / Excel

Parses CSV and XLSX files into structured data, or generates CSV/XLSX files from data. Source-agnostic โ€” works with file content from any upstream block (Google Drive, Dropbox, HTTP, etc.).

Category: Files  ยท  Type identifier: spreadsheet_file

Overview

The CSV / Excel node operates in two modes. In parse mode it reads raw file content โ€” passed in from any upstream node that can fetch a file โ€” and converts it into a structured array of rows that subsequent nodes can iterate over or inspect. In generate mode it accepts a 2D array of values and produces a downloadable file in CSV or XLSX format.

Format detection is automatic by default: the node inspects the file's magic bytes to distinguish CSV from XLSX without relying on the filename or extension. When reading an XLSX workbook you can target a specific sheet by name; if no sheet is specified the first sheet is used. Header detection is configurable โ€” when enabled, the first row is treated as column names and each subsequent row is returned as a keyed object; when disabled, all rows (including the first) are returned as plain arrays and columns are labelled A, B, C, etc.

Generated CSV output is plain UTF-8 text and can be passed directly to a file-storage node such as Google Drive or Amazon S3. Generated XLSX output is base64-encoded binary and must be decoded by the receiving storage node before writing.

Source-agnostic design: The node operates on file content, not on file paths or provider APIs. Fetch the content with a Google Drive, Dropbox, Amazon S3, or HTTP Request node first, then pass the output into this node. This means any file source Flusso supports works equally well.

Configuration

FieldStatusDescription
Action Required parse โ€” read file content and return rows.
generate โ€” build a file from a 2D array of values.
Content Required for parse Raw file content from an upstream node. Use {{ step_key.output.content }} to reference a file downloaded by a Google Drive, Dropbox, HTTP Request, or Amazon S3 node.
Format Optional auto โ€” detect format from magic bytes (default).
csv โ€” treat content as comma-separated text.
xlsx โ€” treat content as an Excel workbook.
Sheet Optional XLSX only. Name of the sheet tab to read. Defaults to the first sheet if left blank. Ignored when format is csv.
Has Headers Optional When enabled (default: true), the first row is interpreted as column headers and each data row is returned as a keyed object. When disabled, all rows are returned as plain arrays and columns are identified as A, B, C, etc.
Rows Required for generate A 2D JSON array of values to write into the file. The first inner array should be the header row when applicable. Example: [["Name","Age"],["Alice","30"],["Bob","25"]]. Supports {{ variable }} expressions.

Output

Output fields depend on the selected action.

FieldTypeDescription
okbooleantrue when the node completed successfully.
rowsarrayParse mode only. Array of row objects (when Has Headers is enabled) or arrays (when disabled). Each element represents one data row.
row_countnumberParse mode only. Number of data rows returned, excluding the header row.
columnsarrayParse mode only. Array of column names taken from the header row, or ["A","B","C",โ€ฆ] when Has Headers is disabled.
contentstringGenerate mode only. The produced file content: plain UTF-8 text for CSV, base64-encoded binary for XLSX.
formatstringThe format actually used: csv or xlsx. Useful when Format is set to auto.
{{ step_key.output.rows }} {{ step_key.output.row_count }} {{ step_key.output.columns }} {{ step_key.output.content }} {{ step_key.output.format }}

Usage Examples

Import CSV from Google Drive

  1. A Google Drive node downloads the file using its file ID. The raw content is available at {{ google_drive_step.output.content }}.
  2. A CSV / Excel node with Action: parse and Format: auto converts the content into an array of row objects.
  3. A Loop node iterates over {{ spreadsheet_step.output.rows }}, processing each record individually in the loop body.

Export data to XLSX on Google Drive

  1. An earlier node produces a list of records stored in the workflow context.
  2. A CSV / Excel node with Action: generate and Format: xlsx converts the records into a base64-encoded XLSX file.
  3. A Google Drive node uploads the file using the {{ spreadsheet_step.output.content }} value, writing it to the target folder.

Parse a CSV fetched over HTTP

  1. An HTTP Request node fetches a CSV report from a remote URL. The response body is the raw CSV text.
  2. A CSV / Excel node with Action: parse and Format: csv parses the response body into rows, with Has Headers: true so each row is a keyed object.
  3. A Filter or Transform node processes the structured rows before the results are stored or forwarded.

Tips & Notes

Related Nodes