[feature]: Support MPP record (alias Payment_Address) for more RPC calls
We should always enforce MPP payments because they include the payment_secret which has been introduced a while ago and therefore we should also be able to include the MPP record in the following RPC-Calls.
They are now required in the specification for writer and reader of an invoice, and when sending via a route we should also make sure we include an MPP record.
relates to https://github.com/lightningnetwork/lnd/pull/9752
Tasks to do:
QueryRoutesshould support including an MPP record (payment_addr) when querying the route which can then be used inSendToRouteSendToRouteshould also enforce an MPP record.
Extras:
- Allow AMP Record in
buildroute - Allow Setting AMP record for
QueryRoutes - Allow
SendToRoutewith an AMP record
I want to contribute
This should also include the buildroute rpc: https://github.com/lightningnetwork/lnd/pull/9752#issuecomment-2973528775
@ziggie1984 I've been working on an initial implementation for this, pushed up what I have so far to https://github.com/lightningnetwork/lnd/pull/10091. There's a lot of work left but at least it's a starting point. Would love feedback/suggestions.
Hi! I see this issue has been stale for a while. I'm a Summer of Bitcoin applicant and I'd like to pick this up and finish the work started by the previous contributor. Is it okay if I take this over?
Consolidating related issue here. The following has been closed as a duplicate:
- #4020 — Original request (from lnd 0.9.0 era) that
QueryRoutes/SendToRouteand other payment APIs should accepttotal_amountandpayment_addressfields. Notes a workaround:SendToRoutecan accept the payment address, but you must manually mutate the route, andQueryRouteswon't properly account for the TLV record size (workaround: add dummy custom records when querying, remove when sending).
@ziggie1984. Hi. thought i'd give this a go seeing as no one is assigned to it - https://github.com/lightningnetwork/lnd/pull/10801
Hope this helps!