authentik_client/models/
identification_challenge_response_request.rs

1/*
2 * authentik
3 *
4 * Making authentication simple.
5 *
6 * The version of the OpenAPI document: 2025.8.4
7 * Contact: hello@goauthentik.io
8 * Generated by: https://openapi-generator.tech
9 */
10
11use crate::models;
12use serde::{Deserialize, Serialize};
13
14/// IdentificationChallengeResponseRequest : Identification challenge
15#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
16pub struct IdentificationChallengeResponseRequest {
17    #[serde(rename = "component", skip_serializing_if = "Option::is_none")]
18    pub component: Option<String>,
19    #[serde(rename = "uid_field")]
20    pub uid_field: String,
21    #[serde(
22        rename = "password",
23        default,
24        with = "::serde_with::rust::double_option",
25        skip_serializing_if = "Option::is_none"
26    )]
27    pub password: Option<Option<String>>,
28    #[serde(
29        rename = "captcha_token",
30        default,
31        with = "::serde_with::rust::double_option",
32        skip_serializing_if = "Option::is_none"
33    )]
34    pub captcha_token: Option<Option<String>>,
35}
36
37impl IdentificationChallengeResponseRequest {
38    /// Identification challenge
39    pub fn new(uid_field: String) -> IdentificationChallengeResponseRequest {
40        IdentificationChallengeResponseRequest {
41            component: None,
42            uid_field,
43            password: None,
44            captcha_token: None,
45        }
46    }
47}