You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
If you have existing authentication code in your application, you can create a custom provider to enable authentication and access to Microsoft Graph for the toolkit's Graph based controls and helpers. To bring your own authentication provider logic, start by extending IProvider.
IProvider
IProvider is the base interface for creating authentication providers that work with the various controls and helpers in the toolkit. Handle authentication with one of our premade IProvider implementations or create your own.
Available in the CommunityToolkit.Authentication package.
usingCommunityToolkit.Authentication;// Create an instance of your custom IProvider implementation.IProvidercustomProvider=newCustomProvider();// Set the global provider using the custom instance.ProviderManager.Instance.GlobalProvider=customProvider;
Properties
Property
Type
Description
State
ProviderState
Gets the current authentication state of the provider.
Events
Event
Type
Description
StateChanged
EventHandler<ProviderStateChangedEventArgs>
An event that is called whenever the login state changes.