mirror of
https://github.com/hanzo-cpp/sdk.git
synced 2026-11-20 19:55:32 +00:00
The projection these were generated from was a month old and predated the compute migration, so every one of them described /v1/visor — which the API serves at zero paths now. That is why a hand-written console client and a generated one had drifted the same way at the same time. No /v1/visor path survives here. The word still appears as a source-plane value and inside gvisor and supervisor, which are not this rename.
231 lines
6.7 KiB
C++
231 lines
6.7 KiB
C++
/**
|
|
* 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
|
|
*
|
|
* NOTE: This class is auto generated by OpenAPI-Generator 7.14.0.
|
|
* https://openapi-generator.tech
|
|
* Do not edit the class manually.
|
|
*/
|
|
|
|
/*
|
|
* ProjectsDeployment.h
|
|
*
|
|
*
|
|
*/
|
|
|
|
#ifndef HANZO_MODEL_ProjectsDeployment_H_
|
|
#define HANZO_MODEL_ProjectsDeployment_H_
|
|
|
|
#include <boost/optional.hpp>
|
|
|
|
#include "hanzo/ModelBase.h"
|
|
|
|
#include "hanzo/model/ProjectsUploadGrant.h"
|
|
#include <cpprest/details/basic_types.h>
|
|
|
|
namespace hanzo {
|
|
namespace model {
|
|
|
|
class ProjectsUploadGrant;
|
|
|
|
|
|
class ProjectsDeployment
|
|
: public ModelBase
|
|
{
|
|
public:
|
|
ProjectsDeployment();
|
|
virtual ~ProjectsDeployment();
|
|
|
|
/////////////////////////////////////////////
|
|
/// ModelBase overrides
|
|
|
|
void validate() override;
|
|
|
|
web::json::value toJson() const override;
|
|
bool fromJson(const web::json::value& json) override;
|
|
|
|
void toMultipart(std::shared_ptr<MultipartFormData> multipart, const utility::string_t& namePrefix) const override;
|
|
bool fromMultiPart(std::shared_ptr<MultipartFormData> multipart, const utility::string_t& namePrefix) override;
|
|
|
|
|
|
/////////////////////////////////////////////
|
|
/// ProjectsDeployment members
|
|
|
|
|
|
/// <summary>
|
|
/// Bucket is the object-store bucket its files were written to.
|
|
/// </summary>
|
|
utility::string_t getBucket() const;
|
|
bool bucketIsSet() const;
|
|
void unsetBucket();
|
|
void setBucket(const utility::string_t& value);
|
|
|
|
/// <summary>
|
|
/// Bytes is their total size in bytes.
|
|
/// </summary>
|
|
int64_t getBytes() const;
|
|
bool bytesIsSet() const;
|
|
void unsetBytes();
|
|
void setBytes(int64_t value);
|
|
|
|
/// <summary>
|
|
/// Commit is the revision that was built, for a deployment that came from a repository. Absent for an uploaded artifact, which has no revision.
|
|
/// </summary>
|
|
utility::string_t getCommit() const;
|
|
bool commitIsSet() const;
|
|
void unsetCommit();
|
|
void setCommit(const utility::string_t& value);
|
|
|
|
/// <summary>
|
|
/// CreatedAt is when the deployment was queued, as Unix seconds.
|
|
/// </summary>
|
|
int64_t getCreatedAt() const;
|
|
bool createdAtIsSet() const;
|
|
void unsetCreatedAt();
|
|
void setCreatedAt(int64_t value);
|
|
|
|
/// <summary>
|
|
/// Files is how many objects the deployment published.
|
|
/// </summary>
|
|
int64_t getFiles() const;
|
|
bool filesIsSet() const;
|
|
void unsetFiles();
|
|
void setFiles(int64_t value);
|
|
|
|
/// <summary>
|
|
/// ID identifies this one deployment attempt, and is what CI quotes back to complete it.
|
|
/// </summary>
|
|
utility::string_t getId() const;
|
|
bool idIsSet() const;
|
|
void unsetId();
|
|
void setId(const utility::string_t& value);
|
|
|
|
/// <summary>
|
|
/// LiveURL is where this deployment serves, once it is live.
|
|
/// </summary>
|
|
utility::string_t getLiveUrl() const;
|
|
bool liveUrlIsSet() const;
|
|
void unsetLiveUrl();
|
|
void setLiveUrl(const utility::string_t& value);
|
|
|
|
/// <summary>
|
|
/// Message is what happened, in words — the build's own note, or on a failure why it failed.
|
|
/// </summary>
|
|
utility::string_t getMessage() const;
|
|
bool messageIsSet() const;
|
|
void unsetMessage();
|
|
void setMessage(const utility::string_t& value);
|
|
|
|
/// <summary>
|
|
/// Prefix is the key prefix within that bucket holding EXACTLY this deployment's objects — the unit an upload grant is scoped to, so a grant for one deployment cannot write over another.
|
|
/// </summary>
|
|
utility::string_t getPrefix() const;
|
|
bool prefixIsSet() const;
|
|
void unsetPrefix();
|
|
void setPrefix(const utility::string_t& value);
|
|
|
|
/// <summary>
|
|
/// ProjectID is the project this deployment belongs to.
|
|
/// </summary>
|
|
utility::string_t getProjectId() const;
|
|
bool projectIdIsSet() const;
|
|
void unsetProjectId();
|
|
void setProjectId(const utility::string_t& value);
|
|
|
|
/// <summary>
|
|
/// Source is what caused the deployment — a git push, an uploaded artifact, a generated site.
|
|
/// </summary>
|
|
utility::string_t getSource() const;
|
|
bool sourceIsSet() const;
|
|
void unsetSource();
|
|
void setSource(const utility::string_t& value);
|
|
|
|
/// <summary>
|
|
/// Status is where the attempt got to — queued, live, or failed. A deployment that is live is not necessarily the one SERVING: the project's own currentDeploymentId says which is.
|
|
/// </summary>
|
|
utility::string_t getStatus() const;
|
|
bool statusIsSet() const;
|
|
void unsetStatus();
|
|
void setStatus(const utility::string_t& value);
|
|
|
|
/// <summary>
|
|
/// UpdatedAt is when it last changed state, as Unix seconds — so the gap between the two is how long the build took.
|
|
/// </summary>
|
|
int64_t getUpdatedAt() const;
|
|
bool updatedAtIsSet() const;
|
|
void unsetUpdatedAt();
|
|
void setUpdatedAt(int64_t value);
|
|
|
|
/// <summary>
|
|
/// Upload is the prefix-scoped, short-lived S3 write grant handed to CI with a queued git deployment, so it needs no bucket credential (grant.go). Present ONLY on the 202 that creates the deployment — it is never stored and never replayed on a later read, so a grant cannot outlive the build it was minted for by being fetched again.
|
|
/// </summary>
|
|
std::shared_ptr<ProjectsUploadGrant> getUpload() const;
|
|
bool uploadIsSet() const;
|
|
void unsetUpload();
|
|
void setUpload(const std::shared_ptr<ProjectsUploadGrant>& value);
|
|
|
|
/// <summary>
|
|
/// Version counts deployments of this project from 1, so the history reads as an ordered sequence rather than by timestamp. It is per project, not global.
|
|
/// </summary>
|
|
int64_t getVersion() const;
|
|
bool versionIsSet() const;
|
|
void unsetVersion();
|
|
void setVersion(int64_t value);
|
|
|
|
|
|
protected:
|
|
utility::string_t m_Bucket;
|
|
bool m_BucketIsSet;
|
|
|
|
int64_t m_Bytes;
|
|
bool m_BytesIsSet;
|
|
|
|
utility::string_t m_Commit;
|
|
bool m_CommitIsSet;
|
|
|
|
int64_t m_CreatedAt;
|
|
bool m_CreatedAtIsSet;
|
|
|
|
int64_t m_Files;
|
|
bool m_FilesIsSet;
|
|
|
|
utility::string_t m_Id;
|
|
bool m_IdIsSet;
|
|
|
|
utility::string_t m_LiveUrl;
|
|
bool m_LiveUrlIsSet;
|
|
|
|
utility::string_t m_Message;
|
|
bool m_MessageIsSet;
|
|
|
|
utility::string_t m_Prefix;
|
|
bool m_PrefixIsSet;
|
|
|
|
utility::string_t m_ProjectId;
|
|
bool m_ProjectIdIsSet;
|
|
|
|
utility::string_t m_Source;
|
|
bool m_SourceIsSet;
|
|
|
|
utility::string_t m_Status;
|
|
bool m_StatusIsSet;
|
|
|
|
int64_t m_UpdatedAt;
|
|
bool m_UpdatedAtIsSet;
|
|
|
|
std::shared_ptr<ProjectsUploadGrant> m_Upload;
|
|
bool m_UploadIsSet;
|
|
|
|
int64_t m_Version;
|
|
bool m_VersionIsSet;
|
|
|
|
};
|
|
|
|
|
|
}
|
|
}
|
|
|
|
#endif /* HANZO_MODEL_ProjectsDeployment_H_ */
|