pub struct ExternalAuthProviderConfig {Show 20 fields
pub id: i64,
pub key: String,
pub provider_kind: ExternalAuthProviderKind,
pub protocol: ExternalAuthProtocol,
pub options: ExternalAuthProviderOptions,
pub issuer_url: Option<String>,
pub authorization_url: Option<String>,
pub token_url: Option<String>,
pub userinfo_url: Option<String>,
pub client_id: String,
pub client_secret: Option<String>,
pub scopes: String,
pub subject_claim: Option<String>,
pub username_claim: Option<String>,
pub display_name_claim: Option<String>,
pub email_claim: Option<String>,
pub email_verified_claim: Option<String>,
pub groups_claim: Option<String>,
pub avatar_url_claim: Option<String>,
pub outbound_http_user_agent: Option<String>,
}Expand description
Runtime configuration used by provider drivers.
The value is intentionally independent from persistence. Application crates can keep their own schema, encrypted secret handling, OpenAPI shape, and migration behavior, then construct this config immediately before invoking a provider driver.
Fields§
§id: i64Product-owned provider id, carried through for logging and app-level correlation.
key: StringProduct-owned stable provider key.
provider_kind: ExternalAuthProviderKindProvider kind selected by the application.
protocol: ExternalAuthProtocolProtocol selected by the application.
options: ExternalAuthProviderOptionsConnector-specific decoded options.
issuer_url: Option<String>Issuer URL for OIDC-style providers.
Authorization endpoint for manual OAuth2 providers.
token_url: Option<String>Token endpoint for manual OAuth2 providers.
userinfo_url: Option<String>Userinfo endpoint for manual OAuth2 providers.
client_id: StringOAuth/OIDC client id.
client_secret: Option<String>Optional OAuth/OIDC client secret.
scopes: StringSpace-separated scope list.
subject_claim: Option<String>Optional profile claim name or JSON pointer used as the subject.
username_claim: Option<String>Optional profile claim name or JSON pointer used as the preferred username.
display_name_claim: Option<String>Optional profile claim name or JSON pointer used as the display name.
email_claim: Option<String>Optional profile claim name or JSON pointer used as the email address.
email_verified_claim: Option<String>Optional profile claim name or JSON pointer used as the email verification flag.
groups_claim: Option<String>Optional profile claim name reserved for group extraction by application crates.
avatar_url_claim: Option<String>Optional profile claim name reserved for avatar URL extraction by application crates.
outbound_http_user_agent: Option<String>Optional application-owned User-Agent for outbound provider API requests.
Implementations§
Source§impl ExternalAuthProviderConfig
impl ExternalAuthProviderConfig
Sourcepub fn require_issuer_url(&self) -> Result<&str>
pub fn require_issuer_url(&self) -> Result<&str>
Returns a non-empty issuer URL or a validation error.
Trait Implementations§
Source§impl Clone for ExternalAuthProviderConfig
impl Clone for ExternalAuthProviderConfig
Source§fn clone(&self) -> ExternalAuthProviderConfig
fn clone(&self) -> ExternalAuthProviderConfig
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreAuto Trait Implementations§
impl Freeze for ExternalAuthProviderConfig
impl RefUnwindSafe for ExternalAuthProviderConfig
impl Send for ExternalAuthProviderConfig
impl Sync for ExternalAuthProviderConfig
impl Unpin for ExternalAuthProviderConfig
impl UnsafeUnpin for ExternalAuthProviderConfig
impl UnwindSafe for ExternalAuthProviderConfig
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more