offers: print out more details, fix up schema for decode of blinded paths.

We need to print out first_node_id, and "node_id" is now called
"blinded_node_id" in the spec.

And the schema didn't include the payment fields in the blinded path
for invoices (which broke as soon as we actually tested one!).

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
This commit is contained in:
Rusty Russell
2022-10-17 11:07:05 +10:30
parent e30ea91908
commit 1cdf21678e
3 changed files with 42 additions and 9 deletions

View File

@@ -254,6 +254,7 @@ static bool json_add_blinded_paths(struct json_stream *js,
json_array_start(js, "paths");
for (size_t i = 0; i < tal_count(paths); i++) {
json_object_start(js, NULL);
json_add_pubkey(js, "first_node_id", &paths[i]->first_node_id);
json_add_pubkey(js, "blinding", &paths[i]->blinding);
json_array_start(js, "path");
for (size_t j = 0; j < tal_count(paths[i]->path); j++) {