🆕
webln.getBalance()
Fetch the balance of the current account.
async function getBalance(): BalanceResponse;
type BalanceResponse = {
balance: number;
currency?: "sats" | "EUR" | "USD"
}
Code Example
await webln.enable();
const result = await webln.getBalance();
Demo
Last modified 2mo ago