TokenSource

Source of bearer tokens for a renewing auth flow.

Source of bearer tokens for a renewing auth flow.

Functions

funcget_cached_token() -> str | None

Return the cached bearer token.

Returns

str | None

Bearer token, or None when nothing usable is cached.

funcfetch_token() -> str | None

Fetch a fresh bearer token.

Returns

str | None

Bearer token, or None when the source cannot produce one.

funcclose() -> None

Close any resources this source opened.

Returns

None

On this page