How to make a second request to the provider's API to fetch an image #853
Replies: 5 comments
-
@italodeandra Since the |
Beta Was this translation helpful? Give feedback.
-
@jachinte That's nice to know but still doesn't fix my problem. Because the Graph API is only accessible with the token. The way I foresee this happening is getting access to NextAuth API inside the |
Beta Was this translation helpful? Give feedback.
-
@italodeandra You can get the token in the |
Beta Was this translation helpful? Give feedback.
-
@italodeandra -- would you be willing to share your MSAL provider config? Starting a project that requires authentication via this route and it would be helpful to have a working example to reference. |
Beta Was this translation helpful? Give feedback.
-
so we recently added https://next-auth.js.org/configuration/providers#using-a-custom-provider I wouldn't recommend using the |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
Your question
I would like to know if its possible to request the image or if we can get the token that NextAuth that used to fetch the user info.
What are you trying to do
I'm currently implementing a custom provider MSAL. It is working perfectly, but the image from Microsoft accounts are a separate request to their Graph API
https://graph.microsoft.com/v1.0/me/photo/$value
.Feedback
Documentation refers to searching through online documentation, code comments and issue history. The example project refers to next-auth-example.
Beta Was this translation helpful? Give feedback.
All reactions