bitwarden_api_api/models/
policy_status_response_model.rs

1/*
2 * Bitwarden Internal API
3 *
4 * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
5 *
6 * The version of the OpenAPI document: latest
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 PolicyStatusResponseModel {
17    #[serde(
18        rename = "object",
19        alias = "Object",
20        skip_serializing_if = "Option::is_none"
21    )]
22    pub object: Option<String>,
23    #[serde(
24        rename = "organizationId",
25        alias = "OrganizationId",
26        skip_serializing_if = "Option::is_none"
27    )]
28    pub organization_id: Option<uuid::Uuid>,
29    #[serde(
30        rename = "type",
31        alias = "R#type",
32        skip_serializing_if = "Option::is_none"
33    )]
34    pub r#type: Option<models::PolicyType>,
35    #[serde(
36        rename = "data",
37        alias = "Data",
38        skip_serializing_if = "Option::is_none"
39    )]
40    pub data: Option<std::collections::HashMap<String, serde_json::Value>>,
41    #[serde(
42        rename = "enabled",
43        alias = "Enabled",
44        skip_serializing_if = "Option::is_none"
45    )]
46    pub enabled: Option<bool>,
47    /// Indicates whether the Policy can be enabled/disabled
48    #[serde(
49        rename = "canToggleState",
50        alias = "CanToggleState",
51        skip_serializing_if = "Option::is_none"
52    )]
53    pub can_toggle_state: Option<bool>,
54}
55
56impl PolicyStatusResponseModel {
57    pub fn new() -> PolicyStatusResponseModel {
58        PolicyStatusResponseModel {
59            object: None,
60            organization_id: None,
61            r#type: None,
62            data: None,
63            enabled: None,
64            can_toggle_state: None,
65        }
66    }
67}