deriv_api_schema/cancel.rs
1
2// Generated automatically by schema_generator.rs - DO NOT EDIT.
3// Source: ./deriv-api-docs/config/v3/cancel/receive.json
4
5// Use direct crate names for imports within generated files
6use serde::{Deserialize, Serialize};
7
8
9
10
11// Import shared types from the *same* crate
12
13// It's a struct
14/// Receipt for the transaction
15#[derive(Debug, Clone, Serialize, Deserialize)]
16#[serde(rename_all = "snake_case")]
17pub struct Cancel {
18 /// New account balance after completion of the sale\n
19 // Correct serde attribute construction - Use helper
20 #[serde(skip_serializing_if = "Option::is_none")]
21 pub balance_after: Option<f64>,
22 /// Internal contract identifier for the sold contract\n
23 // Correct serde attribute construction - Use helper
24 #[serde(skip_serializing_if = "Option::is_none")]
25 pub contract_id: Option<i64>,
26 /// Internal transaction identifier for the corresponding buy transaction\n
27 // Correct serde attribute construction - Use helper
28 #[serde(skip_serializing_if = "Option::is_none")]
29 pub reference_id: Option<i64>,
30 /// Actual effected sale price\n
31 // Correct serde attribute construction - Use helper
32 #[serde(skip_serializing_if = "Option::is_none")]
33 pub sold_for: Option<String>,
34 /// Internal transaction identifier for the sale transaction\n
35 // Correct serde attribute construction - Use helper
36 #[serde(skip_serializing_if = "Option::is_none")]
37 pub transaction_id: Option<i64>,
38}
39