pub trait ExternalAuth: Send + Sync {
// Required methods
fn resolve(&self) -> ExternalAuthFuture<'_, CodexAuth>;
fn refresh(
&self,
context: ExternalAuthRefreshContext,
) -> ExternalAuthFuture<'_, CodexAuth>;
}Expand description
Pluggable auth provider used by AuthManager for externally managed auth flows.
Implementations own the current auth value and any source-specific refresh mechanism.
Required Methods§
Sourcefn resolve(&self) -> ExternalAuthFuture<'_, CodexAuth>
fn resolve(&self) -> ExternalAuthFuture<'_, CodexAuth>
Returns the provider’s current auth value.
Sourcefn refresh(
&self,
context: ExternalAuthRefreshContext,
) -> ExternalAuthFuture<'_, CodexAuth>
fn refresh( &self, context: ExternalAuthRefreshContext, ) -> ExternalAuthFuture<'_, CodexAuth>
Refreshes auth and makes the returned value current for future resolve() calls.
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".