Skip to main content

akeyless_api/models/
target_create_global_sign.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 TargetCreateGlobalSign {
16    /// Email of the GlobalSign GCC account contact
17    #[serde(rename = "contact-email")]
18    pub contact_email: String,
19    /// First name of the GlobalSign GCC account contact
20    #[serde(rename = "contact-first-name")]
21    pub contact_first_name: String,
22    /// Last name of the GlobalSign GCC account contact
23    #[serde(rename = "contact-last-name")]
24    pub contact_last_name: String,
25    /// Telephone of the GlobalSign GCC account contact
26    #[serde(rename = "contact-phone")]
27    pub contact_phone: String,
28    /// Description of the object
29    #[serde(rename = "description", skip_serializing_if = "Option::is_none")]
30    pub description: Option<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 target 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    /// Target name
41    #[serde(rename = "name")]
42    pub name: String,
43    /// Password of the GlobalSign GCC account
44    #[serde(rename = "password")]
45    pub password: String,
46    /// Profile ID of the GlobalSign GCC account
47    #[serde(rename = "profile-id")]
48    pub profile_id: String,
49    /// Timeout waiting for certificate validation in Duration format (1h - 1 Hour, 20m - 20 Minutes, 33m3s - 33 Minutes and 3 Seconds), maximum 1h.
50    #[serde(rename = "timeout", skip_serializing_if = "Option::is_none")]
51    pub timeout: Option<String>,
52    /// Authentication token (see `/auth` and `/configure`)
53    #[serde(rename = "token", skip_serializing_if = "Option::is_none")]
54    pub token: Option<String>,
55    /// The universal identity token, Required only for universal_identity authentication
56    #[serde(rename = "uid-token", skip_serializing_if = "Option::is_none")]
57    pub uid_token: Option<String>,
58    /// Username of the GlobalSign GCC account
59    #[serde(rename = "username")]
60    pub username: String,
61}
62
63impl TargetCreateGlobalSign {
64    pub fn new(contact_email: String, contact_first_name: String, contact_last_name: String, contact_phone: String, name: String, password: String, profile_id: String, username: String) -> TargetCreateGlobalSign {
65        TargetCreateGlobalSign {
66            contact_email,
67            contact_first_name,
68            contact_last_name,
69            contact_phone,
70            description: None,
71            json: None,
72            key: None,
73            max_versions: None,
74            name,
75            password,
76            profile_id,
77            timeout: None,
78            token: None,
79            uid_token: None,
80            username,
81        }
82    }
83}
84