-
Notifications
You must be signed in to change notification settings - Fork 138
Description
Is your feature request related to a problem? Please describe.
Currently, when a Price Oracle receives a QueryAssetRates call, it doesn't know the pubkey of the node that made the call.
Particularly when the caller is an edge node, the Price Oracle might want to know its pubkey so that it could pull more data from it in order to make a better, more informed quote.
Describe the solution you'd like
There is a counterparty_id field in QueryAssetRatesRequest but when an edge node is calling QueryAssetRates this field has the other node's pubkey.
I think the simplest solution is another field like node_id which is the pubkey of the calling node.
That way you know the calling node's pubkey as well as its counterparty's pubkey.
Describe alternatives you've considered
There is a metadata field in QueryAssetRatesRequest which could be set when calling AddInvoice or SendPaymentV2 but this requires customized API calls and is not a generic solution.
Also, setting the metadata field means that an AddInvoice call is restricted to a single edge node and you can't automatically get the best rate from multiple edge nodes. If you wanted to do that, you would have to make an AddInvoice call (or an AddAssetBuyOrder or AddAssetSellOrder) to each edge node and then manually choose the best rate.
We would like a generic solution that doesn't rely on having to manually set the metadata.
Possibly related: #1362
Metadata
Metadata
Assignees
Labels
Type
Projects
Status