Add headers to a CSV file

I’m working on a scenario for pulling a CSV file from an incoming email attachment and saving it to Google Drive. The issue is that this CSV does not have the correct headers for a step I want to execute after the file arrives in Google Drive. I want to add a step in my scenario to either replace the header line or just insert a new line above it with the correct headers.

Currently the scenario runs like this:

  1. Gmail: Watch Emails
  2. Gmail: Iterate Attachments
    (New action here)
  3. Google Drive: Upload a File

I’ve tried using Parse CSV on the data, then Tools: Switch or Text Parser: Replace to change the desired header row, but I’m not sure what to do from there. I assume I need to Create CSV but I’m not sure of the correct settings. The goal is to connect the CSV with replaced text into the Google Drive upload. Any help would be appreciated!

1 Like

Hey, not sure if I fully understood your question, but if you want to add a ‘header’ see the screenshots below, and let me know if this is what you’re looking for, and goodluck.


Screenshot 2023-10-20 at 3.22.53 PM

4 Likes