diff --git a/src/config.rs b/src/config.rs index c98934d..3161b2e 100644 --- a/src/config.rs +++ b/src/config.rs @@ -46,6 +46,9 @@ pub struct Opts { /// FT account id #[clap(long, env)] pub ft_account_id: AccountId, + /// Exchange account id + #[clap(long, env)] + pub exchange_id: AccountId, /// Pool id for swap command #[clap(long, env)] pub pool_id: u32, diff --git a/src/transaction/swap.rs b/src/transaction/swap.rs index 18c26a4..d2d7e2a 100644 --- a/src/transaction/swap.rs +++ b/src/transaction/swap.rs @@ -46,7 +46,7 @@ impl TransactionSample for Swap { Action::FunctionCall(Box::new(FunctionCallAction { method_name: "ft_transfer_call".to_string(), args: serde_json::json!( - {"msg": msg,"amount": "1000000000000000000000","receiver_id": "v2.ref-finance.near"}).to_string().into_bytes(), + {"msg": msg,"amount": "1000000000000000000000","receiver_id": opts.exchange_id}).to_string().into_bytes(), gas: 100_000_000_000_000, // 100 TeraGas deposit: 1, })),