fireblocks_sdk/models/
convert_assets_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 ConvertAssetsRequest {
16    /// Name of the source asset (must be in a currency that is supported for
17    /// conversions in the selected exchange type that corresponds to your
18    /// exchange ID)
19    #[serde(rename = "srcAsset")]
20    pub src_asset: String,
21    /// Name of the destination asset (must be in a currency that is supported
22    /// for conversions in the selected exchange type that corresponds to your
23    /// exchange ID)
24    #[serde(rename = "destAsset")]
25    pub dest_asset: String,
26    /// The amount to transfer (in the currency of the source asset)
27    #[serde(rename = "amount")]
28    pub amount: f64,
29}
30
31impl ConvertAssetsRequest {
32    pub fn new(src_asset: String, dest_asset: String, amount: f64) -> ConvertAssetsRequest {
33        ConvertAssetsRequest {
34            src_asset,
35            dest_asset,
36            amount,
37        }
38    }
39}