Readonly
clientThe client ID.
Gets the access token data for the given user.
The ID of the user to get the access token of.
Optional
scopes: string[]The list of required scopes that will be compared against the existing token scopes.
UnregisteredUserError if user is not registered in the provider.
MissingScopeError if user is not registered in the provider.
Gets the scopes for a user that are currently available using the access token.
If scopes were not set on user registration then it returns an empty array.
UnregisteredUserError if user is not registered in the provider.
Optional
refreshRefreshes the access token.
This method is optional to implement.
The ID of the user to refresh the access token of.
Generated using TypeDoc
Authentication provider that manages access tokens for users.
Remarks
There are two build-in authentication provider implementations:
If these implementations do not meet your needs, you can create your own provider, for example, a Redis-based one, that can share auth data between separate processes.