authentik_rust/models/
patched_proxy_provider_request.rs

1/*
2 * authentik
3 *
4 * Making authentication simple.
5 *
6 * The version of the OpenAPI document: 2024.2.1
7 * Contact: hello@goauthentik.io
8 * Generated by: https://openapi-generator.tech
9 */
10
11use crate::models;
12
13/// PatchedProxyProviderRequest : ProxyProvider Serializer
14#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
15pub struct PatchedProxyProviderRequest {
16    #[serde(rename = "name", skip_serializing_if = "Option::is_none")]
17    pub name: Option<String>,
18    /// Flow used for authentication when the associated application is accessed by an un-authenticated user.
19    #[serde(rename = "authentication_flow", default, with = "::serde_with::rust::double_option", skip_serializing_if = "Option::is_none")]
20    pub authentication_flow: Option<Option<uuid::Uuid>>,
21    /// Flow used when authorizing this provider.
22    #[serde(rename = "authorization_flow", skip_serializing_if = "Option::is_none")]
23    pub authorization_flow: Option<uuid::Uuid>,
24    #[serde(rename = "property_mappings", skip_serializing_if = "Option::is_none")]
25    pub property_mappings: Option<Vec<uuid::Uuid>>,
26    #[serde(rename = "internal_host", skip_serializing_if = "Option::is_none")]
27    pub internal_host: Option<String>,
28    #[serde(rename = "external_host", skip_serializing_if = "Option::is_none")]
29    pub external_host: Option<String>,
30    /// Validate SSL Certificates of upstream servers
31    #[serde(rename = "internal_host_ssl_validation", skip_serializing_if = "Option::is_none")]
32    pub internal_host_ssl_validation: Option<bool>,
33    #[serde(rename = "certificate", default, with = "::serde_with::rust::double_option", skip_serializing_if = "Option::is_none")]
34    pub certificate: Option<Option<uuid::Uuid>>,
35    /// Regular expressions for which authentication is not required. Each new line is interpreted as a new Regular Expression.
36    #[serde(rename = "skip_path_regex", skip_serializing_if = "Option::is_none")]
37    pub skip_path_regex: Option<String>,
38    /// Set a custom HTTP-Basic Authentication header based on values from authentik.
39    #[serde(rename = "basic_auth_enabled", skip_serializing_if = "Option::is_none")]
40    pub basic_auth_enabled: Option<bool>,
41    /// User/Group Attribute used for the password part of the HTTP-Basic Header.
42    #[serde(rename = "basic_auth_password_attribute", skip_serializing_if = "Option::is_none")]
43    pub basic_auth_password_attribute: Option<String>,
44    /// User/Group Attribute used for the user part of the HTTP-Basic Header. If not set, the user's Email address is used.
45    #[serde(rename = "basic_auth_user_attribute", skip_serializing_if = "Option::is_none")]
46    pub basic_auth_user_attribute: Option<String>,
47    /// Enable support for forwardAuth in traefik and nginx auth_request. Exclusive with internal_host.  * `proxy` - Proxy * `forward_single` - Forward Single * `forward_domain` - Forward Domain
48    #[serde(rename = "mode", skip_serializing_if = "Option::is_none")]
49    pub mode: Option<models::ProxyMode>,
50    /// When enabled, this provider will intercept the authorization header and authenticate requests based on its value.
51    #[serde(rename = "intercept_header_auth", skip_serializing_if = "Option::is_none")]
52    pub intercept_header_auth: Option<bool>,
53    #[serde(rename = "cookie_domain", skip_serializing_if = "Option::is_none")]
54    pub cookie_domain: Option<String>,
55    #[serde(rename = "jwks_sources", skip_serializing_if = "Option::is_none")]
56    pub jwks_sources: Option<Vec<uuid::Uuid>>,
57    /// Tokens not valid on or after current time + this value (Format: hours=1;minutes=2;seconds=3).
58    #[serde(rename = "access_token_validity", skip_serializing_if = "Option::is_none")]
59    pub access_token_validity: Option<String>,
60    /// Tokens not valid on or after current time + this value (Format: hours=1;minutes=2;seconds=3).
61    #[serde(rename = "refresh_token_validity", skip_serializing_if = "Option::is_none")]
62    pub refresh_token_validity: Option<String>,
63}
64
65impl PatchedProxyProviderRequest {
66    /// ProxyProvider Serializer
67    pub fn new() -> PatchedProxyProviderRequest {
68        PatchedProxyProviderRequest {
69            name: None,
70            authentication_flow: None,
71            authorization_flow: None,
72            property_mappings: None,
73            internal_host: None,
74            external_host: None,
75            internal_host_ssl_validation: None,
76            certificate: None,
77            skip_path_regex: None,
78            basic_auth_enabled: None,
79            basic_auth_password_attribute: None,
80            basic_auth_user_attribute: None,
81            mode: None,
82            intercept_header_auth: None,
83            cookie_domain: None,
84            jwks_sources: None,
85            access_token_validity: None,
86            refresh_token_validity: None,
87        }
88    }
89}
90