authentik_rust/models/
patched_flow_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/// PatchedFlowRequest : Flow Serializer
14#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
15pub struct PatchedFlowRequest {
16    #[serde(rename = "name", skip_serializing_if = "Option::is_none")]
17    pub name: Option<String>,
18    /// Visible in the URL.
19    #[serde(rename = "slug", skip_serializing_if = "Option::is_none")]
20    pub slug: Option<String>,
21    /// Shown as the Title in Flow pages.
22    #[serde(rename = "title", skip_serializing_if = "Option::is_none")]
23    pub title: Option<String>,
24    /// Decides what this Flow is used for. For example, the Authentication flow is redirect to when an un-authenticated user visits authentik.  * `authentication` - Authentication * `authorization` - Authorization * `invalidation` - Invalidation * `enrollment` - Enrollment * `unenrollment` - Unrenollment * `recovery` - Recovery * `stage_configuration` - Stage Configuration
25    #[serde(rename = "designation", skip_serializing_if = "Option::is_none")]
26    pub designation: Option<models::FlowDesignationEnum>,
27    #[serde(rename = "policy_engine_mode", skip_serializing_if = "Option::is_none")]
28    pub policy_engine_mode: Option<models::PolicyEngineMode>,
29    /// Enable compatibility mode, increases compatibility with password managers on mobile devices.
30    #[serde(rename = "compatibility_mode", skip_serializing_if = "Option::is_none")]
31    pub compatibility_mode: Option<bool>,
32    #[serde(rename = "layout", skip_serializing_if = "Option::is_none")]
33    pub layout: Option<models::FlowLayoutEnum>,
34    /// Configure what should happen when a flow denies access to a user.  * `message_continue` - Message Continue * `message` - Message * `continue` - Continue
35    #[serde(rename = "denied_action", skip_serializing_if = "Option::is_none")]
36    pub denied_action: Option<models::DeniedActionEnum>,
37    /// Required level of authentication and authorization to access a flow.  * `none` - None * `require_authenticated` - Require Authenticated * `require_unauthenticated` - Require Unauthenticated * `require_superuser` - Require Superuser * `require_outpost` - Require Outpost
38    #[serde(rename = "authentication", skip_serializing_if = "Option::is_none")]
39    pub authentication: Option<models::AuthenticationEnum>,
40}
41
42impl PatchedFlowRequest {
43    /// Flow Serializer
44    pub fn new() -> PatchedFlowRequest {
45        PatchedFlowRequest {
46            name: None,
47            slug: None,
48            title: None,
49            designation: None,
50            policy_engine_mode: None,
51            compatibility_mode: None,
52            layout: None,
53            denied_action: None,
54            authentication: None,
55        }
56    }
57}
58