Skip to content

Axios POST requests don't send Authorization headers, but GET requests do #158

@nathanchase

Description

@nathanchase

Version

v5.1.0

Reproduction link

https://stackoverflow.com/questions/45846359/axios-post-not-sending-auth-header-but-get-does

Steps to reproduce

Call axios.post(url) while already logged in and with existing user auth token in place (aka bearer eyJ0eXAiOiJKV1QiLCJhbGci...)

Request should contain the Authorization header, but does not.

Call axios.get(url) and the header exists and sends correctly

What is expected ?

axios.post should send the Authorization header

What is actually happening?

axios.post is not sending the Authorization header

This bug report is available on Nuxt community (#c156)

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions