Skip to content

xpay: Allow "includefees" option to deduct fees from total. #8353

@rustyrussell

Description

@rustyrussell

This is actually really tricky to implement, but useful for the case of "I want to spend all my funds". Note that this is more specific than allowing "all" as them amount parameter to xpay:

  • You may want to use it (with layers) to drain a specific channel.
  • If you're using accounts (I'm writing such a plugin) "all my funds" may not be "all the funds on the node" but some subset.

It's particularly hard with bolt12, since you have to request the invoice with a specific amount (though, you can overpay!) and you don't know the route yet!

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions