netbox_openapi/models/
patched_contact_request.rs

1/*
2 * NetBox REST API
3 *
4 * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
5 *
6 * The version of the OpenAPI document: 4.4.2-Docker-3.4.1 (4.4)
7 *
8 * Generated by: https://openapi-generator.tech
9 */
10
11/// PatchedContactRequest : Adds support for custom fields and tags.
12
13#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)]
14pub struct PatchedContactRequest {
15    #[serde(rename = "groups", skip_serializing_if = "Option::is_none")]
16    pub groups: Option<Vec<i32>>,
17    #[serde(rename = "name", skip_serializing_if = "Option::is_none")]
18    pub name: Option<String>,
19    #[serde(rename = "title", skip_serializing_if = "Option::is_none")]
20    pub title: Option<String>,
21    #[serde(rename = "phone", skip_serializing_if = "Option::is_none")]
22    pub phone: Option<String>,
23    #[serde(rename = "email", skip_serializing_if = "Option::is_none")]
24    pub email: Option<String>,
25    #[serde(rename = "address", skip_serializing_if = "Option::is_none")]
26    pub address: Option<String>,
27    #[serde(rename = "link", skip_serializing_if = "Option::is_none")]
28    pub link: Option<String>,
29    #[serde(rename = "description", skip_serializing_if = "Option::is_none")]
30    pub description: Option<String>,
31    #[serde(rename = "comments", skip_serializing_if = "Option::is_none")]
32    pub comments: Option<String>,
33    #[serde(rename = "tags", skip_serializing_if = "Option::is_none")]
34    pub tags: Option<Vec<crate::models::NestedTagRequest>>,
35    #[serde(rename = "custom_fields", skip_serializing_if = "Option::is_none")]
36    pub custom_fields: Option<::std::collections::HashMap<String, serde_json::Value>>,
37}
38
39impl PatchedContactRequest {
40    /// Adds support for custom fields and tags.
41    pub fn new() -> PatchedContactRequest {
42        PatchedContactRequest {
43            groups: None,
44            name: None,
45            title: None,
46            phone: None,
47            email: None,
48            address: None,
49            link: None,
50            description: None,
51            comments: None,
52            tags: None,
53            custom_fields: None,
54        }
55    }
56}