I am coding a Vue.js application which uses JotForm api system but I am getting an error while using get request with ApiKey.
Here is my request code:
axios.get('https://api.jotform.com/user/forms', {
headers: {
'Content-Type': 'application/x-www-form-urlencoded; charset=UTF-8',
'APIKEY': state.apiKey
} }).then(response => {
console.log(response)
}).catch((error) => {
console.log(error)
})
And this is the error message:
Request header field APIKEY is not allowed by Access-Control-Allow-Headers in preflight response
I searched on the web and tried adding various headers. None of them succeed. Also same get request works perfectly with Postman.