Class Impersonated (9.0.0)

Inheritance

AuthClient > OAuth2Client > Impersonated

Package

google-auth-library

Constructors

(constructor)(options)

constructor(options?: ImpersonatedOptions);

Impersonated service account credentials.

Create a new access token by impersonating another service account.

Impersonated Credentials allowing credentials issued to a user or service account to impersonate another. The source project using Impersonated Credentials must enable the "IAMCredentials" API. Also, the target service account must grant the orginating principal the "Service Account Token Creator" IAM role.

Parameter
NameDescription
options ImpersonatedOptions

The configuration object.

Methods

refreshToken(refreshToken)

protected refreshToken(refreshToken?: string | null): Promise<GetTokenResponse>;

Refreshes the access token.

Parameter
NameDescription
refreshToken string | null

Unused parameter

Returns
TypeDescription
Promise<GetTokenResponse>