class documentation

Run one authorization authenticator on the SDK event loop.

Method __init__ Initialize a runtime-bound authenticator.
Async Method authenticate Add authorization data to request metadata.
Method can_retry Return whether authentication can be retried.
Instance Variable _authenticator Undocumented
Instance Variable _channel Undocumented
def __init__(self, channel: Channel, authenticator: Authenticator): (source)

Initialize a runtime-bound authenticator.

Parameters
channel:ChannelSDK channel that owns the event loop.
authenticator:AuthenticatorAuthorization authenticator to wrap.
async def authenticate(self, metadata: Metadata, timeout: float | None = None, options: dict[str, str] | None = None): (source)

Add authorization data to request metadata.

Parameters
metadata:MetadataMetadata to update.
timeout:float | NoneOptional authentication timeout in seconds.
options:dict[str, str] | NoneOptional authentication settings.
def can_retry(self, err: Exception, options: dict[str, str] | None = None) -> bool: (source)

Return whether authentication can be retried.

Parameters
err:ExceptionError that caused the retry decision.
options:dict[str, str] | NoneOptional authentication settings.
Returns
boolTrue if the authenticator permits a retry.
_authenticator = (source)

Undocumented

_channel = (source)

Undocumented