revolt_api/models/
data_password_reset.rs

1/*
2 * Revolt API
3 *
4 * Open source user-first chat platform.
5 *
6 * The version of the OpenAPI document: 0.6.5
7 * Contact: contact@revolt.chat
8 * Generated by: https://openapi-generator.tech
9 */
10
11
12
13
14#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)]
15pub struct DataPasswordReset {
16    /// Reset token
17    #[serde(rename = "token")]
18    pub token: String,
19    /// New password
20    #[serde(rename = "password")]
21    pub password: String,
22    /// Whether to logout all sessions
23    #[serde(rename = "remove_sessions", skip_serializing_if = "Option::is_none")]
24    pub remove_sessions: Option<bool>,
25}
26
27impl DataPasswordReset {
28    pub fn new(token: String, password: String) -> DataPasswordReset {
29        DataPasswordReset {
30            token,
31            password,
32            remove_sessions: None,
33        }
34    }
35}
36
37