Errors adding data to table from External API
Options
Marianna Kerppola
Member ✭
Hi! I'm setting up an external API to pull data from Airtable by following the steps in this video: https://www.youtube.com/watch?v=rdnuW2Vg8aA
I'm able to get the first two steps to work (fetching data and creating a new variable with the results).
However, when I try to add the records, nothing is added to the database. Here's the video showing my set up and results: https://www.loom.com/share/cb4d76f2e35e4ea38f7865a0c44a0b08
I'm able to get the first two steps to work (fetching data and creating a new variable with the results).
However, when I try to add the records, nothing is added to the database. Here's the video showing my set up and results: https://www.loom.com/share/cb4d76f2e35e4ea38f7865a0c44a0b08
Comments
-
are your fields from the API you're calling named exactly as you're inputting them? For example, the field you want to map to your Xano DB called created_at - is this also named created_at in the external API? If not, it's fine but you just need to use the same nomenclature
-
Hi ! To the best I can tell, the fields are named the same as I'm inputting them.
Here's the results from the API I'm calling:
[Screen Shot 2021-07-13 at 11.00.39 AM.png]
Then, here's the set up for adding these to my Xano table:[Screen Shot 2021-07-13 at 11.01.23 AM.png]
I changed the timestamp to now to make sure there wasn't issues there. Even so, when I run this, the Xano table generates empty rows as in the original video.
Any other troubleshooting ideas? -
All your inputs are mapped to the data type text... you are going to want to make sure that they are set to the Variable if you want to pull any data in
-
Thanks ! I updated them all to variables... not sure they had switched to text in the first place, but still it added blank rows:
[Screen Shot 2021-07-13 at 12.40.38 PM.png]
Does it matter that the paths are set to text, like the one below?
[Screen Shot 2021-07-13 at 12.42.26 PM.png] -
I think I see the issue now. It looks like all the fields you are trying to map to are nested under the fields object.
From chatFlow you will want to get:
fields.chatName
fields.chatTopic
etc.
Please give that a try and let me know
[Screenshot_2021-07-13_22-28-55.png] -
Brilliant! Totally works! Thanks for catching that! 🙌
-
Awesome!
Categories
- All Categories
- 53 ? Announcements
- 47 ? Releases
- 37 ? Welcome
- 983 ? Help! I'm a Noob
- 125 ? No-Code Front-Ends
- 633 ? Working with APIs
- 439 ? Transforming data
- 126 ? Connect Xano to ...
- 50 ?? Find an Expert
- 348 ❓Other questions
- 35 ? Security
- 22 ✂️ Snippets
- 19 ? Showcase
- 7 ?️ Xano Chatter
- 62 ? Video Tutorials
- 171 ? Request a feature
- 229 ? Report a Bug
- 19 ? Templates & Extensions
- 7 ? Feedback