autogen-stedi 0.3.2

Auto-generated, strongly-typed Rust client for the Stedi APIs
Documentation
/*
 * Core
 *
 * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
 *
 * The version of the OpenAPI document: 2023-08-01
 * Contact: core@stedi.com
 * Generated by: https://openapi-generator.tech
 */

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

#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
pub struct Artifact {
    #[serde(rename = "artifactType")]
    pub artifact_type: models::ArtifactType,
    #[serde(rename = "usage")]
    pub usage: models::ArtifactUsage,
    /// The size of the artifact in bytes.
    #[serde(rename = "sizeBytes")]
    pub size_bytes: f64,
    /// A URL to download the artifact.
    #[serde(rename = "url")]
    pub url: String,
    #[serde(rename = "model")]
    pub model: models::ArtifactModel,
}

impl Artifact {
    pub fn new(artifact_type: models::ArtifactType, usage: models::ArtifactUsage, size_bytes: f64, url: String, model: models::ArtifactModel) -> Artifact {
        Artifact {
            artifact_type,
            usage,
            size_bytes,
            url,
            model,
        }
    }
}