hanzo-client 8.5.156

Generated client for the Hanzo API — every service, one crate.
Documentation
/*
 * Hanzo Cloud API
 *
 * The Hanzo Cloud API as a customer calls it: every operation under /v1/ except the operator's admin product, relay routes, legacy spellings and capabilities still reached by flag. Tagged by product: the first path segment after /v1/.
 *
 * The version of the OpenAPI document: v1
 * 
 * Generated by: https://openapi-generator.tech
 */

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

#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
pub struct BotView {
    /// Agent is the cloud Agent this machine runs, lifted out of the binding so a list of bots reads without following one. Empty means the machine is a bot machine with nothing bound — it costs money and answers nothing.
    #[serde(rename = "agent", skip_serializing_if = "Option::is_none")]
    pub agent: Option<String>,
    /// Binding is the record joining this machine to that agent, carrying vm's own reconciled status and its reason. Absent means no runtime is bound, which is also what a stopped bot looks like: stopping unbinds and leaves the machine running.
    #[serde(rename = "binding", skip_serializing_if = "Option::is_none")]
    pub binding: Option<Box<models::AgentBinding>>,
    #[serde(rename = "createdTime", skip_serializing_if = "Option::is_none")]
    pub created_time: Option<String>,
    #[serde(rename = "gpu", skip_serializing_if = "Option::is_none")]
    pub gpu: Option<String>,
    #[serde(rename = "id", skip_serializing_if = "Option::is_none")]
    pub id: Option<String>,
    #[serde(rename = "image", skip_serializing_if = "Option::is_none")]
    pub image: Option<String>,
    #[serde(rename = "mem", skip_serializing_if = "Option::is_none")]
    pub mem: Option<String>,
    #[serde(rename = "name", skip_serializing_if = "Option::is_none")]
    pub name: Option<String>,
    #[serde(rename = "os", skip_serializing_if = "Option::is_none")]
    pub os: Option<String>,
    #[serde(rename = "privateIp", skip_serializing_if = "Option::is_none")]
    pub private_ip: Option<String>,
    #[serde(rename = "provider", skip_serializing_if = "Option::is_none")]
    pub provider: Option<String>,
    #[serde(rename = "publicIp", skip_serializing_if = "Option::is_none")]
    pub public_ip: Option<String>,
    #[serde(rename = "region", skip_serializing_if = "Option::is_none")]
    pub region: Option<String>,
    #[serde(rename = "status", skip_serializing_if = "Option::is_none")]
    pub status: Option<String>,
    #[serde(rename = "type", skip_serializing_if = "Option::is_none")]
    pub r#type: Option<String>,
    #[serde(rename = "vcpu", skip_serializing_if = "Option::is_none")]
    pub vcpu: Option<i32>,
}

impl BotView {
    pub fn new() -> BotView {
        BotView {
            agent: None,
            binding: None,
            created_time: None,
            gpu: None,
            id: None,
            image: None,
            mem: None,
            name: None,
            os: None,
            private_ip: None,
            provider: None,
            public_ip: None,
            region: None,
            status: None,
            r#type: None,
            vcpu: None,
        }
    }
}