hi_jira2/models/
application_role.rs

1/*
2 * The Jira Cloud platform REST API
3 *
4 * Jira Cloud platform REST API documentation
5 *
6 * The version of the OpenAPI document: 1001.0.0-SNAPSHOT
7 * Contact: ecosystem@atlassian.com
8 * Generated by: https://openapi-generator.tech
9 */
10
11/// ApplicationRole : Details of an application role.
12
13
14
15#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)]
16pub struct ApplicationRole {
17    /// The key of the application role.
18    #[serde(rename = "key", skip_serializing_if = "Option::is_none")]
19    pub key: Option<String>,
20    /// The groups associated with the application role. As a group's name can change, use of `groupDetails` is recommended to identify a groups.
21    #[serde(rename = "groups", skip_serializing_if = "Option::is_none")]
22    pub groups: Option<Vec<String>>,
23    /// The groups associated with the application role.
24    #[serde(rename = "groupDetails", skip_serializing_if = "Option::is_none")]
25    pub group_details: Option<Vec<crate::models::GroupName>>,
26    /// The display name of the application role.
27    #[serde(rename = "name", skip_serializing_if = "Option::is_none")]
28    pub name: Option<String>,
29    /// The groups that are granted default access for this application role. As a group's name can change, use of `defaultGroupsDetails` is recommended to identify a groups.
30    #[serde(rename = "defaultGroups", skip_serializing_if = "Option::is_none")]
31    pub default_groups: Option<Vec<String>>,
32    /// The groups that are granted default access for this application role.
33    #[serde(rename = "defaultGroupsDetails", skip_serializing_if = "Option::is_none")]
34    pub default_groups_details: Option<Vec<crate::models::GroupName>>,
35    /// Determines whether this application role should be selected by default on user creation.
36    #[serde(rename = "selectedByDefault", skip_serializing_if = "Option::is_none")]
37    pub selected_by_default: Option<bool>,
38    /// Deprecated.
39    #[serde(rename = "defined", skip_serializing_if = "Option::is_none")]
40    pub defined: Option<bool>,
41    /// The maximum count of users on your license.
42    #[serde(rename = "numberOfSeats", skip_serializing_if = "Option::is_none")]
43    pub number_of_seats: Option<i32>,
44    /// The count of users remaining on your license.
45    #[serde(rename = "remainingSeats", skip_serializing_if = "Option::is_none")]
46    pub remaining_seats: Option<i32>,
47    /// The number of users counting against your license.
48    #[serde(rename = "userCount", skip_serializing_if = "Option::is_none")]
49    pub user_count: Option<i32>,
50    /// The [type of users](https://confluence.atlassian.com/x/lRW3Ng) being counted against your license.
51    #[serde(rename = "userCountDescription", skip_serializing_if = "Option::is_none")]
52    pub user_count_description: Option<String>,
53    #[serde(rename = "hasUnlimitedSeats", skip_serializing_if = "Option::is_none")]
54    pub has_unlimited_seats: Option<bool>,
55    /// Indicates if the application role belongs to Jira platform (`jira-core`).
56    #[serde(rename = "platform", skip_serializing_if = "Option::is_none")]
57    pub platform: Option<bool>,
58}
59
60impl ApplicationRole {
61    /// Details of an application role.
62    pub fn new() -> ApplicationRole {
63        ApplicationRole {
64            key: None,
65            groups: None,
66            group_details: None,
67            name: None,
68            default_groups: None,
69            default_groups_details: None,
70            selected_by_default: None,
71            defined: None,
72            number_of_seats: None,
73            remaining_seats: None,
74            user_count: None,
75            user_count_description: None,
76            has_unlimited_seats: None,
77            platform: None,
78        }
79    }
80}
81
82