How To: .NET 8 Blazor Web App + API + EntraId - how to authorize to SignalR
djfoxer opened this issue · comments
Is there an existing issue for this?
- I have searched the existing issues
Is your feature request related to a problem? Please describe the problem.
Hi. I have similar issue. My solution has Blazor Web Apps (Server) and API. I want to send notifications from API to Blazor (Authorization/Authentication via Microsoft.Identity - EntraID). I stuck with Hub configuration on Blazor side. I should provide AccessTokenProvider to HubConnectionBuilder but I don't see where access token can be. I searched HttpContext (from CascadingParameter) but ther is no access token at all. Any sugestions? Thank you.
Describe the solution you'd like
Provide how to pass accessToken from EntraId to SignalR HubConnectionBuilder in Blazor to connecto to SignalR hosted in API
Additional context
No response