syntax = "proto3"; package cln; // This file was automatically derived from the JSON-RPC schemas in // `doc/schemas`. Do not edit this file manually as it would get // overwritten. import "primitives.proto"; service Node { rpc Getinfo(GetinfoRequest) returns (GetinfoResponse) {} rpc ListPeers(ListpeersRequest) returns (ListpeersResponse) {} rpc ListFunds(ListfundsRequest) returns (ListfundsResponse) {} rpc ListChannels(ListchannelsRequest) returns (ListchannelsResponse) {} rpc AddGossip(AddgossipRequest) returns (AddgossipResponse) {} rpc AutoCleanInvoice(AutocleaninvoiceRequest) returns (AutocleaninvoiceResponse) {} rpc CheckMessage(CheckmessageRequest) returns (CheckmessageResponse) {} rpc Close(CloseRequest) returns (CloseResponse) {} } message GetinfoRequest { } message GetinfoResponse { bytes id = 1; string alias = 2; bytes color = 3; uint32 num_peers = 4; uint32 num_pending_channels = 5; uint32 num_active_channels = 6; uint32 num_inactive_channels = 7; string version = 8; string lightning_dir = 9; uint32 blockheight = 11; string network = 12; Amount fees_collected_msat = 13; repeated GetinfoAddress address = 14; repeated GetinfoBinding binding = 15; optional string warning_bitcoind_sync = 16; optional string warning_lightningd_sync = 17; } message GetinfoOur_features { bytes init = 1; bytes node = 2; bytes channel = 3; bytes invoice = 4; } message GetinfoAddress { // Getinfo.address[].type enum GetinfoAddressType { DNS = 0; IPV4 = 1; IPV6 = 2; TORV2 = 3; TORV3 = 4; WEBSOCKET = 5; } GetinfoAddressType item_type = 1; uint32 port = 2; optional string address = 3; } message GetinfoBinding { // Getinfo.binding[].type enum GetinfoBindingType { LOCAL_SOCKET = 0; IPV4 = 1; IPV6 = 2; TORV2 = 3; TORV3 = 4; } GetinfoBindingType item_type = 1; optional string address = 2; optional uint32 port = 3; optional string socket = 4; } message ListpeersRequest { optional bytes id = 1; optional string level = 2; } message ListpeersResponse { repeated ListpeersPeers peers = 3; } message ListpeersPeers { bytes id = 1; bool connected = 2; repeated ListpeersPeersLog log = 3; repeated ListpeersPeersChannels channels = 4; repeated string netaddr = 5; optional bytes features = 6; } message ListpeersPeersLog { // ListPeers.peers[].log[].type enum ListpeersPeersLogType { SKIPPED = 0; BROKEN = 1; UNUSUAL = 2; INFO = 3; DEBUG = 4; IO_IN = 5; IO_OUT = 6; } ListpeersPeersLogType item_type = 1; optional uint32 num_skipped = 2; optional string time = 3; optional string source = 4; optional string log = 5; optional bytes node_id = 6; optional bytes data = 7; } message ListpeersPeersChannels { // ListPeers.peers[].channels[].state enum ListpeersPeersChannelsState { OPENINGD = 0; CHANNELD_AWAITING_LOCKIN = 1; CHANNELD_NORMAL = 2; CHANNELD_SHUTTING_DOWN = 3; CLOSINGD_SIGEXCHANGE = 4; CLOSINGD_COMPLETE = 5; AWAITING_UNILATERAL = 6; FUNDING_SPEND_SEEN = 7; ONCHAIN = 8; DUALOPEND_OPEN_INIT = 9; DUALOPEND_AWAITING_LOCKIN = 10; } ListpeersPeersChannelsState state = 1; optional bytes scratch_txid = 2; optional string owner = 4; optional string short_channel_id = 5; optional bytes channel_id = 6; optional bytes funding_txid = 7; optional uint32 funding_outnum = 8; optional string initial_feerate = 9; optional string last_feerate = 10; optional string next_feerate = 11; optional uint32 next_fee_step = 12; repeated ListpeersPeersChannelsInflight inflight = 13; optional bytes close_to = 14; optional bool private = 15; ChannelSide opener = 16; optional ChannelSide closer = 17; repeated string features = 18; optional Amount to_us_msat = 20; optional Amount min_to_us_msat = 21; optional Amount max_to_us_msat = 22; optional Amount total_msat = 23; optional Amount fee_base_msat = 24; optional uint32 fee_proportional_millionths = 25; optional Amount dust_limit_msat = 26; optional Amount max_total_htlc_in_msat = 27; optional Amount their_reserve_msat = 28; optional Amount our_reserve_msat = 29; optional Amount spendable_msat = 30; optional Amount receivable_msat = 31; optional Amount minimum_htlc_in_msat = 32; optional uint32 their_to_self_delay = 33; optional uint32 our_to_self_delay = 34; optional uint32 max_accepted_htlcs = 35; repeated string status = 37; optional uint64 in_payments_offered = 38; optional Amount in_offered_msat = 39; optional uint64 in_payments_fulfilled = 40; optional Amount in_fulfilled_msat = 41; optional uint64 out_payments_offered = 42; optional Amount out_offered_msat = 43; optional uint64 out_payments_fulfilled = 44; optional Amount out_fulfilled_msat = 45; repeated ListpeersPeersChannelsHtlcs htlcs = 46; optional string close_to_addr = 47; } message ListpeersPeersChannelsFeerate { uint32 perkw = 1; uint32 perkb = 2; } message ListpeersPeersChannelsInflight { bytes funding_txid = 1; uint32 funding_outnum = 2; string feerate = 3; Amount total_funding_msat = 4; Amount our_funding_msat = 5; bytes scratch_txid = 6; } message ListpeersPeersChannelsFunding { Amount local_msat = 1; Amount remote_msat = 2; Amount pushed_msat = 3; } message ListpeersPeersChannelsHtlcs { // ListPeers.peers[].channels[].htlcs[].direction enum ListpeersPeersChannelsHtlcsDirection { IN = 0; OUT = 1; } // ListPeers.peers[].channels[].htlcs[].state enum ListpeersPeersChannelsHtlcsState { SENT_ADD_HTLC = 0; SENT_ADD_COMMIT = 1; RCVD_ADD_REVOCATION = 2; RCVD_ADD_ACK_COMMIT = 3; SENT_ADD_ACK_REVOCATION = 4; RCVD_REMOVE_HTLC = 5; RCVD_REMOVE_COMMIT = 6; SENT_REMOVE_REVOCATION = 7; SENT_REMOVE_ACK_COMMIT = 8; RCVD_REMOVE_ACK_REVOCATION = 9; } ListpeersPeersChannelsHtlcsDirection direction = 1; uint64 id = 2; Amount amount_msat = 3; uint32 expiry = 4; bytes payment_hash = 5; optional bool local_trimmed = 6; optional string status = 7; ListpeersPeersChannelsHtlcsState state = 8; } message ListfundsRequest { optional bool spent = 1; } message ListfundsResponse { repeated ListfundsOutputs outputs = 2; repeated ListfundsChannels channels = 3; } message ListfundsOutputs { // ListFunds.outputs[].status enum ListfundsOutputsStatus { UNCONFIRMED = 0; CONFIRMED = 1; SPENT = 2; } bytes txid = 1; uint32 output = 2; Amount amount_msat = 3; bytes scriptpubkey = 4; optional string address = 5; optional bytes redeemscript = 6; ListfundsOutputsStatus status = 7; optional uint32 blockheight = 8; } message ListfundsChannels { bytes peer_id = 1; Amount our_amount_msat = 2; Amount amount_msat = 3; bytes funding_txid = 4; uint32 funding_output = 5; bool connected = 6; ChannelState state = 7; optional string short_channel_id = 8; } message ListchannelsRequest { optional string short_channel_id = 1; optional bytes source = 2; optional bytes destination = 3; } message ListchannelsResponse { repeated ListchannelsChannels channels = 4; } message ListchannelsChannels { bytes source = 1; bytes destination = 2; string short_channel_id = 3; bool public = 4; Amount amount_msat = 5; uint32 message_flags = 6; uint32 channel_flags = 7; bool active = 8; uint32 last_update = 9; uint32 base_fee_millisatoshi = 10; uint32 fee_per_millionth = 11; uint32 delay = 12; Amount htlc_minimum_msat = 13; optional Amount htlc_maximum_msat = 14; bytes features = 15; } message AddgossipRequest { bytes message = 1; } message AddgossipResponse { } message AutocleaninvoiceRequest { optional uint64 expired_by = 1; optional uint64 cycle_seconds = 2; } message AutocleaninvoiceResponse { bool enabled = 3; optional uint64 expired_by = 1; optional uint64 cycle_seconds = 2; } message CheckmessageRequest { string message = 1; string zbase = 2; optional bytes pubkey = 3; } message CheckmessageResponse { bool verified = 4; optional bytes pubkey = 3; } message CloseRequest { bytes id = 1; optional uint32 unilateraltimeout = 2; optional string destination = 3; optional string fee_negotiation_step = 4; optional bytes wrong_funding = 5; optional bool force_lease_closed = 6; } message CloseResponse { // Close.type enum CloseType { MUTUAL = 0; UNILATERAL = 1; UNOPENED = 2; } CloseType item_type = 7; optional bytes tx = 8; optional bytes txid = 9; }