We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
is it possible to set the authorization header? I use a bearer token and the server needs the following header: "Authorization" "Bearer [token]"
Thank you!
The text was updated successfully, but these errors were encountered:
In apihandler.js file, I add this:
apihandler.js
$http.defaults.headers.common['Authorization'] = 'Bearer ' + token;
Sorry, something went wrong.
I can think of two ways to handle this.
You can either write a $http interceptor or add default headers as @morteza-gho pointed out, but rather in your code.
Or you can proxy the requests through some endpoint on the same domain so you could use cookies.
No branches or pull requests
is it possible to set the authorization header? I use a bearer token and the server needs the following header: "Authorization" "Bearer [token]"
Thank you!
The text was updated successfully, but these errors were encountered: