artifact-keeper-client 1.2.1

Rust client for the Artifact Keeper REST API
Documentation
/*
 * Artifact Keeper API
 *
 * Enterprise artifact registry supporting 45+ package formats.
 *
 * The version of the OpenAPI document: 1.2.1
 * 
 * Generated by: https://openapi-generator.tech
 */

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

#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
pub struct UpdateOidcConfigRequest {
    /// Partial update for `attribute_mapping`. Keys present in this object overwrite the matching keys in the stored mapping. Keys not present are preserved. To remove a key, set it to `null`. To replace the whole mapping atomically, set `attribute_mapping_replace = true`. (See issue #1191.)
    #[serde(rename = "attribute_mapping", default, with = "::serde_with::rust::double_option", skip_serializing_if = "Option::is_none")]
    pub attribute_mapping: Option<Option<serde_json::Value>>,
    /// When `true`, treat `attribute_mapping` as a wholesale replacement (legacy behavior). Defaults to `false` — partial merge.
    #[serde(rename = "attribute_mapping_replace", default, with = "::serde_with::rust::double_option", skip_serializing_if = "Option::is_none")]
    pub attribute_mapping_replace: Option<Option<bool>>,
    #[serde(rename = "auto_create_users", default, with = "::serde_with::rust::double_option", skip_serializing_if = "Option::is_none")]
    pub auto_create_users: Option<Option<bool>>,
    #[serde(rename = "client_id", default, with = "::serde_with::rust::double_option", skip_serializing_if = "Option::is_none")]
    pub client_id: Option<Option<String>>,
    #[serde(rename = "client_secret", default, with = "::serde_with::rust::double_option", skip_serializing_if = "Option::is_none")]
    pub client_secret: Option<Option<String>>,
    #[serde(rename = "is_enabled", default, with = "::serde_with::rust::double_option", skip_serializing_if = "Option::is_none")]
    pub is_enabled: Option<Option<bool>>,
    #[serde(rename = "issuer_url", default, with = "::serde_with::rust::double_option", skip_serializing_if = "Option::is_none")]
    pub issuer_url: Option<Option<String>>,
    #[serde(rename = "map_groups_to_groups", default, with = "::serde_with::rust::double_option", skip_serializing_if = "Option::is_none")]
    pub map_groups_to_groups: Option<Option<bool>>,
    #[serde(rename = "name", default, with = "::serde_with::rust::double_option", skip_serializing_if = "Option::is_none")]
    pub name: Option<Option<String>>,
    #[serde(rename = "pkce_enabled", default, with = "::serde_with::rust::double_option", skip_serializing_if = "Option::is_none")]
    pub pkce_enabled: Option<Option<bool>>,
    #[serde(rename = "scopes", default, with = "::serde_with::rust::double_option", skip_serializing_if = "Option::is_none")]
    pub scopes: Option<Option<Vec<String>>>,
}

impl UpdateOidcConfigRequest {
    pub fn new() -> UpdateOidcConfigRequest {
        UpdateOidcConfigRequest {
            attribute_mapping: None,
            attribute_mapping_replace: None,
            auto_create_users: None,
            client_id: None,
            client_secret: None,
            is_enabled: None,
            issuer_url: None,
            map_groups_to_groups: None,
            name: None,
            pkce_enabled: None,
            scopes: None,
        }
    }
}