There’s been a few recent posts about using fetch() in the new scripting block. Here’s another question/use case that’s not currently working for me.
My office uses Airtable for, among other things, tracking course videos through the editing process. Videos are hosted on Vimeo and one task we do is pull in the latest runtime. This can be done easiest through Vimeo’s oEmbed API which includes a “duration” field that provides the length of a video in seconds.
The problem: our videos are private and accessible through (able to be embedded on) a small whitelist of domains. Using the “old” API, this worked as I could set the referrer to our domain (the code was written in NodeJS and called the
https.get() method). I’ve tried adding “airtable.com” and “api.airtable.com” to the video whitelist, but it still returns a 403 error.
Some initial searches indicate this might be a CORS issue with
fetch() and it may not include the right options to make the request? Or it could be a bug in the scripting block/it is using a different URL than I whitelisted?
Anyone have any advice/tips/ideas?