hanzo_client/models/projects_deploy_start.rs
1/*
2 * Hanzo Cloud API
3 *
4 * 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/.
5 *
6 * The version of the OpenAPI document: v1
7 *
8 * Generated by: https://openapi-generator.tech
9 */
10
11use crate::models;
12use serde::{Deserialize, Serialize};
13
14#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
15pub struct ProjectsDeployStart {
16 /// Commit is the git sha this build was produced from, recorded on the deployment so a released site can be traced back to its source. Optional. It is the ONLY field here, and deliberately: the predecessor also accepted `source` and `branch`. `source` was the Content-Type discriminator this split removed. `branch` was accepted and DISCARDED — there is no branch column on a deployment, and the lifecycle event derives the branch from the project's own linked one — so declaring it would publish a settable field that does nothing into the document, every generated SDK and the MCP input schema. A field that is read by nothing is not described as if it were. `url:\"-\"` because zip binds the query string OVER a decoded body, so without it a `?commit=` the caller never sent would outrank the one it did.
17 #[serde(rename = "commit", skip_serializing_if = "Option::is_none")]
18 pub commit: Option<String>,
19 /// Slug is the site to deploy, from the path.
20 #[serde(rename = "slug", skip_serializing_if = "Option::is_none")]
21 pub slug: Option<String>,
22}
23
24impl ProjectsDeployStart {
25 pub fn new() -> ProjectsDeployStart {
26 ProjectsDeployStart {
27 commit: None,
28 slug: None,
29 }
30 }
31}
32