Trait CashuClient
Source pub trait CashuClient {
Show 19 methods
// Required methods
fn get_keys<'life0, 'life1, 'async_trait>(
&'life0 self,
mint_url: &'life1 Url,
) -> Pin<Box<dyn Future<Output = Result<KeysResponse, MokshaWalletError>> + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
fn get_keys_by_id<'life0, 'life1, 'async_trait>(
&'life0 self,
mint_url: &'life1 Url,
keyset_id: String,
) -> Pin<Box<dyn Future<Output = Result<KeysResponse, MokshaWalletError>> + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
fn get_keysets<'life0, 'life1, 'async_trait>(
&'life0 self,
mint_url: &'life1 Url,
) -> Pin<Box<dyn Future<Output = Result<V1Keysets, MokshaWalletError>> + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
fn post_swap<'life0, 'life1, 'async_trait>(
&'life0 self,
mint_url: &'life1 Url,
proofs: Proofs,
output: Vec<BlindedMessage>,
) -> Pin<Box<dyn Future<Output = Result<PostSwapResponse, MokshaWalletError>> + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
fn post_melt_bolt11<'life0, 'life1, 'async_trait>(
&'life0 self,
mint_url: &'life1 Url,
proofs: Proofs,
quote: String,
outputs: Vec<BlindedMessage>,
) -> Pin<Box<dyn Future<Output = Result<PostMeltBolt11Response, MokshaWalletError>> + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
fn post_melt_quote_bolt11<'life0, 'life1, 'async_trait>(
&'life0 self,
mint_url: &'life1 Url,
payment_request: String,
unit: CurrencyUnit,
) -> Pin<Box<dyn Future<Output = Result<PostMeltQuoteBolt11Response, MokshaWalletError>> + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
fn get_melt_quote_bolt11<'life0, 'life1, 'async_trait>(
&'life0 self,
mint_url: &'life1 Url,
quote: String,
) -> Pin<Box<dyn Future<Output = Result<PostMeltQuoteBolt11Response, MokshaWalletError>> + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
fn post_mint_bolt11<'life0, 'life1, 'async_trait>(
&'life0 self,
mint_url: &'life1 Url,
quote: String,
blinded_messages: Vec<BlindedMessage>,
) -> Pin<Box<dyn Future<Output = Result<PostMintBolt11Response, MokshaWalletError>> + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
fn post_mint_quote_bolt11<'life0, 'life1, 'async_trait>(
&'life0 self,
mint_url: &'life1 Url,
amount: u64,
unit: CurrencyUnit,
) -> Pin<Box<dyn Future<Output = Result<PostMintQuoteBolt11Response, MokshaWalletError>> + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
fn get_mint_quote_bolt11<'life0, 'life1, 'async_trait>(
&'life0 self,
mint_url: &'life1 Url,
quote: String,
) -> Pin<Box<dyn Future<Output = Result<PostMintQuoteBolt11Response, MokshaWalletError>> + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
fn get_info<'life0, 'life1, 'async_trait>(
&'life0 self,
mint_url: &'life1 Url,
) -> Pin<Box<dyn Future<Output = Result<MintInfoResponse, MokshaWalletError>> + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
fn is_v1_supported<'life0, 'life1, 'async_trait>(
&'life0 self,
mint_url: &'life1 Url,
) -> Pin<Box<dyn Future<Output = Result<bool, MokshaWalletError>> + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
fn post_mint_onchain<'life0, 'life1, 'async_trait>(
&'life0 self,
mint_url: &'life1 Url,
quote: String,
blinded_messages: Vec<BlindedMessage>,
) -> Pin<Box<dyn Future<Output = Result<PostMintOnchainResponse, MokshaWalletError>> + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
fn post_mint_quote_onchain<'life0, 'life1, 'async_trait>(
&'life0 self,
mint_url: &'life1 Url,
amount: u64,
unit: CurrencyUnit,
) -> Pin<Box<dyn Future<Output = Result<PostMintQuoteOnchainResponse, MokshaWalletError>> + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
fn get_mint_quote_onchain<'life0, 'life1, 'async_trait>(
&'life0 self,
mint_url: &'life1 Url,
quote: String,
) -> Pin<Box<dyn Future<Output = Result<PostMintQuoteOnchainResponse, MokshaWalletError>> + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
fn post_melt_onchain<'life0, 'life1, 'async_trait>(
&'life0 self,
mint_url: &'life1 Url,
proofs: Proofs,
quote: String,
) -> Pin<Box<dyn Future<Output = Result<PostMeltOnchainResponse, MokshaWalletError>> + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
fn post_melt_quote_onchain<'life0, 'life1, 'async_trait>(
&'life0 self,
mint_url: &'life1 Url,
address: String,
amount: u64,
unit: CurrencyUnit,
) -> Pin<Box<dyn Future<Output = Result<Vec<PostMeltQuoteOnchainResponse>, MokshaWalletError>> + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
fn get_melt_quote_onchain<'life0, 'life1, 'async_trait>(
&'life0 self,
mint_url: &'life1 Url,
quote: String,
) -> Pin<Box<dyn Future<Output = Result<PostMeltQuoteOnchainResponse, MokshaWalletError>> + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
fn get_melt_onchain<'life0, 'life1, 'async_trait>(
&'life0 self,
mint_url: &'life1 Url,
txid: String,
) -> Pin<Box<dyn Future<Output = Result<GetMeltOnchainResponse, MokshaWalletError>> + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
}