Skip to main content

akeyless_api/models/
dynamic_secret_create_redis.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/// DynamicSecretCreateRedis : dynamicSecretCreateRedis is a command that creates Redis dynamic secret
15#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
16pub struct DynamicSecretCreateRedis {
17    /// A JSON array list of redis ACL rules to attach to the created user. For available rules see the ACL CAT command https://redis.io/commands/acl-cat By default the user will have permissions to read all keys '[\"~*\", \"+@read\"]'
18    #[serde(rename = "acl-rules", skip_serializing_if = "Option::is_none")]
19    pub acl_rules: Option<String>,
20    /// Customize how temporary usernames are generated using go template
21    #[serde(rename = "custom-username-template", skip_serializing_if = "Option::is_none")]
22    pub custom_username_template: Option<String>,
23    /// Protection from accidental deletion of this object [true/false]
24    #[serde(rename = "delete_protection", skip_serializing_if = "Option::is_none")]
25    pub delete_protection: Option<String>,
26    /// Description of the object
27    #[serde(rename = "description", skip_serializing_if = "Option::is_none")]
28    pub description: Option<String>,
29    /// Redis Host
30    #[serde(rename = "host", skip_serializing_if = "Option::is_none")]
31    pub host: Option<String>,
32    /// Additional custom fields to associate with the item
33    #[serde(rename = "item-custom-fields", skip_serializing_if = "Option::is_none")]
34    pub item_custom_fields: Option<std::collections::HashMap<String, String>>,
35    /// Set output format to JSON
36    #[serde(rename = "json", skip_serializing_if = "Option::is_none")]
37    pub json: Option<bool>,
38    /// Dynamic secret name
39    #[serde(rename = "name")]
40    pub name: String,
41    /// Redis Password
42    #[serde(rename = "password", skip_serializing_if = "Option::is_none")]
43    pub password: Option<String>,
44    /// The length of the password to be generated
45    #[serde(rename = "password-length", skip_serializing_if = "Option::is_none")]
46    pub password_length: Option<String>,
47    /// Redis Port
48    #[serde(rename = "port", skip_serializing_if = "Option::is_none")]
49    pub port: Option<String>,
50    /// Dynamic producer encryption key
51    #[serde(rename = "producer-encryption-key-name", skip_serializing_if = "Option::is_none")]
52    pub producer_encryption_key_name: Option<String>,
53    /// Enable/Disable SSL [true/false]
54    #[serde(rename = "ssl", skip_serializing_if = "Option::is_none")]
55    pub ssl: Option<bool>,
56    /// SSL CA certificate in base64 encoding generated from a trusted Certificate Authority (CA)
57    #[serde(rename = "ssl-certificate", skip_serializing_if = "Option::is_none")]
58    pub ssl_certificate: Option<String>,
59    /// Add tags attached to this object
60    #[serde(rename = "tags", skip_serializing_if = "Option::is_none")]
61    pub tags: Option<Vec<String>>,
62    /// Target name
63    #[serde(rename = "target-name", skip_serializing_if = "Option::is_none")]
64    pub target_name: Option<String>,
65    /// Authentication token (see `/auth` and `/configure`)
66    #[serde(rename = "token", skip_serializing_if = "Option::is_none")]
67    pub token: Option<String>,
68    /// The universal identity token, Required only for universal_identity authentication
69    #[serde(rename = "uid-token", skip_serializing_if = "Option::is_none")]
70    pub uid_token: Option<String>,
71    /// User TTL
72    #[serde(rename = "user-ttl", skip_serializing_if = "Option::is_none")]
73    pub user_ttl: Option<String>,
74    /// Redis Username
75    #[serde(rename = "username", skip_serializing_if = "Option::is_none")]
76    pub username: Option<String>,
77}
78
79impl DynamicSecretCreateRedis {
80    /// dynamicSecretCreateRedis is a command that creates Redis dynamic secret
81    pub fn new(name: String) -> DynamicSecretCreateRedis {
82        DynamicSecretCreateRedis {
83            acl_rules: None,
84            custom_username_template: None,
85            delete_protection: None,
86            description: None,
87            host: None,
88            item_custom_fields: None,
89            json: None,
90            name,
91            password: None,
92            password_length: None,
93            port: None,
94            producer_encryption_key_name: None,
95            ssl: None,
96            ssl_certificate: None,
97            tags: None,
98            target_name: None,
99            token: None,
100            uid_token: None,
101            user_ttl: None,
102            username: None,
103        }
104    }
105}
106