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
/*
* JSON Ledger API HTTP endpoints
*
* No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
*
* The version of the OpenAPI document: 3.3.0-SNAPSHOT
*
* Generated by: https://openapi-generator.tech
*/
use crate::models;
use serde::{Deserialize, Serialize};
/// RevokeUserRightsRequest : Remove the rights from the set of rights granted to the user. Required authorization: ``HasRight(ParticipantAdmin) OR IsAuthenticatedIdentityProviderAdmin(identity_provider_id)``
#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
pub struct RevokeUserRightsRequest {
/// The user from whom to revoke rights. Required
#[serde(rename = "userId")]
pub user_id: String,
/// The rights to revoke. Optional
#[serde(rename = "rights", skip_serializing_if = "Option::is_none")]
pub rights: Option<Vec<models::Right>>,
/// The id of the ``Identity Provider`` Optional, if not set, assume the user is managed by the default identity provider.
#[serde(rename = "identityProviderId")]
pub identity_provider_id: String,
}
impl RevokeUserRightsRequest {
/// Remove the rights from the set of rights granted to the user. Required authorization: ``HasRight(ParticipantAdmin) OR IsAuthenticatedIdentityProviderAdmin(identity_provider_id)``
pub fn new(user_id: String, identity_provider_id: String) -> RevokeUserRightsRequest {
RevokeUserRightsRequest {
user_id,
rights: None,
identity_provider_id,
}
}
}