Open lockhartsoftware opened 4 months ago
Hi @lockhartsoftware Thank you for great feedback!!
Very great question, just for further clarification, you need to send a an API request from your Blazor Web App to another API that authenticates with the same app registration but different scope? is that correct?
Hi @aksoftware98
Yes, that's absolutely correct.
The scenario I have in mind is:
the client app is a .NET 8.0 Blazor Server Side Render (SSR) Web App which enables the client app user to Authenticate using Entra ID (register Client App in Entra ID) to return a Cookie back to the Web App.
the client app calls a .NET 8.0 Web API end-point which also Authenticates against Entra ID (register API in Entra ID).
What do you think? Is there a better way to do this?
I can't seem to find any sample code for achieving that with the latest .NET 8.0 Blazor Server-side Render Web App.
Yeah brilliant got what you mean 100% And yes that's completely possible. I will modify the repo to add a sample with Downstream API call sample with token acquisition and caching.
In the meantime, check this link, hopefully it will be help you. A web app that calls web APIs: Code configuration
I will keep this issue opened until the example is added to the repo,
Let me know if you have any other questions
Wow, thank you so much. I’ve been struggling with that for ages.
So happy that helped, I will also simplify the project event more so it can be directly implemented in the template through a command or something. Thank for helping make this package better.
Excellent code, as usual. Thank you.
Can you please help on how I could extend this approach to Authenticate with a Downstream ASP.NET 8.0 Web API?