linkbreakers 1.81.4

Official Rust SDK for the Linkbreakers API
Documentation
/*
 * Linkbreakers API
 *
 * This is a documentation of all the APIs of Linkbreakers
 *
 * The version of the OpenAPI document: 1.81.4
 * 
 * Generated by: https://openapi-generator.tech
 */

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

/// CustomDomain : Captures a branded hostname that Linkbreakers provisions for a workspace so scans and shortlinks resolve under the customer's domain, including verification and certificate lifecycle state.
#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
pub struct CustomDomain {
    /// Timestamp when the domain became active after passing verification and certificate checks.
    #[serde(rename = "activatedAt", skip_serializing_if = "Option::is_none")]
    pub activated_at: Option<String>,
    #[serde(rename = "createdAt", skip_serializing_if = "Option::is_none")]
    pub created_at: Option<String>,
    #[serde(rename = "id", skip_serializing_if = "Option::is_none")]
    pub id: Option<String>,
    #[serde(rename = "lastCheckedAt", skip_serializing_if = "Option::is_none")]
    pub last_checked_at: Option<String>,
    #[serde(rename = "name", skip_serializing_if = "Option::is_none")]
    pub name: Option<String>,
    /// URL where visitors are redirected when accessing your custom domain without a path (e.g., qr.yourdomain.com). This redirect is not tracked and serves purely for white-label purposes—preventing visitors from seeing linkbreakers.com branding. If not specified, redirects to linkbreakers.com by default.
    #[serde(rename = "rootDestination", skip_serializing_if = "Option::is_none")]
    pub root_destination: Option<String>,
    /// The status of a custom domain   - STATUS_UNSPECIFIED: The status is not specified  - STATUS_INACTIVE: The domain is inactive. It was created but not checked yet.  - STATUS_DOMAIN_PENDING: The domain is pending. Last time it was checked, it was not pointing to the correct Linkbreakers subdomain.  - STATUS_VERIFICATION_PENDING: The domain is pending verification. Please verify through TXT record.  - STATUS_CERTIFICATE_PENDING: The domain is pending certificate. The SSL certificate is not yet ready.  - STATUS_ACTIVE: The domain is fully active
    #[serde(rename = "status", skip_serializing_if = "Option::is_none")]
    pub status: Option<Status>,
    #[serde(rename = "updatedAt", skip_serializing_if = "Option::is_none")]
    pub updated_at: Option<String>,
    #[serde(rename = "workspaceId", skip_serializing_if = "Option::is_none")]
    pub workspace_id: Option<String>,
}

impl CustomDomain {
    /// Captures a branded hostname that Linkbreakers provisions for a workspace so scans and shortlinks resolve under the customer's domain, including verification and certificate lifecycle state.
    pub fn new() -> CustomDomain {
        CustomDomain {
            activated_at: None,
            created_at: None,
            id: None,
            last_checked_at: None,
            name: None,
            root_destination: None,
            status: None,
            updated_at: None,
            workspace_id: None,
        }
    }
}
/// The status of a custom domain   - STATUS_UNSPECIFIED: The status is not specified  - STATUS_INACTIVE: The domain is inactive. It was created but not checked yet.  - STATUS_DOMAIN_PENDING: The domain is pending. Last time it was checked, it was not pointing to the correct Linkbreakers subdomain.  - STATUS_VERIFICATION_PENDING: The domain is pending verification. Please verify through TXT record.  - STATUS_CERTIFICATE_PENDING: The domain is pending certificate. The SSL certificate is not yet ready.  - STATUS_ACTIVE: The domain is fully active
#[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash, Serialize, Deserialize)]
pub enum Status {
    #[serde(rename = "STATUS_UNSPECIFIED")]
    StatusUnspecified,
    #[serde(rename = "STATUS_INACTIVE")]
    StatusInactive,
    #[serde(rename = "STATUS_DOMAIN_PENDING")]
    StatusDomainPending,
    #[serde(rename = "STATUS_VERIFICATION_PENDING")]
    StatusVerificationPending,
    #[serde(rename = "STATUS_CERTIFICATE_PENDING")]
    StatusCertificatePending,
    #[serde(rename = "STATUS_ACTIVE")]
    StatusActive,
}

impl Default for Status {
    fn default() -> Status {
        Self::StatusUnspecified
    }
}