1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)]
pub struct BouncedEmailDto {
#[serde(rename = "bounceMta", skip_serializing_if = "Option::is_none")]
pub bounce_mta: Option<String>,
#[serde(rename = "bounceRecipients", skip_serializing_if = "Option::is_none")]
pub bounce_recipients: Option<Vec<String>>,
#[serde(rename = "bounceSubType", skip_serializing_if = "Option::is_none")]
pub bounce_sub_type: Option<String>,
#[serde(rename = "bounceType", skip_serializing_if = "Option::is_none")]
pub bounce_type: Option<String>,
#[serde(rename = "createdAt")]
pub created_at: String,
#[serde(rename = "id", skip_serializing_if = "Option::is_none")]
pub id: Option<String>,
#[serde(rename = "notificationType")]
pub notification_type: String,
#[serde(rename = "sender")]
pub sender: String,
#[serde(rename = "sentToRecipients", skip_serializing_if = "Option::is_none")]
pub sent_to_recipients: Option<Vec<String>>,
#[serde(rename = "userId")]
pub user_id: String,
}
impl BouncedEmailDto {
pub fn new(created_at: String, notification_type: String, sender: String, user_id: String) -> BouncedEmailDto {
BouncedEmailDto {
bounce_mta: None,
bounce_recipients: None,
bounce_sub_type: None,
bounce_type: None,
created_at,
id: None,
notification_type,
sender,
sent_to_recipients: None,
user_id,
}
}
}