Update RegisterSchema, add LoginSchema

This commit is contained in:
bitfl0wer 2023-04-15 21:16:47 +02:00
parent ff60853d0b
commit e1003ac2b6
1 changed files with 13 additions and 2 deletions

View File

@ -4,9 +4,9 @@ pub mod schemas {
#[derive(Debug, Serialize, Deserialize)]
#[serde(rename_all = "snake_case")]
pub struct RegisterSchema {
username: Option<String>,
username: String,
password: Option<String>,
consent: Option<bool>,
consent: bool,
email: Option<String>,
fingerprint: Option<String>,
invite: Option<String>,
@ -15,4 +15,15 @@ pub mod schemas {
captcha_key: Option<String>,
promotional_email_opt_in: Option<bool>,
}
#[derive(Debug, Serialize, Deserialize)]
#[serde(rename_all = "snake_case")]
pub struct LoginSchema {
login: String,
password: String,
undelete: Option<bool>,
captcha_key: Option<String>,
login_source: Option<String>,
gift_code_sku_id: Option<String>,
}
}