rusty-box 0.2.0-alpha

Box.com API wrapper
Documentation
/*
 * Box Platform API
 *
 * [Box Platform](https://box.dev) provides functionality to provide access to content stored within [Box](https://box.com). It provides endpoints for basic manipulation of files and folders, management of users within an enterprise, as well as more complex topics such as legal holds and retention policies.
 *
 * The version of the OpenAPI document: 2.0.0
 * Contact: devrel@box.com
 * Generated by: https://openapi-generator.tech
 */

/// TrackingCode : Tracking codes allow an admin to generate reports from the admin console and assign an attribute to a specific group of users. This setting must be enabled for an enterprise before it can be used.

#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)]
pub struct TrackingCode {
    /// `tracking_code`
    #[serde(rename = "type", skip_serializing_if = "Option::is_none")]
    pub r#type: Option<RHashType>,
    /// The name of the tracking code, which must be preconfigured in the Admin Console
    #[serde(rename = "name", skip_serializing_if = "Option::is_none")]
    pub name: Option<String>,
    /// The value of the tracking code
    #[serde(rename = "value", skip_serializing_if = "Option::is_none")]
    pub value: Option<String>,
}

impl TrackingCode {
    /// Tracking codes allow an admin to generate reports from the admin console and assign an attribute to a specific group of users. This setting must be enabled for an enterprise before it can be used.
    pub fn new() -> TrackingCode {
        TrackingCode {
            r#type: None,
            name: None,
            value: None,
        }
    }
}

/// `tracking_code`
#[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash, Serialize, Deserialize)]
pub enum RHashType {
    #[serde(rename = "tracking_code")]
    TrackingCode,
}

impl Default for RHashType {
    fn default() -> RHashType {
        Self::TrackingCode
    }
}