mirror of https://github.com/bumi/lnrpc
More examples
This commit is contained in:
parent
26e15192eb
commit
57f36b69ff
18
examples.rb
18
examples.rb
|
@ -21,6 +21,18 @@ puts lnd.versioner.get_version
|
|||
puts lnd.wallet_kit.estimate_fee(conf_target: 10)
|
||||
puts lnd.wallet_kit.next_addr
|
||||
|
||||
lnd.lightning.subscribe_invoices(settle_index: 1).each do |invoice|
|
||||
puts invoice.payment_request
|
||||
end
|
||||
channel = lnd.lightning.list_channels.channels[0]
|
||||
puts lnd.lightning.get_chan_info(chan_id: channel.chan_id)
|
||||
channel_point = {
|
||||
funding_txid_str: channel.channel_point.split(":")[0],
|
||||
output_index: channel.channel_point.split(":")[1].to_i
|
||||
}
|
||||
lnd.lightning.update_channel_policy({
|
||||
time_lock_delta: 40,
|
||||
base_fee_msat: 1100,
|
||||
chan_point: channel_point
|
||||
})
|
||||
|
||||
#lnd.lightning.subscribe_invoices(settle_index: 1).each do |invoice|
|
||||
# puts invoice.payment_request
|
||||
#end
|
||||
|
|
Loading…
Reference in New Issue