public class ComputeCredential.Initializer : ServiceCredential.Initializer
An initializer class for the Compute credential. It uses ComputeTokenUrl
as the token server URL (optionally overriding the host using the GCE_METADATA_HOST environment variable).
public Initializer(string tokenUrl, string oidcTokenUrl)
Constructs a new initializer using the given token URL
and OIDC token URL (optionally overriding the host using the GCE_METADATA_HOST environment variable).
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Hard to understand","hardToUnderstand","thumb-down"],["Incorrect information or sample code","incorrectInformationOrSampleCode","thumb-down"],["Missing the information/samples I need","missingTheInformationSamplesINeed","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-03-05 UTC."],[[["The `ComputeCredential.Initializer` class is designed for initializing Compute credentials, utilizing `ComputeTokenUrl` as the default token server URL, with the option to override the host via the `GCE_METADATA_HOST` environment variable."],["This class inherits from `ServiceCredential.Initializer`, inheriting members such as `TokenServerUrl`, `Clock`, `AccessMethod`, `HttpClientFactory`, `DefaultExponentialBackOffPolicy`, `QuotaProject`, and `Scopes`."],["The `Initializer` class provides three constructors, one default, one taking a `tokenUrl` string, and one taking both `tokenUrl` and `oidcTokenUrl` strings, offering flexibility in configuring the initializer."],["The class contains the `OidcTokenUrl` property, a string, which is a get-only property that returns the OIDC token URL."],["There are multiple versions of this documentation available for the library, with version 1.69.0 being the latest available."]]],[]]