1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
/*
* Hanzo Cloud API
*
* The Hanzo Cloud API as a customer calls it: every operation under /v1/ except the operator's admin product, relay routes, legacy spellings and capabilities still reached by flag. Tagged by product: the first path segment after /v1/.
*
* The version of the OpenAPI document: v1
*
* Generated by: https://openapi-generator.tech
*/
use crate::models;
use serde::{Deserialize, Serialize};
#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
pub struct AllowlistPutIn {
/// AccessGroups REPLACES the org's named access groups, as group name -> channel -> entries. Absent or null leaves them alone.
#[serde(rename = "accessGroups", skip_serializing_if = "Option::is_none")]
pub access_groups: Option<std::collections::HashMap<String, std::collections::HashMap<String, Vec<String>>>>,
/// Channel is the transport to edit: discord, slack, teams, telegram or whatsapp. Required; an unknown value is a 404.
#[serde(rename = "channel", skip_serializing_if = "Option::is_none")]
pub channel: Option<String>,
/// DM REPLACES the config-managed DM allow entries. Absent or null leaves them alone; an empty list clears them. It never touches senders approved through pairing — a policy edit cannot revoke an approved pairing.
#[serde(rename = "dm", skip_serializing_if = "Option::is_none")]
pub dm: Option<Vec<String>>,
/// DMPolicy sets how direct messages are admitted: \"pairing\" (a person must be approved first), \"allowlist\" (only listed senders) or \"open\". Empty leaves it unchanged.
#[serde(rename = "dmPolicy", skip_serializing_if = "Option::is_none")]
pub dm_policy: Option<String>,
/// Group REPLACES the config-managed group allow entries. Absent or null leaves them alone; an empty list clears them.
#[serde(rename = "group", skip_serializing_if = "Option::is_none")]
pub group: Option<Vec<String>>,
/// GroupPolicy sets how group and thread rooms are admitted: \"open\", \"allowlist\" or \"disabled\". Empty leaves it unchanged.
#[serde(rename = "groupPolicy", skip_serializing_if = "Option::is_none")]
pub group_policy: Option<String>,
}
impl AllowlistPutIn {
pub fn new() -> AllowlistPutIn {
AllowlistPutIn {
access_groups: None,
channel: None,
dm: None,
dm_policy: None,
group: None,
group_policy: None,
}
}
}