Creates an instance of ChainedTokenCredential using the given credentials.
TokenCredential
implementations to be tried in order.
Example usage:
const firstCredential = new ClientSecretCredential(tenantId, clientId, clientSecret);
const secondCredential = new ClientSecretCredential(tenantId, anotherClientId, anotherSecret);
const credentialChain = new ChainedTokenCredential(firstCredential, secondCredential);
Returns the first access token returned by one of the chained
TokenCredential
implementations. Throws an AggregateAuthenticationError
when one or more credentials throws an AuthenticationError and
no credentials have returned an access token.
The list of scopes for which the token will have access.
The options used to configure any requests this
TokenCredential
implementation might make.
Generated using TypeDoc
Enables multiple
TokenCredential
implementations to be tried in order until one of the getToken methods returns an access token.