mirror of
https://github.com/bumi/lnrpc
synced 2025-06-16 13:25:34 +00:00
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.estimate_fee(conf_target: 10)
|
||||||
puts lnd.wallet_kit.next_addr
|
puts lnd.wallet_kit.next_addr
|
||||||
|
|
||||||
lnd.lightning.subscribe_invoices(settle_index: 1).each do |invoice|
|
channel = lnd.lightning.list_channels.channels[0]
|
||||||
puts invoice.payment_request
|
puts lnd.lightning.get_chan_info(chan_id: channel.chan_id)
|
||||||
end
|
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…
x
Reference in New Issue
Block a user