I cannot figure how to use @attribute [Authorize] in razor component with Bearer token authentication. When I decorate API controller with [Authorize] and attach bearer token to header, its working nicely. When I use same attribute in razor component it always throw 401.
I tried using multiple schemas with fallbacks
@attribute [Authorize(AuthenticationSchemes = "Identity.BearerAndApplication, Identity.Bearer, Identity.Application, Identity.External")]but did not help. What am I doing wrong?
Thanks.