@nebius/js-sdk - v0.2.78
    Preparing search index...

    Class IMDSBearer

    Reads access_token and expires_at from an HTTP token endpoint for each acquisition.

    Hierarchy (View Summary)

    Indexable

    • [key: symbol]: (() => string) | (() => object)

      Reads access_token and expires_at from an HTTP token endpoint for each acquisition.

      • () => string
          • (): string
          • Reads access_token and expires_at from an HTTP token endpoint for each acquisition.

            Returns string

      • () => object
          • (): object
          • Returns a JSON-safe value for logs.

            Returns object

    Index
    $type: "nebius.sdk.IMDSBearer" = 'nebius.sdk.IMDSBearer'

    Contains the fully qualified runtime type name.

    • get acquisitionBudgetMs(): number | undefined

      Returns the budget for one token acquisition, in milliseconds.

      undefined means no declared budget. A non-positive value means an immediate failure. A cache asks only its immediate source. Transparent wrappers must forward this value; wrappers that add work must compose it.

      Returns number | undefined

    • get metricProvider(): string

      Returns the provider name for authorization metrics.

      Returns string

    • get name(): string | undefined

      Returns the stable credential name used by file-backed token caches.

      Most bearers do not have a name. Wrappers can add one with NamedBearer.

      Returns string | undefined

    • get wrapped(): Bearer | undefined

      Returns the next bearer in a wrapper chain, when this bearer wraps another source.

      Returns Bearer | undefined

    • Stops owned background work and closes the wrapped bearer.

      Parameters

      • OptionalgraceMs: number

      Returns Promise<void>

    • Fetches a token. Retries HTTP 429 and 5xx responses within one timeout budget.

      Parameters

      • OptionaltimeoutMs: number

      Returns Promise<Token>