Good point. SENDING would be much safer and easier to implement. I want to study CoinOs' implementation first. I just checked the CoinOs web interface, and I don't yet see a way to send a keysend using that... so maybe it is NWC only? In that case.. can you recommend which applications that users would typically be using to send these keysend payments (presumably they have NWC support?)
Login to reply
Replies (2)
Thank you for looking into supporting keysend.
According to my db at v4vmusic.com approx 95.5% of the music feeds support keysend only.
This will open up a vast opportunity for your wallet users to support their favorite artists.
NWC seems to be the way to go. It's been working great for me using albyhub as a proxy to my node.
If you can ever get the receiving part of keysend that would be great also. Alby has code for it in it's repo (somewhere)
Basically you use a customKey and customValue
The payments go to one node. The customKey and customValue tell you the node runner which "account" the payment belongs to.
I haven't tried it yet but I believe this is also how lnbits does it.
Receiving is a harder problem, so getting sending to work first makes the most sense.
Again, Thank You For Your Courage! 🙂
NWC seems to be the way to go. It's been working great for me using albyhub as a proxy to my node.
If you can ever get the receiving part of keysend that would be great also. Alby has code for it in it's repo (somewhere)
Basically you use a customKey and customValue
The payments go to one node. The customKey and customValue tell you the node runner which "account" the payment belongs to.
I haven't tried it yet but I believe this is also how lnbits does it.
Receiving is a harder problem, so getting sending to work first makes the most sense.
Again, Thank You For Your Courage! 🙂CoinOs's implementation is NWC-only as far as I know. Here's the relevant (Core Lightning) code from their repo:
Here's Alby Hub's LND implementation:
The main ones that support NWC right now are v4vmusic.com, Castamatic, and StableKraft.app. Podverse is adding NWC to their 2.0 version. The other apps have historically used the Alby API directly, but we're working to get each of them to adopt NWC.
GitHub
coinos-server/lib/nwc.ts at master · coinos/coinos-server
Coinos back-end application server. Contribute to coinos/coinos-server development by creating an account on GitHub.
GitHub
coinos-server/lib/payments.ts at master · coinos/coinos-server
Coinos back-end application server. Contribute to coinos/coinos-server development by creating an account on GitHub.
GitHub
hub/nip47/controllers/pay_keysend_controller.go at master · getAlby/hub
Alby Hub - Your own Bitcoin Lightning node: easy, connectable, feature-rich ✨ Run anywhere. Become self-sovereign. - getAlby/hub
GitHub
hub/lnclient/lnd/lnd.go at master · getAlby/hub
Alby Hub - Your own Bitcoin Lightning node: easy, connectable, feature-rich ✨ Run anywhere. Become self-sovereign. - getAlby/hub