Skip to main content

oanda_v20_openapi/models/
order_client_extensions_modify_transaction.rs

1/*
2 * OANDA v20 API
3 *
4 * The full OANDA v20 API Specification. This specification defines how to interact with v20 Accounts, Trades, Orders, Pricing and more.
5 *
6 * The version of the OpenAPI document: 0.2.1
7 * Contact: jmicoud02@gmail.com
8 * Generated by: https://openapi-generator.tech
9 */
10
11use crate::models;
12use serde::{Deserialize, Serialize};
13
14/// OrderClientExtensionsModifyTransaction : A OrderClientExtensionsModifyTransaction represents the modification of an Order's Client Extensions.
15#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
16pub struct OrderClientExtensionsModifyTransaction {
17    /// The Transaction's Identifier.
18    #[serde(rename = "id", skip_serializing_if = "Option::is_none")]
19    pub id: Option<i32>,
20    /// A date and time value using either RFC3339 or UNIX time representation. The RFC 3339 representation is a string conforming to https://tools.ietf.org/rfc/rfc3339.txt. The Unix representation is a string representing the number of seconds since the Unix Epoch (January 1st, 1970 at UTC). The value is a fractional number, where the fractional part represents a fraction of a second (up to nine decimal places).
21    #[serde(rename = "time", skip_serializing_if = "Option::is_none")]
22    pub time: Option<String>,
23    /// The ID of the user that initiated the creation of the Transaction.
24    #[serde(rename = "userID", skip_serializing_if = "Option::is_none")]
25    pub user_id: Option<i32>,
26    /// The Account's identifier
27    #[serde(rename = "accountID", skip_serializing_if = "Option::is_none")]
28    pub account_id: Option<String>,
29    /// The ID of the \"batch\" that the Transaction belongs to. Transactions in the same batch are applied to the Account simultaneously.
30    #[serde(rename = "batchID", skip_serializing_if = "Option::is_none")]
31    pub batch_id: Option<i32>,
32    /// The Request ID of the request which generated the transaction.
33    #[serde(rename = "requestID", skip_serializing_if = "Option::is_none")]
34    pub request_id: Option<String>,
35    #[serde(rename = "type", skip_serializing_if = "Option::is_none")]
36    pub r#type: Option<models::TransactionType>,
37    /// The ID of the Order who's client extensions are to be modified.
38    #[serde(rename = "orderID", skip_serializing_if = "Option::is_none")]
39    pub order_id: Option<i32>,
40    /// The original Client ID of the Order who's client extensions are to be modified.
41    #[serde(rename = "clientOrderID", skip_serializing_if = "Option::is_none")]
42    pub client_order_id: Option<String>,
43    #[serde(rename = "clientExtensionsModify", skip_serializing_if = "Option::is_none")]
44    pub client_extensions_modify: Option<Box<models::ClientExtensions>>,
45    #[serde(rename = "tradeClientExtensionsModify", skip_serializing_if = "Option::is_none")]
46    pub trade_client_extensions_modify: Option<Box<models::ClientExtensions>>,
47}
48
49impl OrderClientExtensionsModifyTransaction {
50    /// A OrderClientExtensionsModifyTransaction represents the modification of an Order's Client Extensions.
51    pub fn new() -> OrderClientExtensionsModifyTransaction {
52        OrderClientExtensionsModifyTransaction {
53            id: None,
54            time: None,
55            user_id: None,
56            account_id: None,
57            batch_id: None,
58            request_id: None,
59            r#type: None,
60            order_id: None,
61            client_order_id: None,
62            client_extensions_modify: None,
63            trade_client_extensions_modify: None,
64        }
65    }
66}
67