Interface ISynchronizingUserService

Synchronizes a claims identity to the database

Namespace: EPiServer.Security
Assembly: EPiServer.dll
Version: 11.20.7
Syntax
public interface ISynchronizingUserService

Methods

SynchronizeAsync(ClaimsIdentity, IEnumerable<String>)

Synchronizes a claims identity to the database

Declaration
Task SynchronizeAsync(ClaimsIdentity identity, IEnumerable<string> additionalClaimsToSync)
Parameters
Type Name Description
System.Security.Claims.ClaimsIdentity identity

The claims identity

System.Collections.Generic.IEnumerable<System.String> additionalClaimsToSync

Additional claims types to synchronize or empty list to only synchronize default claims

Returns
Type Description
System.Threading.Tasks.Task
Remarks

By default is claims such as role claims and Email synched. additionalClaimsToSync can be specified to synchronize additional claims. This can be used for example to sync a phone number which then can be used by notification system.

Exceptions
Type Condition
System.ArgumentException

If the identity is not authenticated

Extension Methods