MicrosoftIdp class
Main class for the Microsoft identity provider. The methods defined here are intended to be called from an endpoint.
The admin property provides access to MicrosoftIdpAdmin, which contains
admin-related methods for managing Microsoft-backed accounts.
The utils property provides access to MicrosoftIdpUtils, which contains
utility methods for working with Microsoft-backed accounts. These can be used
to implement custom authentication flows if needed.
If you would like to modify the authentication flow, consider creating custom implementations of the relevant methods.
Constructors
- MicrosoftIdp(MicrosoftIdpConfig config, {required TokenIssuer tokenIssuer, AuthUsers authUsers = const AuthUsers(), UserProfiles userProfiles = const UserProfiles()})
-
Creates a new instance of MicrosoftIdp.
factory
Properties
- admin → MicrosoftIdpAdmin
-
Admin operations to work with Microsoft-backed accounts.
final
- config → MicrosoftIdpConfig
-
The configuration for the Microsoft identity provider.
final
- hashCode → int
-
The hash code for this object.
no setterinherited
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- utils → MicrosoftIdpUtils
-
Utility functions for the Microsoft identity provider.
final
Methods
-
hasAccount(
Session session) → Future< bool> - Determines whether the current session has an associated Microsoft account.
-
login(
Session session, {required String code, required String codeVerifier, required String redirectUri, required bool isWebPlatform, Transaction? transaction}) → Future< AuthSuccess> - Validates a Microsoft authorization code and either logs in the associated user or creates a new user account if the Microsoft account ID is not yet known.
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited