fireblocks_sdk/models/
travel_rule_create_transaction_request.rs

1// Fireblocks API
2//
3// Fireblocks provides a suite of applications to manage digital asset operations and a complete development platform to build your business on the blockchain.  - Visit our website for more information: [Fireblocks Website](https://fireblocks.com) - Visit our developer docs: [Fireblocks DevPortal](https://developers.fireblocks.com)
4//
5// The version of the OpenAPI document: 1.8.0
6// Contact: developers@fireblocks.com
7// Generated by: https://openapi-generator.tech
8
9use {
10    crate::models,
11    serde::{Deserialize, Serialize},
12};
13
14#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
15pub struct TravelRuleCreateTransactionRequest {
16    /// The Decentralized Identifier (DID) of the exchange (VASP) that is
17    /// sending the virtual assets. This identifier is unique to the exchange
18    /// and is generated when the exchange's account is  created in the Notabene
19    /// network.
20    #[serde(rename = "originatorVASPdid", skip_serializing_if = "Option::is_none")]
21    pub originator_vas_pdid: Option<String>,
22    /// The Decentralized Identifier (DID) of the exchange (VASP) that is
23    /// receiving the virtual assets. This identifier is unique to the exchange
24    /// and is generated when the exchange's account is  created in the Notabene
25    /// network.
26    #[serde(rename = "beneficiaryVASPdid", skip_serializing_if = "Option::is_none")]
27    pub beneficiary_vas_pdid: Option<String>,
28    /// The name of the VASP acting as the transaction originator.
29    #[serde(rename = "originatorVASPname", skip_serializing_if = "Option::is_none")]
30    pub originator_vas_pname: Option<String>,
31    /// The name of the VASP acting as the transaction beneficiary.
32    #[serde(
33        rename = "beneficiaryVASPname",
34        skip_serializing_if = "Option::is_none"
35    )]
36    pub beneficiary_vas_pname: Option<String>,
37    /// The website of the VASP acting as the transaction beneficiary.
38    #[serde(
39        rename = "beneficiaryVASPwebsite",
40        skip_serializing_if = "Option::is_none"
41    )]
42    pub beneficiary_vas_pwebsite: Option<String>,
43    /// Information about the blockchain transaction.
44    #[serde(
45        rename = "transactionBlockchainInfo",
46        skip_serializing_if = "Option::is_none"
47    )]
48    pub transaction_blockchain_info: Option<models::TravelRuleTransactionBlockchainInfo>,
49    /// Information about the originator of the transaction.
50    #[serde(rename = "originator")]
51    pub originator: models::TravelRulePiiIvms,
52    /// Information about the beneficiary of the transaction.
53    #[serde(rename = "beneficiary")]
54    pub beneficiary: models::TravelRulePiiIvms,
55    /// Encrypted data related to the transaction.
56    #[serde(rename = "encrypted", skip_serializing_if = "Option::is_none")]
57    pub encrypted: Option<String>,
58    /// The protocol used to perform the travel rule.
59    #[serde(rename = "protocol", skip_serializing_if = "Option::is_none")]
60    pub protocol: Option<String>,
61    /// Whether to skip validation of beneficiary data.
62    #[serde(
63        rename = "skipBeneficiaryDataValidation",
64        skip_serializing_if = "Option::is_none"
65    )]
66    pub skip_beneficiary_data_validation: Option<bool>,
67    /// Whether to check if the transaction complies with the travel rule in the
68    /// beneficiary VASP's jurisdiction.
69    #[serde(rename = "travelRuleBehavior", skip_serializing_if = "Option::is_none")]
70    pub travel_rule_behavior: Option<bool>,
71    /// A reference ID related to the originator of the transaction.
72    #[serde(rename = "originatorRef", skip_serializing_if = "Option::is_none")]
73    pub originator_ref: Option<String>,
74    /// A reference ID related to the beneficiary of the transaction.
75    #[serde(rename = "beneficiaryRef", skip_serializing_if = "Option::is_none")]
76    pub beneficiary_ref: Option<String>,
77    /// A reference ID related to the travel rule behavior.
78    #[serde(
79        rename = "travelRuleBehaviorRef",
80        skip_serializing_if = "Option::is_none"
81    )]
82    pub travel_rule_behavior_ref: Option<String>,
83    /// Ownership proof related to the originator of the transaction.
84    #[serde(rename = "originatorProof", skip_serializing_if = "Option::is_none")]
85    pub originator_proof: Option<models::TravelRuleOwnershipProof>,
86    /// Ownership proof related to the beneficiary of the transaction.
87    #[serde(rename = "beneficiaryProof", skip_serializing_if = "Option::is_none")]
88    pub beneficiary_proof: Option<models::TravelRuleOwnershipProof>,
89    /// The Decentralized Identifier (DID) of the person at the receiving
90    /// exchange (VASP).  This identifier is generated when the customer is
91    /// registered in the Notabene network,  or automatically created based on
92    /// the `beneficiaryRef`.  - If neither `beneficiaryRef` nor
93    /// `beneficiaryDid` is provided in the `txCreate` payload,    a new random
94    /// DID is generated for every transaction.
95    #[serde(rename = "beneficiaryDid", skip_serializing_if = "Option::is_none")]
96    pub beneficiary_did: Option<String>,
97    /// The Decentralized Identifier (DID) of the person at the exchange (VASP)
98    /// who is requesting the withdrawal. This identifier is generated when the
99    /// customer is registered in the Notabene network or automatically created
100    /// based on the `originatorRef`.  - If neither `originatorRef` nor
101    /// `originatorDid` is provided in the `txCreate` payload,    a new random
102    /// DID is generated for every transaction.
103    #[serde(rename = "originatorDid", skip_serializing_if = "Option::is_none")]
104    pub originator_did: Option<String>,
105    /// Indicates if the transaction involves a non-custodial wallet.
106    #[serde(rename = "isNonCustodial", skip_serializing_if = "Option::is_none")]
107    pub is_non_custodial: Option<bool>,
108}
109
110impl TravelRuleCreateTransactionRequest {
111    pub fn new(
112        originator: models::TravelRulePiiIvms,
113        beneficiary: models::TravelRulePiiIvms,
114    ) -> TravelRuleCreateTransactionRequest {
115        TravelRuleCreateTransactionRequest {
116            originator_vas_pdid: None,
117            beneficiary_vas_pdid: None,
118            originator_vas_pname: None,
119            beneficiary_vas_pname: None,
120            beneficiary_vas_pwebsite: None,
121            transaction_blockchain_info: None,
122            originator,
123            beneficiary,
124            encrypted: None,
125            protocol: None,
126            skip_beneficiary_data_validation: None,
127            travel_rule_behavior: None,
128            originator_ref: None,
129            beneficiary_ref: None,
130            travel_rule_behavior_ref: None,
131            originator_proof: None,
132            beneficiary_proof: None,
133            beneficiary_did: None,
134            originator_did: None,
135            is_non_custodial: None,
136        }
137    }
138}