Skip to main content

clientapi_pbs/models/
nodes_subscription_get_subscription_response_data.rs

1/*
2 * Proxmox Backup Server API
3 *
4 * Generated from apidoc.js. NOT an official Proxmox specification. See https://pbs.proxmox.com/docs/api-viewer/ for the upstream documentation.
5 *
6 * The version of the OpenAPI document: 9.x
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 NodesSubscriptionGetSubscriptionResponseData {
16
17    /// timestamp of the last check done
18    #[serde(rename = "checktime", skip_serializing_if = "Option::is_none")]
19    pub checktime: Option<i64>,
20
21    /// the subscription key, if set and permitted to access
22    #[serde(rename = "key", skip_serializing_if = "Option::is_none")]
23    pub key: Option<String>,
24
25    /// a more human readable status message
26    #[serde(rename = "message", skip_serializing_if = "Option::is_none")]
27    pub message: Option<String>,
28
29    /// next due date of the set subscription
30    #[serde(rename = "nextduedate", skip_serializing_if = "Option::is_none")]
31    pub nextduedate: Option<String>,
32
33    /// human readable productname of the set subscription
34    #[serde(rename = "productname", skip_serializing_if = "Option::is_none")]
35    pub productname: Option<String>,
36
37    /// register date of the set subscription
38    #[serde(rename = "regdate", skip_serializing_if = "Option::is_none")]
39    pub regdate: Option<String>,
40
41    /// the server ID, if permitted to access
42    #[serde(rename = "serverid", skip_serializing_if = "Option::is_none")]
43    pub serverid: Option<String>,
44
45    /// Signature for offline keys
46    #[serde(rename = "signature", skip_serializing_if = "Option::is_none")]
47    pub signature: Option<String>,
48
49    /// Subscription status
50    #[serde(rename = "status")]
51    pub status: models::PbsNodesSubscriptionStatusEnum,
52
53    /// URL to the web shop
54    #[serde(rename = "url", skip_serializing_if = "Option::is_none")]
55    pub url: Option<String>,
56
57
58}
59
60impl NodesSubscriptionGetSubscriptionResponseData {
61    pub fn new(status: models::PbsNodesSubscriptionStatusEnum) -> NodesSubscriptionGetSubscriptionResponseData {
62        NodesSubscriptionGetSubscriptionResponseData {
63            
64            checktime: None,
65            
66            key: None,
67            
68            message: None,
69            
70            nextduedate: None,
71            
72            productname: None,
73            
74            regdate: None,
75            
76            serverid: None,
77            
78            signature: None,
79            
80            status,
81            
82            url: None,
83            
84        }
85    }
86}
87
88