// Code generated by oagen. DO NOT EDIT.

#[allow(unused_imports)]
use super::*;
#[allow(unused_imports)]
use crate::enums::*;
use serde::{Deserialize, Serialize};
/// A short-lived signed link to download a file, with its `filename` and expiry.
#[derive(Debug, Clone, Serialize, Deserialize)]
pub struct FileLink {
    /// The signed URL to download the file
    pub download_url: String,
    /// The expiration time of the signed URL
    pub expires_in: String,
    /// The name of the file
    pub filename: String,
    /// Durable Retab MIMEData reference for API reuse
    #[serde(skip_serializing_if = "Option::is_none", default)]
    pub mime_data: Option<MimeData>,
}
impl FileLink {
    /// Construct a new `FileLink` with the required fields set.
    #[allow(deprecated)]
    pub fn new(
        download_url: impl Into<String>,
        expires_in: impl Into<String>,
        filename: impl Into<String>,
    ) -> Self {
        Self {
            download_url: download_url.into(),
            expires_in: expires_in.into(),
            filename: filename.into(),
            mime_data: Default::default(),
        }
    }
}
