Blueprints

Load multiple CSV files from an HTTP API into Excel Sheets

About this blueprint

API Ingest Outputs

This flow downloads multiple CSV files from an HTTP API and loads them into separate sheets in an Excel file. It uses the Download, CsvToIon, and IonToExcel plugins to download the CSV files, convert them to Ion format, and write them to an Excel file.

The flow is composed of the following tasks:

  1. Download the first CSV file from an HTTP API.
  2. Download the second CSV file from an HTTP API.
  3. Convert the first CSV file to Ion format.
  4. Convert the second CSV file to Ion format.
  5. Write the Ion data to an Excel file with two sheets.

The flow can be used to download multiple CSV files from an HTTP API and load them into separate sheets in an Excel file. It's useful if you need to get data from external sources and store them in Excel format.

yaml
id: load_multiple_csv_files_into_excel
namespace: company.team

tasks:
  - id: dataset1
    type: io.kestra.plugin.core.http.Download
    uri: https://huggingface.co/datasets/kestra/datasets/raw/main/csv/products.csv

  - id: dataset2
    type: io.kestra.plugin.core.http.Download
    uri: https://huggingface.co/datasets/kestra/datasets/raw/main/csv/fruit.csv

  - id: convert1
    type: io.kestra.plugin.serdes.csv.CsvToIon
    from: "{{ outputs.dataset1.uri }}"

  - id: convert2
    type: io.kestra.plugin.serdes.csv.CsvToIon
    from: "{{ outputs.dataset2.uri }}"

  - id: write_to_excel
    type: io.kestra.plugin.serdes.excel.IonToExcel
    from:
      Sheet_1: "{{ outputs.convert1.uri }}"
      Sheet_2: "{{ outputs.convert2.uri }}"

Download

Csv To Ion

Ion To Excel

New to Kestra?

Use blueprints to kickstart your first workflows.

Get started with Kestra