clerk_sdk_rust_community/models/
instance_restrictions.rs

1/*
2 * Clerk Backend API
3 *
4 * The Clerk REST Backend API, meant to be accessed by backend servers. Please see https://clerk.com/docs for more information.
5 *
6 * The version of the OpenAPI document: v1
7 * Contact: support@clerk.dev
8 * Generated by: https://openapi-generator.tech
9 */
10
11
12
13
14#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)]
15pub struct InstanceRestrictions {
16    /// String representing the object's type. Objects of the same type share the same value.
17    #[serde(rename = "object", skip_serializing_if = "Option::is_none")]
18    pub object: Option<Object>,
19    #[serde(rename = "allowlist", skip_serializing_if = "Option::is_none")]
20    pub allowlist: Option<bool>,
21    #[serde(rename = "blocklist", skip_serializing_if = "Option::is_none")]
22    pub blocklist: Option<bool>,
23}
24
25impl InstanceRestrictions {
26    pub fn new() -> InstanceRestrictions {
27        InstanceRestrictions {
28            object: None,
29            allowlist: None,
30            blocklist: None,
31        }
32    }
33}
34
35/// String representing the object's type. Objects of the same type share the same value.
36#[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash, Serialize, Deserialize)]
37pub enum Object {
38    #[serde(rename = "instance_restrictions")]
39    InstanceRestrictions,
40}
41
42impl Default for Object {
43    fn default() -> Object {
44        Self::InstanceRestrictions
45    }
46}
47