I'm trying to do the following in Blazor:
public GraphServiceClient GraphClient { get; set; } = new(new AccessTokenProviderTokenCredential(AccessTokenProvider));
But I have the following error message:
Is GraphServiceClient not allowed in Blazor? Or am I doing something wrong? Thank you.
CodePudding user response:
The default HttpProvider
is not supported in Blazor. You can use GraphServiceClient if you provide your own IHttpProvider
or use the constructor that takes a HttpClient
.