peakshift / makers.bolt.fun

https://makers.bolt.fun
GNU General Public License v3.0
31 stars 21 forks source link

Add description to lightning payments #111

Open barefoot-88 opened 2 years ago

barefoot-88 commented 2 years ago

Issue

Currently when a user wants to upvote a story/comment/project, they are unable to see any description for this within the Alby widget.

Screenshot 2022-08-02 at 13 33 43

Solution

Provide a description/message that can be used for each category of payment. This gives context to the action and let's the user remember what the payment was for and who it went to.

Stories ✍️ = "Reward {username} for their awesome story." Comment 💬 = "Reward {username} for their awesome comment." Product 🚀 = "Reward {product-name} for their awesome work."

Here's an example of a description for a TX within Alby. image

barefoot-88 commented 2 years ago

Question

HMW display a description/message that makes sense to read for both the sender and receiver?

johnsBeharry commented 2 years ago

While we're at it the structure should use NameDesc spec for the description formatting. https://github.com/lightning/blips/blob/master/blip-0011.md#specification

MTG2000 commented 2 years ago

@johnsBeharry A question btw.

How can we customize the description field of an invoice that get generated on a lightning-address server. When you want to make a payment currently: 1- We make a request to the users lightning address server (eg. getalby.com/.well-known/lnurlp/mtg). 2- we get a callback url that we can call with the amount query param to get a payment_request that we can return to the user to pay.

So in which stage can we specify what description we want the wallet to show?? I've been searching for a while for that, but couldn't find any example or mentioning of this...

So if you know how to do this, please tell me how to do so.

MTG2000 commented 1 year ago

@johnsBeharry Please check my old comment above. With the current method we are handling the invoice generation, I don't think it's possible to add a description to it. (I looked again today) If you know of some way to do that, please let me know.