hanzo_client/models/project_view.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 ProjectView {
16 /// Applications is how many platform apps this org has under the project, counted per request. It is the one fact IAM cannot answer about a project.
17 #[serde(rename = "applications", skip_serializing_if = "Option::is_none")]
18 pub applications: Option<i32>,
19 /// CreatedAt is IAM's creation time as unix seconds. 0 when IAM's timestamp is absent or unparseable — never a fabricated time.
20 #[serde(rename = "createdAt", skip_serializing_if = "Option::is_none")]
21 pub created_at: Option<i32>,
22 /// Description is IAM's free text about the project. Nothing derives from it.
23 #[serde(rename = "description", skip_serializing_if = "Option::is_none")]
24 pub description: Option<String>,
25 /// Name is IAM's display name, falling back to the slug when the project has none, so this is never empty.
26 #[serde(rename = "name", skip_serializing_if = "Option::is_none")]
27 pub name: Option<String>,
28 /// Org is the project's IAM owner, and the tenant every app under it deploys into. It comes from the validated identity, never from the request.
29 #[serde(rename = "org", skip_serializing_if = "Option::is_none")]
30 pub org: Option<String>,
31 /// Slug is the project's IAM name — half of the (org,name) identity, the `:project` path segment, and the scope key an app is filed under. It is the project's address; Name is not.
32 #[serde(rename = "slug", skip_serializing_if = "Option::is_none")]
33 pub slug: Option<String>,
34}
35
36impl ProjectView {
37 pub fn new() -> ProjectView {
38 ProjectView {
39 applications: None,
40 created_at: None,
41 description: None,
42 name: None,
43 org: None,
44 slug: None,
45 }
46 }
47}
48