authentik_rust/models/
brand.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/// Brand : Brand Serializer
14#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
15pub struct Brand {
16    #[serde(rename = "brand_uuid")]
17    pub brand_uuid: uuid::Uuid,
18    /// Domain that activates this brand. Can be a superset, i.e. `a.b` for `aa.b` and `ba.b`
19    #[serde(rename = "domain")]
20    pub domain: String,
21    #[serde(rename = "default", skip_serializing_if = "Option::is_none")]
22    pub default: Option<bool>,
23    #[serde(rename = "branding_title", skip_serializing_if = "Option::is_none")]
24    pub branding_title: Option<String>,
25    #[serde(rename = "branding_logo", skip_serializing_if = "Option::is_none")]
26    pub branding_logo: Option<String>,
27    #[serde(rename = "branding_favicon", skip_serializing_if = "Option::is_none")]
28    pub branding_favicon: Option<String>,
29    #[serde(rename = "flow_authentication", default, with = "::serde_with::rust::double_option", skip_serializing_if = "Option::is_none")]
30    pub flow_authentication: Option<Option<uuid::Uuid>>,
31    #[serde(rename = "flow_invalidation", default, with = "::serde_with::rust::double_option", skip_serializing_if = "Option::is_none")]
32    pub flow_invalidation: Option<Option<uuid::Uuid>>,
33    #[serde(rename = "flow_recovery", default, with = "::serde_with::rust::double_option", skip_serializing_if = "Option::is_none")]
34    pub flow_recovery: Option<Option<uuid::Uuid>>,
35    #[serde(rename = "flow_unenrollment", default, with = "::serde_with::rust::double_option", skip_serializing_if = "Option::is_none")]
36    pub flow_unenrollment: Option<Option<uuid::Uuid>>,
37    #[serde(rename = "flow_user_settings", default, with = "::serde_with::rust::double_option", skip_serializing_if = "Option::is_none")]
38    pub flow_user_settings: Option<Option<uuid::Uuid>>,
39    #[serde(rename = "flow_device_code", default, with = "::serde_with::rust::double_option", skip_serializing_if = "Option::is_none")]
40    pub flow_device_code: Option<Option<uuid::Uuid>>,
41    /// Web Certificate used by the authentik Core webserver.
42    #[serde(rename = "web_certificate", default, with = "::serde_with::rust::double_option", skip_serializing_if = "Option::is_none")]
43    pub web_certificate: Option<Option<uuid::Uuid>>,
44    #[serde(rename = "attributes", default, with = "::serde_with::rust::double_option", skip_serializing_if = "Option::is_none")]
45    pub attributes: Option<Option<serde_json::Value>>,
46}
47
48impl Brand {
49    /// Brand Serializer
50    pub fn new(brand_uuid: uuid::Uuid, domain: String) -> Brand {
51        Brand {
52            brand_uuid,
53            domain,
54            default: None,
55            branding_title: None,
56            branding_logo: None,
57            branding_favicon: None,
58            flow_authentication: None,
59            flow_invalidation: None,
60            flow_recovery: None,
61            flow_unenrollment: None,
62            flow_user_settings: None,
63            flow_device_code: None,
64            web_certificate: None,
65            attributes: None,
66        }
67    }
68}
69