mirror of
https://github.com/aljazceru/lightning.git
synced 2025-12-26 02:24:18 +01:00
Changelog-Experimental: JSON-RPC: new RPC `setleaserates`, for passing in the rates to advertise for a channel lease (option_will_fund)
4.5 KiB
4.5 KiB
| 1 | #include <common/cryptomsg.h> |
|---|---|
| 2 | #include <common/features.h> |
| 3 | #include <common/wireaddr.h> |
| 4 | #include <wire/peer_wire.h> |
| 5 | #include <wire/onion_wire.h> |
| 6 | # Initialize the gossip daemon. |
| 7 | msgtype,gossipd_init,3000 |
| 8 | msgdata,gossipd_init,chainparams,chainparams, |
| 9 | msgdata,gossipd_init,our_features,feature_set, |
| 10 | msgdata,gossipd_init,id,node_id, |
| 11 | msgdata,gossipd_init,rgb,u8,3 |
| 12 | msgdata,gossipd_init,alias,u8,32 |
| 13 | msgdata,gossipd_init,num_announcable,u16, |
| 14 | msgdata,gossipd_init,announcable,wireaddr,num_announcable |
| 15 | msgdata,gossipd_init,dev_gossip_time,?u32, |
| 16 | msgdata,gossipd_init,dev_fast_gossip,bool, |
| 17 | msgdata,gossipd_init,dev_fast_gossip_prune,bool, |
| 18 | msgtype,gossipd_init_reply,3100 |
| 19 | # In developer mode, we can mess with time. |
| 20 | msgtype,gossipd_dev_set_time,3001 |
| 21 | msgdata,gossipd_dev_set_time,dev_gossip_time,u32, |
| 22 | # Ping/pong test. Waits for a reply if it expects one. |
| 23 | msgtype,gossipd_ping,3008 |
| 24 | msgdata,gossipd_ping,id,node_id, |
| 25 | msgdata,gossipd_ping,num_pong_bytes,u16, |
| 26 | msgdata,gossipd_ping,len,u16, |
| 27 | msgtype,gossipd_ping_reply,3108 |
| 28 | msgdata,gossipd_ping_reply,id,node_id, |
| 29 | # False if id in gossip_ping was unknown. |
| 30 | msgdata,gossipd_ping_reply,sent,bool, |
| 31 | # 0 == no pong expected |
| 32 | msgdata,gossipd_ping_reply,totlen,u16, |
| 33 | # Set artificial maximum reply_channel_range size. Master->gossipd |
| 34 | msgtype,gossipd_dev_set_max_scids_encode_size,3030 |
| 35 | msgdata,gossipd_dev_set_max_scids_encode_size,max,u32, |
| 36 | # Given a short_channel_id, return the latest (stripped) update for error msg. |
| 37 | msgtype,gossipd_get_stripped_cupdate,3010 |
| 38 | msgdata,gossipd_get_stripped_cupdate,channel_id,short_channel_id, |
| 39 | msgtype,gossipd_get_stripped_cupdate_reply,3110 |
| 40 | msgdata,gossipd_get_stripped_cupdate_reply,stripped_update_len,u16, |
| 41 | msgdata,gossipd_get_stripped_cupdate_reply,stripped_update,u8,stripped_update_len |
| 42 | # gossipd->master: we're closing this channel. |
| 43 | msgtype,gossipd_local_channel_close,3027 |
| 44 | msgdata,gossipd_local_channel_close,short_channel_id,short_channel_id, |
| 45 | # Gossipd->master get this tx output please. |
| 46 | msgtype,gossipd_get_txout,3018 |
| 47 | msgdata,gossipd_get_txout,short_channel_id,short_channel_id, |
| 48 | # master->gossipd here is the output, or empty if none. |
| 49 | msgtype,gossipd_get_txout_reply,3118 |
| 50 | msgdata,gossipd_get_txout_reply,short_channel_id,short_channel_id, |
| 51 | msgdata,gossipd_get_txout_reply,satoshis,amount_sat, |
| 52 | msgdata,gossipd_get_txout_reply,len,u16, |
| 53 | msgdata,gossipd_get_txout_reply,outscript,u8,len |
| 54 | # master -> gossipd: a potential funding outpoint was spent, please forget the eventual channel |
| 55 | msgtype,gossipd_outpoint_spent,3024 |
| 56 | msgdata,gossipd_outpoint_spent,short_channel_id,short_channel_id, |
| 57 | # master -> gossipd: stop gossip timers. |
| 58 | msgtype,gossipd_dev_suppress,3032 |
| 59 | # master -> gossipd: do you have a memleak? |
| 60 | msgtype,gossipd_dev_memleak,3033 |
| 61 | msgtype,gossipd_dev_memleak_reply,3133 |
| 62 | msgdata,gossipd_dev_memleak_reply,leak,bool, |
| 63 | # master -> gossipd: please rewrite the gossip_store |
| 64 | msgtype,gossipd_dev_compact_store,3034 |
| 65 | # gossipd -> master: ok |
| 66 | msgtype,gossipd_dev_compact_store_reply,3134 |
| 67 | msgdata,gossipd_dev_compact_store_reply,success,bool, |
| 68 | # master -> gossipd: blockheight increased. |
| 69 | msgtype,gossipd_new_blockheight,3026 |
| 70 | msgdata,gossipd_new_blockheight,blockheight,u32, |
| 71 | # Tell lightningd we got a onion message (for us, or to fwd) |
| 72 | msgtype,gossipd_got_onionmsg_to_us,3142 |
| 73 | msgdata,gossipd_got_onionmsg_to_us,blinding_in,?pubkey, |
| 74 | msgdata,gossipd_got_onionmsg_to_us,reply_blinding,?pubkey, |
| 75 | msgdata,gossipd_got_onionmsg_to_us,reply_path_len,u16, |
| 76 | msgdata,gossipd_got_onionmsg_to_us,reply_path,onionmsg_path,reply_path_len |
| 77 | msgdata,gossipd_got_onionmsg_to_us,rawmsg_len,u16, |
| 78 | msgdata,gossipd_got_onionmsg_to_us,rawmsg,u8,rawmsg_len |
| 79 | msgtype,gossipd_got_onionmsg_forward,3143 |
| 80 | msgdata,gossipd_got_onionmsg_forward,next_scid,?short_channel_id, |
| 81 | msgdata,gossipd_got_onionmsg_forward,next_node_id,?node_id, |
| 82 | msgdata,gossipd_got_onionmsg_forward,next_blinding,?pubkey, |
| 83 | msgdata,gossipd_got_onionmsg_forward,next_onion_len,u16, |
| 84 | msgdata,gossipd_got_onionmsg_forward,next_onion,u8,next_onion_len |
| 85 | # Lightningd tells us to send a onion message. |
| 86 | msgtype,gossipd_send_onionmsg,3040 |
| 87 | msgdata,gossipd_send_onionmsg,id,node_id, |
| 88 | msgdata,gossipd_send_onionmsg,onion_len,u16, |
| 89 | msgdata,gossipd_send_onionmsg,onion,u8,onion_len |
| 90 | msgdata,gossipd_send_onionmsg,blinding,?pubkey, |
| 91 | # Lightningd tells us to inject a gossip message (for addgossip RPC) |
| 92 | msgtype,gossipd_addgossip,3044 |
| 93 | msgdata,gossipd_addgossip,len,u16, |
| 94 | msgdata,gossipd_addgossip,msg,u8,len |
| 95 | # Empty string means no problem. |
| 96 | msgtype,gossipd_addgossip_reply,3144 |
| 97 | msgdata,gossipd_addgossip_reply,err,wirestring, |
| 98 | # Updated lease rates available |
| 99 | msgtype,gossipd_new_lease_rates,3046 |
| 100 | msgdata,gossipd_new_lease_rates,rates,lease_rates, |