1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
/*
* Hotdata API
*
* Powerful data platform API for managed databases, queries, and analytics.
*
* The version of the OpenAPI document: 1.0.0
* Contact: developers@hotdata.dev
* Generated by: https://openapi-generator.tech
*/
use crate::models;
use serde::{Deserialize, Serialize};
/// ForkDatabaseRequest : Request body for POST /databases/{database_id}/fork
#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
pub struct ForkDatabaseRequest {
/// When the fork expires. Accepts either an RFC 3339 timestamp (e.g. `\"2026-06-01T00:00:00Z\"`) or a relative duration suffixed with `h` (hours), `m` (minutes), or `d` (days) — for example `\"24h\"` or `\"7d\"`. When omitted, a still-future expiry on the source is carried over; otherwise the fork never expires.
#[serde(
rename = "expires_at",
default,
with = "::serde_with::rust::double_option",
skip_serializing_if = "Option::is_none"
)]
pub expires_at: Option<Option<String>>,
/// Optional display label for the fork. When omitted, the source database's name (if any) is carried over.
#[serde(
rename = "name",
default,
with = "::serde_with::rust::double_option",
skip_serializing_if = "Option::is_none"
)]
pub name: Option<Option<String>>,
}
impl ForkDatabaseRequest {
/// Request body for POST /databases/{database_id}/fork
pub fn new() -> ForkDatabaseRequest {
ForkDatabaseRequest {
expires_at: None,
name: None,
}
}
}