alongside one tap zap nip47 also supports showing your wallet balance in-app, so damus can let you know when youβre out of corn. very cool.
Discussion
very cool π€π»π
nostr:npub1gcxzte5zlkncx26j68ez60fzkvtkm9e0vrwdcvsjakxf9mu9qewqlfnj5z is there API for Damus & Amethyst
#nostr
Yep, we use the same
Does it?
It doesnt at the moment. Should the balance be a replaceable event or an rpc call?
get_balance is in nip47 is it not ?
It's not
I see. I saw it mentioned but I guess it was just an example. Would be nice to have it.
Should definitely be an rpc call, not a replaceable event
Why not a replaceable event? Would make sense, no?
hmm I guess that would be good for realtime balance updates
It would. But what if your balance changes because of a non-zap π€ could be tricky to implement on the back-end side
You just send the event whenever a payment is received, is your backend not setup for that ?
Haha that's optimistic of you π yeah it is possible but a bit more work. We have a fairly simple open source backend github.com/getAlby/nostr-wallet-connect so we would need to hook this up to our event queue
There is a privacy issue with this. You could easily probe the relay by sending lightning payments to an account and subscribing to the replaceable events to see which nostr keys are associated with what account.
The wallet balance is not part of NIP-47, is it? How does it get that information?