Interface IUserConsentStore
- Namespace
- Fdyay.IdentityServer.Services
- Assembly
- Fdyay.IdentityServer.Core.dll
Stores and retrieves users' consent decisions.
public interface IUserConsentStore
Methods
GetUserConsentAsync(string, string, CancellationToken)
The consent a user has stored for a client, or null.
Task<Consent?> GetUserConsentAsync(string subjectId, string clientId, CancellationToken cancellationToken = default)
Parameters
subjectIdstringThe user.
clientIdstringThe client.
cancellationTokenCancellationTokenCancels the read.
Returns
RemoveUserConsentAsync(string, string, CancellationToken)
Removes the consent a user has stored for a client.
Task RemoveUserConsentAsync(string subjectId, string clientId, CancellationToken cancellationToken = default)
Parameters
subjectIdstringThe user.
clientIdstringThe client.
cancellationTokenCancellationTokenCancels the removal.
Returns
StoreUserConsentAsync(Consent, CancellationToken)
Stores a user's consent for a client, replacing any already stored for the pair.
Task StoreUserConsentAsync(Consent consent, CancellationToken cancellationToken = default)
Parameters
consentConsentThe consent.
cancellationTokenCancellationTokenCancels the write.