wrong request url when calling await sso.getGraphToken(bootstrapToken);
I'm working on outlook addon and I'm having problem with sso.getGraphToken(bootstrapToken) call.
I'm service addon from AWS S3 bucket which is behind nginx proxy. When I call getGraphToken(bootstrapToken) it's sending request to `https://my_app_domain/auth?_=1605895039463 which is wrong as such path doesn't exists.
I think that /auth should be called from Microsoft domain instead to get graphToken. What am I doing wrong and how can I fix that?
thanks
when I added 'graph.microsoft.com' as a domain to /auth request (https://graph.microsoft.com/v1.0/auth?_=1606130673915) I'm getting this response
{ "error": { "code": "InvalidAuthenticationToken", "message": "Access token validation failure. Invalid audience.", "innerError": { "date": "2020-11-23T11:24:34", "request-id": "7699605a-1f1a-472a-913a-2efec2829b5e", "client-request-id": "7699605a-1f1a-472a-913a-2efec2829b5e" } } }
sso.getGraphToken() calls the API hosted in node server to get access token, which is not running in your system. If you don't want to run that server, but use your own APIs, you can do that as documented here -> https://docs.microsoft.com/en-us/azure/active-directory/develop/v2-oauth2-auth-code-flow#request-an-access-token-with-a-client_secret
The SSO template has been significantly revamped. Please look at it for a sample of a functional case.