MCPcopy Create free account
hub / github.com/ElementsProject/lightning / json_add_onionmsg_path

Function json_add_onionmsg_path

plugins/offers.c:229–246  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

227}
228
229static void json_add_onionmsg_path(struct json_stream *js,
230 const char *fieldname,
231 const struct onionmsg_path *path,
232 const struct blinded_payinfo *payinfo)
233{
234 json_object_start(js, fieldname);
235 json_add_pubkey(js, "node_id", &path->node_id);
236 json_add_hex_talarr(js, "encrypted_recipient_data", path->encrypted_recipient_data);
237 if (payinfo) {
238 json_add_u32(js, "fee_base_msat", payinfo->fee_base_msat);
239 json_add_u32(js, "fee_proportional_millionths",
240 payinfo->fee_proportional_millionths);
241 json_add_u32(js, "cltv_expiry_delta",
242 payinfo->cltv_expiry_delta);
243 json_add_hex_talarr(js, "features", payinfo->features);
244 }
245 json_object_end(js);
246}
247
248/* Returns true if valid */
249static bool json_add_blinded_paths(struct json_stream *js,

Callers 1

json_add_blinded_pathsFunction · 0.85

Calls 5

json_add_pubkeyFunction · 0.85
json_object_startFunction · 0.50
json_add_hex_talarrFunction · 0.50
json_add_u32Function · 0.50
json_object_endFunction · 0.50

Tested by

no test coverage detected