Skip to main content

I’ve been trying to query an API, it works using POSTMAN but when I try and replicate in Airtable I get an error message.





let response = await fetch('https://api.xavier-analytics.com/clients', {

headers: {

'Authorization': 'Bearer XXXXXXXXXXXXXXXXXXXXXXXXXX',

'Content-Type': 'application/json',

'Access-Control-Allow-Origin': '*',

}});



console.log(await response.json);

Hi @Jonathan_Gaunt and welcome to the Community !



I recently got a lot of help by @Bill.French about CORS cases from Airtable Scripting App here:





You could search CORS in Scripting App Forum to get more.



I will end this short message by telling you that in practice, even if experimental case-by-case interventions are still possible, the best solution seems to me, still experimentally, to use a CORS-Proxy (some examples can be found on GitHub) or to rent a proxy service specially designed for Airtable such as on2air.



Best,



olπ


Reply