late 0.0.297

API reference for Zernio. Authenticate with a Bearer API key. Base URL: https://zernio.com/api
Documentation
/*
 * Zernio API
 *
 * API reference for Zernio. Authenticate with a Bearer API key. Base URL: https://zernio.com/api
 *
 * The version of the OpenAPI document: 1.0.4
 * Contact: support@zernio.com
 * Generated by: https://openapi-generator.tech
 */

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

/// BusinessCenter : TikTok Business Center entity. Returned by `GET /v1/ads/business-centers`. BCs are TikTok's agency container — one BC owns N advertisers (ad accounts). Most solo advertisers don't have one; the agency token uses BCs to roll up multi-client access.
#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
pub struct BusinessCenter {
    /// Business Center ID
    #[serde(rename = "bcId", skip_serializing_if = "Option::is_none")]
    pub bc_id: Option<String>,
    /// Display name set by the BC owner
    #[serde(rename = "name", skip_serializing_if = "Option::is_none")]
    pub name: Option<String>,
    /// Number of advertisers reachable under this BC for the calling token. `null` when the BC asset walk returned empty or failed (typical for agency apps without full BC asset read scope) — distinct from `0`, which would imply the BC genuinely has no advertisers.
    #[serde(rename = "advertiserCount", skip_serializing_if = "Option::is_none")]
    pub advertiser_count: Option<i32>,
}

impl BusinessCenter {
    /// TikTok Business Center entity. Returned by `GET /v1/ads/business-centers`. BCs are TikTok's agency container — one BC owns N advertisers (ad accounts). Most solo advertisers don't have one; the agency token uses BCs to roll up multi-client access.
    pub fn new() -> BusinessCenter {
        BusinessCenter {
            bc_id: None,
            name: None,
            advertiser_count: None,
        }
    }
}