BlueWallet / LndHub

Wrapper for Lightning Network Daemon. It provides separate accounts for end-users
http://LndHub.io
MIT License
752 stars 185 forks source link

Add support to pass description_hash to LND #319

Open bumi opened 2 years ago

bumi commented 2 years ago

This adds support to pass an additional, optional description_hash to the addinvoice call. The API stays the same it simply adds support for passing an additional parameter.

Some applications (e.g. LNURLpay/lighting addresses) require the possibility to set a description_hash. This becomes possible with this change.

johnsBeharry commented 2 years ago

+1

I also have the need for description_hash in a project im working on. Since https://github.com/BlueWallet/LndHub/pull/291 is a bigger change, and seem like it will take sometime before it's merged this update would be more than suitable as a stop gap for us to provide lnurl-pay functionality on-top of lndhub.

bumi commented 2 years ago

I also think full lnurl support should not be part of LNDhub and LNDHub should only be a small accounting layer on top of LND. Anything LNURL related can then be built using the LNDHub API in a separate service.

kiwiidb commented 2 years ago

I also think full lnurl support should not be part of LNDhub and LNDHub should only be a small accounting layer on top of LND. Anything LNURL related can then be built using the LNDHub API in a separate service.

I agree with this, but shouldn't LNDHub have a public endpoint to fetch an invoice, without the need for an Authorization header? You can still have rate limiting ofcourse, but I feel it would make the implementation of a supporting LNURL service a lot easier.

bumi commented 2 years ago

hmm... I don't have much thoughts about this. But then it would need to implement the LNURL response also? or it would be a custom response format (which I think would be helpful to implement features to call lndhub from JS in the browser (e.g. for some tipping)

dennisreimann commented 2 years ago

@Overtorment this would be a very helpful addition for LNURL support – please consider integrating it.

kiwiidb commented 2 years ago

@dennisreimann The bluewallet team has stated that there won't be any new features added to lndhub.io. Check out https://github.com/getAlby/lndhub.go for an alternative.

dennisreimann commented 2 years ago

@kiwiidb thanks for the heads-up.

That's unfortunate as I'm working on an integration of LNDhub wallets for BTCPay Server. I'd like to allow merchants to use their BlueWallet account as an external Lightning Node.

From what I see, they will then also be able to use their Alby wallet for that – glad that your compatible API seems to be developed further :)