I am currently facing an issue with the npm package axios while attempting to execute a get request to a specific URL. The problem arises as I consistently receive an error code 503. Here is the snippet of code in question:
let data, response;
response = await axios.get(url, {
headers: {
Accept: 'application/json',
}
})
Initially, my assumption was that there might be something wrong with the code itself (such as mistakenly changing Accept to 'Accept'). However, upon testing the exact same request on Postman, it returned successfully without any errors.