Forum Academy Marketplace Showcase Pricing Features

[New Plugin] CSV File to JSON

Thanks for the reply! I’m sure it’s something simple that I’m missing, but how to I map the right column data to the right field of the data type I am creating when a CSV is uploaded?

It’s a little difficult but you would create a new endpoint in your backend workflow and then using something like Postman you will send a POST request to your endpoint while it’s in “initializing” mode and it will pick up all the fields in your CSV.

The body of the Post request needs to be the json generated by the plugin.

Ah that makes total sense.

Can I validate the csv’s headers match my expected values using your plugin before scheduling the api workflow?

There isn’t a validation feature, but I assume its irrelevant because you will be hand picking each column and deciding which field to populate in your Bubble database when you are creating the workflow in your backend.

Also keep in mind the headers used in your CSV has to be exactly the same in every csv file or else your bubble backend workflow wont recognize those headers. When you run the “initializer” it saves the names of the headers, so anything different will be ignored by bubble.

CSV File:

| First Name | | Last Name | | Age |
Shawn Lancer. 28

Bubble Database:
(field) Fname ------> First Name (CSV Field)
(field) Lname ------> Last Name (CSV Field)
(field) age ----------> Age (CSV Field)

@avern87 if you need validation and the ability to upload any csv file with any type of headers and have the user match their own headers with your pre-defined ones, then would be a good solution for you. I recently did a custom integration for @ksaitow1 let me know if I can help with yours if needed.

Thanks for all the help! Yea, I love FlatFile’s product, but $99 a month prices me out.

I’m getting an error when I try to run this plugin on an uploaded CSV. I’m uploading, running your parse action and then attempting to set a state to the result json so I can fire off the results to detect the api parameters.

Here’s the error:
Plugin action Convert CSV to JSON error:
ReferenceError: $jscomp is not defined
at eval (eval at build_function (/var/task/index.js:55:21), :1:105)
at Object.async_fn [as async] (/var/task/index.js:242:13)
at eval (eval at build_function (/var/task/index.js:55:21), :1:75)
at /var/task/index.js:278:23
at run_fn (/var/task/u.js:594:18)

Thanks for the update. Its a known bubble bug, just fixed it. Please update the plugin and try again.

Perfect. It runs now!

Two questions for you. First, when I set the preview field to just 3 lines, the server times out. But, when I allow it to process the whole CSV, it runs without issue. Weird right?

Second, I put the json result into a text element on the page and used that to initialize the backend workflow with the right day. But, it seems detecting the data gets rid of the other parameters I put in the workflow. I want to send the CSV + a Client and a Team. Am I missing something?

@avern87 just pushed a new update added couple of new features and cleaned up some bugs.

  • Now you can add custom key/value pairs to your json data

  • Now you can have the plugin automatically send the converted data to any api endpoint

*Bubble’s servers timeout with files above 1,000 rows, so it would be a safe practice to limit the numbers of rows to 1,000.

*Preview functionality has been removed as it had a pending issue waiting to be fixed.

Would like to get your take on how (or if) your plugin would take a csv file that has row headers instead of column headers? An example is shown below where I need to take 13 columns of data (12 months and 1 description) and input that into the database. It’s almost as if I need a solution that can turn the csv on its side first.


Hi @shawnmi6

This plugin looks very interesting! Thanks for your work! Would you please share how you build the backend workflow to update the database? Also, how do you pass the JSON generated from Convert to JSON action? I would love to try this plugin but got stuck.

The plugin has the option to send off the converted data to a api endpoint. You can just crate a new backend api workflow and then take that url and paste it into the plugin endpoint field.

You might need to first initialize the api endpoint so it automatically detects the incoming json structure.

1 Like

Thanks for the instruction! I am able to get the endpoint recognizing the data converted from the plugin. I use the plugin to send a sample csv to a mock endpoint URL and then use Postman to send the JSON body back to the Bubble endpoint URL.
However, when I try to add that backend workflow, it’s not showing up in the dropdown…

Would you please point out where could be wrong?

once you run the “Convert CSV to JSON” step then your data is sent to your “runjson” backend api workflow. You can then run any steps inside that runjson workflow to mutate your data…

1 Like

Thanks for your instruction! @shawnmi6

Hi @shawnmi6

Sorry for bugging you again. I have been banging my head against the wall and still couldn’t get my API workflow to work. I used your plugin to parse CSV and have Bubble’s endpoint detected the data sent to it. I also configured subsequent API workflow to create a thing using the data coming from the API endpoint. However, I can’t select the API workflow on the page where I want it to be triggered. It seems I need to “manual definition” the data sent to for the workflow to be called. Is this true or I’m missing something?

Can you please help?

I have some time now, I can get on a quick zoom call in which you can share your screen and I can help you out.

Hi, thank you so much for the plugin.

I have a doubt… when i upload my csv file and change for example to create product on my database, it creates list of values instead of one item per line as it suppose to be… is there a way so it reads every line as a different product? because if i say that, for example…

Creat a new product… where “name = title”… instead of creating as many products as i have by line, it just put all the titles in the same field as a list, even though my data field is not a list.

Can you help me @shawnmi6 or @avern87



I have a single-column CSV file with the header addresses.

Is there a way to parse the CSV file into a list of texts and remove the header from the list of texts?

Thank you,

I’m having a hard time figuring out how to send over the JSON data to my backend workflow.
I can’t figure out how to take the whole JSON string and divide it so each parameter gets only their slice of the pie.

(My backend workflow gets data from SP-API as CSV but I’m having a issue with bubble because the max CSV import they allow is 1,000 rows, and that’s why I’m converting it to JSON first, but I’m getting a issue when it comes to loading it into my database)