Microgateway api key does not work, although OAuth does

garysole
Participant II

I have nodejs 9.5.0 and edgemicro 2.5.12

My OAuth plugin configuration is

allowNoAuthorization: false 
allowInvalidAuthorization: false
verify_api_key_url: 'https://org-test.apigee.net/edgemicro-auth/verifyApiKey'

When I use my App Consumer Key and Secret to get an OAuth token from /edgemicro-auth/token and then submit the token in Authorization: Bearer xxxx, the API call works - currently just with /hello/echo.

However, when I submit the same request using my Consumer Key in x-api-key header, I get

{
    "error": "access_denied",
    "error_description": "Internal Server Error"
}
0 2 202
2 REPLIES 2

Former Community Member
Not applicable

Can you please trace the edgemicro-auth proxy? See if the proxy responds ok.

Thanks - had not thought of tracing that as a debugging solution. Found an error in the JavaScript - my fault. Thanks for the debugging tip.