6

I have a firebase authentication token that i am trying to pass to a web api controller. I am following this post here. stackoverflowpost

I have the bearer token in the $http request headers. angular

I took care of cors(unless I missed something). The end point in my api project is receiving the request with null headers. So I am trying to debug what is wrong but without any specific errors I am not sure where to look apiproject

Community
  • 1
  • 1
texas697
  • 5,609
  • 16
  • 65
  • 131

1 Answers1

2

You can get the value of an element "Authorization" in header by using following code:

  string firebaseAuthToken = string.Empty;
    firebaseAuthToken = actionContext.Request.Headers.GetValues("Authorization").First();
Sachin Verma
  • 493
  • 1
  • 5
  • 11