I am having trouble getting my api response to save to my database. My api response evaluates like so:
When I try to set up the api workflow, it evaluates to an api call instead of a list
How do I get this to evaluate to a list?
Not sure if this helps, but when I click on “more”, it gives me these options:
Given my api structure has categories above these, I would have at least thought my results would evaluate to look like this:
Any help would be much appreciated.
Can you share how it’s come in API connector? Please share screenshot of API Connected initialization step with the raw data too.
Definitely. I assume you mean this
Yes… but also, if you scroll at the bottom, you will see “Show raw data” or something like that. Can you click on it and share this part too
And maybe URL to API Doc
Here you go. I built the api myself, given I’m using this for my own app, I never bothered to write any documentation for it. I can explain anything you need though.
I appreciate you responding so quickly.
I think it’s a good news if you have built it. You will need to review how it’s written
Actually, you can see that there’s no array in your json. They are all object with with key value. An array will be between  and there’s none.
If you wan’t to have a good design to work with Bubble API Connector, you should consider this format instead
"wine_cat": "Red wine"
"wine_cat": "Red wine"
Awesome. Thanks for the tip. I will rewrite the response now and give it a try. I will message you back to confirm it works. Super helpful.
so I reformatted my json response to the way you said:
And still i am getting errors:
Is there a special way I should be setting up my database “recos”?
If you can spare a little more advice I would really appreciate it.
Yes, the “type” here is NOT your database table name.
The “Type of things” should be List of API Call wine_recos.
Then in your API workflow you create the recos record from that.
That worked. Awesome. Thank you @NigelG and @Jici .
One last question, I am using this api to make recommendations for a user every time they log into the website. I am on a personal plan which means I get monthly scheduled workflows. Does this mean that the functionality I am trying to build can’t be done with the personal plan? If so, the professional and enterprise plans run daily (which I assume means once per day) so even with those plans, I couldn’t do what I want to do as just one user can log in more than once per day.
If you have a workflow when they log in, you don’t need to use scheduled WF. Just process the call when they log in.