-
Notifications
You must be signed in to change notification settings - Fork 19
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add support for getting and accepting quotes #81
base: trunk
Are you sure you want to change the base?
Conversation
use bitcoin::{ | ||
hashes::sha256, hex::DisplayHex, taproot::TapLeaf, PublicKey, ScriptBuf, Transaction, | ||
}; | ||
use bitcoin::{key, Amount}; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why is Amount
being imported?
@@ -564,6 +564,28 @@ impl BoltzApiClientV2 { | |||
let end_point = format!("chain/{}/transaction", chain); | |||
Ok(serde_json::from_str(&self.post(&end_point, data)?)?) | |||
} | |||
|
|||
/// Looks up the quote for a Zero-Amount Receive Chain Swap. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
/// Looks up the quote for a Zero-Amount Receive Chain Swap. | |
/// Gets a quote for a Zero-Amount or over- or underpaid Chain Swap. |
Ok(serde_json::from_str(&self.get(&end_point)?)?) | ||
} | ||
|
||
/// Accepts a specific quote for a Zero-Amount Receive Chain Swap. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
/// Accepts a specific quote for a Zero-Amount Receive Chain Swap. | |
/// Accepts a specific quote for a Zero-Amount or over- or underpaid Chain Swap. |
This PR adds the ability to get and accept quotes for Zero-Amount Chain Swaps.
Fixes #78