printnanny_api_client/models/
user.rs

1/*
2 * printnanny-api-client
3 *
4 * Official API client library for printnanny.ai
5 *
6 * The version of the OpenAPI document: 0.135.1
7 * Contact: leigh@printnanny.ai
8 * Generated by: https://openapi-generator.tech
9 */
10
11
12
13
14#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)]
15pub struct User {
16    #[serde(rename = "email")]
17    pub email: String,
18    #[serde(rename = "id")]
19    pub id: i32,
20    #[serde(rename = "first_name", skip_serializing_if = "Option::is_none")]
21    pub first_name: Option<String>,
22    #[serde(rename = "last_name", skip_serializing_if = "Option::is_none")]
23    pub last_name: Option<String>,
24    #[serde(rename = "is_beta_tester")]
25    pub is_beta_tester: bool,
26}
27
28impl User {
29    pub fn new(email: String, id: i32, is_beta_tester: bool) -> User {
30        User {
31            email,
32            id,
33            first_name: None,
34            last_name: None,
35            is_beta_tester,
36        }
37    }
38}
39
40