Refund Command

This commit is contained in:
Daniel Karzel 2021-02-01 16:25:33 +11:00
parent 0600a7048e
commit ad2aefc2a5
4 changed files with 102 additions and 4 deletions

View file

@ -51,6 +51,7 @@ pub enum Command {
History,
Resume(Resume),
Cancel(Cancel),
Refund(Refund),
}
#[derive(structopt::StructOpt, Debug)]
@ -98,6 +99,24 @@ pub enum Cancel {
},
}
#[derive(structopt::StructOpt, Debug)]
pub enum Refund {
BuyXmr {
#[structopt(long = "swap-id")]
swap_id: Uuid,
// TODO: Remove Alice peer-id/address, it should be saved in the database when running swap
// and loaded from the database when running resume/cancel/refund
#[structopt(long = "counterpart-peer-id")]
alice_peer_id: PeerId,
#[structopt(long = "counterpart-addr")]
alice_addr: Multiaddr,
#[structopt(flatten)]
config: Config,
},
}
#[derive(structopt::StructOpt, Debug)]
pub struct Config {
#[structopt(