public async Task<RefreshStoredTokenPayload> RefreshStoredTokenAsync( [Service] IAuthTokenStoreReader tokenStore, string id, CancellationToken cancellationToken) { TokenStoreHeader header = await tokenStore.RefreshAsync(id, cancellationToken); return new RefreshStoredTokenPayload(header); }
public Task <string?> GetStoredTokenAsync( [Service] IAuthTokenStoreReader tokenReader, GetStoredTokenInput input, CancellationToken cancellationToken) { return(tokenReader.GetTokenAsync( input.Id, input.Type, input.AutoRefresh, cancellationToken)); }
public Task <IEnumerable <TokenStoreHeader> > GetStoredTokensAsync( [Service] IAuthTokenStoreReader tokenReader, CancellationToken cancellationToken) { return(tokenReader.GetTokensAsync(cancellationToken)); }