fastly_api/models/
contact_response.rs1#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)]
12pub struct ContactResponse {
13 #[serde(rename = "user_id", skip_serializing_if = "Option::is_none")]
15 pub user_id: Option<String>,
16 #[serde(rename = "contact_type", skip_serializing_if = "Option::is_none")]
18 pub contact_type: Option<ContactType>,
19 #[serde(rename = "name", skip_serializing_if = "Option::is_none")]
21 pub name: Option<String>,
22 #[serde(rename = "email", skip_serializing_if = "Option::is_none")]
24 pub email: Option<String>,
25 #[serde(rename = "phone", skip_serializing_if = "Option::is_none")]
27 pub phone: Option<String>,
28 #[serde(rename = "customer_id", skip_serializing_if = "Option::is_none")]
30 pub customer_id: Option<String>,
31 #[serde(rename = "created_at", skip_serializing_if = "Option::is_none")]
33 pub created_at: Option<String>,
34 #[serde(rename = "deleted_at", skip_serializing_if = "Option::is_none")]
36 pub deleted_at: Option<String>,
37 #[serde(rename = "updated_at", skip_serializing_if = "Option::is_none")]
39 pub updated_at: Option<String>,
40 #[serde(rename = "id", skip_serializing_if = "Option::is_none")]
41 pub id: Option<Box<String>>,
42}
43
44impl ContactResponse {
45 pub fn new() -> ContactResponse {
46 ContactResponse {
47 user_id: None,
48 contact_type: None,
49 name: None,
50 email: None,
51 phone: None,
52 customer_id: None,
53 created_at: None,
54 deleted_at: None,
55 updated_at: None,
56 id: None,
57 }
58 }
59}
60
61#[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash, Serialize, Deserialize)]
63pub enum ContactType {
64 #[serde(rename = "primary")]
65 Primary,
66 #[serde(rename = "billing")]
67 Billing,
68 #[serde(rename = "technical")]
69 Technical,
70 #[serde(rename = "security")]
71 Security,
72 #[serde(rename = "emergency")]
73 Emergency,
74 #[serde(rename = "general compliance")]
75 GeneralCompliance,
76}
77
78impl Default for ContactType {
79 fn default() -> ContactType {
80 Self::Primary
81 }
82}
83