mattermost_rust_client/models/
create_scheme_request.rs

1/*
2 * Mattermost API Reference
3 *
4 * There is also a work-in-progress [Postman API reference](https://documenter.getpostman.com/view/4508214/RW8FERUn). 
5 *
6 * The version of the OpenAPI document: 4.0.0
7 * Contact: feedback@mattermost.com
8 * Generated by: https://openapi-generator.tech
9 */
10
11
12
13
14#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)]
15pub struct CreateSchemeRequest {
16    /// The name of the scheme
17    #[serde(rename = "name")]
18    pub name: String,
19    /// The description of the scheme
20    #[serde(rename = "description", skip_serializing_if = "Option::is_none")]
21    pub description: Option<String>,
22    /// The scope of the scheme (\"team\" or \"channel\")
23    #[serde(rename = "scope")]
24    pub scope: String,
25}
26
27impl CreateSchemeRequest {
28    pub fn new(name: String, scope: String) -> CreateSchemeRequest {
29        CreateSchemeRequest {
30            name,
31            description: None,
32            scope,
33        }
34    }
35}
36
37