Does Axios support Set-Cookie? Is it possible to authenticate through Axios HTTP request?

Try this out! axios.get(‘your_url’, {withCredentials: true}); //for GET axios.post(‘your_url’, data, {withCredentials: true}); //for POST axios.put(‘your_url’, data, {withCredentials: true}); //for PUT axios.delete(‘your_url’, data, {withCredentials: true}); //for DELETE For more information on this from the axios docs: “withCredentials indicates whether or not cross-site Access-Control requests should be made using credentials” – https://github.com/axios/axios More detail on withCredentials: https://developer.mozilla.org/en-US/docs/Web/API/XMLHttpRequest/withCredentials

Request header field Access-Control-Allow-Headers is not allowed by itself in preflight response

When you start playing around with custom request headers you will get a CORS preflight. This is a request that uses the HTTP OPTIONS verb and includes several headers, one of which being Access-Control-Request-Headers listing the headers the client wants to include in the request. You need to reply to that CORS preflight with the … Read more