The refresh credentials is used to get new auth token to make REST call for Upload and Download requests. This class will use the refresh token generated in a previous interaction with LoginCredentials to get new auth tokens. Also will automatically get a new auth token when the current auth token expires using the refresh token.

It also has a logout function which will revoke the refresh token.

Most callers are recommended to use the LoginCredentials class to get the initial credentials which will return an instance of this class, instead of directly instantiating this class.

Hierarchy

  • RefreshingCredentials

Implements

Constructors

Properties

_currentTokenExpiryTime: Number
_token: string

Token obtained using refreshToken.

_tokenFetchPromise: Promise<void>

Sort of a debounce mechanism when getAuthToken is called in quick succession.

Methods

  • Returns Promise<string>

  • Returns Promise<any>

Generated using TypeDoc