lnrpc 0.12.1 → 0.14.3.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/Gemfile.lock +19 -19
- data/README.md +6 -9
- data/examples.rb +43 -0
- data/generate-grpc-service-files.sh +2 -3
- data/lib/grpc_services/invoicesrpc/invoices_pb.rb +18 -0
- data/lib/grpc_services/invoicesrpc/invoices_services_pb.rb +4 -0
- data/lib/grpc_services/lnclipb/lncli_pb.rb +1 -0
- data/lib/grpc_services/routerrpc/router_pb.rb +47 -0
- data/lib/grpc_services/routerrpc/router_services_pb.rb +19 -0
- data/lib/grpc_services/rpc_pb.rb +41 -0
- data/lib/grpc_services/rpc_services_pb.rb +2 -2
- data/lib/grpc_services/signrpc/signer_pb.rb +2 -0
- data/lib/grpc_services/walletrpc/walletkit_pb.rb +78 -1
- data/lib/grpc_services/walletrpc/walletkit_services_pb.rb +53 -0
- data/lib/grpc_services/walletunlocker_pb.rb +17 -0
- data/lib/grpc_services/wtclientrpc/wtclient_pb.rb +2 -0
- data/lib/lnrpc/client.rb +1 -0
- data/lib/lnrpc/version.rb +1 -1
- data/lnrpc.gemspec +1 -1
- metadata +5 -5
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: d1501e290f91d54b09af1d2abc92fef6869c0064c667ef3b129d50a6e0f4885c
|
4
|
+
data.tar.gz: af3884acd17e590108e293134fb15170d53fc309f79431397e8cdd3a8da4b075
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 435fbe6709811cec7be3f8e57ce3ee35ba53c46ed7a20484c65ff51981658b8522ef211acebaa81dc74b11098dd22e27767484b2412cecf7998e2221d333fc18
|
7
|
+
data.tar.gz: de2e8589a9179407c3019b160f1a1267e87cb0a355c082d681a01c3f047ff97cc9f341ac7d92868b84f946e719d1b99409cc89fed9966bd5d0dd2e53be3e508c
|
data/Gemfile.lock
CHANGED
@@ -1,34 +1,34 @@
|
|
1
1
|
PATH
|
2
2
|
remote: .
|
3
3
|
specs:
|
4
|
-
lnrpc (0.
|
5
|
-
google-protobuf (>= 3.
|
4
|
+
lnrpc (0.14.1)
|
5
|
+
google-protobuf (>= 3.15.7)
|
6
6
|
grpc (>= 1.28.0)
|
7
7
|
|
8
8
|
GEM
|
9
9
|
remote: https://rubygems.org/
|
10
10
|
specs:
|
11
|
-
diff-lcs (1.
|
12
|
-
google-protobuf (3.
|
13
|
-
googleapis-common-protos-types (1.1
|
11
|
+
diff-lcs (1.5.0)
|
12
|
+
google-protobuf (3.21.1)
|
13
|
+
googleapis-common-protos-types (1.3.1)
|
14
14
|
google-protobuf (~> 3.14)
|
15
|
-
grpc (1.
|
16
|
-
google-protobuf (~> 3.
|
15
|
+
grpc (1.46.3)
|
16
|
+
google-protobuf (~> 3.19)
|
17
17
|
googleapis-common-protos-types (~> 1.0)
|
18
18
|
rake (13.0.6)
|
19
|
-
rspec (3.
|
20
|
-
rspec-core (~> 3.
|
21
|
-
rspec-expectations (~> 3.
|
22
|
-
rspec-mocks (~> 3.
|
23
|
-
rspec-core (3.
|
24
|
-
rspec-support (~> 3.
|
25
|
-
rspec-expectations (3.
|
19
|
+
rspec (3.11.0)
|
20
|
+
rspec-core (~> 3.11.0)
|
21
|
+
rspec-expectations (~> 3.11.0)
|
22
|
+
rspec-mocks (~> 3.11.0)
|
23
|
+
rspec-core (3.11.0)
|
24
|
+
rspec-support (~> 3.11.0)
|
25
|
+
rspec-expectations (3.11.0)
|
26
26
|
diff-lcs (>= 1.2.0, < 2.0)
|
27
|
-
rspec-support (~> 3.
|
28
|
-
rspec-mocks (3.
|
27
|
+
rspec-support (~> 3.11.0)
|
28
|
+
rspec-mocks (3.11.1)
|
29
29
|
diff-lcs (>= 1.2.0, < 2.0)
|
30
|
-
rspec-support (~> 3.
|
31
|
-
rspec-support (3.
|
30
|
+
rspec-support (~> 3.11.0)
|
31
|
+
rspec-support (3.11.0)
|
32
32
|
|
33
33
|
PLATFORMS
|
34
34
|
ruby
|
@@ -40,4 +40,4 @@ DEPENDENCIES
|
|
40
40
|
rspec (~> 3.0)
|
41
41
|
|
42
42
|
BUNDLED WITH
|
43
|
-
2.
|
43
|
+
2.2.33
|
data/README.md
CHANGED
@@ -5,13 +5,10 @@ a [gRPC](https://grpc.io/) client for [LND, the Lightning Network Daemon](https:
|
|
5
5
|
|
6
6
|
## Installation
|
7
7
|
|
8
|
-
Note: there is still an GRPC/protobuf [issue with Ruby 2.7](https://github.com/protocolbuffers/protobuf/issues/7070).
|
9
|
-
So lnrpc requires Ruby < 2.7.
|
10
|
-
|
11
8
|
Add this line to your application's Gemfile:
|
12
9
|
|
13
10
|
```ruby
|
14
|
-
gem 'lnrpc', '~> 0.
|
11
|
+
gem 'lnrpc', '~> 0.13.0'
|
15
12
|
```
|
16
13
|
lnrpc follows the lnd versioning, thus it is recommended to specify the exact version you need for your lnd node as dependency (see [#Versioning](#Versioning)).
|
17
14
|
|
@@ -27,7 +24,7 @@ Or install it yourself as:
|
|
27
24
|
|
28
25
|
## Usage
|
29
26
|
|
30
|
-
This gem makes the gRPC client classes created from the [LND service
|
27
|
+
This gem makes the gRPC client classes created from the [LND service definitions](https://github.com/lightningnetwork/lnd/tree/master/lnrpc) available.
|
31
28
|
|
32
29
|
```ruby
|
33
30
|
require "lnrpc"
|
@@ -35,7 +32,7 @@ require "lnrpc"
|
|
35
32
|
# With the changes in LND v.10.0 this load the `Lnrpc` and `Routerrpc` namespace
|
36
33
|
|
37
34
|
Lnrpc::Lightning::Stub
|
38
|
-
Routerrpc
|
35
|
+
Routerrpc::Routerrpc::Stub
|
39
36
|
Lnrpc::GetInfoRequest
|
40
37
|
...
|
41
38
|
```
|
@@ -78,7 +75,7 @@ lnd = Lnrpc::Client.new({credentials_path: '/path/to.cert.cls', macaroon_path: '
|
|
78
75
|
lnd.lightning # => Lnrpc::Lightning::Stub
|
79
76
|
lnd.router # => Lnrpc::Router::Stub
|
80
77
|
|
81
|
-
lnd.
|
78
|
+
lnd.lightning.get_info
|
82
79
|
```
|
83
80
|
|
84
81
|
Also have a look at [examples.rb](https://github.com/bumi/lnrpc/blob/master/examples.rb)
|
@@ -133,7 +130,7 @@ client.lightning.grpc.list_channels(request)
|
|
133
130
|
|
134
131
|
client.lightning.wallet_balance.total_balance
|
135
132
|
# is the same as:
|
136
|
-
request = Lnrpc::WalletBalanceRequest.new
|
133
|
+
request = Lnrpc::WalletBalanceRequest.new
|
137
134
|
client.lightning.grpc.wallet_balance(request).total_balance
|
138
135
|
```
|
139
136
|
|
@@ -144,7 +141,7 @@ If you have a running BTC Pay Server with LND support, integrating with lnrpc is
|
|
144
141
|
- Navigate to Services on the Server Settings page
|
145
142
|
- Click "see information" for your gRPC Server
|
146
143
|
- The link by "More details..." will expose the address and various macaroon hex strings
|
147
|
-
- Initialize your client with the options detailed above. BTC Pay Server utilizes LetsEncrypt for trusted TLC
|
144
|
+
- Initialize your client with the options detailed above. BTC Pay Server utilizes LetsEncrypt for trusted TLC Certificates so set that option to nil.
|
148
145
|
|
149
146
|
Don't have a BTC Pay Server? [Setting one up is easy.](https://medium.com/@BtcpayServer/launch-btcpay-server-via-web-interface-and-deploy-full-bitcoin-node-lnd-in-less-than-a-minute-dc8bc6f06a3)
|
150
147
|
|
data/examples.rb
CHANGED
@@ -24,3 +24,46 @@ puts lnd.wallet_kit.next_addr
|
|
24
24
|
lnd.lightning.subscribe_invoices(settle_index: 1).each do |invoice|
|
25
25
|
puts invoice.payment_request
|
26
26
|
end
|
27
|
+
|
28
|
+
# sign a message with your node
|
29
|
+
signed_message = lnd.lightning.sign_message({ msg: "Money printer goes brrr" })
|
30
|
+
puts "Signature: " + signed_message.signature
|
31
|
+
|
32
|
+
# verify a signed message by another node
|
33
|
+
verification_response = lnd.lightning.verify_message({
|
34
|
+
msg: "Money printer goes brrr",
|
35
|
+
signature: signed_message.signature
|
36
|
+
})
|
37
|
+
puts "Pubkey: " + verification_response.pubkey # pubkey of the node that signed
|
38
|
+
puts "Valid: " + verification_response.valid.to_s
|
39
|
+
|
40
|
+
# get information on a node
|
41
|
+
node_info_response = lnd.lightning.get_node_info(pub_key: verification_response.pubkey, include_channels: true)
|
42
|
+
puts "Updated: " + Time.at(node_info_response.node.last_update).to_s
|
43
|
+
puts "Pubkey: " + node_info_response.node.pub_key.to_s
|
44
|
+
puts "Alias: " + node_info_response.node.alias.to_s
|
45
|
+
puts "Color: " + node_info_response.node.color.to_s
|
46
|
+
puts "Channels: " + node_info_response.num_channels.to_s
|
47
|
+
puts "Capacity SAT: " + node_info_response.total_capacity.to_s
|
48
|
+
puts "Address: " + node_info_response.node.addresses.first["addr"].to_s
|
49
|
+
|
50
|
+
# extract channel information
|
51
|
+
node_info_response.channels.each do |channel|
|
52
|
+
puts "Channel ID: " + channel["channel_id"].to_s
|
53
|
+
puts "Channel 1:" + channel["node1_pub"].to_s # pubkey of the first node
|
54
|
+
puts "Channel 2:" + channel["node2_pub"].to_s # pubkey of the second node
|
55
|
+
puts "Channel Capacity:" + channel["capacity"].to_s
|
56
|
+
end
|
57
|
+
|
58
|
+
# update channel policy
|
59
|
+
channel = lnd.lightning.list_channels.channels[0]
|
60
|
+
puts lnd.lightning.get_chan_info(chan_id: channel.chan_id)
|
61
|
+
channel_point = {
|
62
|
+
funding_txid_str: channel.channel_point.split(":")[0],
|
63
|
+
output_index: channel.channel_point.split(":")[1].to_i
|
64
|
+
}
|
65
|
+
lnd.lightning.update_channel_policy({
|
66
|
+
time_lock_delta: 40,
|
67
|
+
base_fee_msat: 1100,
|
68
|
+
chan_point: channel_point
|
69
|
+
})
|
@@ -18,9 +18,8 @@ for file in $PROTOS; do
|
|
18
18
|
echo "Generating protos from ${file}, into ${LNRPC_TARGET_DIR}/${DIRECTORY}"
|
19
19
|
|
20
20
|
# writes all ruby files in the ruby directory
|
21
|
-
grpc_tools_ruby_protoc -I
|
22
|
-
-I. \
|
23
|
-
-I$GOPATH/src/github.com/grpc-ecosystem/grpc-gateway/third_party/googleapis \
|
21
|
+
grpc_tools_ruby_protoc -I. \
|
22
|
+
-I$GOPATH/src/github.com/googleapis/googleapis \
|
24
23
|
-I$GOPATH/src/github.com/lightningnetwork/lnd/lnrpc \
|
25
24
|
--ruby_out=plugins=grpc,paths=source_relative:${LNRPC_TARGET_DIR} \
|
26
25
|
--grpc_out=${LNRPC_TARGET_DIR} "${file}"
|
@@ -4,6 +4,7 @@
|
|
4
4
|
require 'google/protobuf'
|
5
5
|
|
6
6
|
require 'rpc_pb'
|
7
|
+
|
7
8
|
Google::Protobuf::DescriptorPool.generated_pool.build do
|
8
9
|
add_file("invoicesrpc/invoices.proto", :syntax => :proto3) do
|
9
10
|
add_message "invoicesrpc.CancelInvoiceMsg" do
|
@@ -25,6 +26,8 @@ Google::Protobuf::DescriptorPool.generated_pool.build do
|
|
25
26
|
end
|
26
27
|
add_message "invoicesrpc.AddHoldInvoiceResp" do
|
27
28
|
optional :payment_request, :string, 1
|
29
|
+
optional :add_index, :uint64, 2
|
30
|
+
optional :payment_addr, :bytes, 3
|
28
31
|
end
|
29
32
|
add_message "invoicesrpc.SettleInvoiceMsg" do
|
30
33
|
optional :preimage, :bytes, 1
|
@@ -34,6 +37,19 @@ Google::Protobuf::DescriptorPool.generated_pool.build do
|
|
34
37
|
add_message "invoicesrpc.SubscribeSingleInvoiceRequest" do
|
35
38
|
optional :r_hash, :bytes, 2
|
36
39
|
end
|
40
|
+
add_message "invoicesrpc.LookupInvoiceMsg" do
|
41
|
+
optional :lookup_modifier, :enum, 4, "invoicesrpc.LookupModifier"
|
42
|
+
oneof :invoice_ref do
|
43
|
+
optional :payment_hash, :bytes, 1
|
44
|
+
optional :payment_addr, :bytes, 2
|
45
|
+
optional :set_id, :bytes, 3
|
46
|
+
end
|
47
|
+
end
|
48
|
+
add_enum "invoicesrpc.LookupModifier" do
|
49
|
+
value :DEFAULT, 0
|
50
|
+
value :HTLC_SET_ONLY, 1
|
51
|
+
value :HTLC_SET_BLANK, 2
|
52
|
+
end
|
37
53
|
end
|
38
54
|
end
|
39
55
|
|
@@ -45,4 +61,6 @@ module Invoicesrpc
|
|
45
61
|
SettleInvoiceMsg = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("invoicesrpc.SettleInvoiceMsg").msgclass
|
46
62
|
SettleInvoiceResp = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("invoicesrpc.SettleInvoiceResp").msgclass
|
47
63
|
SubscribeSingleInvoiceRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("invoicesrpc.SubscribeSingleInvoiceRequest").msgclass
|
64
|
+
LookupInvoiceMsg = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("invoicesrpc.LookupInvoiceMsg").msgclass
|
65
|
+
LookupModifier = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("invoicesrpc.LookupModifier").enummodule
|
48
66
|
end
|
@@ -34,6 +34,10 @@ module Invoicesrpc
|
|
34
34
|
# SettleInvoice settles an accepted invoice. If the invoice is already
|
35
35
|
# settled, this call will succeed.
|
36
36
|
rpc :SettleInvoice, ::Invoicesrpc::SettleInvoiceMsg, ::Invoicesrpc::SettleInvoiceResp
|
37
|
+
#
|
38
|
+
# LookupInvoiceV2 attempts to look up at invoice. An invoice can be refrenced
|
39
|
+
# using either its payment hash, payment address, or set ID.
|
40
|
+
rpc :LookupInvoiceV2, ::Invoicesrpc::LookupInvoiceMsg, ::Lnrpc::Invoice
|
37
41
|
end
|
38
42
|
|
39
43
|
Stub = Service.rpc_stub_class
|
@@ -4,6 +4,7 @@
|
|
4
4
|
require 'google/protobuf'
|
5
5
|
|
6
6
|
require 'rpc_pb'
|
7
|
+
|
7
8
|
Google::Protobuf::DescriptorPool.generated_pool.build do
|
8
9
|
add_file("routerrpc/router.proto", :syntax => :proto3) do
|
9
10
|
add_message "routerrpc.SendPaymentRequest" do
|
@@ -28,6 +29,7 @@ Google::Protobuf::DescriptorPool.generated_pool.build do
|
|
28
29
|
optional :max_parts, :uint32, 17
|
29
30
|
optional :no_inflight_updates, :bool, 18
|
30
31
|
optional :max_shard_size_msat, :uint64, 21
|
32
|
+
optional :amp, :bool, 22
|
31
33
|
end
|
32
34
|
add_message "routerrpc.TrackPaymentRequest" do
|
33
35
|
optional :payment_hash, :bytes, 1
|
@@ -58,6 +60,12 @@ Google::Protobuf::DescriptorPool.generated_pool.build do
|
|
58
60
|
add_message "routerrpc.QueryMissionControlResponse" do
|
59
61
|
repeated :pairs, :message, 2, "routerrpc.PairHistory"
|
60
62
|
end
|
63
|
+
add_message "routerrpc.XImportMissionControlRequest" do
|
64
|
+
repeated :pairs, :message, 1, "routerrpc.PairHistory"
|
65
|
+
optional :force, :bool, 2
|
66
|
+
end
|
67
|
+
add_message "routerrpc.XImportMissionControlResponse" do
|
68
|
+
end
|
61
69
|
add_message "routerrpc.PairHistory" do
|
62
70
|
optional :node_from, :bytes, 1
|
63
71
|
optional :node_to, :bytes, 2
|
@@ -71,6 +79,23 @@ Google::Protobuf::DescriptorPool.generated_pool.build do
|
|
71
79
|
optional :success_amt_sat, :int64, 6
|
72
80
|
optional :success_amt_msat, :int64, 7
|
73
81
|
end
|
82
|
+
add_message "routerrpc.GetMissionControlConfigRequest" do
|
83
|
+
end
|
84
|
+
add_message "routerrpc.GetMissionControlConfigResponse" do
|
85
|
+
optional :config, :message, 1, "routerrpc.MissionControlConfig"
|
86
|
+
end
|
87
|
+
add_message "routerrpc.SetMissionControlConfigRequest" do
|
88
|
+
optional :config, :message, 1, "routerrpc.MissionControlConfig"
|
89
|
+
end
|
90
|
+
add_message "routerrpc.SetMissionControlConfigResponse" do
|
91
|
+
end
|
92
|
+
add_message "routerrpc.MissionControlConfig" do
|
93
|
+
optional :half_life_seconds, :uint64, 1
|
94
|
+
optional :hop_probability, :float, 2
|
95
|
+
optional :weight, :float, 3
|
96
|
+
optional :maximum_payment_results, :uint32, 4
|
97
|
+
optional :minimum_failure_relax_interval, :uint64, 5
|
98
|
+
end
|
74
99
|
add_message "routerrpc.QueryProbabilityRequest" do
|
75
100
|
optional :from_node, :bytes, 1
|
76
101
|
optional :to_node, :bytes, 2
|
@@ -124,6 +149,7 @@ Google::Protobuf::DescriptorPool.generated_pool.build do
|
|
124
149
|
add_message "routerrpc.ForwardFailEvent" do
|
125
150
|
end
|
126
151
|
add_message "routerrpc.SettleEvent" do
|
152
|
+
optional :preimage, :bytes, 1
|
127
153
|
end
|
128
154
|
add_message "routerrpc.LinkFailEvent" do
|
129
155
|
optional :info, :message, 1, "routerrpc.HtlcInfo"
|
@@ -156,6 +182,12 @@ Google::Protobuf::DescriptorPool.generated_pool.build do
|
|
156
182
|
optional :action, :enum, 2, "routerrpc.ResolveHoldForwardAction"
|
157
183
|
optional :preimage, :bytes, 3
|
158
184
|
end
|
185
|
+
add_message "routerrpc.UpdateChanStatusRequest" do
|
186
|
+
optional :chan_point, :message, 1, "lnrpc.ChannelPoint"
|
187
|
+
optional :action, :enum, 2, "routerrpc.ChanStatusAction"
|
188
|
+
end
|
189
|
+
add_message "routerrpc.UpdateChanStatusResponse" do
|
190
|
+
end
|
159
191
|
add_enum "routerrpc.FailureDetail" do
|
160
192
|
value :UNKNOWN, 0
|
161
193
|
value :NO_DETAIL, 1
|
@@ -195,6 +227,11 @@ Google::Protobuf::DescriptorPool.generated_pool.build do
|
|
195
227
|
value :FAIL, 1
|
196
228
|
value :RESUME, 2
|
197
229
|
end
|
230
|
+
add_enum "routerrpc.ChanStatusAction" do
|
231
|
+
value :ENABLE, 0
|
232
|
+
value :DISABLE, 1
|
233
|
+
value :AUTO, 2
|
234
|
+
end
|
198
235
|
end
|
199
236
|
end
|
200
237
|
|
@@ -209,8 +246,15 @@ module Routerrpc
|
|
209
246
|
ResetMissionControlResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("routerrpc.ResetMissionControlResponse").msgclass
|
210
247
|
QueryMissionControlRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("routerrpc.QueryMissionControlRequest").msgclass
|
211
248
|
QueryMissionControlResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("routerrpc.QueryMissionControlResponse").msgclass
|
249
|
+
XImportMissionControlRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("routerrpc.XImportMissionControlRequest").msgclass
|
250
|
+
XImportMissionControlResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("routerrpc.XImportMissionControlResponse").msgclass
|
212
251
|
PairHistory = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("routerrpc.PairHistory").msgclass
|
213
252
|
PairData = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("routerrpc.PairData").msgclass
|
253
|
+
GetMissionControlConfigRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("routerrpc.GetMissionControlConfigRequest").msgclass
|
254
|
+
GetMissionControlConfigResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("routerrpc.GetMissionControlConfigResponse").msgclass
|
255
|
+
SetMissionControlConfigRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("routerrpc.SetMissionControlConfigRequest").msgclass
|
256
|
+
SetMissionControlConfigResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("routerrpc.SetMissionControlConfigResponse").msgclass
|
257
|
+
MissionControlConfig = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("routerrpc.MissionControlConfig").msgclass
|
214
258
|
QueryProbabilityRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("routerrpc.QueryProbabilityRequest").msgclass
|
215
259
|
QueryProbabilityResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("routerrpc.QueryProbabilityResponse").msgclass
|
216
260
|
BuildRouteRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("routerrpc.BuildRouteRequest").msgclass
|
@@ -227,7 +271,10 @@ module Routerrpc
|
|
227
271
|
CircuitKey = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("routerrpc.CircuitKey").msgclass
|
228
272
|
ForwardHtlcInterceptRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("routerrpc.ForwardHtlcInterceptRequest").msgclass
|
229
273
|
ForwardHtlcInterceptResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("routerrpc.ForwardHtlcInterceptResponse").msgclass
|
274
|
+
UpdateChanStatusRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("routerrpc.UpdateChanStatusRequest").msgclass
|
275
|
+
UpdateChanStatusResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("routerrpc.UpdateChanStatusResponse").msgclass
|
230
276
|
FailureDetail = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("routerrpc.FailureDetail").enummodule
|
231
277
|
PaymentState = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("routerrpc.PaymentState").enummodule
|
232
278
|
ResolveHoldForwardAction = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("routerrpc.ResolveHoldForwardAction").enummodule
|
279
|
+
ChanStatusAction = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("routerrpc.ChanStatusAction").enummodule
|
233
280
|
end
|
@@ -51,6 +51,19 @@ module Routerrpc
|
|
51
51
|
# It is a development feature.
|
52
52
|
rpc :QueryMissionControl, ::Routerrpc::QueryMissionControlRequest, ::Routerrpc::QueryMissionControlResponse
|
53
53
|
#
|
54
|
+
# XImportMissionControl is an experimental API that imports the state provided
|
55
|
+
# to the internal mission control's state, using all results which are more
|
56
|
+
# recent than our existing values. These values will only be imported
|
57
|
+
# in-memory, and will not be persisted across restarts.
|
58
|
+
rpc :XImportMissionControl, ::Routerrpc::XImportMissionControlRequest, ::Routerrpc::XImportMissionControlResponse
|
59
|
+
#
|
60
|
+
# GetMissionControlConfig returns mission control's current config.
|
61
|
+
rpc :GetMissionControlConfig, ::Routerrpc::GetMissionControlConfigRequest, ::Routerrpc::GetMissionControlConfigResponse
|
62
|
+
#
|
63
|
+
# SetMissionControlConfig will set mission control's config, if the config
|
64
|
+
# provided is valid.
|
65
|
+
rpc :SetMissionControlConfig, ::Routerrpc::SetMissionControlConfigRequest, ::Routerrpc::SetMissionControlConfigResponse
|
66
|
+
#
|
54
67
|
# QueryProbability returns the current success probability estimate for a
|
55
68
|
# given node pair and amount.
|
56
69
|
rpc :QueryProbability, ::Routerrpc::QueryProbabilityRequest, ::Routerrpc::QueryProbabilityResponse
|
@@ -79,6 +92,12 @@ module Routerrpc
|
|
79
92
|
# In case of interception, the htlc can be either settled, cancelled or
|
80
93
|
# resumed later by using the ResolveHoldForward endpoint.
|
81
94
|
rpc :HtlcInterceptor, stream(::Routerrpc::ForwardHtlcInterceptResponse), stream(::Routerrpc::ForwardHtlcInterceptRequest)
|
95
|
+
#
|
96
|
+
# UpdateChanStatus attempts to manually set the state of a channel
|
97
|
+
# (enabled, disabled, or auto). A manual "disable" request will cause the
|
98
|
+
# channel to stay disabled until a subsequent manual request of either
|
99
|
+
# "enable" or "auto".
|
100
|
+
rpc :UpdateChanStatus, ::Routerrpc::UpdateChanStatusRequest, ::Routerrpc::UpdateChanStatusResponse
|
82
101
|
end
|
83
102
|
|
84
103
|
Stub = Service.rpc_stub_class
|
data/lib/grpc_services/rpc_pb.rb
CHANGED
@@ -28,6 +28,7 @@ Google::Protobuf::DescriptorPool.generated_pool.build do
|
|
28
28
|
add_message "lnrpc.GetTransactionsRequest" do
|
29
29
|
optional :start_height, :int32, 1
|
30
30
|
optional :end_height, :int32, 2
|
31
|
+
optional :account, :string, 3
|
31
32
|
end
|
32
33
|
add_message "lnrpc.TransactionDetails" do
|
33
34
|
repeated :transactions, :message, 1, "lnrpc.Transaction"
|
@@ -55,6 +56,7 @@ Google::Protobuf::DescriptorPool.generated_pool.build do
|
|
55
56
|
map :dest_custom_records, :uint64, :bytes, 11
|
56
57
|
optional :allow_self_payment, :bool, 14
|
57
58
|
repeated :dest_features, :enum, 15, "lnrpc.FeatureBit"
|
59
|
+
optional :payment_addr, :bytes, 16
|
58
60
|
end
|
59
61
|
add_message "lnrpc.SendResponse" do
|
60
62
|
optional :payment_error, :string, 1
|
@@ -113,14 +115,18 @@ Google::Protobuf::DescriptorPool.generated_pool.build do
|
|
113
115
|
add_message "lnrpc.EstimateFeeRequest" do
|
114
116
|
map :AddrToAmount, :string, :int64, 1
|
115
117
|
optional :target_conf, :int32, 2
|
118
|
+
optional :min_confs, :int32, 3
|
119
|
+
optional :spend_unconfirmed, :bool, 4
|
116
120
|
end
|
117
121
|
add_message "lnrpc.EstimateFeeResponse" do
|
118
122
|
optional :fee_sat, :int64, 1
|
119
123
|
optional :feerate_sat_per_byte, :int64, 2
|
124
|
+
optional :sat_per_vbyte, :uint64, 3
|
120
125
|
end
|
121
126
|
add_message "lnrpc.SendManyRequest" do
|
122
127
|
map :AddrToAmount, :string, :int64, 1
|
123
128
|
optional :target_conf, :int32, 3
|
129
|
+
optional :sat_per_vbyte, :uint64, 4
|
124
130
|
optional :sat_per_byte, :int64, 5
|
125
131
|
optional :label, :string, 6
|
126
132
|
optional :min_confs, :int32, 7
|
@@ -133,6 +139,7 @@ Google::Protobuf::DescriptorPool.generated_pool.build do
|
|
133
139
|
optional :addr, :string, 1
|
134
140
|
optional :amount, :int64, 2
|
135
141
|
optional :target_conf, :int32, 3
|
142
|
+
optional :sat_per_vbyte, :uint64, 4
|
136
143
|
optional :sat_per_byte, :int64, 5
|
137
144
|
optional :send_all, :bool, 6
|
138
145
|
optional :label, :string, 7
|
@@ -145,12 +152,14 @@ Google::Protobuf::DescriptorPool.generated_pool.build do
|
|
145
152
|
add_message "lnrpc.ListUnspentRequest" do
|
146
153
|
optional :min_confs, :int32, 1
|
147
154
|
optional :max_confs, :int32, 2
|
155
|
+
optional :account, :string, 3
|
148
156
|
end
|
149
157
|
add_message "lnrpc.ListUnspentResponse" do
|
150
158
|
repeated :utxos, :message, 1, "lnrpc.Utxo"
|
151
159
|
end
|
152
160
|
add_message "lnrpc.NewAddressRequest" do
|
153
161
|
optional :type, :enum, 1, "lnrpc.AddressType"
|
162
|
+
optional :account, :string, 2
|
154
163
|
end
|
155
164
|
add_message "lnrpc.NewAddressResponse" do
|
156
165
|
optional :address, :string, 1
|
@@ -373,6 +382,7 @@ Google::Protobuf::DescriptorPool.generated_pool.build do
|
|
373
382
|
optional :target_conf, :int32, 3
|
374
383
|
optional :sat_per_byte, :int64, 4
|
375
384
|
optional :delivery_address, :string, 5
|
385
|
+
optional :sat_per_vbyte, :uint64, 6
|
376
386
|
end
|
377
387
|
add_message "lnrpc.CloseStatusUpdate" do
|
378
388
|
oneof :update do
|
@@ -390,6 +400,7 @@ Google::Protobuf::DescriptorPool.generated_pool.build do
|
|
390
400
|
optional :psbt, :bytes, 3
|
391
401
|
end
|
392
402
|
add_message "lnrpc.OpenChannelRequest" do
|
403
|
+
optional :sat_per_vbyte, :uint64, 1
|
393
404
|
optional :node_pubkey, :bytes, 2
|
394
405
|
optional :node_pubkey_string, :string, 3
|
395
406
|
optional :local_funding_amount, :int64, 4
|
@@ -550,12 +561,17 @@ Google::Protobuf::DescriptorPool.generated_pool.build do
|
|
550
561
|
value :INACTIVE_CHANNEL, 3
|
551
562
|
value :PENDING_OPEN_CHANNEL, 4
|
552
563
|
end
|
564
|
+
add_message "lnrpc.WalletAccountBalance" do
|
565
|
+
optional :confirmed_balance, :int64, 1
|
566
|
+
optional :unconfirmed_balance, :int64, 2
|
567
|
+
end
|
553
568
|
add_message "lnrpc.WalletBalanceRequest" do
|
554
569
|
end
|
555
570
|
add_message "lnrpc.WalletBalanceResponse" do
|
556
571
|
optional :total_balance, :int64, 1
|
557
572
|
optional :confirmed_balance, :int64, 2
|
558
573
|
optional :unconfirmed_balance, :int64, 3
|
574
|
+
map :account_balance, :string, :message, 4, "lnrpc.WalletAccountBalance"
|
559
575
|
end
|
560
576
|
add_message "lnrpc.Amount" do
|
561
577
|
optional :sat, :uint64, 1
|
@@ -614,12 +630,18 @@ Google::Protobuf::DescriptorPool.generated_pool.build do
|
|
614
630
|
optional :pub_key, :string, 8
|
615
631
|
optional :tlv_payload, :bool, 9
|
616
632
|
optional :mpp_record, :message, 10, "lnrpc.MPPRecord"
|
633
|
+
optional :amp_record, :message, 12, "lnrpc.AMPRecord"
|
617
634
|
map :custom_records, :uint64, :bytes, 11
|
618
635
|
end
|
619
636
|
add_message "lnrpc.MPPRecord" do
|
620
637
|
optional :payment_addr, :bytes, 11
|
621
638
|
optional :total_amt_msat, :int64, 10
|
622
639
|
end
|
640
|
+
add_message "lnrpc.AMPRecord" do
|
641
|
+
optional :root_share, :bytes, 1
|
642
|
+
optional :set_id, :bytes, 2
|
643
|
+
optional :child_index, :uint32, 3
|
644
|
+
end
|
623
645
|
add_message "lnrpc.Route" do
|
624
646
|
optional :total_time_lock, :uint32, 1
|
625
647
|
optional :total_fees, :int64, 2
|
@@ -721,6 +743,7 @@ Google::Protobuf::DescriptorPool.generated_pool.build do
|
|
721
743
|
optional :global_features, :bytes, 3
|
722
744
|
optional :alias, :string, 4
|
723
745
|
optional :color, :string, 5
|
746
|
+
repeated :node_addresses, :message, 7, "lnrpc.NodeAddress"
|
724
747
|
map :features, :uint32, :message, 6, "lnrpc.Feature"
|
725
748
|
end
|
726
749
|
add_message "lnrpc.ChannelEdgeUpdate" do
|
@@ -773,6 +796,7 @@ Google::Protobuf::DescriptorPool.generated_pool.build do
|
|
773
796
|
map :features, :uint32, :message, 24, "lnrpc.Feature"
|
774
797
|
optional :is_keysend, :bool, 25
|
775
798
|
optional :payment_addr, :bytes, 26
|
799
|
+
optional :is_amp, :bool, 27
|
776
800
|
end
|
777
801
|
add_enum "lnrpc.Invoice.InvoiceState" do
|
778
802
|
value :OPEN, 0
|
@@ -791,6 +815,14 @@ Google::Protobuf::DescriptorPool.generated_pool.build do
|
|
791
815
|
optional :state, :enum, 8, "lnrpc.InvoiceHTLCState"
|
792
816
|
map :custom_records, :uint64, :bytes, 9
|
793
817
|
optional :mpp_total_amt_msat, :uint64, 10
|
818
|
+
optional :amp, :message, 11, "lnrpc.AMP"
|
819
|
+
end
|
820
|
+
add_message "lnrpc.AMP" do
|
821
|
+
optional :root_share, :bytes, 1
|
822
|
+
optional :set_id, :bytes, 2
|
823
|
+
optional :child_index, :uint32, 3
|
824
|
+
optional :hash, :bytes, 4
|
825
|
+
optional :preimage, :bytes, 5
|
794
826
|
end
|
795
827
|
add_message "lnrpc.AddInvoiceResponse" do
|
796
828
|
optional :r_hash, :bytes, 1
|
@@ -866,6 +898,8 @@ Google::Protobuf::DescriptorPool.generated_pool.build do
|
|
866
898
|
optional :last_index_offset, :uint64, 3
|
867
899
|
end
|
868
900
|
add_message "lnrpc.DeleteAllPaymentsRequest" do
|
901
|
+
optional :failed_payments_only, :bool, 1
|
902
|
+
optional :failed_htlcs_only, :bool, 2
|
869
903
|
end
|
870
904
|
add_message "lnrpc.DeleteAllPaymentsResponse" do
|
871
905
|
end
|
@@ -950,6 +984,7 @@ Google::Protobuf::DescriptorPool.generated_pool.build do
|
|
950
984
|
optional :fee_msat, :uint64, 8
|
951
985
|
optional :amt_in_msat, :uint64, 9
|
952
986
|
optional :amt_out_msat, :uint64, 10
|
987
|
+
optional :timestamp_ns, :uint64, 11
|
953
988
|
end
|
954
989
|
add_message "lnrpc.ForwardingHistoryResponse" do
|
955
990
|
repeated :forwarding_events, :message, 1, "lnrpc.ForwardingEvent"
|
@@ -1052,6 +1087,7 @@ Google::Protobuf::DescriptorPool.generated_pool.build do
|
|
1052
1087
|
value :PERMANENT_CHANNEL_FAILURE, 21
|
1053
1088
|
value :EXPIRY_TOO_FAR, 22
|
1054
1089
|
value :MPP_TIMEOUT, 23
|
1090
|
+
value :INVALID_ONION_PAYLOAD, 24
|
1055
1091
|
value :INTERNAL_FAILURE, 997
|
1056
1092
|
value :UNKNOWN_FAILURE, 998
|
1057
1093
|
value :UNREADABLE_FAILURE, 999
|
@@ -1153,6 +1189,8 @@ Google::Protobuf::DescriptorPool.generated_pool.build do
|
|
1153
1189
|
value :ANCHORS_OPT, 21
|
1154
1190
|
value :ANCHORS_ZERO_FEE_HTLC_REQ, 22
|
1155
1191
|
value :ANCHORS_ZERO_FEE_HTLC_OPT, 23
|
1192
|
+
value :AMP_REQ, 30
|
1193
|
+
value :AMP_OPT, 31
|
1156
1194
|
end
|
1157
1195
|
end
|
1158
1196
|
end
|
@@ -1244,6 +1282,7 @@ module Lnrpc
|
|
1244
1282
|
ChannelEventSubscription = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("lnrpc.ChannelEventSubscription").msgclass
|
1245
1283
|
ChannelEventUpdate = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("lnrpc.ChannelEventUpdate").msgclass
|
1246
1284
|
ChannelEventUpdate::UpdateType = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("lnrpc.ChannelEventUpdate.UpdateType").enummodule
|
1285
|
+
WalletAccountBalance = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("lnrpc.WalletAccountBalance").msgclass
|
1247
1286
|
WalletBalanceRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("lnrpc.WalletBalanceRequest").msgclass
|
1248
1287
|
WalletBalanceResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("lnrpc.WalletBalanceResponse").msgclass
|
1249
1288
|
Amount = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("lnrpc.Amount").msgclass
|
@@ -1255,6 +1294,7 @@ module Lnrpc
|
|
1255
1294
|
QueryRoutesResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("lnrpc.QueryRoutesResponse").msgclass
|
1256
1295
|
Hop = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("lnrpc.Hop").msgclass
|
1257
1296
|
MPPRecord = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("lnrpc.MPPRecord").msgclass
|
1297
|
+
AMPRecord = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("lnrpc.AMPRecord").msgclass
|
1258
1298
|
Route = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("lnrpc.Route").msgclass
|
1259
1299
|
NodeInfoRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("lnrpc.NodeInfoRequest").msgclass
|
1260
1300
|
NodeInfo = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("lnrpc.NodeInfo").msgclass
|
@@ -1282,6 +1322,7 @@ module Lnrpc
|
|
1282
1322
|
Invoice = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("lnrpc.Invoice").msgclass
|
1283
1323
|
Invoice::InvoiceState = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("lnrpc.Invoice.InvoiceState").enummodule
|
1284
1324
|
InvoiceHTLC = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("lnrpc.InvoiceHTLC").msgclass
|
1325
|
+
AMP = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("lnrpc.AMP").msgclass
|
1285
1326
|
AddInvoiceResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("lnrpc.AddInvoiceResponse").msgclass
|
1286
1327
|
PaymentHash = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("lnrpc.PaymentHash").msgclass
|
1287
1328
|
ListInvoiceRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("lnrpc.ListInvoiceRequest").msgclass
|
@@ -58,7 +58,7 @@ module Lnrpc
|
|
58
58
|
# lncli: `sendcoins`
|
59
59
|
# SendCoins executes a request to send coins to a particular address. Unlike
|
60
60
|
# SendMany, this RPC call only allows creating a single output at a time. If
|
61
|
-
# neither target_conf, or
|
61
|
+
# neither target_conf, or sat_per_vbyte are set, then the internal wallet will
|
62
62
|
# consult its fee model to determine a fee for the default confirmation
|
63
63
|
# target.
|
64
64
|
rpc :SendCoins, ::Lnrpc::SendCoinsRequest, ::Lnrpc::SendCoinsResponse
|
@@ -75,7 +75,7 @@ module Lnrpc
|
|
75
75
|
rpc :SubscribeTransactions, ::Lnrpc::GetTransactionsRequest, stream(::Lnrpc::Transaction)
|
76
76
|
# lncli: `sendmany`
|
77
77
|
# SendMany handles a request for a transaction that creates multiple specified
|
78
|
-
# outputs in parallel. If neither target_conf, or
|
78
|
+
# outputs in parallel. If neither target_conf, or sat_per_vbyte are set, then
|
79
79
|
# the internal wallet will consult its fee model to determine a fee for the
|
80
80
|
# default confirmation target.
|
81
81
|
rpc :SendMany, ::Lnrpc::SendManyRequest, ::Lnrpc::SendManyResponse
|
@@ -43,6 +43,8 @@ Google::Protobuf::DescriptorPool.generated_pool.build do
|
|
43
43
|
add_message "signrpc.SignMessageReq" do
|
44
44
|
optional :msg, :bytes, 1
|
45
45
|
optional :key_loc, :message, 2, "signrpc.KeyLocator"
|
46
|
+
optional :double_hash, :bool, 3
|
47
|
+
optional :compact_sig, :bool, 4
|
46
48
|
end
|
47
49
|
add_message "signrpc.SignMessageResp" do
|
48
50
|
optional :signature, :bytes, 1
|
@@ -5,11 +5,13 @@ require 'google/protobuf'
|
|
5
5
|
|
6
6
|
require 'rpc_pb'
|
7
7
|
require 'signrpc/signer_pb'
|
8
|
+
|
8
9
|
Google::Protobuf::DescriptorPool.generated_pool.build do
|
9
10
|
add_file("walletrpc/walletkit.proto", :syntax => :proto3) do
|
10
11
|
add_message "walletrpc.ListUnspentRequest" do
|
11
12
|
optional :min_confs, :int32, 1
|
12
13
|
optional :max_confs, :int32, 2
|
14
|
+
optional :account, :string, 3
|
13
15
|
end
|
14
16
|
add_message "walletrpc.ListUnspentResponse" do
|
15
17
|
repeated :utxos, :message, 1, "lnrpc.Utxo"
|
@@ -17,6 +19,7 @@ Google::Protobuf::DescriptorPool.generated_pool.build do
|
|
17
19
|
add_message "walletrpc.LeaseOutputRequest" do
|
18
20
|
optional :id, :bytes, 1
|
19
21
|
optional :outpoint, :message, 2, "lnrpc.OutPoint"
|
22
|
+
optional :expiration_seconds, :uint64, 3
|
20
23
|
end
|
21
24
|
add_message "walletrpc.LeaseOutputResponse" do
|
22
25
|
optional :expiration, :uint64, 1
|
@@ -32,10 +35,48 @@ Google::Protobuf::DescriptorPool.generated_pool.build do
|
|
32
35
|
optional :key_family, :int32, 2
|
33
36
|
end
|
34
37
|
add_message "walletrpc.AddrRequest" do
|
38
|
+
optional :account, :string, 1
|
39
|
+
optional :type, :enum, 2, "walletrpc.AddressType"
|
40
|
+
optional :change, :bool, 3
|
35
41
|
end
|
36
42
|
add_message "walletrpc.AddrResponse" do
|
37
43
|
optional :addr, :string, 1
|
38
44
|
end
|
45
|
+
add_message "walletrpc.Account" do
|
46
|
+
optional :name, :string, 1
|
47
|
+
optional :address_type, :enum, 2, "walletrpc.AddressType"
|
48
|
+
optional :extended_public_key, :string, 3
|
49
|
+
optional :master_key_fingerprint, :bytes, 4
|
50
|
+
optional :derivation_path, :string, 5
|
51
|
+
optional :external_key_count, :uint32, 6
|
52
|
+
optional :internal_key_count, :uint32, 7
|
53
|
+
optional :watch_only, :bool, 8
|
54
|
+
end
|
55
|
+
add_message "walletrpc.ListAccountsRequest" do
|
56
|
+
optional :name, :string, 1
|
57
|
+
optional :address_type, :enum, 2, "walletrpc.AddressType"
|
58
|
+
end
|
59
|
+
add_message "walletrpc.ListAccountsResponse" do
|
60
|
+
repeated :accounts, :message, 1, "walletrpc.Account"
|
61
|
+
end
|
62
|
+
add_message "walletrpc.ImportAccountRequest" do
|
63
|
+
optional :name, :string, 1
|
64
|
+
optional :extended_public_key, :string, 2
|
65
|
+
optional :master_key_fingerprint, :bytes, 3
|
66
|
+
optional :address_type, :enum, 4, "walletrpc.AddressType"
|
67
|
+
optional :dry_run, :bool, 5
|
68
|
+
end
|
69
|
+
add_message "walletrpc.ImportAccountResponse" do
|
70
|
+
optional :account, :message, 1, "walletrpc.Account"
|
71
|
+
repeated :dry_run_external_addrs, :string, 2
|
72
|
+
repeated :dry_run_internal_addrs, :string, 3
|
73
|
+
end
|
74
|
+
add_message "walletrpc.ImportPublicKeyRequest" do
|
75
|
+
optional :public_key, :bytes, 1
|
76
|
+
optional :address_type, :enum, 2, "walletrpc.AddressType"
|
77
|
+
end
|
78
|
+
add_message "walletrpc.ImportPublicKeyResponse" do
|
79
|
+
end
|
39
80
|
add_message "walletrpc.Transaction" do
|
40
81
|
optional :tx_hex, :bytes, 1
|
41
82
|
optional :label, :string, 2
|
@@ -68,6 +109,8 @@ Google::Protobuf::DescriptorPool.generated_pool.build do
|
|
68
109
|
optional :next_broadcast_height, :uint32, 6
|
69
110
|
optional :requested_conf_target, :uint32, 8
|
70
111
|
optional :requested_sat_per_byte, :uint32, 9
|
112
|
+
optional :sat_per_vbyte, :uint64, 10
|
113
|
+
optional :requested_sat_per_vbyte, :uint64, 11
|
71
114
|
optional :force, :bool, 7
|
72
115
|
end
|
73
116
|
add_message "walletrpc.PendingSweepsRequest" do
|
@@ -80,6 +123,7 @@ Google::Protobuf::DescriptorPool.generated_pool.build do
|
|
80
123
|
optional :target_conf, :uint32, 2
|
81
124
|
optional :sat_per_byte, :uint32, 3
|
82
125
|
optional :force, :bool, 4
|
126
|
+
optional :sat_per_vbyte, :uint64, 5
|
83
127
|
end
|
84
128
|
add_message "walletrpc.BumpFeeResponse" do
|
85
129
|
end
|
@@ -103,13 +147,16 @@ Google::Protobuf::DescriptorPool.generated_pool.build do
|
|
103
147
|
add_message "walletrpc.LabelTransactionResponse" do
|
104
148
|
end
|
105
149
|
add_message "walletrpc.FundPsbtRequest" do
|
150
|
+
optional :account, :string, 5
|
151
|
+
optional :min_confs, :int32, 6
|
152
|
+
optional :spend_unconfirmed, :bool, 7
|
106
153
|
oneof :template do
|
107
154
|
optional :psbt, :bytes, 1
|
108
155
|
optional :raw, :message, 2, "walletrpc.TxTemplate"
|
109
156
|
end
|
110
157
|
oneof :fees do
|
111
158
|
optional :target_conf, :uint32, 3
|
112
|
-
optional :sat_per_vbyte, :
|
159
|
+
optional :sat_per_vbyte, :uint64, 4
|
113
160
|
end
|
114
161
|
end
|
115
162
|
add_message "walletrpc.FundPsbtResponse" do
|
@@ -126,13 +173,31 @@ Google::Protobuf::DescriptorPool.generated_pool.build do
|
|
126
173
|
optional :outpoint, :message, 2, "lnrpc.OutPoint"
|
127
174
|
optional :expiration, :uint64, 3
|
128
175
|
end
|
176
|
+
add_message "walletrpc.SignPsbtRequest" do
|
177
|
+
optional :funded_psbt, :bytes, 1
|
178
|
+
end
|
179
|
+
add_message "walletrpc.SignPsbtResponse" do
|
180
|
+
optional :signed_psbt, :bytes, 1
|
181
|
+
end
|
129
182
|
add_message "walletrpc.FinalizePsbtRequest" do
|
130
183
|
optional :funded_psbt, :bytes, 1
|
184
|
+
optional :account, :string, 5
|
131
185
|
end
|
132
186
|
add_message "walletrpc.FinalizePsbtResponse" do
|
133
187
|
optional :signed_psbt, :bytes, 1
|
134
188
|
optional :raw_final_tx, :bytes, 2
|
135
189
|
end
|
190
|
+
add_message "walletrpc.ListLeasesRequest" do
|
191
|
+
end
|
192
|
+
add_message "walletrpc.ListLeasesResponse" do
|
193
|
+
repeated :locked_utxos, :message, 1, "walletrpc.UtxoLease"
|
194
|
+
end
|
195
|
+
add_enum "walletrpc.AddressType" do
|
196
|
+
value :UNKNOWN, 0
|
197
|
+
value :WITNESS_PUBKEY_HASH, 1
|
198
|
+
value :NESTED_WITNESS_PUBKEY_HASH, 2
|
199
|
+
value :HYBRID_NESTED_WITNESS_PUBKEY_HASH, 3
|
200
|
+
end
|
136
201
|
add_enum "walletrpc.WitnessType" do
|
137
202
|
value :UNKNOWN_WITNESS, 0
|
138
203
|
value :COMMITMENT_TIME_LOCK, 1
|
@@ -162,6 +227,13 @@ module Walletrpc
|
|
162
227
|
KeyReq = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("walletrpc.KeyReq").msgclass
|
163
228
|
AddrRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("walletrpc.AddrRequest").msgclass
|
164
229
|
AddrResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("walletrpc.AddrResponse").msgclass
|
230
|
+
Account = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("walletrpc.Account").msgclass
|
231
|
+
ListAccountsRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("walletrpc.ListAccountsRequest").msgclass
|
232
|
+
ListAccountsResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("walletrpc.ListAccountsResponse").msgclass
|
233
|
+
ImportAccountRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("walletrpc.ImportAccountRequest").msgclass
|
234
|
+
ImportAccountResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("walletrpc.ImportAccountResponse").msgclass
|
235
|
+
ImportPublicKeyRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("walletrpc.ImportPublicKeyRequest").msgclass
|
236
|
+
ImportPublicKeyResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("walletrpc.ImportPublicKeyResponse").msgclass
|
165
237
|
Transaction = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("walletrpc.Transaction").msgclass
|
166
238
|
PublishResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("walletrpc.PublishResponse").msgclass
|
167
239
|
SendOutputsRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("walletrpc.SendOutputsRequest").msgclass
|
@@ -182,7 +254,12 @@ module Walletrpc
|
|
182
254
|
FundPsbtResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("walletrpc.FundPsbtResponse").msgclass
|
183
255
|
TxTemplate = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("walletrpc.TxTemplate").msgclass
|
184
256
|
UtxoLease = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("walletrpc.UtxoLease").msgclass
|
257
|
+
SignPsbtRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("walletrpc.SignPsbtRequest").msgclass
|
258
|
+
SignPsbtResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("walletrpc.SignPsbtResponse").msgclass
|
185
259
|
FinalizePsbtRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("walletrpc.FinalizePsbtRequest").msgclass
|
186
260
|
FinalizePsbtResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("walletrpc.FinalizePsbtResponse").msgclass
|
261
|
+
ListLeasesRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("walletrpc.ListLeasesRequest").msgclass
|
262
|
+
ListLeasesResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("walletrpc.ListLeasesResponse").msgclass
|
263
|
+
AddressType = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("walletrpc.AddressType").enummodule
|
187
264
|
WitnessType = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("walletrpc.WitnessType").enummodule
|
188
265
|
end
|
@@ -33,6 +33,9 @@ module Walletrpc
|
|
33
33
|
# originally lock the output.
|
34
34
|
rpc :ReleaseOutput, ::Walletrpc::ReleaseOutputRequest, ::Walletrpc::ReleaseOutputResponse
|
35
35
|
#
|
36
|
+
# ListLeases lists all currently locked utxos.
|
37
|
+
rpc :ListLeases, ::Walletrpc::ListLeasesRequest, ::Walletrpc::ListLeasesResponse
|
38
|
+
#
|
36
39
|
# DeriveNextKey attempts to derive the *next* key within the key family
|
37
40
|
# (account in BIP43) specified. This method should return the next external
|
38
41
|
# child within this branch.
|
@@ -45,6 +48,43 @@ module Walletrpc
|
|
45
48
|
# NextAddr returns the next unused address within the wallet.
|
46
49
|
rpc :NextAddr, ::Walletrpc::AddrRequest, ::Walletrpc::AddrResponse
|
47
50
|
#
|
51
|
+
# ListAccounts retrieves all accounts belonging to the wallet by default. A
|
52
|
+
# name and key scope filter can be provided to filter through all of the
|
53
|
+
# wallet accounts and return only those matching.
|
54
|
+
rpc :ListAccounts, ::Walletrpc::ListAccountsRequest, ::Walletrpc::ListAccountsResponse
|
55
|
+
#
|
56
|
+
# ImportAccount imports an account backed by an account extended public key.
|
57
|
+
# The master key fingerprint denotes the fingerprint of the root key
|
58
|
+
# corresponding to the account public key (also known as the key with
|
59
|
+
# derivation path m/). This may be required by some hardware wallets for
|
60
|
+
# proper identification and signing.
|
61
|
+
#
|
62
|
+
# The address type can usually be inferred from the key's version, but may be
|
63
|
+
# required for certain keys to map them into the proper scope.
|
64
|
+
#
|
65
|
+
# For BIP-0044 keys, an address type must be specified as we intend to not
|
66
|
+
# support importing BIP-0044 keys into the wallet using the legacy
|
67
|
+
# pay-to-pubkey-hash (P2PKH) scheme. A nested witness address type will force
|
68
|
+
# the standard BIP-0049 derivation scheme, while a witness address type will
|
69
|
+
# force the standard BIP-0084 derivation scheme.
|
70
|
+
#
|
71
|
+
# For BIP-0049 keys, an address type must also be specified to make a
|
72
|
+
# distinction between the standard BIP-0049 address schema (nested witness
|
73
|
+
# pubkeys everywhere) and our own BIP-0049Plus address schema (nested pubkeys
|
74
|
+
# externally, witness pubkeys internally).
|
75
|
+
#
|
76
|
+
# NOTE: Events (deposits/spends) for keys derived from an account will only be
|
77
|
+
# detected by lnd if they happen after the import. Rescans to detect past
|
78
|
+
# events will be supported later on.
|
79
|
+
rpc :ImportAccount, ::Walletrpc::ImportAccountRequest, ::Walletrpc::ImportAccountResponse
|
80
|
+
#
|
81
|
+
# ImportPublicKey imports a public key as watch-only into the wallet.
|
82
|
+
#
|
83
|
+
# NOTE: Events (deposits/spends) for a key will only be detected by lnd if
|
84
|
+
# they happen after the import. Rescans to detect past events will be
|
85
|
+
# supported later on.
|
86
|
+
rpc :ImportPublicKey, ::Walletrpc::ImportPublicKeyRequest, ::Walletrpc::ImportPublicKeyResponse
|
87
|
+
#
|
48
88
|
# PublishTransaction attempts to publish the passed transaction to the
|
49
89
|
# network. Once this returns without an error, the wallet will continually
|
50
90
|
# attempt to re-broadcast the transaction on start up, until it enters the
|
@@ -129,6 +169,19 @@ module Walletrpc
|
|
129
169
|
# an error on the caller's side.
|
130
170
|
rpc :FundPsbt, ::Walletrpc::FundPsbtRequest, ::Walletrpc::FundPsbtResponse
|
131
171
|
#
|
172
|
+
# SignPsbt expects a partial transaction with all inputs and outputs fully
|
173
|
+
# declared and tries to sign all unsigned inputs that have all required fields
|
174
|
+
# (UTXO information, BIP32 derivation information, witness or sig scripts)
|
175
|
+
# set.
|
176
|
+
# If no error is returned, the PSBT is ready to be given to the next signer or
|
177
|
+
# to be finalized if lnd was the last signer.
|
178
|
+
#
|
179
|
+
# NOTE: This RPC only signs inputs (and only those it can sign), it does not
|
180
|
+
# perform any other tasks (such as coin selection, UTXO locking or
|
181
|
+
# input/output/fee value validation, PSBT finalization). Any input that is
|
182
|
+
# incomplete will be skipped.
|
183
|
+
rpc :SignPsbt, ::Walletrpc::SignPsbtRequest, ::Walletrpc::SignPsbtResponse
|
184
|
+
#
|
132
185
|
# FinalizePsbt expects a partial transaction with all inputs and outputs fully
|
133
186
|
# declared and tries to sign all inputs that belong to the wallet. Lnd must be
|
134
187
|
# the last signer of the transaction. That means, if there are any unsigned
|
@@ -4,6 +4,7 @@
|
|
4
4
|
require 'google/protobuf'
|
5
5
|
|
6
6
|
require 'rpc_pb'
|
7
|
+
|
7
8
|
Google::Protobuf::DescriptorPool.generated_pool.build do
|
8
9
|
add_file("walletunlocker.proto", :syntax => :proto3) do
|
9
10
|
add_message "lnrpc.GenSeedRequest" do
|
@@ -21,10 +22,24 @@ Google::Protobuf::DescriptorPool.generated_pool.build do
|
|
21
22
|
optional :recovery_window, :int32, 4
|
22
23
|
optional :channel_backups, :message, 5, "lnrpc.ChanBackupSnapshot"
|
23
24
|
optional :stateless_init, :bool, 6
|
25
|
+
optional :extended_master_key, :string, 7
|
26
|
+
optional :extended_master_key_birthday_timestamp, :uint64, 8
|
27
|
+
optional :watch_only, :message, 9, "lnrpc.WatchOnly"
|
24
28
|
end
|
25
29
|
add_message "lnrpc.InitWalletResponse" do
|
26
30
|
optional :admin_macaroon, :bytes, 1
|
27
31
|
end
|
32
|
+
add_message "lnrpc.WatchOnly" do
|
33
|
+
optional :master_key_birthday_timestamp, :uint64, 1
|
34
|
+
optional :master_key_fingerprint, :bytes, 2
|
35
|
+
repeated :accounts, :message, 3, "lnrpc.WatchOnlyAccount"
|
36
|
+
end
|
37
|
+
add_message "lnrpc.WatchOnlyAccount" do
|
38
|
+
optional :purpose, :uint32, 1
|
39
|
+
optional :coin_type, :uint32, 2
|
40
|
+
optional :account, :uint32, 3
|
41
|
+
optional :xpub, :string, 4
|
42
|
+
end
|
28
43
|
add_message "lnrpc.UnlockWalletRequest" do
|
29
44
|
optional :wallet_password, :bytes, 1
|
30
45
|
optional :recovery_window, :int32, 2
|
@@ -50,6 +65,8 @@ module Lnrpc
|
|
50
65
|
GenSeedResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("lnrpc.GenSeedResponse").msgclass
|
51
66
|
InitWalletRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("lnrpc.InitWalletRequest").msgclass
|
52
67
|
InitWalletResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("lnrpc.InitWalletResponse").msgclass
|
68
|
+
WatchOnly = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("lnrpc.WatchOnly").msgclass
|
69
|
+
WatchOnlyAccount = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("lnrpc.WatchOnlyAccount").msgclass
|
53
70
|
UnlockWalletRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("lnrpc.UnlockWalletRequest").msgclass
|
54
71
|
UnlockWalletResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("lnrpc.UnlockWalletResponse").msgclass
|
55
72
|
ChangePasswordRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("lnrpc.ChangePasswordRequest").msgclass
|
@@ -26,6 +26,7 @@ Google::Protobuf::DescriptorPool.generated_pool.build do
|
|
26
26
|
optional :num_pending_backups, :uint32, 2
|
27
27
|
optional :max_backups, :uint32, 3
|
28
28
|
optional :sweep_sat_per_byte, :uint32, 4
|
29
|
+
optional :sweep_sat_per_vbyte, :uint32, 5
|
29
30
|
end
|
30
31
|
add_message "wtclientrpc.Tower" do
|
31
32
|
optional :pubkey, :bytes, 1
|
@@ -55,6 +56,7 @@ Google::Protobuf::DescriptorPool.generated_pool.build do
|
|
55
56
|
add_message "wtclientrpc.PolicyResponse" do
|
56
57
|
optional :max_updates, :uint32, 1
|
57
58
|
optional :sweep_sat_per_byte, :uint32, 2
|
59
|
+
optional :sweep_sat_per_vbyte, :uint32, 3
|
58
60
|
end
|
59
61
|
add_enum "wtclientrpc.PolicyType" do
|
60
62
|
value :LEGACY, 0
|
data/lib/lnrpc/client.rb
CHANGED
data/lib/lnrpc/version.rb
CHANGED
data/lnrpc.gemspec
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: lnrpc
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.14.3.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Michael Bumann
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2022-06-12 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|
@@ -72,14 +72,14 @@ dependencies:
|
|
72
72
|
requirements:
|
73
73
|
- - ">="
|
74
74
|
- !ruby/object:Gem::Version
|
75
|
-
version:
|
75
|
+
version: 3.15.7
|
76
76
|
type: :runtime
|
77
77
|
prerelease: false
|
78
78
|
version_requirements: !ruby/object:Gem::Requirement
|
79
79
|
requirements:
|
80
80
|
- - ">="
|
81
81
|
- !ruby/object:Gem::Version
|
82
|
-
version:
|
82
|
+
version: 3.15.7
|
83
83
|
description: gRPC service definitions for the Lightning Network Daemon (lnd) gRPC
|
84
84
|
interface packed as ruby gem
|
85
85
|
email:
|
@@ -149,7 +149,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
149
149
|
- !ruby/object:Gem::Version
|
150
150
|
version: '0'
|
151
151
|
requirements: []
|
152
|
-
rubygems_version: 3.1.
|
152
|
+
rubygems_version: 3.1.6
|
153
153
|
signing_key:
|
154
154
|
specification_version: 4
|
155
155
|
summary: gRPC interface for lnd packed as ruby gem
|