Skip to main content

akeyless_api/models/
rotated_secret_create_mysql.rs

1/*
2 * Akeyless API
3 *
4 * The purpose of this application is to provide access to Akeyless API.
5 *
6 * The version of the OpenAPI document: 3.0
7 * Contact: support@akeyless.io
8 * Generated by: https://openapi-generator.tech
9 */
10
11use crate::models;
12use serde::{Deserialize, Serialize};
13
14#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
15pub struct RotatedSecretCreateMysql {
16    /// The credentials to connect with use-user-creds/use-target-creds
17    #[serde(rename = "authentication-credentials", skip_serializing_if = "Option::is_none")]
18    pub authentication_credentials: Option<String>,
19    /// Whether to automatically rotate every --rotation-interval days, or disable existing automatic rotation [true/false]
20    #[serde(rename = "auto-rotate", skip_serializing_if = "Option::is_none")]
21    pub auto_rotate: Option<String>,
22    /// Protection from accidental deletion of this object [true/false]
23    #[serde(rename = "delete_protection", skip_serializing_if = "Option::is_none")]
24    pub delete_protection: Option<String>,
25    /// Description of the object
26    #[serde(rename = "description", skip_serializing_if = "Option::is_none")]
27    pub description: Option<String>,
28    /// Additional custom fields to associate with the item
29    #[serde(rename = "item-custom-fields", skip_serializing_if = "Option::is_none")]
30    pub item_custom_fields: Option<std::collections::HashMap<String, String>>,
31    /// Set output format to JSON
32    #[serde(rename = "json", skip_serializing_if = "Option::is_none")]
33    pub json: Option<bool>,
34    /// The name of a key that used to encrypt the secret value (if empty, the account default protectionKey key will be used)
35    #[serde(rename = "key", skip_serializing_if = "Option::is_none")]
36    pub key: Option<String>,
37    /// Set the maximum number of versions, limited by the account settings defaults.
38    #[serde(rename = "max-versions", skip_serializing_if = "Option::is_none")]
39    pub max_versions: Option<String>,
40    /// Rotated secret name
41    #[serde(rename = "name")]
42    pub name: String,
43    /// The length of the password to be generated
44    #[serde(rename = "password-length", skip_serializing_if = "Option::is_none")]
45    pub password_length: Option<String>,
46    /// Rotate the value of the secret after SRA session ends [true/false]
47    #[serde(rename = "rotate-after-disconnect", skip_serializing_if = "Option::is_none")]
48    pub rotate_after_disconnect: Option<String>,
49    /// rotated-username password (relevant only for rotator-type=password)
50    #[serde(rename = "rotated-password", skip_serializing_if = "Option::is_none")]
51    pub rotated_password: Option<String>,
52    /// username to be rotated, if selected use-self-creds at rotator-creds-type, this username will try to rotate it's own password, if use-target-creds is selected, target credentials will be use to rotate the rotated-password (relevant only for rotator-type=password)
53    #[serde(rename = "rotated-username", skip_serializing_if = "Option::is_none")]
54    pub rotated_username: Option<String>,
55    /// How many days before the rotation of the item would you like to be notified
56    #[serde(rename = "rotation-event-in", skip_serializing_if = "Option::is_none")]
57    pub rotation_event_in: Option<Vec<String>>,
58    /// The Hour of the rotation in UTC
59    #[serde(rename = "rotation-hour", skip_serializing_if = "Option::is_none")]
60    pub rotation_hour: Option<i32>,
61    /// The number of days to wait between every automatic key rotation (1-365)
62    #[serde(rename = "rotation-interval", skip_serializing_if = "Option::is_none")]
63    pub rotation_interval: Option<String>,
64    /// The rotator type. options: [target/password]
65    #[serde(rename = "rotator-type")]
66    pub rotator_type: String,
67    /// Deprecated. use secure-access-certificate-issuer
68    #[serde(rename = "secure-access-bastion-issuer", skip_serializing_if = "Option::is_none")]
69    pub secure_access_bastion_issuer: Option<String>,
70    /// Path to the SSH Certificate Issuer for your Akeyless Secure Access
71    #[serde(rename = "secure-access-certificate-issuer", skip_serializing_if = "Option::is_none")]
72    pub secure_access_certificate_issuer: Option<String>,
73    /// The DB name (relevant only for DB Dynamic-Secret)
74    #[serde(rename = "secure-access-db-name", skip_serializing_if = "Option::is_none")]
75    pub secure_access_db_name: Option<String>,
76    /// Enable/Disable secure remote access [true/false]
77    #[serde(rename = "secure-access-enable", skip_serializing_if = "Option::is_none")]
78    pub secure_access_enable: Option<String>,
79    /// Target servers for connections (In case of Linked Target association, host(s) will inherit Linked Target hosts - Relevant only for Dynamic Secrets/producers)
80    #[serde(rename = "secure-access-host", skip_serializing_if = "Option::is_none")]
81    pub secure_access_host: Option<Vec<String>>,
82    /// Enable Web Secure Remote Access
83    #[serde(rename = "secure-access-web", skip_serializing_if = "Option::is_none")]
84    pub secure_access_web: Option<bool>,
85    /// Add tags attached to this object
86    #[serde(rename = "tags", skip_serializing_if = "Option::is_none")]
87    pub tags: Option<Vec<String>>,
88    /// The target name to associate
89    #[serde(rename = "target-name")]
90    pub target_name: String,
91    /// Authentication token (see `/auth` and `/configure`)
92    #[serde(rename = "token", skip_serializing_if = "Option::is_none")]
93    pub token: Option<String>,
94    /// The universal identity token, Required only for universal_identity authentication
95    #[serde(rename = "uid-token", skip_serializing_if = "Option::is_none")]
96    pub uid_token: Option<String>,
97}
98
99impl RotatedSecretCreateMysql {
100    pub fn new(name: String, rotator_type: String, target_name: String) -> RotatedSecretCreateMysql {
101        RotatedSecretCreateMysql {
102            authentication_credentials: None,
103            auto_rotate: None,
104            delete_protection: None,
105            description: None,
106            item_custom_fields: None,
107            json: None,
108            key: None,
109            max_versions: None,
110            name,
111            password_length: None,
112            rotate_after_disconnect: None,
113            rotated_password: None,
114            rotated_username: None,
115            rotation_event_in: None,
116            rotation_hour: None,
117            rotation_interval: None,
118            rotator_type,
119            secure_access_bastion_issuer: None,
120            secure_access_certificate_issuer: None,
121            secure_access_db_name: None,
122            secure_access_enable: None,
123            secure_access_host: None,
124            secure_access_web: None,
125            tags: None,
126            target_name,
127            token: None,
128            uid_token: None,
129        }
130    }
131}
132