lnrpc 0.9.0 → 0.13.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (37) hide show
  1. checksums.yaml +4 -4
  2. data/.gitignore +2 -0
  3. data/Gemfile.lock +24 -24
  4. data/README.md +30 -16
  5. data/examples.rb +13 -6
  6. data/generate-grpc-service-files.sh +29 -0
  7. data/lib/grpc_services/autopilotrpc/autopilot_pb.rb +48 -0
  8. data/lib/grpc_services/autopilotrpc/autopilot_services_pb.rb +40 -0
  9. data/lib/grpc_services/chainrpc/chainnotifier_pb.rb +67 -0
  10. data/lib/grpc_services/chainrpc/chainnotifier_services_pb.rb +51 -0
  11. data/lib/grpc_services/invoicesrpc/invoices_pb.rb +48 -0
  12. data/lib/grpc_services/invoicesrpc/invoices_services_pb.rb +41 -0
  13. data/lib/grpc_services/lnclipb/lncli_pb.rb +18 -0
  14. data/lib/grpc_services/routerrpc/router_pb.rb +277 -0
  15. data/lib/grpc_services/routerrpc/router_services_pb.rb +105 -0
  16. data/lib/grpc_services/rpc_pb.rb +1388 -0
  17. data/lib/{lnrpc → grpc_services}/rpc_services_pb.rb +165 -178
  18. data/lib/grpc_services/signrpc/signer_pb.rb +84 -0
  19. data/lib/grpc_services/signrpc/signer_services_pb.rb +69 -0
  20. data/lib/grpc_services/verrpc/verrpc_pb.rb +27 -0
  21. data/lib/grpc_services/verrpc/verrpc_services_pb.rb +27 -0
  22. data/lib/grpc_services/walletrpc/walletkit_pb.rb +254 -0
  23. data/lib/grpc_services/walletrpc/walletkit_services_pb.rb +188 -0
  24. data/lib/grpc_services/walletunlocker_pb.rb +57 -0
  25. data/lib/grpc_services/walletunlocker_services_pb.rb +72 -0
  26. data/lib/grpc_services/watchtowerrpc/watchtower_pb.rb +21 -0
  27. data/lib/grpc_services/watchtowerrpc/watchtower_services_pb.rb +28 -0
  28. data/lib/grpc_services/wtclientrpc/wtclient_pb.rb +83 -0
  29. data/lib/grpc_services/wtclientrpc/wtclient_services_pb.rb +43 -0
  30. data/lib/lnrpc.rb +19 -3
  31. data/lib/lnrpc/client.rb +62 -46
  32. data/lib/lnrpc/grpc_wrapper.rb +43 -0
  33. data/lib/lnrpc/version.rb +1 -1
  34. data/lnrpc.gemspec +7 -5
  35. metadata +41 -17
  36. data/lib/lnrpc/rpc.proto +0 -3075
  37. data/lib/lnrpc/rpc_pb.rb +0 -1082
@@ -0,0 +1,48 @@
1
+ # Generated by the protocol buffer compiler. DO NOT EDIT!
2
+ # source: invoicesrpc/invoices.proto
3
+
4
+ require 'google/protobuf'
5
+
6
+ require 'rpc_pb'
7
+ Google::Protobuf::DescriptorPool.generated_pool.build do
8
+ add_file("invoicesrpc/invoices.proto", :syntax => :proto3) do
9
+ add_message "invoicesrpc.CancelInvoiceMsg" do
10
+ optional :payment_hash, :bytes, 1
11
+ end
12
+ add_message "invoicesrpc.CancelInvoiceResp" do
13
+ end
14
+ add_message "invoicesrpc.AddHoldInvoiceRequest" do
15
+ optional :memo, :string, 1
16
+ optional :hash, :bytes, 2
17
+ optional :value, :int64, 3
18
+ optional :value_msat, :int64, 10
19
+ optional :description_hash, :bytes, 4
20
+ optional :expiry, :int64, 5
21
+ optional :fallback_addr, :string, 6
22
+ optional :cltv_expiry, :uint64, 7
23
+ repeated :route_hints, :message, 8, "lnrpc.RouteHint"
24
+ optional :private, :bool, 9
25
+ end
26
+ add_message "invoicesrpc.AddHoldInvoiceResp" do
27
+ optional :payment_request, :string, 1
28
+ end
29
+ add_message "invoicesrpc.SettleInvoiceMsg" do
30
+ optional :preimage, :bytes, 1
31
+ end
32
+ add_message "invoicesrpc.SettleInvoiceResp" do
33
+ end
34
+ add_message "invoicesrpc.SubscribeSingleInvoiceRequest" do
35
+ optional :r_hash, :bytes, 2
36
+ end
37
+ end
38
+ end
39
+
40
+ module Invoicesrpc
41
+ CancelInvoiceMsg = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("invoicesrpc.CancelInvoiceMsg").msgclass
42
+ CancelInvoiceResp = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("invoicesrpc.CancelInvoiceResp").msgclass
43
+ AddHoldInvoiceRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("invoicesrpc.AddHoldInvoiceRequest").msgclass
44
+ AddHoldInvoiceResp = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("invoicesrpc.AddHoldInvoiceResp").msgclass
45
+ SettleInvoiceMsg = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("invoicesrpc.SettleInvoiceMsg").msgclass
46
+ SettleInvoiceResp = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("invoicesrpc.SettleInvoiceResp").msgclass
47
+ SubscribeSingleInvoiceRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("invoicesrpc.SubscribeSingleInvoiceRequest").msgclass
48
+ end
@@ -0,0 +1,41 @@
1
+ # Generated by the protocol buffer compiler. DO NOT EDIT!
2
+ # Source: invoicesrpc/invoices.proto for package 'invoicesrpc'
3
+
4
+ require 'grpc'
5
+ require 'invoicesrpc/invoices_pb'
6
+
7
+ module Invoicesrpc
8
+ module Invoices
9
+ # Invoices is a service that can be used to create, accept, settle and cancel
10
+ # invoices.
11
+ class Service
12
+
13
+ include ::GRPC::GenericService
14
+
15
+ self.marshal_class_method = :encode
16
+ self.unmarshal_class_method = :decode
17
+ self.service_name = 'invoicesrpc.Invoices'
18
+
19
+ #
20
+ # SubscribeSingleInvoice returns a uni-directional stream (server -> client)
21
+ # to notify the client of state transitions of the specified invoice.
22
+ # Initially the current invoice state is always sent out.
23
+ rpc :SubscribeSingleInvoice, ::Invoicesrpc::SubscribeSingleInvoiceRequest, stream(::Lnrpc::Invoice)
24
+ #
25
+ # CancelInvoice cancels a currently open invoice. If the invoice is already
26
+ # canceled, this call will succeed. If the invoice is already settled, it will
27
+ # fail.
28
+ rpc :CancelInvoice, ::Invoicesrpc::CancelInvoiceMsg, ::Invoicesrpc::CancelInvoiceResp
29
+ #
30
+ # AddHoldInvoice creates a hold invoice. It ties the invoice to the hash
31
+ # supplied in the request.
32
+ rpc :AddHoldInvoice, ::Invoicesrpc::AddHoldInvoiceRequest, ::Invoicesrpc::AddHoldInvoiceResp
33
+ #
34
+ # SettleInvoice settles an accepted invoice. If the invoice is already
35
+ # settled, this call will succeed.
36
+ rpc :SettleInvoice, ::Invoicesrpc::SettleInvoiceMsg, ::Invoicesrpc::SettleInvoiceResp
37
+ end
38
+
39
+ Stub = Service.rpc_stub_class
40
+ end
41
+ end
@@ -0,0 +1,18 @@
1
+ # Generated by the protocol buffer compiler. DO NOT EDIT!
2
+ # source: lnclipb/lncli.proto
3
+
4
+ require 'google/protobuf'
5
+
6
+ require 'verrpc/verrpc_pb'
7
+ Google::Protobuf::DescriptorPool.generated_pool.build do
8
+ add_file("lnclipb/lncli.proto", :syntax => :proto3) do
9
+ add_message "lnclipb.VersionResponse" do
10
+ optional :lncli, :message, 1, "verrpc.Version"
11
+ optional :lnd, :message, 2, "verrpc.Version"
12
+ end
13
+ end
14
+ end
15
+
16
+ module Lnclipb
17
+ VersionResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("lnclipb.VersionResponse").msgclass
18
+ end
@@ -0,0 +1,277 @@
1
+ # Generated by the protocol buffer compiler. DO NOT EDIT!
2
+ # source: routerrpc/router.proto
3
+
4
+ require 'google/protobuf'
5
+
6
+ require 'rpc_pb'
7
+ Google::Protobuf::DescriptorPool.generated_pool.build do
8
+ add_file("routerrpc/router.proto", :syntax => :proto3) do
9
+ add_message "routerrpc.SendPaymentRequest" do
10
+ optional :dest, :bytes, 1
11
+ optional :amt, :int64, 2
12
+ optional :amt_msat, :int64, 12
13
+ optional :payment_hash, :bytes, 3
14
+ optional :final_cltv_delta, :int32, 4
15
+ optional :payment_addr, :bytes, 20
16
+ optional :payment_request, :string, 5
17
+ optional :timeout_seconds, :int32, 6
18
+ optional :fee_limit_sat, :int64, 7
19
+ optional :fee_limit_msat, :int64, 13
20
+ optional :outgoing_chan_id, :uint64, 8
21
+ repeated :outgoing_chan_ids, :uint64, 19
22
+ optional :last_hop_pubkey, :bytes, 14
23
+ optional :cltv_limit, :int32, 9
24
+ repeated :route_hints, :message, 10, "lnrpc.RouteHint"
25
+ map :dest_custom_records, :uint64, :bytes, 11
26
+ optional :allow_self_payment, :bool, 15
27
+ repeated :dest_features, :enum, 16, "lnrpc.FeatureBit"
28
+ optional :max_parts, :uint32, 17
29
+ optional :no_inflight_updates, :bool, 18
30
+ optional :max_shard_size_msat, :uint64, 21
31
+ optional :amp, :bool, 22
32
+ end
33
+ add_message "routerrpc.TrackPaymentRequest" do
34
+ optional :payment_hash, :bytes, 1
35
+ optional :no_inflight_updates, :bool, 2
36
+ end
37
+ add_message "routerrpc.RouteFeeRequest" do
38
+ optional :dest, :bytes, 1
39
+ optional :amt_sat, :int64, 2
40
+ end
41
+ add_message "routerrpc.RouteFeeResponse" do
42
+ optional :routing_fee_msat, :int64, 1
43
+ optional :time_lock_delay, :int64, 2
44
+ end
45
+ add_message "routerrpc.SendToRouteRequest" do
46
+ optional :payment_hash, :bytes, 1
47
+ optional :route, :message, 2, "lnrpc.Route"
48
+ end
49
+ add_message "routerrpc.SendToRouteResponse" do
50
+ optional :preimage, :bytes, 1
51
+ optional :failure, :message, 2, "lnrpc.Failure"
52
+ end
53
+ add_message "routerrpc.ResetMissionControlRequest" do
54
+ end
55
+ add_message "routerrpc.ResetMissionControlResponse" do
56
+ end
57
+ add_message "routerrpc.QueryMissionControlRequest" do
58
+ end
59
+ add_message "routerrpc.QueryMissionControlResponse" do
60
+ repeated :pairs, :message, 2, "routerrpc.PairHistory"
61
+ end
62
+ add_message "routerrpc.XImportMissionControlRequest" do
63
+ repeated :pairs, :message, 1, "routerrpc.PairHistory"
64
+ end
65
+ add_message "routerrpc.XImportMissionControlResponse" do
66
+ end
67
+ add_message "routerrpc.PairHistory" do
68
+ optional :node_from, :bytes, 1
69
+ optional :node_to, :bytes, 2
70
+ optional :history, :message, 7, "routerrpc.PairData"
71
+ end
72
+ add_message "routerrpc.PairData" do
73
+ optional :fail_time, :int64, 1
74
+ optional :fail_amt_sat, :int64, 2
75
+ optional :fail_amt_msat, :int64, 4
76
+ optional :success_time, :int64, 5
77
+ optional :success_amt_sat, :int64, 6
78
+ optional :success_amt_msat, :int64, 7
79
+ end
80
+ add_message "routerrpc.GetMissionControlConfigRequest" do
81
+ end
82
+ add_message "routerrpc.GetMissionControlConfigResponse" do
83
+ optional :config, :message, 1, "routerrpc.MissionControlConfig"
84
+ end
85
+ add_message "routerrpc.SetMissionControlConfigRequest" do
86
+ optional :config, :message, 1, "routerrpc.MissionControlConfig"
87
+ end
88
+ add_message "routerrpc.SetMissionControlConfigResponse" do
89
+ end
90
+ add_message "routerrpc.MissionControlConfig" do
91
+ optional :half_life_seconds, :uint64, 1
92
+ optional :hop_probability, :float, 2
93
+ optional :weight, :float, 3
94
+ optional :maximum_payment_results, :uint32, 4
95
+ optional :minimum_failure_relax_interval, :uint64, 5
96
+ end
97
+ add_message "routerrpc.QueryProbabilityRequest" do
98
+ optional :from_node, :bytes, 1
99
+ optional :to_node, :bytes, 2
100
+ optional :amt_msat, :int64, 3
101
+ end
102
+ add_message "routerrpc.QueryProbabilityResponse" do
103
+ optional :probability, :double, 1
104
+ optional :history, :message, 2, "routerrpc.PairData"
105
+ end
106
+ add_message "routerrpc.BuildRouteRequest" do
107
+ optional :amt_msat, :int64, 1
108
+ optional :final_cltv_delta, :int32, 2
109
+ optional :outgoing_chan_id, :uint64, 3
110
+ repeated :hop_pubkeys, :bytes, 4
111
+ optional :payment_addr, :bytes, 5
112
+ end
113
+ add_message "routerrpc.BuildRouteResponse" do
114
+ optional :route, :message, 1, "lnrpc.Route"
115
+ end
116
+ add_message "routerrpc.SubscribeHtlcEventsRequest" do
117
+ end
118
+ add_message "routerrpc.HtlcEvent" do
119
+ optional :incoming_channel_id, :uint64, 1
120
+ optional :outgoing_channel_id, :uint64, 2
121
+ optional :incoming_htlc_id, :uint64, 3
122
+ optional :outgoing_htlc_id, :uint64, 4
123
+ optional :timestamp_ns, :uint64, 5
124
+ optional :event_type, :enum, 6, "routerrpc.HtlcEvent.EventType"
125
+ oneof :event do
126
+ optional :forward_event, :message, 7, "routerrpc.ForwardEvent"
127
+ optional :forward_fail_event, :message, 8, "routerrpc.ForwardFailEvent"
128
+ optional :settle_event, :message, 9, "routerrpc.SettleEvent"
129
+ optional :link_fail_event, :message, 10, "routerrpc.LinkFailEvent"
130
+ end
131
+ end
132
+ add_enum "routerrpc.HtlcEvent.EventType" do
133
+ value :UNKNOWN, 0
134
+ value :SEND, 1
135
+ value :RECEIVE, 2
136
+ value :FORWARD, 3
137
+ end
138
+ add_message "routerrpc.HtlcInfo" do
139
+ optional :incoming_timelock, :uint32, 1
140
+ optional :outgoing_timelock, :uint32, 2
141
+ optional :incoming_amt_msat, :uint64, 3
142
+ optional :outgoing_amt_msat, :uint64, 4
143
+ end
144
+ add_message "routerrpc.ForwardEvent" do
145
+ optional :info, :message, 1, "routerrpc.HtlcInfo"
146
+ end
147
+ add_message "routerrpc.ForwardFailEvent" do
148
+ end
149
+ add_message "routerrpc.SettleEvent" do
150
+ end
151
+ add_message "routerrpc.LinkFailEvent" do
152
+ optional :info, :message, 1, "routerrpc.HtlcInfo"
153
+ optional :wire_failure, :enum, 2, "lnrpc.Failure.FailureCode"
154
+ optional :failure_detail, :enum, 3, "routerrpc.FailureDetail"
155
+ optional :failure_string, :string, 4
156
+ end
157
+ add_message "routerrpc.PaymentStatus" do
158
+ optional :state, :enum, 1, "routerrpc.PaymentState"
159
+ optional :preimage, :bytes, 2
160
+ repeated :htlcs, :message, 4, "lnrpc.HTLCAttempt"
161
+ end
162
+ add_message "routerrpc.CircuitKey" do
163
+ optional :chan_id, :uint64, 1
164
+ optional :htlc_id, :uint64, 2
165
+ end
166
+ add_message "routerrpc.ForwardHtlcInterceptRequest" do
167
+ optional :incoming_circuit_key, :message, 1, "routerrpc.CircuitKey"
168
+ optional :incoming_amount_msat, :uint64, 5
169
+ optional :incoming_expiry, :uint32, 6
170
+ optional :payment_hash, :bytes, 2
171
+ optional :outgoing_requested_chan_id, :uint64, 7
172
+ optional :outgoing_amount_msat, :uint64, 3
173
+ optional :outgoing_expiry, :uint32, 4
174
+ map :custom_records, :uint64, :bytes, 8
175
+ optional :onion_blob, :bytes, 9
176
+ end
177
+ add_message "routerrpc.ForwardHtlcInterceptResponse" do
178
+ optional :incoming_circuit_key, :message, 1, "routerrpc.CircuitKey"
179
+ optional :action, :enum, 2, "routerrpc.ResolveHoldForwardAction"
180
+ optional :preimage, :bytes, 3
181
+ end
182
+ add_message "routerrpc.UpdateChanStatusRequest" do
183
+ optional :chan_point, :message, 1, "lnrpc.ChannelPoint"
184
+ optional :action, :enum, 2, "routerrpc.ChanStatusAction"
185
+ end
186
+ add_message "routerrpc.UpdateChanStatusResponse" do
187
+ end
188
+ add_enum "routerrpc.FailureDetail" do
189
+ value :UNKNOWN, 0
190
+ value :NO_DETAIL, 1
191
+ value :ONION_DECODE, 2
192
+ value :LINK_NOT_ELIGIBLE, 3
193
+ value :ON_CHAIN_TIMEOUT, 4
194
+ value :HTLC_EXCEEDS_MAX, 5
195
+ value :INSUFFICIENT_BALANCE, 6
196
+ value :INCOMPLETE_FORWARD, 7
197
+ value :HTLC_ADD_FAILED, 8
198
+ value :FORWARDS_DISABLED, 9
199
+ value :INVOICE_CANCELED, 10
200
+ value :INVOICE_UNDERPAID, 11
201
+ value :INVOICE_EXPIRY_TOO_SOON, 12
202
+ value :INVOICE_NOT_OPEN, 13
203
+ value :MPP_INVOICE_TIMEOUT, 14
204
+ value :ADDRESS_MISMATCH, 15
205
+ value :SET_TOTAL_MISMATCH, 16
206
+ value :SET_TOTAL_TOO_LOW, 17
207
+ value :SET_OVERPAID, 18
208
+ value :UNKNOWN_INVOICE, 19
209
+ value :INVALID_KEYSEND, 20
210
+ value :MPP_IN_PROGRESS, 21
211
+ value :CIRCULAR_ROUTE, 22
212
+ end
213
+ add_enum "routerrpc.PaymentState" do
214
+ value :IN_FLIGHT, 0
215
+ value :SUCCEEDED, 1
216
+ value :FAILED_TIMEOUT, 2
217
+ value :FAILED_NO_ROUTE, 3
218
+ value :FAILED_ERROR, 4
219
+ value :FAILED_INCORRECT_PAYMENT_DETAILS, 5
220
+ value :FAILED_INSUFFICIENT_BALANCE, 6
221
+ end
222
+ add_enum "routerrpc.ResolveHoldForwardAction" do
223
+ value :SETTLE, 0
224
+ value :FAIL, 1
225
+ value :RESUME, 2
226
+ end
227
+ add_enum "routerrpc.ChanStatusAction" do
228
+ value :ENABLE, 0
229
+ value :DISABLE, 1
230
+ value :AUTO, 2
231
+ end
232
+ end
233
+ end
234
+
235
+ module Routerrpc
236
+ SendPaymentRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("routerrpc.SendPaymentRequest").msgclass
237
+ TrackPaymentRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("routerrpc.TrackPaymentRequest").msgclass
238
+ RouteFeeRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("routerrpc.RouteFeeRequest").msgclass
239
+ RouteFeeResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("routerrpc.RouteFeeResponse").msgclass
240
+ SendToRouteRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("routerrpc.SendToRouteRequest").msgclass
241
+ SendToRouteResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("routerrpc.SendToRouteResponse").msgclass
242
+ ResetMissionControlRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("routerrpc.ResetMissionControlRequest").msgclass
243
+ ResetMissionControlResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("routerrpc.ResetMissionControlResponse").msgclass
244
+ QueryMissionControlRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("routerrpc.QueryMissionControlRequest").msgclass
245
+ QueryMissionControlResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("routerrpc.QueryMissionControlResponse").msgclass
246
+ XImportMissionControlRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("routerrpc.XImportMissionControlRequest").msgclass
247
+ XImportMissionControlResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("routerrpc.XImportMissionControlResponse").msgclass
248
+ PairHistory = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("routerrpc.PairHistory").msgclass
249
+ PairData = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("routerrpc.PairData").msgclass
250
+ GetMissionControlConfigRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("routerrpc.GetMissionControlConfigRequest").msgclass
251
+ GetMissionControlConfigResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("routerrpc.GetMissionControlConfigResponse").msgclass
252
+ SetMissionControlConfigRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("routerrpc.SetMissionControlConfigRequest").msgclass
253
+ SetMissionControlConfigResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("routerrpc.SetMissionControlConfigResponse").msgclass
254
+ MissionControlConfig = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("routerrpc.MissionControlConfig").msgclass
255
+ QueryProbabilityRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("routerrpc.QueryProbabilityRequest").msgclass
256
+ QueryProbabilityResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("routerrpc.QueryProbabilityResponse").msgclass
257
+ BuildRouteRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("routerrpc.BuildRouteRequest").msgclass
258
+ BuildRouteResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("routerrpc.BuildRouteResponse").msgclass
259
+ SubscribeHtlcEventsRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("routerrpc.SubscribeHtlcEventsRequest").msgclass
260
+ HtlcEvent = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("routerrpc.HtlcEvent").msgclass
261
+ HtlcEvent::EventType = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("routerrpc.HtlcEvent.EventType").enummodule
262
+ HtlcInfo = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("routerrpc.HtlcInfo").msgclass
263
+ ForwardEvent = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("routerrpc.ForwardEvent").msgclass
264
+ ForwardFailEvent = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("routerrpc.ForwardFailEvent").msgclass
265
+ SettleEvent = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("routerrpc.SettleEvent").msgclass
266
+ LinkFailEvent = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("routerrpc.LinkFailEvent").msgclass
267
+ PaymentStatus = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("routerrpc.PaymentStatus").msgclass
268
+ CircuitKey = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("routerrpc.CircuitKey").msgclass
269
+ ForwardHtlcInterceptRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("routerrpc.ForwardHtlcInterceptRequest").msgclass
270
+ ForwardHtlcInterceptResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("routerrpc.ForwardHtlcInterceptResponse").msgclass
271
+ UpdateChanStatusRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("routerrpc.UpdateChanStatusRequest").msgclass
272
+ UpdateChanStatusResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("routerrpc.UpdateChanStatusResponse").msgclass
273
+ FailureDetail = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("routerrpc.FailureDetail").enummodule
274
+ PaymentState = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("routerrpc.PaymentState").enummodule
275
+ ResolveHoldForwardAction = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("routerrpc.ResolveHoldForwardAction").enummodule
276
+ ChanStatusAction = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("routerrpc.ChanStatusAction").enummodule
277
+ end
@@ -0,0 +1,105 @@
1
+ # Generated by the protocol buffer compiler. DO NOT EDIT!
2
+ # Source: routerrpc/router.proto for package 'routerrpc'
3
+
4
+ require 'grpc'
5
+ require 'routerrpc/router_pb'
6
+
7
+ module Routerrpc
8
+ module Router
9
+ # Router is a service that offers advanced interaction with the router
10
+ # subsystem of the daemon.
11
+ class Service
12
+
13
+ include ::GRPC::GenericService
14
+
15
+ self.marshal_class_method = :encode
16
+ self.unmarshal_class_method = :decode
17
+ self.service_name = 'routerrpc.Router'
18
+
19
+ #
20
+ # SendPaymentV2 attempts to route a payment described by the passed
21
+ # PaymentRequest to the final destination. The call returns a stream of
22
+ # payment updates.
23
+ rpc :SendPaymentV2, ::Routerrpc::SendPaymentRequest, stream(::Lnrpc::Payment)
24
+ #
25
+ # TrackPaymentV2 returns an update stream for the payment identified by the
26
+ # payment hash.
27
+ rpc :TrackPaymentV2, ::Routerrpc::TrackPaymentRequest, stream(::Lnrpc::Payment)
28
+ #
29
+ # EstimateRouteFee allows callers to obtain a lower bound w.r.t how much it
30
+ # may cost to send an HTLC to the target end destination.
31
+ rpc :EstimateRouteFee, ::Routerrpc::RouteFeeRequest, ::Routerrpc::RouteFeeResponse
32
+ #
33
+ # Deprecated, use SendToRouteV2. SendToRoute attempts to make a payment via
34
+ # the specified route. This method differs from SendPayment in that it
35
+ # allows users to specify a full route manually. This can be used for
36
+ # things like rebalancing, and atomic swaps. It differs from the newer
37
+ # SendToRouteV2 in that it doesn't return the full HTLC information.
38
+ rpc :SendToRoute, ::Routerrpc::SendToRouteRequest, ::Routerrpc::SendToRouteResponse
39
+ #
40
+ # SendToRouteV2 attempts to make a payment via the specified route. This
41
+ # method differs from SendPayment in that it allows users to specify a full
42
+ # route manually. This can be used for things like rebalancing, and atomic
43
+ # swaps.
44
+ rpc :SendToRouteV2, ::Routerrpc::SendToRouteRequest, ::Lnrpc::HTLCAttempt
45
+ #
46
+ # ResetMissionControl clears all mission control state and starts with a clean
47
+ # slate.
48
+ rpc :ResetMissionControl, ::Routerrpc::ResetMissionControlRequest, ::Routerrpc::ResetMissionControlResponse
49
+ #
50
+ # QueryMissionControl exposes the internal mission control state to callers.
51
+ # It is a development feature.
52
+ rpc :QueryMissionControl, ::Routerrpc::QueryMissionControlRequest, ::Routerrpc::QueryMissionControlResponse
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
+ #
67
+ # QueryProbability returns the current success probability estimate for a
68
+ # given node pair and amount.
69
+ rpc :QueryProbability, ::Routerrpc::QueryProbabilityRequest, ::Routerrpc::QueryProbabilityResponse
70
+ #
71
+ # BuildRoute builds a fully specified route based on a list of hop public
72
+ # keys. It retrieves the relevant channel policies from the graph in order to
73
+ # calculate the correct fees and time locks.
74
+ rpc :BuildRoute, ::Routerrpc::BuildRouteRequest, ::Routerrpc::BuildRouteResponse
75
+ #
76
+ # SubscribeHtlcEvents creates a uni-directional stream from the server to
77
+ # the client which delivers a stream of htlc events.
78
+ rpc :SubscribeHtlcEvents, ::Routerrpc::SubscribeHtlcEventsRequest, stream(::Routerrpc::HtlcEvent)
79
+ #
80
+ # Deprecated, use SendPaymentV2. SendPayment attempts to route a payment
81
+ # described by the passed PaymentRequest to the final destination. The call
82
+ # returns a stream of payment status updates.
83
+ rpc :SendPayment, ::Routerrpc::SendPaymentRequest, stream(::Routerrpc::PaymentStatus)
84
+ #
85
+ # Deprecated, use TrackPaymentV2. TrackPayment returns an update stream for
86
+ # the payment identified by the payment hash.
87
+ rpc :TrackPayment, ::Routerrpc::TrackPaymentRequest, stream(::Routerrpc::PaymentStatus)
88
+ # *
89
+ # HtlcInterceptor dispatches a bi-directional streaming RPC in which
90
+ # Forwarded HTLC requests are sent to the client and the client responds with
91
+ # a boolean that tells LND if this htlc should be intercepted.
92
+ # In case of interception, the htlc can be either settled, cancelled or
93
+ # resumed later by using the ResolveHoldForward endpoint.
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
101
+ end
102
+
103
+ Stub = Service.rpc_stub_class
104
+ end
105
+ end