Hi @chadwell
For logging in the user, I assume I use MSAL-node for authorization code flow in Azure and can I retrieve both an id token and an access token?
Yes, of course. After you authenticate the logged in user using the authorization code flow, you will be able to get an id token and an access token.
The id token will be used to display the users name etc, and the access token will allow the React app to call the backend for API calls?
Yes, the id token contains some basic information of the logged in user. For example, name, email, etc.
The access token will be able to call the Web API. Like the id token, the access token also contains basic information of the logged in user, and it is more comprehensive.
I have another need. Whilst the user will be able to interact with the UI, I also want them to be able to access the API and experiment with it from say postman or a cli. Is there some mechanism I can implement where they can generate a token (access?) from the UI and copy it and be able to use it in an API call?
Yes, of course. You can implement the authorization code flow through the library, or you can implement the authorization code flow through postman/cli + UI and test the call to your Web API in postman.
Hope this helps.
If the reply is helpful, please click Accept Answer and kindly upvote it. If you have additional questions about this answer, please click Comment.