content-type is not allowed by Access-Control-Allow-Headers
bruno-barros opened this issue · comments
Bruno Barros commented
I'm working with JWT Authentication on local server without any problem, but deploing the app (on a differente server) I can fetch data from graphql, but NOT able to log in.
I'm getting the CORS message content-type is not allowed by Access-Control-Allow-Headers
.
The only difference I could note is that the serve is returning content-type text/html
instead of application/json
as is expected.
On the server the request works.
graphql([
'query' => 'mutation MyMutation {
__typename
login(input: {clientMutationId: "somelogin", password: "mypassword", username: "somelogin"}) {
authToken
clientMutationId
refreshToken
}
}
'
])
Any help?