Extract rust snippets and reference them

This commit is contained in:
ok300
2023-10-20 17:36:58 +02:00
parent c719cc4ae6
commit 32c39e2543
32 changed files with 4069 additions and 144 deletions

View File

@@ -0,0 +1,14 @@
use std::sync::Arc;
use anyhow::Result;
use breez_sdk_core::*;
async fn buy(sdk: Arc<BreezServices>) -> Result<()> {
let res = sdk.buy_bitcoin(
BuyBitcoinRequest {
provider: BuyBitcoinProvider::Moonpay,
opening_fee_params: None})
.await?;
Ok(())
}