Skip to main content

mountos_admin_sdk/
types_gen.rs

1// Code generated by gen; DO NOT EDIT.
2
3use serde::{Deserialize, Serialize};
4
5/// Client configuration.
6#[derive(Debug, Clone, Default)]
7pub struct Config {
8    /// Base URL of the appserv provider API, e.g. `https://appserv.example.com`.
9    pub base_url: String,
10    /// Base64-encoded ED25519 private key (32-byte seed or 64-byte seed+public key).
11    pub private_key: String,
12    /// Optional dashboard operator context, signed into each request.
13    pub dashboard_user: Option<DashboardUser>,
14    /// Dedicated HMAC secret for the `X-MountOS-Dashboard-User` header (appserv
15    /// `DASHBOARD_USER_HMAC_KEY`); required when `dashboard_user` is set.
16    pub dashboard_hmac_key: Option<String>,
17}
18
19/// Page-based pagination options.
20#[derive(Debug, Clone, Default)]
21pub struct ListOptions {
22    pub page: Option<i64>,
23    pub limit: Option<i64>,
24}
25
26/// Pagination metadata returned by page-based list endpoints.
27#[derive(Debug, Clone, Deserialize)]
28pub struct PaginationMeta {
29    pub page: i64,
30    pub limit: i64,
31    pub total: i64,
32    #[serde(rename = "totalPages")]
33    pub total_pages: i64,
34}
35
36/// Page-based list response.
37#[derive(Debug, Clone, Deserialize)]
38pub struct PaginatedResponse<T> {
39    pub items: Vec<T>,
40    pub pagination: PaginationMeta,
41}
42
43/// Cursor-based list response.
44#[derive(Debug, Clone, Deserialize)]
45pub struct CursorPaginatedResponse<T> {
46    pub items: Vec<T>,
47    #[serde(rename = "nextCursor")]
48    pub next_cursor: Option<i64>,
49}
50
51/// Identifier returned by create/edit/toggle endpoints.
52#[derive(Debug, Clone, Deserialize)]
53pub struct IdResponse {
54    pub id: i64,
55}
56
57/// `ClientSessionStatus` values accepted/returned on the wire. `UnknownValue` preserves a
58/// value this SDK does not recognize yet, for forward compatibility with
59/// a server that has introduced a new ClientSessionStatus value.
60#[derive(Debug, Clone, PartialEq, Eq)]
61pub enum ClientSessionStatus {
62    Connected,
63    Active,
64    Degraded,
65    Disconnected,
66    Expired,
67    Unknown,
68    /// A value not defined when this SDK was generated.
69    UnknownValue(String),
70}
71
72impl ClientSessionStatus {
73    /// Returns the wire string for this value.
74    pub fn as_str(&self) -> &str {
75        match self {
76            ClientSessionStatus::Connected => "connected",
77            ClientSessionStatus::Active => "active",
78            ClientSessionStatus::Degraded => "degraded",
79            ClientSessionStatus::Disconnected => "disconnected",
80            ClientSessionStatus::Expired => "expired",
81            ClientSessionStatus::Unknown => "unknown",
82            ClientSessionStatus::UnknownValue(s) => s.as_str(),
83        }
84    }
85
86    /// Reports whether this is one of the values defined when this SDK was
87    /// generated (false for `UnknownValue`).
88    pub fn is_known(&self) -> bool {
89        !matches!(self, ClientSessionStatus::UnknownValue(_))
90    }
91}
92
93impl std::fmt::Display for ClientSessionStatus {
94    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
95        f.write_str(self.as_str())
96    }
97}
98
99impl From<&str> for ClientSessionStatus {
100    fn from(s: &str) -> Self {
101        match s {
102            "connected" => ClientSessionStatus::Connected,
103            "active" => ClientSessionStatus::Active,
104            "degraded" => ClientSessionStatus::Degraded,
105            "disconnected" => ClientSessionStatus::Disconnected,
106            "expired" => ClientSessionStatus::Expired,
107            "unknown" => ClientSessionStatus::Unknown,
108            other => ClientSessionStatus::UnknownValue(other.to_string()),
109        }
110    }
111}
112
113impl Serialize for ClientSessionStatus {
114    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
115    where
116        S: serde::Serializer,
117    {
118        serializer.serialize_str(self.as_str())
119    }
120}
121
122impl<'de> Deserialize<'de> for ClientSessionStatus {
123    fn deserialize<D>(deserializer: D) -> Result<Self, D::Error>
124    where
125        D: serde::Deserializer<'de>,
126    {
127        let s = String::deserialize(deserializer)?;
128        Ok(ClientSessionStatus::from(s.as_str()))
129    }
130}
131
132/// `CopysetState` values accepted/returned on the wire. `Unknown` preserves a
133/// value this SDK does not recognize yet, for forward compatibility with
134/// a server that has introduced a new CopysetState value.
135#[derive(Debug, Clone, PartialEq, Eq)]
136pub enum CopysetState {
137    Active,
138    Draining,
139    SyncedDrained,
140    Retired,
141    /// A value not defined when this SDK was generated.
142    Unknown(String),
143}
144
145impl CopysetState {
146    /// Returns the wire string for this value.
147    pub fn as_str(&self) -> &str {
148        match self {
149            CopysetState::Active => "active",
150            CopysetState::Draining => "draining",
151            CopysetState::SyncedDrained => "synced_drained",
152            CopysetState::Retired => "retired",
153            CopysetState::Unknown(s) => s.as_str(),
154        }
155    }
156
157    /// Reports whether this is one of the values defined when this SDK was
158    /// generated (false for `Unknown`).
159    pub fn is_known(&self) -> bool {
160        !matches!(self, CopysetState::Unknown(_))
161    }
162}
163
164impl std::fmt::Display for CopysetState {
165    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
166        f.write_str(self.as_str())
167    }
168}
169
170impl From<&str> for CopysetState {
171    fn from(s: &str) -> Self {
172        match s {
173            "active" => CopysetState::Active,
174            "draining" => CopysetState::Draining,
175            "synced_drained" => CopysetState::SyncedDrained,
176            "retired" => CopysetState::Retired,
177            other => CopysetState::Unknown(other.to_string()),
178        }
179    }
180}
181
182impl Serialize for CopysetState {
183    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
184    where
185        S: serde::Serializer,
186    {
187        serializer.serialize_str(self.as_str())
188    }
189}
190
191impl<'de> Deserialize<'de> for CopysetState {
192    fn deserialize<D>(deserializer: D) -> Result<Self, D::Error>
193    where
194        D: serde::Deserializer<'de>,
195    {
196        let s = String::deserialize(deserializer)?;
197        Ok(CopysetState::from(s.as_str()))
198    }
199}
200
201/// `LicenseQuotaState` values accepted/returned on the wire. `Unknown` preserves a
202/// value this SDK does not recognize yet, for forward compatibility with
203/// a server that has introduced a new LicenseQuotaState value.
204#[derive(Debug, Clone, PartialEq, Eq)]
205pub enum LicenseQuotaState {
206    Ok,
207    Exceeded,
208    /// A value not defined when this SDK was generated.
209    Unknown(String),
210}
211
212impl LicenseQuotaState {
213    /// Returns the wire string for this value.
214    pub fn as_str(&self) -> &str {
215        match self {
216            LicenseQuotaState::Ok => "ok",
217            LicenseQuotaState::Exceeded => "exceeded",
218            LicenseQuotaState::Unknown(s) => s.as_str(),
219        }
220    }
221
222    /// Reports whether this is one of the values defined when this SDK was
223    /// generated (false for `Unknown`).
224    pub fn is_known(&self) -> bool {
225        !matches!(self, LicenseQuotaState::Unknown(_))
226    }
227}
228
229impl std::fmt::Display for LicenseQuotaState {
230    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
231        f.write_str(self.as_str())
232    }
233}
234
235impl From<&str> for LicenseQuotaState {
236    fn from(s: &str) -> Self {
237        match s {
238            "ok" => LicenseQuotaState::Ok,
239            "exceeded" => LicenseQuotaState::Exceeded,
240            other => LicenseQuotaState::Unknown(other.to_string()),
241        }
242    }
243}
244
245impl Serialize for LicenseQuotaState {
246    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
247    where
248        S: serde::Serializer,
249    {
250        serializer.serialize_str(self.as_str())
251    }
252}
253
254impl<'de> Deserialize<'de> for LicenseQuotaState {
255    fn deserialize<D>(deserializer: D) -> Result<Self, D::Error>
256    where
257        D: serde::Deserializer<'de>,
258    {
259        let s = String::deserialize(deserializer)?;
260        Ok(LicenseQuotaState::from(s.as_str()))
261    }
262}
263
264/// `LicenseStatus` values accepted/returned on the wire. `Unknown` preserves a
265/// value this SDK does not recognize yet, for forward compatibility with
266/// a server that has introduced a new LicenseStatus value.
267#[derive(Debug, Clone, PartialEq, Eq)]
268pub enum LicenseStatus {
269    Valid,
270    Expiring,
271    Grace,
272    ExpiredAccess,
273    Expired,
274    /// A value not defined when this SDK was generated.
275    Unknown(String),
276}
277
278impl LicenseStatus {
279    /// Returns the wire string for this value.
280    pub fn as_str(&self) -> &str {
281        match self {
282            LicenseStatus::Valid => "valid",
283            LicenseStatus::Expiring => "expiring",
284            LicenseStatus::Grace => "grace",
285            LicenseStatus::ExpiredAccess => "expired_access",
286            LicenseStatus::Expired => "expired",
287            LicenseStatus::Unknown(s) => s.as_str(),
288        }
289    }
290
291    /// Reports whether this is one of the values defined when this SDK was
292    /// generated (false for `Unknown`).
293    pub fn is_known(&self) -> bool {
294        !matches!(self, LicenseStatus::Unknown(_))
295    }
296}
297
298impl std::fmt::Display for LicenseStatus {
299    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
300        f.write_str(self.as_str())
301    }
302}
303
304impl From<&str> for LicenseStatus {
305    fn from(s: &str) -> Self {
306        match s {
307            "valid" => LicenseStatus::Valid,
308            "expiring" => LicenseStatus::Expiring,
309            "grace" => LicenseStatus::Grace,
310            "expired_access" => LicenseStatus::ExpiredAccess,
311            "expired" => LicenseStatus::Expired,
312            other => LicenseStatus::Unknown(other.to_string()),
313        }
314    }
315}
316
317impl Serialize for LicenseStatus {
318    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
319    where
320        S: serde::Serializer,
321    {
322        serializer.serialize_str(self.as_str())
323    }
324}
325
326impl<'de> Deserialize<'de> for LicenseStatus {
327    fn deserialize<D>(deserializer: D) -> Result<Self, D::Error>
328    where
329        D: serde::Deserializer<'de>,
330    {
331        let s = String::deserialize(deserializer)?;
332        Ok(LicenseStatus::from(s.as_str()))
333    }
334}
335
336#[derive(Debug, Clone, Serialize, Deserialize)]
337pub struct Account {
338    pub id: i64,
339    pub name: String,
340    pub description: String,
341    #[serde(rename = "iconUrl", skip_serializing_if = "Option::is_none")]
342    pub icon_url: Option<String>,
343    #[serde(rename = "providerInfo", skip_serializing_if = "Option::is_none")]
344    pub provider_info: Option<serde_json::Value>,
345    #[serde(rename = "liveVolume")]
346    pub live_volume: i64,
347    #[serde(rename = "totalVolume")]
348    pub total_volume: i64,
349    #[serde(rename = "quotaLimit")]
350    pub quota_limit: i64,
351    #[serde(rename = "quotaExcessPct")]
352    pub quota_excess_pct: i32,
353    #[serde(rename = "isActive")]
354    pub is_active: bool,
355    pub locked: bool,
356    #[serde(skip_serializing_if = "Option::is_none")]
357    pub retention: Option<RetentionPolicy>,
358    #[serde(rename = "createdAt")]
359    pub created_at: String,
360    #[serde(rename = "updatedAt")]
361    pub updated_at: String,
362}
363
364#[derive(Debug, Clone, Serialize, Deserialize)]
365pub struct User {
366    pub id: i64,
367    #[serde(rename = "accountId")]
368    pub account_id: i64,
369    pub username: String,
370    pub email: String,
371    pub name: String,
372    #[serde(rename = "isActive")]
373    pub is_active: bool,
374}
375
376#[derive(Debug, Clone, Serialize, Deserialize)]
377pub struct Region {
378    pub id: i64,
379    #[serde(rename = "exportId")]
380    pub export_id: String,
381    #[serde(rename = "accountId")]
382    pub account_id: i64,
383    pub name: String,
384    #[serde(rename = "liveVolume")]
385    pub live_volume: i64,
386    #[serde(rename = "totalVolume")]
387    pub total_volume: i64,
388    #[serde(rename = "isActive")]
389    pub is_active: bool,
390    #[serde(rename = "createdAt")]
391    pub created_at: String,
392    #[serde(rename = "updatedAt")]
393    pub updated_at: String,
394}
395
396#[derive(Debug, Clone, Serialize, Deserialize)]
397pub struct MetadataCluster {
398    pub id: i64,
399    #[serde(rename = "exportId")]
400    pub export_id: String,
401    #[serde(rename = "regionId")]
402    pub region_id: i64,
403    pub name: String,
404    #[serde(rename = "defaultCluster")]
405    pub default_cluster: bool,
406    #[serde(rename = "isReady")]
407    pub is_ready: bool,
408    #[serde(rename = "isActive")]
409    pub is_active: bool,
410    #[serde(rename = "createdAt")]
411    pub created_at: String,
412    #[serde(rename = "updatedAt")]
413    pub updated_at: String,
414}
415
416#[derive(Debug, Clone, Serialize, Deserialize)]
417pub struct Storage {
418    pub id: i64,
419    pub uuid: String,
420    pub account: Ref,
421    #[serde(rename = "regionInfo")]
422    pub region_info: Ref,
423    pub name: String,
424    #[serde(skip_serializing_if = "Option::is_none")]
425    pub description: Option<String>,
426    #[serde(rename = "storageType")]
427    pub storage_type: String,
428    #[serde(rename = "providerType")]
429    pub provider_type: String,
430    pub endpoint: String,
431    #[serde(skip_serializing_if = "Option::is_none")]
432    pub region: Option<String>,
433    #[serde(skip_serializing_if = "Option::is_none")]
434    pub bucket: Option<String>,
435    #[serde(skip_serializing_if = "Option::is_none")]
436    pub base: Option<String>,
437    #[serde(rename = "physicalFingerprint", skip_serializing_if = "Option::is_none")]
438    pub physical_fingerprint: Option<String>,
439    #[serde(rename = "blockRegion", skip_serializing_if = "Option::is_none")]
440    pub block_region: Option<String>,
441    #[serde(rename = "blockSize", skip_serializing_if = "Option::is_none")]
442    pub block_size: Option<i32>,
443    #[serde(rename = "directAccess", skip_serializing_if = "Option::is_none")]
444    pub direct_access: Option<bool>,
445    #[serde(rename = "isActive")]
446    pub is_active: bool,
447    #[serde(rename = "createdAt")]
448    pub created_at: String,
449    #[serde(rename = "updatedAt")]
450    pub updated_at: String,
451}
452
453#[derive(Debug, Clone, Serialize, Deserialize)]
454pub struct BlockVolume {
455    pub id: String,
456    #[serde(skip_serializing_if = "Option::is_none")]
457    pub name: Option<String>,
458    #[serde(rename = "clusterName", skip_serializing_if = "Option::is_none")]
459    pub cluster_name: Option<String>,
460    #[serde(rename = "clusterUuid", skip_serializing_if = "Option::is_none")]
461    pub cluster_uuid: Option<String>,
462    #[serde(rename = "shardId")]
463    pub shard_id: i64,
464    #[serde(rename = "regionClusterId")]
465    pub region_cluster_id: i64,
466    #[serde(rename = "clusterReady")]
467    pub cluster_ready: bool,
468    #[serde(rename = "isActive")]
469    pub is_active: bool,
470    #[serde(rename = "createdAt")]
471    pub created_at: String,
472    #[serde(rename = "updatedAt")]
473    pub updated_at: String,
474    #[serde(rename = "memberState", skip_serializing_if = "Option::is_none")]
475    pub member_state: Option<String>,
476    #[serde(rename = "copysetId", skip_serializing_if = "Option::is_none")]
477    pub copyset_id: Option<String>,
478}
479
480#[derive(Debug, Clone, Serialize, Deserialize)]
481pub struct UpdateConfigResult {
482    pub id: String,
483    #[serde(rename = "targetK")]
484    pub target_k: i32,
485    #[serde(rename = "activeCopysetCountBefore")]
486    pub active_copyset_count_before: i32,
487    #[serde(rename = "copysetsNeeded")]
488    pub copysets_needed: i32,
489    #[serde(rename = "copysetsFormed")]
490    pub copysets_formed: i32,
491    #[serde(rename = "activeCopysetCountAfter")]
492    pub active_copyset_count_after: i32,
493    pub partial: bool,
494    #[serde(skip_serializing_if = "Option::is_none")]
495    pub reason: Option<String>,
496}
497
498#[derive(Debug, Clone, Serialize, Deserialize)]
499pub struct Copyset {
500    pub id: String,
501    #[serde(rename = "storageId")]
502    pub storage_id: String,
503    pub state: CopysetState,
504    #[serde(rename = "memberA", skip_serializing_if = "Option::is_none")]
505    pub member_a: Option<String>,
506    #[serde(rename = "memberB", skip_serializing_if = "Option::is_none")]
507    pub member_b: Option<String>,
508    #[serde(rename = "placementGroupA", skip_serializing_if = "Option::is_none")]
509    pub placement_group_a: Option<i64>,
510    #[serde(rename = "placementGroupB", skip_serializing_if = "Option::is_none")]
511    pub placement_group_b: Option<i64>,
512    #[serde(rename = "drainStartedAt", skip_serializing_if = "Option::is_none")]
513    pub drain_started_at: Option<String>,
514    #[serde(rename = "syncedAt", skip_serializing_if = "Option::is_none")]
515    pub synced_at: Option<String>,
516    #[serde(rename = "retiredAt", skip_serializing_if = "Option::is_none")]
517    pub retired_at: Option<String>,
518    #[serde(rename = "pendingSyncJobsA", skip_serializing_if = "Option::is_none")]
519    pub pending_sync_jobs_a: Option<i32>,
520    #[serde(rename = "pendingSyncJobsB", skip_serializing_if = "Option::is_none")]
521    pub pending_sync_jobs_b: Option<i32>,
522    #[serde(rename = "drainInitiatedBy", skip_serializing_if = "Option::is_none")]
523    pub drain_initiated_by: Option<i64>,
524    pub tags: Vec<String>,
525}
526
527#[derive(Debug, Clone, Serialize, Deserialize)]
528pub struct PoolMember {
529    pub id: String,
530    pub name: String,
531    #[serde(rename = "regionId")]
532    pub region_id: i64,
533    #[serde(rename = "regionClusterId")]
534    pub region_cluster_id: i64,
535    #[serde(rename = "memberState")]
536    pub member_state: String,
537}
538
539#[derive(Debug, Clone, Serialize, Deserialize)]
540pub struct Volume {
541    pub id: i64,
542    pub account: Ref,
543    pub storage: Ref,
544    pub region: Ref,
545    #[serde(rename = "metadataCluster", skip_serializing_if = "Option::is_none")]
546    pub metadata_cluster: Option<Ref>,
547    pub name: String,
548    #[serde(skip_serializing_if = "Option::is_none")]
549    pub description: Option<String>,
550    #[serde(rename = "volumeType")]
551    pub volume_type: String,
552    #[serde(rename = "storageType", skip_serializing_if = "Option::is_none")]
553    pub storage_type: Option<String>,
554    pub encryption: bool,
555    #[serde(rename = "quotaLimit")]
556    pub quota_limit: i64,
557    #[serde(rename = "liveVolume")]
558    pub live_volume: i64,
559    #[serde(rename = "totalVolume")]
560    pub total_volume: i64,
561    #[serde(rename = "pendingVolume")]
562    pub pending_volume: i64,
563    #[serde(rename = "liveInactiveVolume")]
564    pub live_inactive_volume: i64,
565    pub locked: bool,
566    pub retention: VolumeRetentionPolicy,
567    pub versioning: VolumeVersioningPolicy,
568    pub compaction: String,
569    #[serde(rename = "isActive")]
570    pub is_active: bool,
571    #[serde(rename = "isCleanupMetaEnabled")]
572    pub is_cleanup_meta_enabled: bool,
573    #[serde(rename = "isCleanupStorageEnabled")]
574    pub is_cleanup_storage_enabled: bool,
575    #[serde(rename = "isCleanupVaultEnabled")]
576    pub is_cleanup_vault_enabled: bool,
577    #[serde(rename = "createdAt")]
578    pub created_at: String,
579    #[serde(rename = "updatedAt")]
580    pub updated_at: String,
581}
582
583#[derive(Debug, Clone, Serialize, Deserialize)]
584pub struct VolumeBlockPlacementConfig {
585    pub id: i64,
586    #[serde(rename = "targetCopysetCount")]
587    pub target_copyset_count: i32,
588    #[serde(rename = "currentEpoch")]
589    pub current_epoch: i64,
590    #[serde(rename = "copysetIds")]
591    pub copyset_ids: Vec<String>,
592}
593
594#[derive(Debug, Clone, Serialize, Deserialize)]
595pub struct VolumeBlockPlacementResizeResult {
596    pub id: i64,
597    #[serde(rename = "targetCopysetCount")]
598    pub target_copyset_count: i32,
599    #[serde(rename = "copysetCountBefore")]
600    pub copyset_count_before: i32,
601    #[serde(rename = "copysetsAdded")]
602    pub copysets_added: i32,
603    #[serde(rename = "copysetsRemoved")]
604    pub copysets_removed: i32,
605    #[serde(rename = "copysetCountAfter")]
606    pub copyset_count_after: i32,
607    pub epoch: i64,
608    pub partial: bool,
609    #[serde(skip_serializing_if = "Option::is_none")]
610    pub reason: Option<String>,
611}
612
613#[derive(Debug, Clone, Serialize, Deserialize)]
614pub struct Fork {
615    pub fid: i32,
616    pub name: String,
617    #[serde(rename = "parentFid")]
618    pub parent_fid: i32,
619    #[serde(rename = "parentName")]
620    pub parent_name: String,
621    #[serde(rename = "snapshotTs")]
622    pub snapshot_ts: i64,
623    #[serde(rename = "createdBy", skip_serializing_if = "Option::is_none")]
624    pub created_by: Option<i64>,
625    #[serde(rename = "createdAt")]
626    pub created_at: i64,
627    #[serde(rename = "childrenCount")]
628    pub children_count: i32,
629    #[serde(skip_serializing_if = "Option::is_none")]
630    pub inactive: Option<bool>,
631    #[serde(rename = "inactiveAt", skip_serializing_if = "Option::is_none")]
632    pub inactive_at: Option<i64>,
633    pub status: String,
634    pub size: i64,
635}
636
637#[derive(Debug, Clone, Serialize, Deserialize)]
638pub struct ForkTreeEntry {
639    pub inode: i64,
640    pub name: String,
641    pub kind: String,
642    pub size: i64,
643    pub mtime: i64,
644    pub ctime: i64,
645    #[serde(rename = "creatorId", skip_serializing_if = "Option::is_none")]
646    pub creator_id: Option<i64>,
647    #[serde(rename = "updaterId", skip_serializing_if = "Option::is_none")]
648    pub updater_id: Option<i64>,
649}
650
651#[derive(Debug, Clone, Serialize, Deserialize)]
652pub struct ForkEntryDetail {
653    pub inode: i64,
654    pub path: String,
655    pub name: String,
656    pub kind: String,
657    pub size: i64,
658    pub mtime: i64,
659    pub ctime: i64,
660    pub generation: i64,
661    #[serde(skip_serializing_if = "Option::is_none")]
662    pub owner: Option<String>,
663    #[serde(skip_serializing_if = "Option::is_none")]
664    pub mode: Option<i32>,
665    #[serde(skip_serializing_if = "Option::is_none")]
666    pub xattrs: Option<serde_json::Value>,
667    #[serde(rename = "creatorId", skip_serializing_if = "Option::is_none")]
668    pub creator_id: Option<i64>,
669    #[serde(rename = "updaterId", skip_serializing_if = "Option::is_none")]
670    pub updater_id: Option<i64>,
671}
672
673#[derive(Debug, Clone, Serialize, Deserialize)]
674pub struct ForkEntryVersion {
675    pub generation: i64,
676    pub size: i64,
677    pub mtime: i64,
678    #[serde(rename = "updaterId", skip_serializing_if = "Option::is_none")]
679    pub updater_id: Option<i64>,
680    #[serde(rename = "contentHash", skip_serializing_if = "Option::is_none")]
681    pub content_hash: Option<String>,
682}
683
684#[derive(Debug, Clone, Serialize, Deserialize)]
685pub struct ForkTreeMatch {
686    pub path: String,
687    pub inode: i64,
688    pub kind: String,
689    pub size: i64,
690    pub mtime: i64,
691}
692
693#[derive(Debug, Clone, Serialize, Deserialize)]
694pub struct AuditLog {
695    pub id: i64,
696    pub title: String,
697    #[serde(skip_serializing_if = "Option::is_none")]
698    pub description: Option<String>,
699    #[serde(skip_serializing_if = "Option::is_none")]
700    pub subject: Option<String>,
701    pub success: bool,
702    #[serde(skip_serializing_if = "Option::is_none")]
703    pub data: Option<serde_json::Value>,
704    #[serde(rename = "createdBy", skip_serializing_if = "Option::is_none")]
705    pub created_by: Option<String>,
706    #[serde(skip_serializing_if = "Option::is_none")]
707    pub node: Option<String>,
708    #[serde(rename = "accountId", skip_serializing_if = "Option::is_none")]
709    pub account_id: Option<i64>,
710    #[serde(rename = "regionId", skip_serializing_if = "Option::is_none")]
711    pub region_id: Option<i64>,
712    #[serde(rename = "metadataClusterId", skip_serializing_if = "Option::is_none")]
713    pub metadata_cluster_id: Option<i64>,
714    #[serde(rename = "createdAt", skip_serializing_if = "Option::is_none")]
715    pub created_at: Option<String>,
716    #[serde(rename = "updatedAt", skip_serializing_if = "Option::is_none")]
717    pub updated_at: Option<String>,
718}
719
720#[derive(Debug, Clone, Serialize, Deserialize)]
721pub struct ServiceNode {
722    pub id: i64,
723    #[serde(rename = "regionId")]
724    pub region_id: i64,
725    #[serde(rename = "metadataClusterId", skip_serializing_if = "Option::is_none")]
726    pub metadata_cluster_id: Option<i64>,
727    #[serde(rename = "serviceType")]
728    pub service_type: String,
729    #[serde(rename = "nodeId")]
730    pub node_id: String,
731    #[serde(rename = "advertiseAddr")]
732    pub advertise_addr: String,
733    #[serde(rename = "rpcAddr", skip_serializing_if = "Option::is_none")]
734    pub rpc_addr: Option<String>,
735    #[serde(skip_serializing_if = "Option::is_none")]
736    pub metadata: Option<serde_json::Value>,
737    #[serde(rename = "metricsEndpoint", skip_serializing_if = "Option::is_none")]
738    pub metrics_endpoint: Option<String>,
739    #[serde(rename = "instanceId", skip_serializing_if = "Option::is_none")]
740    pub instance_id: Option<String>,
741    #[serde(rename = "instanceInfo", skip_serializing_if = "Option::is_none")]
742    pub instance_info: Option<serde_json::Value>,
743    pub status: String,
744    #[serde(rename = "lastHeartbeat", skip_serializing_if = "Option::is_none")]
745    pub last_heartbeat: Option<i64>,
746    #[serde(rename = "isActive")]
747    pub is_active: bool,
748    #[serde(rename = "memUsage", skip_serializing_if = "Option::is_none")]
749    pub mem_usage: Option<f64>,
750    #[serde(rename = "sysLoad", skip_serializing_if = "Option::is_none")]
751    pub sys_load: Option<i64>,
752    #[serde(rename = "binaryVersion", skip_serializing_if = "Option::is_none")]
753    pub binary_version: Option<i32>,
754}
755
756#[derive(Debug, Clone, Serialize, Deserialize)]
757pub struct ClientSession {
758    pub id: i64,
759    pub account: Ref,
760    pub region: Ref,
761    #[serde(rename = "metadataCluster", skip_serializing_if = "Option::is_none")]
762    pub metadata_cluster: Option<Ref>,
763    pub volume: VolumeRef,
764    #[serde(skip_serializing_if = "Option::is_none")]
765    pub user: Option<Ref>,
766    #[serde(rename = "clientType")]
767    pub client_type: String,
768    #[serde(rename = "osName")]
769    pub os_name: String,
770    #[serde(rename = "osVersion", skip_serializing_if = "Option::is_none")]
771    pub os_version: Option<String>,
772    #[serde(rename = "appVersion", skip_serializing_if = "Option::is_none")]
773    pub app_version: Option<String>,
774    #[serde(skip_serializing_if = "Option::is_none")]
775    pub hostname: Option<String>,
776    #[serde(rename = "ipAddr")]
777    pub ip_addr: String,
778    #[serde(rename = "mountMode", skip_serializing_if = "Option::is_none")]
779    pub mount_mode: Option<String>,
780    #[serde(rename = "mountPath", skip_serializing_if = "Option::is_none")]
781    pub mount_path: Option<String>,
782    #[serde(rename = "forkName", skip_serializing_if = "Option::is_none")]
783    pub fork_name: Option<String>,
784    #[serde(rename = "isTemporaryFork")]
785    pub is_temporary_fork: bool,
786    #[serde(skip_serializing_if = "Option::is_none")]
787    pub metadata: Option<serde_json::Value>,
788    #[serde(skip_serializing_if = "Option::is_none")]
789    pub metrics: Option<serde_json::Value>,
790    pub status: ClientSessionStatus,
791    #[serde(rename = "lastHeartbeat", skip_serializing_if = "Option::is_none")]
792    pub last_heartbeat: Option<i64>,
793    #[serde(rename = "connectedAt", skip_serializing_if = "Option::is_none")]
794    pub connected_at: Option<i64>,
795    #[serde(rename = "disconnectedAt", skip_serializing_if = "Option::is_none")]
796    pub disconnected_at: Option<i64>,
797    #[serde(rename = "isActive")]
798    pub is_active: bool,
799}
800
801#[derive(Debug, Clone, Serialize, Deserialize)]
802pub struct SessionSummary {
803    #[serde(rename = "byStatus")]
804    pub by_status: Vec<SessionSummaryStatusEntry>,
805    #[serde(rename = "byPlatform")]
806    pub by_platform: Vec<SessionSummaryFacet>,
807    #[serde(rename = "byOsName")]
808    pub by_os_name: Vec<SessionSummaryFacet>,
809    #[serde(rename = "regionCount")]
810    pub region_count: i64,
811    #[serde(rename = "volumeCount")]
812    pub volume_count: i64,
813    #[serde(rename = "hostCount")]
814    pub host_count: i64,
815    #[serde(rename = "degradedCount")]
816    pub degraded_count: i64,
817}
818
819#[derive(Debug, Clone, Serialize, Deserialize)]
820pub struct DiscoverMetaResponse {
821    #[serde(rename = "regionId")]
822    pub region_id: i64,
823    pub region: String,
824    pub endpoints: Vec<DiscoverEndpoint>,
825}
826
827#[derive(Debug, Clone, Serialize, Deserialize)]
828pub struct MetricsTarget {
829    pub targets: Vec<String>,
830    pub labels: serde_json::Value,
831}
832
833#[derive(Debug, Clone, Serialize, Deserialize)]
834pub struct MetricsTokenResponse {
835    pub token: String,
836}
837
838#[derive(Debug, Clone, Serialize, Deserialize)]
839pub struct DashboardStats {
840    #[serde(rename = "userCount")]
841    pub user_count: i64,
842    #[serde(rename = "volumeCount")]
843    pub volume_count: i64,
844    #[serde(rename = "regionCount")]
845    pub region_count: i64,
846    #[serde(rename = "storageCount")]
847    pub storage_count: i64,
848    #[serde(rename = "totalVolumeUsed")]
849    pub total_volume_used: i64,
850    #[serde(rename = "totalQuotaLimit")]
851    pub total_quota_limit: i64,
852    #[serde(rename = "activeSessionCount")]
853    pub active_session_count: i64,
854    #[serde(rename = "regionBreakdown")]
855    pub region_breakdown: Vec<RegionVolumeMetrics>,
856}
857
858#[derive(Debug, Clone, Serialize, Deserialize)]
859pub struct LicenseDetails {
860    #[serde(rename = "licenseId")]
861    pub license_id: String,
862    pub licensee: String,
863    pub contact: String,
864    #[serde(rename = "licenseType")]
865    pub license_type: String,
866    #[serde(rename = "issuedAt")]
867    pub issued_at: String,
868    #[serde(rename = "expiresAt")]
869    pub expires_at: String,
870    #[serde(rename = "gracePeriodDays")]
871    pub grace_period_days: i64,
872    #[serde(rename = "expiredAccessDays")]
873    pub expired_access_days: i64,
874    #[serde(rename = "maxNodes")]
875    pub max_nodes: i64,
876    #[serde(rename = "maxVolumes")]
877    pub max_volumes: i64,
878    #[serde(rename = "maxUsers")]
879    pub max_users: i64,
880    #[serde(rename = "maxAccounts")]
881    pub max_accounts: i64,
882    #[serde(rename = "maxRegions")]
883    pub max_regions: i64,
884    #[serde(rename = "maxStorageBytes")]
885    pub max_storage_bytes: i64,
886    pub status: LicenseStatus,
887    #[serde(rename = "daysRemaining")]
888    pub days_remaining: i64,
889    #[serde(rename = "graceEndsAt")]
890    pub grace_ends_at: String,
891    #[serde(rename = "graceDaysLeft")]
892    pub grace_days_left: i64,
893    #[serde(rename = "expiredAccessEndsAt")]
894    pub expired_access_ends_at: String,
895    #[serde(rename = "expiredAccessDaysLeft")]
896    pub expired_access_days_left: i64,
897    pub quota: LicenseQuota,
898    #[serde(skip_serializing_if = "Option::is_none")]
899    pub distribution: Option<String>,
900    #[serde(rename = "distributionRef", skip_serializing_if = "Option::is_none")]
901    pub distribution_ref: Option<Vec<String>>,
902    #[serde(rename = "unlimitedStorage", skip_serializing_if = "Option::is_none")]
903    pub unlimited_storage: Option<bool>,
904}
905
906#[derive(Debug, Clone, Serialize, Deserialize)]
907pub struct LicenseTerms {
908    pub terms: String,
909}
910
911#[derive(Debug, Clone, Serialize, Deserialize)]
912pub struct LicenseLoadResult {
913    pub loaded: i64,
914    pub ignored: i64,
915}
916
917#[derive(Debug, Clone, Serialize, Deserialize)]
918pub struct LicenseList {
919    pub items: Vec<LicenseRecord>,
920}
921
922#[derive(Debug, Clone, Serialize, Deserialize)]
923pub struct ServiceAlert {
924    pub id: i64,
925    #[serde(rename = "alertId")]
926    pub alert_id: String,
927    pub source: String,
928    #[serde(rename = "nodeId")]
929    pub node_id: String,
930    pub severity: i64,
931    pub category: String,
932    pub title: String,
933    #[serde(skip_serializing_if = "Option::is_none")]
934    pub description: Option<String>,
935    #[serde(skip_serializing_if = "Option::is_none")]
936    pub region: Option<Ref>,
937    #[serde(skip_serializing_if = "Option::is_none")]
938    pub account: Option<Ref>,
939    #[serde(rename = "eventTime")]
940    pub event_time: String,
941    #[serde(rename = "resolvedAt", skip_serializing_if = "Option::is_none")]
942    pub resolved_at: Option<String>,
943    #[serde(rename = "createdAt", skip_serializing_if = "Option::is_none")]
944    pub created_at: Option<String>,
945}
946
947#[derive(Debug, Clone, Serialize, Deserialize)]
948pub struct AlertCountResponse {
949    pub active: i64,
950    pub recent: i64,
951    #[serde(rename = "infoCount")]
952    pub info_count: i64,
953    #[serde(rename = "warningCount")]
954    pub warning_count: i64,
955    #[serde(rename = "criticalCount")]
956    pub critical_count: i64,
957    #[serde(rename = "asOf")]
958    pub as_of: String,
959}
960
961#[derive(Debug, Clone, Serialize, Deserialize)]
962pub struct RegionAlert {
963    pub id: i64,
964    #[serde(rename = "alertId")]
965    pub alert_id: String,
966    pub source: String,
967    #[serde(rename = "nodeId")]
968    pub node_id: String,
969    #[serde(rename = "metadataClusterId", skip_serializing_if = "Option::is_none")]
970    pub metadata_cluster_id: Option<i64>,
971    pub severity: i64,
972    pub category: String,
973    pub title: String,
974    #[serde(skip_serializing_if = "Option::is_none")]
975    pub description: Option<String>,
976    #[serde(rename = "eventTime")]
977    pub event_time: String,
978    #[serde(rename = "resolvedAt", skip_serializing_if = "Option::is_none")]
979    pub resolved_at: Option<String>,
980    #[serde(rename = "createdAt", skip_serializing_if = "Option::is_none")]
981    pub created_at: Option<String>,
982}
983
984#[derive(Debug, Clone, Serialize, Deserialize)]
985pub struct GCWorkerEvent {
986    pub id: i64,
987    #[serde(rename = "nodeId")]
988    pub node_id: String,
989    #[serde(rename = "metadataClusterId", skip_serializing_if = "Option::is_none")]
990    pub metadata_cluster_id: Option<i64>,
991    pub goal: String,
992    #[serde(skip_serializing_if = "Option::is_none")]
993    pub sid: Option<i64>,
994    #[serde(skip_serializing_if = "Option::is_none")]
995    pub subject: Option<String>,
996    pub ops: serde_json::Value,
997    #[serde(rename = "durationMs")]
998    pub duration_ms: i64,
999    #[serde(rename = "eventTime")]
1000    pub event_time: String,
1001    #[serde(rename = "createdAt", skip_serializing_if = "Option::is_none")]
1002    pub created_at: Option<String>,
1003}
1004
1005#[derive(Debug, Clone, Serialize, Deserialize)]
1006pub struct GCWorkerEventHistogramResponse {
1007    pub buckets: Vec<GCWorkerEventBucket>,
1008}
1009
1010#[derive(Debug, Clone, Serialize, Deserialize)]
1011pub struct GCWorkerEventGoalsResponse {
1012    pub goals: Vec<String>,
1013}
1014
1015#[derive(Debug, Clone, Serialize, Deserialize)]
1016pub struct BackfillFailure {
1017    #[serde(rename = "shardId")]
1018    pub shard_id: i64,
1019    pub error: String,
1020}
1021
1022#[derive(Debug, Clone, Serialize, Deserialize)]
1023pub struct BlockMember {
1024    #[serde(skip_serializing_if = "Option::is_none")]
1025    pub name: Option<String>,
1026    #[serde(rename = "regionClusterId")]
1027    pub region_cluster_id: i64,
1028}
1029
1030#[derive(Debug, Clone, Serialize, Deserialize)]
1031pub struct CompatibleStorage {
1032    pub id: i64,
1033    pub uuid: String,
1034    pub name: String,
1035    #[serde(rename = "storageType")]
1036    pub storage_type: String,
1037    #[serde(rename = "providerType")]
1038    pub provider_type: String,
1039    pub volumes: Vec<CompatibleVolume>,
1040}
1041
1042#[derive(Debug, Clone, Serialize, Deserialize)]
1043pub struct CompatibleVolume {
1044    pub id: String,
1045    pub name: String,
1046}
1047
1048#[derive(Debug, Clone, Serialize, Deserialize)]
1049pub struct DashboardUser {
1050    pub id: String,
1051    pub name: String,
1052    #[serde(skip_serializing_if = "Option::is_none")]
1053    pub email: Option<String>,
1054    pub role: String,
1055    #[serde(skip_serializing_if = "Option::is_none")]
1056    pub username: Option<String>,
1057    #[serde(rename = "accountId", skip_serializing_if = "Option::is_none")]
1058    pub account_id: Option<i64>,
1059    #[serde(rename = "userId", skip_serializing_if = "Option::is_none")]
1060    pub user_id: Option<i64>,
1061    #[serde(rename = "volumeId", skip_serializing_if = "Option::is_none")]
1062    pub volume_id: Option<i64>,
1063    #[serde(skip_serializing_if = "Option::is_none")]
1064    pub exp: Option<i64>,
1065}
1066
1067#[derive(Debug, Clone, Serialize, Deserialize)]
1068pub struct DiscoverEndpoint {
1069    #[serde(rename = "nodeId")]
1070    pub node_id: String,
1071    pub addr: String,
1072    pub status: String,
1073}
1074
1075#[derive(Debug, Clone, Serialize, Deserialize)]
1076pub struct GCWorkerEventBucket {
1077    #[serde(rename = "bucketStart")]
1078    pub bucket_start: String,
1079    pub goal: String,
1080    pub count: i64,
1081}
1082
1083#[derive(Debug, Clone, Serialize, Deserialize)]
1084pub struct LicenseQuota {
1085    pub state: LicenseQuotaState,
1086    #[serde(rename = "liveVolume")]
1087    pub live_volume: i64,
1088    #[serde(rename = "totalVolume")]
1089    pub total_volume: i64,
1090    pub generation: i64,
1091    #[serde(rename = "lastTransitionAtMs")]
1092    pub last_transition_at_ms: i64,
1093}
1094
1095#[derive(Debug, Clone, Serialize, Deserialize)]
1096pub struct LicenseRecord {
1097    pub key: String,
1098    pub licensee: String,
1099    pub status: LicenseStatus,
1100    #[serde(rename = "issuedAt")]
1101    pub issued_at: String,
1102    #[serde(rename = "expiresAt")]
1103    pub expires_at: String,
1104    #[serde(rename = "maxStorageBytes")]
1105    pub max_storage_bytes: i64,
1106    #[serde(rename = "insertedAt")]
1107    pub inserted_at: String,
1108}
1109
1110#[derive(Debug, Clone, Serialize, Deserialize)]
1111pub struct MoveVolumeFailure {
1112    #[serde(rename = "volumeId")]
1113    pub volume_id: String,
1114    pub error: String,
1115}
1116
1117#[derive(Debug, Clone, Serialize, Deserialize)]
1118pub struct NodeStatsSample {
1119    #[serde(rename = "timestampMs")]
1120    pub timestamp_ms: i64,
1121    #[serde(rename = "intervalMs")]
1122    pub interval_ms: i64,
1123    #[serde(rename = "loadAvg1")]
1124    pub load_avg1: f64,
1125    #[serde(rename = "loadAvg5")]
1126    pub load_avg5: f64,
1127    #[serde(rename = "loadAvg15")]
1128    pub load_avg15: f64,
1129    #[serde(rename = "memUsage")]
1130    pub mem_usage: f64,
1131    #[serde(rename = "readIops")]
1132    pub read_iops: f64,
1133    #[serde(rename = "writeIops")]
1134    pub write_iops: f64,
1135    #[serde(rename = "netRxBytesPerSec")]
1136    pub net_rx_bytes_per_sec: f64,
1137    #[serde(rename = "netTxBytesPerSec")]
1138    pub net_tx_bytes_per_sec: f64,
1139    #[serde(rename = "processCount")]
1140    pub process_count: i64,
1141    #[serde(rename = "diskUsedBytes", skip_serializing_if = "Option::is_none")]
1142    pub disk_used_bytes: Option<i64>,
1143    #[serde(rename = "diskTotalBytes", skip_serializing_if = "Option::is_none")]
1144    pub disk_total_bytes: Option<i64>,
1145    #[serde(rename = "dbLatency1mUs", skip_serializing_if = "Option::is_none")]
1146    pub db_latency1m_us: Option<f64>,
1147    #[serde(rename = "dbLatency5mUs", skip_serializing_if = "Option::is_none")]
1148    pub db_latency5m_us: Option<f64>,
1149    #[serde(rename = "dbLatency15mUs", skip_serializing_if = "Option::is_none")]
1150    pub db_latency15m_us: Option<f64>,
1151    #[serde(rename = "dbQueriesPerSec", skip_serializing_if = "Option::is_none")]
1152    pub db_queries_per_sec: Option<f64>,
1153    #[serde(rename = "dbConnsInUse", skip_serializing_if = "Option::is_none")]
1154    pub db_conns_in_use: Option<i64>,
1155    #[serde(rename = "dbConnsMax", skip_serializing_if = "Option::is_none")]
1156    pub db_conns_max: Option<i64>,
1157    #[serde(rename = "dbConnsIdle", skip_serializing_if = "Option::is_none")]
1158    pub db_conns_idle: Option<i64>,
1159    #[serde(rename = "dbConnsFree", skip_serializing_if = "Option::is_none")]
1160    pub db_conns_free: Option<i64>,
1161    #[serde(rename = "dbConnsInUse1m", skip_serializing_if = "Option::is_none")]
1162    pub db_conns_in_use1m: Option<f64>,
1163    #[serde(rename = "dbConnsInUse5m", skip_serializing_if = "Option::is_none")]
1164    pub db_conns_in_use5m: Option<f64>,
1165    #[serde(rename = "dbConnsInUse15m", skip_serializing_if = "Option::is_none")]
1166    pub db_conns_in_use15m: Option<f64>,
1167    #[serde(rename = "dbPingAvgUs", skip_serializing_if = "Option::is_none")]
1168    pub db_ping_avg_us: Option<f64>,
1169    #[serde(rename = "dbPingMinUs", skip_serializing_if = "Option::is_none")]
1170    pub db_ping_min_us: Option<f64>,
1171    #[serde(rename = "dbPingMaxUs", skip_serializing_if = "Option::is_none")]
1172    pub db_ping_max_us: Option<f64>,
1173    #[serde(rename = "dbPingStdDevUs", skip_serializing_if = "Option::is_none")]
1174    pub db_ping_std_dev_us: Option<f64>,
1175    #[serde(rename = "dbDispatchOutstanding", skip_serializing_if = "Option::is_none")]
1176    pub db_dispatch_outstanding: Option<i64>,
1177    #[serde(rename = "dbDispatchLaneCap", skip_serializing_if = "Option::is_none")]
1178    pub db_dispatch_lane_cap: Option<i64>,
1179}
1180
1181#[derive(Debug, Clone, Serialize, Deserialize)]
1182pub struct Ref {
1183    pub id: i64,
1184    pub name: String,
1185}
1186
1187#[derive(Debug, Clone, Serialize, Deserialize)]
1188pub struct RegionVolumeMetrics {
1189    #[serde(rename = "regionId")]
1190    pub region_id: i64,
1191    #[serde(rename = "regionName")]
1192    pub region_name: String,
1193    #[serde(rename = "volumeCount")]
1194    pub volume_count: i64,
1195    #[serde(rename = "totalVolumeUsed")]
1196    pub total_volume_used: i64,
1197    #[serde(rename = "totalQuotaLimit")]
1198    pub total_quota_limit: i64,
1199}
1200
1201#[derive(Debug, Clone, Serialize, Deserialize)]
1202pub struct RetentionPolicy {
1203    #[serde(rename = "clientSessionDays", skip_serializing_if = "Option::is_none")]
1204    pub client_session_days: Option<i32>,
1205}
1206
1207#[derive(Debug, Clone, Serialize, Deserialize)]
1208pub struct SessionSummaryFacet {
1209    pub label: String,
1210    pub count: i64,
1211}
1212
1213#[derive(Debug, Clone, Serialize, Deserialize)]
1214pub struct SessionSummaryStatusEntry {
1215    #[serde(rename = "clientType")]
1216    pub client_type: String,
1217    pub status: String,
1218    pub count: i64,
1219}
1220
1221#[derive(Debug, Clone, Serialize, Deserialize)]
1222pub struct UserLite {
1223    pub id: i64,
1224    pub username: String,
1225    pub name: String,
1226}
1227
1228#[derive(Debug, Clone, Serialize, Deserialize)]
1229pub struct VolumeApiKey {
1230    #[serde(rename = "apiKey")]
1231    pub api_key: String,
1232    #[serde(skip_serializing_if = "Option::is_none")]
1233    pub name: Option<String>,
1234    #[serde(rename = "createdAt", skip_serializing_if = "Option::is_none")]
1235    pub created_at: Option<String>,
1236    #[serde(rename = "lastUsedAt", skip_serializing_if = "Option::is_none")]
1237    pub last_used_at: Option<String>,
1238}
1239
1240#[derive(Debug, Clone, Serialize, Deserialize)]
1241pub struct VolumeRef {
1242    pub id: i64,
1243    pub name: String,
1244    #[serde(skip_serializing_if = "Option::is_none")]
1245    pub r#type: Option<String>,
1246}
1247
1248#[derive(Debug, Clone, Serialize, Deserialize)]
1249pub struct VolumeRetentionPolicy {
1250    #[serde(rename = "dataDays", skip_serializing_if = "Option::is_none")]
1251    pub data_days: Option<i32>,
1252    #[serde(rename = "graceDays", skip_serializing_if = "Option::is_none")]
1253    pub grace_days: Option<i32>,
1254    #[serde(rename = "forkGraceDays", skip_serializing_if = "Option::is_none")]
1255    pub fork_grace_days: Option<i32>,
1256    #[serde(rename = "eventLogDays", skip_serializing_if = "Option::is_none")]
1257    pub event_log_days: Option<i32>,
1258}
1259
1260#[derive(Debug, Clone, Serialize, Deserialize)]
1261pub struct VolumeSizePoint {
1262    #[serde(rename = "bucketEnd")]
1263    pub bucket_end: String,
1264    #[serde(rename = "liveVolume")]
1265    pub live_volume: i64,
1266    #[serde(rename = "totalVolume")]
1267    pub total_volume: i64,
1268    #[serde(rename = "pendingVolume")]
1269    pub pending_volume: i64,
1270    #[serde(rename = "liveInactiveVolume")]
1271    pub live_inactive_volume: i64,
1272}
1273
1274#[derive(Debug, Clone, Serialize, Deserialize)]
1275pub struct VolumeVersioningPolicy {
1276    #[serde(rename = "contentWindowSeconds", skip_serializing_if = "Option::is_none")]
1277    pub content_window_seconds: Option<i32>,
1278}
1279
1280// Accounts
1281
1282#[derive(Debug, Clone, Serialize)]
1283pub struct CreateAccountRequest {
1284    pub name: String,
1285    #[serde(skip_serializing_if = "Option::is_none")]
1286    pub description: Option<String>,
1287    #[serde(rename = "iconUrl", skip_serializing_if = "Option::is_none")]
1288    pub icon_url: Option<String>,
1289    #[serde(rename = "providerInfo", skip_serializing_if = "Option::is_none")]
1290    pub provider_info: Option<serde_json::Value>,
1291}
1292
1293#[derive(Debug, Clone, Serialize)]
1294pub struct EditAccountRequest {
1295    pub name: String,
1296    #[serde(skip_serializing_if = "Option::is_none")]
1297    pub description: Option<String>,
1298    #[serde(rename = "iconUrl", skip_serializing_if = "Option::is_none")]
1299    pub icon_url: Option<String>,
1300    #[serde(rename = "providerInfo", skip_serializing_if = "Option::is_none")]
1301    pub provider_info: Option<serde_json::Value>,
1302    #[serde(skip_serializing_if = "Option::is_none")]
1303    pub retention: Option<RetentionPolicy>,
1304}
1305
1306#[derive(Debug, Clone, Serialize)]
1307pub struct UpdateAccountQuotaRequest {
1308    #[serde(rename = "quotaLimit")]
1309    pub quota_limit: i64,
1310    #[serde(rename = "quotaExcessPct", skip_serializing_if = "Option::is_none")]
1311    pub quota_excess_pct: Option<i32>,
1312}
1313
1314#[derive(Debug, Clone, Default)]
1315pub struct AccountListOptions {
1316    pub is_active: Option<bool>,
1317    pub page: Option<i64>,
1318    pub limit: Option<i64>,
1319}
1320
1321// Users
1322
1323#[derive(Debug, Clone, Serialize)]
1324pub struct AddUserRequest {
1325    #[serde(rename = "accountId")]
1326    pub account_id: i64,
1327    pub username: String,
1328    pub email: String,
1329    #[serde(skip_serializing_if = "Option::is_none")]
1330    pub name: Option<String>,
1331    #[serde(rename = "providerInfo", skip_serializing_if = "Option::is_none")]
1332    pub provider_info: Option<serde_json::Value>,
1333}
1334
1335#[derive(Debug, Clone, Serialize)]
1336pub struct BulkUserRequest {
1337    pub ids: Vec<i64>,
1338}
1339
1340#[derive(Debug, Clone, Serialize, Deserialize)]
1341pub struct BulkUserResponse {
1342    pub users: Vec<UserLite>,
1343}
1344
1345#[derive(Debug, Clone, Serialize)]
1346pub struct EditUserRequest {
1347    pub username: String,
1348    pub email: String,
1349    #[serde(skip_serializing_if = "Option::is_none")]
1350    pub name: Option<String>,
1351    #[serde(rename = "providerInfo", skip_serializing_if = "Option::is_none")]
1352    pub provider_info: Option<serde_json::Value>,
1353}
1354
1355#[derive(Debug, Clone, Default)]
1356pub struct UserListOptions {
1357    pub account_id: i64,
1358    pub search: Option<String>,
1359    pub is_active: Option<bool>,
1360    pub page: Option<i64>,
1361    pub limit: Option<i64>,
1362}
1363
1364// Regions
1365
1366#[derive(Debug, Clone, Serialize)]
1367pub struct CreateRegionRequest {
1368    #[serde(rename = "accountId")]
1369    pub account_id: i64,
1370    pub name: String,
1371}
1372
1373#[derive(Debug, Clone, Serialize)]
1374pub struct EditRegionRequest {
1375    #[serde(rename = "accountId")]
1376    pub account_id: i64,
1377    pub name: String,
1378}
1379
1380#[derive(Debug, Clone, Default)]
1381pub struct RegionListOptions {
1382    pub account_id: i64,
1383    pub is_active: Option<bool>,
1384    pub page: Option<i64>,
1385    pub limit: Option<i64>,
1386}
1387
1388// Clusters
1389
1390#[derive(Debug, Clone, Default)]
1391pub struct ClusterListOptions {
1392    pub account_id: i64,
1393    pub region_id: Option<i64>,
1394    pub is_active: Option<bool>,
1395    pub page: Option<i64>,
1396    pub limit: Option<i64>,
1397}
1398
1399// MetadataClusters
1400
1401#[derive(Debug, Clone, Serialize)]
1402pub struct CreateMetadataClusterRequest {
1403    pub name: String,
1404}
1405
1406#[derive(Debug, Clone, Serialize)]
1407pub struct EditMetadataClusterRequest {
1408    pub name: String,
1409}
1410
1411#[derive(Debug, Clone, Serialize)]
1412pub struct SetMetadataClusterReadyRequest {
1413    pub ready: bool,
1414}
1415
1416#[derive(Debug, Clone, Serialize, Deserialize)]
1417pub struct SetReadyMetadataClusterResponse {
1418    pub id: i64,
1419    pub ready: bool,
1420}
1421
1422#[derive(Debug, Clone, Default)]
1423pub struct MetadataClusterListOptions {
1424    pub is_active: Option<bool>,
1425    pub page: Option<i64>,
1426    pub limit: Option<i64>,
1427}
1428
1429// Storages
1430
1431#[derive(Debug, Clone, Serialize)]
1432pub struct CreateStorageRequest {
1433    #[serde(rename = "accountId")]
1434    pub account_id: i64,
1435    #[serde(rename = "regionId")]
1436    pub region_id: i64,
1437    pub name: String,
1438    #[serde(skip_serializing_if = "Option::is_none")]
1439    pub description: Option<String>,
1440    #[serde(rename = "storageType")]
1441    pub storage_type: String,
1442    #[serde(rename = "providerType")]
1443    pub provider_type: String,
1444    pub endpoint: String,
1445    #[serde(skip_serializing_if = "Option::is_none")]
1446    pub region: Option<String>,
1447    #[serde(skip_serializing_if = "Option::is_none")]
1448    pub bucket: Option<String>,
1449    #[serde(skip_serializing_if = "Option::is_none")]
1450    pub base: Option<String>,
1451    #[serde(rename = "blockRegion", skip_serializing_if = "Option::is_none")]
1452    pub block_region: Option<String>,
1453    #[serde(rename = "blockSize", skip_serializing_if = "Option::is_none")]
1454    pub block_size: Option<i32>,
1455    #[serde(skip_serializing_if = "Option::is_none")]
1456    pub members: Option<Vec<BlockMember>>,
1457    #[serde(rename = "accessKey", skip_serializing_if = "Option::is_none")]
1458    pub access_key: Option<String>,
1459    #[serde(rename = "secretKey", skip_serializing_if = "Option::is_none")]
1460    pub secret_key: Option<String>,
1461}
1462
1463#[derive(Debug, Clone, Serialize, Deserialize)]
1464pub struct CreateStorageResponse {
1465    pub id: i64,
1466    #[serde(rename = "blockVolumeIds", skip_serializing_if = "Option::is_none")]
1467    pub block_volume_ids: Option<Vec<String>>,
1468}
1469
1470#[derive(Debug, Clone, Serialize)]
1471pub struct EditStorageRequest {
1472    pub name: String,
1473    #[serde(skip_serializing_if = "Option::is_none")]
1474    pub description: Option<String>,
1475    #[serde(skip_serializing_if = "Option::is_none")]
1476    pub endpoint: Option<String>,
1477    #[serde(rename = "accessKey", skip_serializing_if = "Option::is_none")]
1478    pub access_key: Option<String>,
1479    #[serde(rename = "secretKey", skip_serializing_if = "Option::is_none")]
1480    pub secret_key: Option<String>,
1481    #[serde(rename = "directAccess", skip_serializing_if = "Option::is_none")]
1482    pub direct_access: Option<bool>,
1483}
1484
1485#[derive(Debug, Clone, Serialize)]
1486pub struct TestStorageNewBucketRequest {
1487    pub endpoint: String,
1488    #[serde(skip_serializing_if = "Option::is_none")]
1489    pub region: Option<String>,
1490    pub bucket: String,
1491    #[serde(rename = "accessKey")]
1492    pub access_key: String,
1493    #[serde(rename = "secretKey")]
1494    pub secret_key: String,
1495    #[serde(rename = "providerType", skip_serializing_if = "Option::is_none")]
1496    pub provider_type: Option<String>,
1497}
1498
1499#[derive(Debug, Clone, Serialize, Deserialize)]
1500pub struct TestNewBucketStorageResponse {
1501    #[serde(rename = "bucketExists")]
1502    pub bucket_exists: bool,
1503    pub list: bool,
1504    pub write: bool,
1505    pub read: bool,
1506    pub delete: bool,
1507    pub multipart: bool,
1508}
1509
1510#[derive(Debug, Clone, Serialize, Deserialize)]
1511pub struct TestStorageBucketStorageResponse {
1512    #[serde(rename = "bucketExists")]
1513    pub bucket_exists: bool,
1514    pub list: bool,
1515    pub write: bool,
1516    pub read: bool,
1517    pub delete: bool,
1518    pub multipart: bool,
1519}
1520
1521#[derive(Debug, Clone, Serialize, Deserialize)]
1522pub struct ListCompatibleStorageResponse {
1523    pub storages: Vec<CompatibleStorage>,
1524}
1525
1526#[derive(Debug, Clone, Serialize)]
1527pub struct MoveStorageVolumesRequest {
1528    #[serde(rename = "volumeIds")]
1529    pub volume_ids: Vec<String>,
1530}
1531
1532#[derive(Debug, Clone, Serialize, Deserialize)]
1533pub struct MoveVolumesStorageResponse {
1534    pub moved: Vec<String>,
1535    pub failures: Vec<MoveVolumeFailure>,
1536}
1537
1538#[derive(Debug, Clone, Serialize)]
1539pub struct UpdateStorageConfigRequest {
1540    pub k: i32,
1541}
1542
1543#[derive(Debug, Clone, Serialize, Deserialize)]
1544pub struct GetConfigStorageResponse {
1545    pub id: String,
1546    pub k: i32,
1547    #[serde(rename = "algorithmVersion")]
1548    pub algorithm_version: i32,
1549    #[serde(rename = "epochPolicyVersion")]
1550    pub epoch_policy_version: i32,
1551}
1552
1553#[derive(Debug, Clone, Serialize, Deserialize)]
1554pub struct DrainCopysetStorageResponse {
1555    pub id: String,
1556    pub state: String,
1557}
1558
1559#[derive(Debug, Clone, Serialize, Deserialize)]
1560pub struct CancelDrainStorageResponse {
1561    pub id: String,
1562    pub state: String,
1563}
1564
1565#[derive(Debug, Clone, Serialize)]
1566pub struct UpdateStorageTagsRequest {
1567    #[serde(skip_serializing_if = "Option::is_none")]
1568    pub tags: Option<Vec<String>>,
1569}
1570
1571#[derive(Debug, Clone, Serialize)]
1572pub struct RegisterStorageMemberRequest {
1573    #[serde(rename = "regionClusterId")]
1574    pub region_cluster_id: i64,
1575    #[serde(skip_serializing_if = "Option::is_none")]
1576    pub name: Option<String>,
1577}
1578
1579#[derive(Debug, Clone, Serialize, Deserialize)]
1580pub struct RemoveMemberStorageResponse {
1581    pub id: String,
1582}
1583
1584#[derive(Debug, Clone, Serialize, Deserialize)]
1585pub struct BackfillFingerprintsStorageResponse {
1586    pub scanned: i32,
1587    pub updated: i32,
1588    pub failures: Vec<BackfillFailure>,
1589    #[serde(rename = "hasMore")]
1590    pub has_more: bool,
1591}
1592
1593#[derive(Debug, Clone, Default)]
1594pub struct StorageListOptions {
1595    pub account_id: i64,
1596    pub search: Option<String>,
1597    pub region_id: Option<i64>,
1598    pub storage_type: Option<String>,
1599    pub provider_type: Option<String>,
1600    pub is_active: Option<bool>,
1601    pub direct_access: Option<bool>,
1602    pub page: Option<i64>,
1603    pub limit: Option<i64>,
1604}
1605
1606// Volumes
1607
1608#[derive(Debug, Clone, Serialize)]
1609pub struct CreateVolumeRequest {
1610    #[serde(rename = "accountId")]
1611    pub account_id: i64,
1612    #[serde(rename = "storageId")]
1613    pub storage_id: i64,
1614    pub name: String,
1615    #[serde(skip_serializing_if = "Option::is_none")]
1616    pub description: Option<String>,
1617    #[serde(rename = "volumeType")]
1618    pub volume_type: String,
1619    #[serde(skip_serializing_if = "Option::is_none")]
1620    pub encryption: Option<bool>,
1621    #[serde(rename = "encryptionKey", skip_serializing_if = "Option::is_none")]
1622    pub encryption_key: Option<String>,
1623    #[serde(skip_serializing_if = "Option::is_none")]
1624    pub retention: Option<VolumeRetentionPolicy>,
1625    #[serde(skip_serializing_if = "Option::is_none")]
1626    pub versioning: Option<VolumeVersioningPolicy>,
1627    #[serde(skip_serializing_if = "Option::is_none")]
1628    pub compaction: Option<String>,
1629    #[serde(rename = "quotaLimit", skip_serializing_if = "Option::is_none")]
1630    pub quota_limit: Option<i64>,
1631    #[serde(rename = "metadataClusterId", skip_serializing_if = "Option::is_none")]
1632    pub metadata_cluster_id: Option<i64>,
1633    #[serde(rename = "metadataClusterUuid", skip_serializing_if = "Option::is_none")]
1634    pub metadata_cluster_uuid: Option<String>,
1635}
1636
1637#[derive(Debug, Clone, Serialize, Deserialize)]
1638pub struct CreateVolumeResponse {
1639    pub id: i64,
1640    #[serde(rename = "encryptionKey", skip_serializing_if = "Option::is_none")]
1641    pub encryption_key: Option<String>,
1642}
1643
1644#[derive(Debug, Clone, Serialize)]
1645pub struct EditVolumeRequest {
1646    #[serde(skip_serializing_if = "Option::is_none")]
1647    pub description: Option<String>,
1648    #[serde(skip_serializing_if = "Option::is_none")]
1649    pub retention: Option<VolumeRetentionPolicy>,
1650    #[serde(skip_serializing_if = "Option::is_none")]
1651    pub versioning: Option<VolumeVersioningPolicy>,
1652    #[serde(skip_serializing_if = "Option::is_none")]
1653    pub compaction: Option<String>,
1654}
1655
1656#[derive(Debug, Clone, Serialize)]
1657pub struct MoveVolumeClusterRequest {
1658    #[serde(rename = "targetClusterId", skip_serializing_if = "Option::is_none")]
1659    pub target_cluster_id: Option<i64>,
1660    #[serde(rename = "targetClusterUuid", skip_serializing_if = "Option::is_none")]
1661    pub target_cluster_uuid: Option<String>,
1662}
1663
1664#[derive(Debug, Clone, Serialize, Deserialize)]
1665pub struct MoveClusterVolumeResponse {
1666    pub id: i64,
1667    #[serde(rename = "sourceClusterId")]
1668    pub source_cluster_id: i64,
1669    #[serde(rename = "targetClusterId")]
1670    pub target_cluster_id: i64,
1671    #[serde(rename = "handoverUntil")]
1672    pub handover_until: i64,
1673}
1674
1675#[derive(Debug, Clone, Serialize)]
1676pub struct DeactivateVolumeRequest {
1677    #[serde(rename = "isCleanupMetaEnabled", skip_serializing_if = "Option::is_none")]
1678    pub is_cleanup_meta_enabled: Option<bool>,
1679    #[serde(rename = "isCleanupStorageEnabled", skip_serializing_if = "Option::is_none")]
1680    pub is_cleanup_storage_enabled: Option<bool>,
1681    #[serde(rename = "isCleanupVaultEnabled", skip_serializing_if = "Option::is_none")]
1682    pub is_cleanup_vault_enabled: Option<bool>,
1683}
1684
1685#[derive(Debug, Clone, Serialize)]
1686pub struct GenerateVolumeAPIKeysRequest {
1687    #[serde(rename = "userId")]
1688    pub user_id: i64,
1689    #[serde(skip_serializing_if = "Option::is_none")]
1690    pub name: Option<String>,
1691}
1692
1693#[derive(Debug, Clone, Serialize, Deserialize)]
1694pub struct GenerateAPIKeysVolumeResponse {
1695    #[serde(rename = "apiKey")]
1696    pub api_key: String,
1697    #[serde(rename = "apiSecret")]
1698    pub api_secret: String,
1699    #[serde(rename = "evictedApiKeys", skip_serializing_if = "Option::is_none")]
1700    pub evicted_api_keys: Option<Vec<String>>,
1701}
1702
1703#[derive(Debug, Clone, Serialize, Deserialize)]
1704pub struct ListAPIKeysVolumeResponse {
1705    pub keys: Vec<VolumeApiKey>,
1706}
1707
1708#[derive(Debug, Clone, Serialize)]
1709pub struct RevokeVolumeAPIKeyRequest {
1710    #[serde(rename = "apiKey")]
1711    pub api_key: String,
1712}
1713
1714#[derive(Debug, Clone, Serialize)]
1715pub struct RevokeVolumeAPIKeysByUserRequest {
1716    #[serde(rename = "userId")]
1717    pub user_id: i64,
1718}
1719
1720#[derive(Debug, Clone, Serialize)]
1721pub struct GenerateVolumeSttKeyRequest {
1722    #[serde(rename = "userId", skip_serializing_if = "Option::is_none")]
1723    pub user_id: Option<i64>,
1724    #[serde(rename = "expirySeconds")]
1725    pub expiry_seconds: i64,
1726}
1727
1728#[derive(Debug, Clone, Serialize, Deserialize)]
1729pub struct GenerateSttKeyVolumeResponse {
1730    #[serde(rename = "apiKey")]
1731    pub api_key: String,
1732    #[serde(rename = "apiSecret")]
1733    pub api_secret: String,
1734    #[serde(rename = "expiresAt")]
1735    pub expires_at: String,
1736}
1737
1738#[derive(Debug, Clone, Serialize)]
1739pub struct UpdateVolumeQuotaRequest {
1740    #[serde(rename = "quotaLimit")]
1741    pub quota_limit: i64,
1742}
1743
1744#[derive(Debug, Clone, Serialize)]
1745pub struct UpdateVolumeCopysetConfigRequest {
1746    #[serde(rename = "targetCopysetCount")]
1747    pub target_copyset_count: i32,
1748}
1749
1750#[derive(Debug, Clone, Serialize, Deserialize)]
1751pub struct StatsVolumeResponse {
1752    #[serde(rename = "volumeId")]
1753    pub volume_id: String,
1754    #[serde(rename = "liveVolume")]
1755    pub live_volume: i64,
1756    #[serde(rename = "totalVolume")]
1757    pub total_volume: i64,
1758    #[serde(rename = "pendingVolume")]
1759    pub pending_volume: i64,
1760    #[serde(rename = "liveInactiveVolume")]
1761    pub live_inactive_volume: i64,
1762}
1763
1764#[derive(Debug, Clone, Serialize, Deserialize)]
1765pub struct SizeHistoryVolumeResponse {
1766    pub points: Vec<VolumeSizePoint>,
1767}
1768
1769#[derive(Debug, Clone, Serialize)]
1770pub struct CreateVolumeForkRequest {
1771    pub name: String,
1772    #[serde(rename = "parentName", skip_serializing_if = "Option::is_none")]
1773    pub parent_name: Option<String>,
1774    #[serde(rename = "asOf", skip_serializing_if = "Option::is_none")]
1775    pub as_of: Option<i64>,
1776    #[serde(rename = "volumeType", skip_serializing_if = "Option::is_none")]
1777    pub volume_type: Option<String>,
1778}
1779
1780#[derive(Debug, Clone, Serialize)]
1781pub struct DeleteVolumeForkRequest {
1782    #[serde(skip_serializing_if = "Option::is_none")]
1783    pub force: Option<bool>,
1784    #[serde(rename = "volumeType", skip_serializing_if = "Option::is_none")]
1785    pub volume_type: Option<String>,
1786}
1787
1788#[derive(Debug, Clone, Serialize, Deserialize)]
1789pub struct DeleteForkVolumeResponse {
1790    #[serde(rename = "inactivatedFids")]
1791    pub inactivated_fids: Vec<i32>,
1792}
1793
1794#[derive(Debug, Clone, Serialize)]
1795pub struct RestoreVolumeForkRequest {
1796    #[serde(rename = "volumeType", skip_serializing_if = "Option::is_none")]
1797    pub volume_type: Option<String>,
1798}
1799
1800#[derive(Debug, Clone, Default)]
1801pub struct VolumeListOptions {
1802    pub account_id: i64,
1803    pub region_id: Option<i64>,
1804    pub metadata_cluster_id: Option<i64>,
1805    pub storage_id: Option<i64>,
1806    pub volume_type: Option<String>,
1807    pub locked: Option<bool>,
1808    pub is_active: Option<bool>,
1809    pub page: Option<i64>,
1810    pub limit: Option<i64>,
1811}
1812
1813// VolumeForkTrees
1814
1815#[derive(Debug, Clone, Default)]
1816pub struct VolumeForkTreeListOptions {
1817    pub path: Option<String>,
1818    pub as_of: Option<i64>,
1819    pub cursor: Option<i64>,
1820    pub limit: Option<i64>,
1821    pub sort: Option<String>,
1822    pub kind: Option<String>,
1823}
1824
1825// VolumeForkEntries
1826
1827#[derive(Debug, Clone, Default)]
1828pub struct VolumeForkEntryListOptions {
1829    pub path: Option<String>,
1830    pub cursor: Option<i64>,
1831    pub limit: Option<i64>,
1832}
1833
1834// VolumeForkSearches
1835
1836#[derive(Debug, Clone, Default)]
1837pub struct VolumeForkSearchListOptions {
1838    pub q: Option<String>,
1839    pub path: Option<String>,
1840    pub as_of: Option<i64>,
1841    pub exact: Option<bool>,
1842    pub cursor: Option<i64>,
1843    pub limit: Option<i64>,
1844    pub kind: Option<String>,
1845}
1846
1847// AuditLogs
1848
1849#[derive(Debug, Clone, Default)]
1850pub struct AuditLogListOptions {
1851    pub account_id: i64,
1852    pub region_id: Option<i64>,
1853    pub metadata_cluster_id: Option<i64>,
1854    pub cursor: Option<i64>,
1855    pub limit: Option<i64>,
1856    pub subject: Option<String>,
1857    pub created_by: Option<String>,
1858}
1859
1860// RegionAuditLogs
1861
1862#[derive(Debug, Clone, Default)]
1863pub struct RegionAuditLogListOptions {
1864    pub metadata_cluster_id: Option<i64>,
1865    pub cursor: Option<i64>,
1866    pub limit: Option<i64>,
1867    pub subject: Option<String>,
1868    pub node: Option<String>,
1869}
1870
1871// ServiceNodes
1872
1873#[derive(Debug, Clone, Serialize, Deserialize)]
1874pub struct StatsHistoryServiceNodeResponse {
1875    #[serde(rename = "intervalMs")]
1876    pub interval_ms: i64,
1877    pub samples: Vec<NodeStatsSample>,
1878}
1879
1880// Nodes
1881
1882// ClientSessions
1883
1884#[derive(Debug, Clone, Default)]
1885pub struct ClientSessionListOptions {
1886    pub account_id: i64,
1887    pub region_id: Option<i64>,
1888    pub metadata_cluster_id: Option<i64>,
1889    pub volume_id: Option<i64>,
1890    pub user_id: Option<i64>,
1891    pub client_type: Option<String>,
1892    pub status: Option<ClientSessionStatus>,
1893    pub is_active: Option<bool>,
1894    pub os_name: Option<String>,
1895    pub platform: Option<String>,
1896    pub search: Option<String>,
1897    pub page: Option<i64>,
1898    pub limit: Option<i64>,
1899}
1900
1901// Discover
1902
1903// Metrics
1904
1905#[derive(Debug, Clone, Serialize)]
1906pub struct GenerateMetricTokenRequest {
1907    #[serde(rename = "expirySeconds")]
1908    pub expiry_seconds: i64,
1909}
1910
1911// Dashboard
1912
1913// License
1914
1915#[derive(Debug, Clone, Serialize)]
1916pub struct LoadLicenseRequest {
1917    pub payloads: Vec<String>,
1918}
1919
1920// Alerts
1921
1922#[derive(Debug, Clone, Serialize, Deserialize)]
1923pub struct ResolveAlertResponse {
1924    #[serde(rename = "alertId")]
1925    pub alert_id: String,
1926}
1927
1928#[derive(Debug, Clone, Default)]
1929pub struct AlertListOptions {
1930    pub active: Option<bool>,
1931    pub account_id: Option<i64>,
1932    pub region_id: Option<i64>,
1933    pub severity: Option<i64>,
1934    pub category: Option<String>,
1935    pub since: Option<String>,
1936    pub page: Option<i64>,
1937    pub limit: Option<i64>,
1938}
1939
1940// RegionAlerts
1941
1942#[derive(Debug, Clone, Serialize, Deserialize)]
1943pub struct ResolveRegionAlertResponse {
1944    #[serde(rename = "alertId")]
1945    pub alert_id: String,
1946}
1947
1948#[derive(Debug, Clone, Default)]
1949pub struct RegionAlertListOptions {
1950    pub active: Option<bool>,
1951    pub severity: Option<i64>,
1952    pub category: Option<String>,
1953    pub node_id: Option<String>,
1954    pub metadata_cluster_id: Option<i64>,
1955    pub since: Option<String>,
1956    pub page: Option<i64>,
1957    pub limit: Option<i64>,
1958}
1959
1960// GCWorkerEvents
1961
1962#[derive(Debug, Clone, Default)]
1963pub struct GCWorkerEventListOptions {
1964    pub node_id: Option<String>,
1965    pub goal: Option<String>,
1966    pub sid: Option<i64>,
1967    pub metadata_cluster_id: Option<i64>,
1968    pub since: Option<String>,
1969    pub page: Option<i64>,
1970    pub limit: Option<i64>,
1971}
1972
1973// Vault