bitwarden_api_api/models/
granted_access_policy_request.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 GrantedAccessPolicyRequest {
17    #[serde(rename = "grantedId")]
18    pub granted_id: uuid::Uuid,
19    #[serde(rename = "read")]
20    pub read: bool,
21    #[serde(rename = "write")]
22    pub write: bool,
23}
24
25impl GrantedAccessPolicyRequest {
26    pub fn new(granted_id: uuid::Uuid, read: bool, write: bool) -> GrantedAccessPolicyRequest {
27        GrantedAccessPolicyRequest {
28            granted_id,
29            read,
30            write,
31        }
32    }
33}