Skip to main content

gitbundle_sdk/models/
webhook_patch_input.rs

1/*
2 * GitBundle API
3 *
4 * GitBundle API documentation.
5 *
6 * The version of the OpenAPI document: 3.4.1
7 *
8 * Generated by: https://openapi-generator.tech
9 */
10
11use serde::{Deserialize, Serialize};
12
13use crate::models;
14
15#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
16pub struct WebhookPatchInput {
17    #[serde(
18        rename = "description",
19        default,
20        with = "::serde_with::rust::double_option",
21        skip_serializing_if = "Option::is_none"
22    )]
23    pub description: Option<Option<String>>,
24    #[serde(
25        rename = "display_name",
26        default,
27        with = "::serde_with::rust::double_option",
28        skip_serializing_if = "Option::is_none"
29    )]
30    pub display_name: Option<Option<String>>,
31    #[serde(
32        rename = "enabled",
33        default,
34        with = "::serde_with::rust::double_option",
35        skip_serializing_if = "Option::is_none"
36    )]
37    pub enabled: Option<Option<bool>>,
38    #[serde(
39        rename = "identifier",
40        default,
41        with = "::serde_with::rust::double_option",
42        skip_serializing_if = "Option::is_none"
43    )]
44    pub identifier: Option<Option<String>>,
45    #[serde(
46        rename = "insecure",
47        default,
48        with = "::serde_with::rust::double_option",
49        skip_serializing_if = "Option::is_none"
50    )]
51    pub insecure: Option<Option<bool>>,
52    #[serde(
53        rename = "secret",
54        default,
55        with = "::serde_with::rust::double_option",
56        skip_serializing_if = "Option::is_none"
57    )]
58    pub secret: Option<Option<String>>,
59    #[serde(
60        rename = "triggers",
61        default,
62        with = "::serde_with::rust::double_option",
63        skip_serializing_if = "Option::is_none"
64    )]
65    pub triggers: Option<Option<Vec<models::WebhookTrigger>>>,
66    #[serde(
67        rename = "url",
68        default,
69        with = "::serde_with::rust::double_option",
70        skip_serializing_if = "Option::is_none"
71    )]
72    pub url: Option<Option<String>>,
73}
74
75impl WebhookPatchInput {
76    pub fn new() -> WebhookPatchInput {
77        WebhookPatchInput {
78            description: None,
79            display_name: None,
80            enabled: None,
81            identifier: None,
82            insecure: None,
83            secret: None,
84            triggers: None,
85            url: None,
86        }
87    }
88}