windmill-api 1.684.1

No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
Documentation
/*
 * Windmill API
 *
 * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
 *
 * The version of the OpenAPI document: 1.684.1
 * Contact: contact@windmill.dev
 * Generated by: https://openapi-generator.tech
 */

use crate::models;
use serde::{Deserialize, Serialize};

#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
pub struct VaultSettings {
    /// HashiCorp Vault server address (e.g., https://vault.company.com:8200)
    #[serde(rename = "address")]
    pub address: String,
    /// KV v2 secrets engine mount path (e.g., windmill)
    #[serde(rename = "mount_path")]
    pub mount_path: String,
    /// Vault JWT auth role name for Windmill (optional, if not provided token auth is used)
    #[serde(rename = "jwt_role", skip_serializing_if = "Option::is_none")]
    pub jwt_role: Option<String>,
    /// Vault Enterprise namespace (optional)
    #[serde(rename = "namespace", skip_serializing_if = "Option::is_none")]
    pub namespace: Option<String>,
    /// Static Vault token for testing/development (optional, if provided this is used instead of JWT authentication)
    #[serde(rename = "token", skip_serializing_if = "Option::is_none")]
    pub token: Option<String>,
    /// Skip TLS certificate verification when connecting to Vault. Only use for self-signed certificates in development environments.
    #[serde(rename = "skip_ssl_verify", skip_serializing_if = "Option::is_none")]
    pub skip_ssl_verify: Option<bool>,
}

impl VaultSettings {
    pub fn new(address: String, mount_path: String) -> VaultSettings {
        VaultSettings {
            address,
            mount_path,
            jwt_role: None,
            namespace: None,
            token: None,
            skip_ssl_verify: None,
        }
    }
}