-
Notifications
You must be signed in to change notification settings - Fork 231
IdentityManagerService
The IIdentityManagerService
interface abstracts the identity management library that IdentityManager will use.
The IIdentityManagerService
is configured via the IdentityManagerFactory
function on the IdentityManagerConfiguration
and is requested on each HTTP request into IdentityManager. If the returned IIdentityManagerService
also implements IDisposable
then Dispose
will be invoked at the end of the request.
The design of the IIdentityManagerService
interface revolves around users, roles and metadata.
The users are the identities to be managed with IdentityManager.
The roles in IdentityManager are role definitions and are optional. Role definitions simply provide a convenience in the user interface to populate a list of role claims when editing a user.
Metadata provides information about which operations are allowed on users and roles (create/delete) and what data the users and roles support (for editing and validation). This metadata drives the IdentityManager user interface as well as the RESTful API.
There are three types of APIs that the IIdentityManagerService
interface is comprised of:
- metadata
-
GetMetadataAsync
: returnsIdentityManagerMetadata
which describes what operations and data are supported for users and roles.
-
- user related operations
-
CreateUserAsync
: Creates a user. -
DeleteUserAsync
: Deletes a user. -
QueryUsersAsync
: Queries users; supports paging and filtering. -
GetUserAsync
: Gets a user's details. -
SetUserPropertyAsync
: Updates a property on a user. -
AddUserClaimAsync
: Adds a claim on a user. -
RemoveUserClaimAsync
: Removes a claim from a user.
-
- role related operations
-
CreateRoleAsync
: Creates a role. -
DeleteRoleAsync
: Deletes a role. -
QueryRolesAsync
: Queries roles; supports paging and filtering. -
GetRoleAsync
: Gets a roles's details. -
SetRolePropertyAsync
: Updates a property on a role.
-