svix_webhook_with_clone/models/
operational_webhook_endpoint_in.rs

1/*
2 * Svix API
3 *
4 * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
5 *
6 * The version of the OpenAPI document: 1.1.1
7 * 
8 * Generated by: https://openapi-generator.tech
9 */
10
11#[allow(unused_imports)]
12use crate::models;
13#[allow(unused_imports)]
14use serde::{Deserialize, Serialize};
15        
16                #[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
17                pub struct OperationalWebhookEndpointIn {
18                        #[serde(rename = "description", skip_serializing_if = "Option::is_none")]
19                        pub description: Option<String>,
20                        #[serde(rename = "disabled", skip_serializing_if = "Option::is_none")]
21                        pub disabled: Option<bool>,
22                        #[serde(rename = "filterTypes", skip_serializing_if = "Option::is_none")]
23                        pub filter_types: Option<Vec<String>>,
24                        #[serde(rename = "metadata", skip_serializing_if = "Option::is_none")]
25                        pub metadata: Option<std::collections::HashMap<String, String>>,
26                        #[serde(rename = "rateLimit", skip_serializing_if = "Option::is_none")]
27                        pub rate_limit: Option<i32>,
28                        /// The endpoint's verification secret.  Format: `base64` encoded random bytes optionally prefixed with `whsec_`. It is recommended to not set this and let the server generate the secret.
29                        #[serde(rename = "secret", skip_serializing_if = "Option::is_none")]
30                        pub secret: Option<String>,
31                        /// Optional unique identifier for the endpoint
32                        #[serde(rename = "uid", skip_serializing_if = "Option::is_none")]
33                        pub uid: Option<String>,
34                        #[serde(rename = "url")]
35                        pub url: String,
36                    }
37
38                    impl OperationalWebhookEndpointIn {
39                    pub fn new(url: String) -> OperationalWebhookEndpointIn {
40                OperationalWebhookEndpointIn {
41                    description: None,
42                    disabled: None,
43                    filter_types: None,
44                    metadata: None,
45                    rate_limit: None,
46                    secret: None,
47                    uid: None,
48                    url,
49                    }
50                    }
51                    }
52