CORS error while using datatable API
Hello,
We are trying to use Datatable API and sending the configuration in the code block using Axios. But we are getting Cors error on localhost and on the build hosted on Github pages. We have tried public tokens with domains as well.
Thanks
let config = {
method: 'get',
url: `https://${process.env.THREEKIT_ENV}/api/datatables/${datatableId}/row?orgId=${process.env.THREEKIT_ORG_ID}&where=${encodeURIComponent(
JSON.stringify(rowQuery)
)}`,
headers: {
authorization: `Bearer ${privateToken}`,
},
};
Comments
1 comment
Hi Shiv,
Can you refer to this example on the Datatables API documentation and let me know if it is helpful?
I was able to successfully execute a GET request with a public token pointed to developer.threekit.com when using the API sandbox on the docs.
Please sign in to leave a comment.