rack-lightning 0.1.1 → 0.1.2

Sign up to get free protection for your applications and to get access to all the features.
@@ -1,307 +0,0 @@
1
- # Generated by the protocol buffer compiler. DO NOT EDIT!
2
- # Source: rpc.proto for package 'lnrpc'
3
-
4
- require 'grpc'
5
- require_relative 'rpc_pb'
6
-
7
- module Lnrpc
8
- module WalletUnlocker
9
- # The WalletUnlocker service is used to set up a wallet password for
10
- # lnd at first startup, and unlock a previously set up wallet.
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 = 'lnrpc.WalletUnlocker'
18
-
19
- # *
20
- # GenSeed is the first method that should be used to instantiate a new lnd
21
- # instance. This method allows a caller to generate a new aezeed cipher seed
22
- # given an optional passphrase. If provided, the passphrase will be necessary
23
- # to decrypt the cipherseed to expose the internal wallet seed.
24
- #
25
- # Once the cipherseed is obtained and verified by the user, the InitWallet
26
- # method should be used to commit the newly generated seed, and create the
27
- # wallet.
28
- rpc :GenSeed, GenSeedRequest, GenSeedResponse
29
- # *
30
- # InitWallet is used when lnd is starting up for the first time to fully
31
- # initialize the daemon and its internal wallet. At the very least a wallet
32
- # password must be provided. This will be used to encrypt sensitive material
33
- # on disk.
34
- #
35
- # In the case of a recovery scenario, the user can also specify their aezeed
36
- # mnemonic and passphrase. If set, then the daemon will use this prior state
37
- # to initialize its internal wallet.
38
- #
39
- # Alternatively, this can be used along with the GenSeed RPC to obtain a
40
- # seed, then present it to the user. Once it has been verified by the user,
41
- # the seed can be fed into this RPC in order to commit the new wallet.
42
- rpc :InitWallet, InitWalletRequest, InitWalletResponse
43
- # * lncli: `unlock`
44
- # UnlockWallet is used at startup of lnd to provide a password to unlock
45
- # the wallet database.
46
- rpc :UnlockWallet, UnlockWalletRequest, UnlockWalletResponse
47
- # * lncli: `changepassword`
48
- # ChangePassword changes the password of the encrypted wallet. This will
49
- # automatically unlock the wallet database if successful.
50
- rpc :ChangePassword, ChangePasswordRequest, ChangePasswordResponse
51
- end
52
-
53
- Stub = Service.rpc_stub_class
54
- end
55
- module Lightning
56
- class Service
57
-
58
- include GRPC::GenericService
59
-
60
- self.marshal_class_method = :encode
61
- self.unmarshal_class_method = :decode
62
- self.service_name = 'lnrpc.Lightning'
63
-
64
- # * lncli: `walletbalance`
65
- # WalletBalance returns total unspent outputs(confirmed and unconfirmed), all
66
- # confirmed unspent outputs and all unconfirmed unspent outputs under control
67
- # of the wallet.
68
- rpc :WalletBalance, WalletBalanceRequest, WalletBalanceResponse
69
- # * lncli: `channelbalance`
70
- # ChannelBalance returns the total funds available across all open channels
71
- # in satoshis.
72
- rpc :ChannelBalance, ChannelBalanceRequest, ChannelBalanceResponse
73
- # * lncli: `listchaintxns`
74
- # GetTransactions returns a list describing all the known transactions
75
- # relevant to the wallet.
76
- rpc :GetTransactions, GetTransactionsRequest, TransactionDetails
77
- # * lncli: `sendcoins`
78
- # SendCoins executes a request to send coins to a particular address. Unlike
79
- # SendMany, this RPC call only allows creating a single output at a time. If
80
- # neither target_conf, or sat_per_byte are set, then the internal wallet will
81
- # consult its fee model to determine a fee for the default confirmation
82
- # target.
83
- rpc :SendCoins, SendCoinsRequest, SendCoinsResponse
84
- # *
85
- # SubscribeTransactions creates a uni-directional stream from the server to
86
- # the client in which any newly discovered transactions relevant to the
87
- # wallet are sent over.
88
- rpc :SubscribeTransactions, GetTransactionsRequest, stream(Transaction)
89
- # * lncli: `sendmany`
90
- # SendMany handles a request for a transaction that creates multiple specified
91
- # outputs in parallel. If neither target_conf, or sat_per_byte are set, then
92
- # the internal wallet will consult its fee model to determine a fee for the
93
- # default confirmation target.
94
- rpc :SendMany, SendManyRequest, SendManyResponse
95
- # * lncli: `newaddress`
96
- # NewAddress creates a new address under control of the local wallet.
97
- rpc :NewAddress, NewAddressRequest, NewAddressResponse
98
- # * lncli: `signmessage`
99
- # SignMessage signs a message with this node's private key. The returned
100
- # signature string is `zbase32` encoded and pubkey recoverable, meaning that
101
- # only the message digest and signature are needed for verification.
102
- rpc :SignMessage, SignMessageRequest, SignMessageResponse
103
- # * lncli: `verifymessage`
104
- # VerifyMessage verifies a signature over a msg. The signature must be
105
- # zbase32 encoded and signed by an active node in the resident node's
106
- # channel database. In addition to returning the validity of the signature,
107
- # VerifyMessage also returns the recovered pubkey from the signature.
108
- rpc :VerifyMessage, VerifyMessageRequest, VerifyMessageResponse
109
- # * lncli: `connect`
110
- # ConnectPeer attempts to establish a connection to a remote peer. This is at
111
- # the networking level, and is used for communication between nodes. This is
112
- # distinct from establishing a channel with a peer.
113
- rpc :ConnectPeer, ConnectPeerRequest, ConnectPeerResponse
114
- # * lncli: `disconnect`
115
- # DisconnectPeer attempts to disconnect one peer from another identified by a
116
- # given pubKey. In the case that we currently have a pending or active channel
117
- # with the target peer, then this action will be not be allowed.
118
- rpc :DisconnectPeer, DisconnectPeerRequest, DisconnectPeerResponse
119
- # * lncli: `listpeers`
120
- # ListPeers returns a verbose listing of all currently active peers.
121
- rpc :ListPeers, ListPeersRequest, ListPeersResponse
122
- # * lncli: `getinfo`
123
- # GetInfo returns general information concerning the lightning node including
124
- # it's identity pubkey, alias, the chains it is connected to, and information
125
- # concerning the number of open+pending channels.
126
- rpc :GetInfo, GetInfoRequest, GetInfoResponse
127
- # TODO(roasbeef): merge with below with bool?
128
- #
129
- # * lncli: `pendingchannels`
130
- # PendingChannels returns a list of all the channels that are currently
131
- # considered "pending". A channel is pending if it has finished the funding
132
- # workflow and is waiting for confirmations for the funding txn, or is in the
133
- # process of closure, either initiated cooperatively or non-cooperatively.
134
- rpc :PendingChannels, PendingChannelsRequest, PendingChannelsResponse
135
- # * lncli: `listchannels`
136
- # ListChannels returns a description of all the open channels that this node
137
- # is a participant in.
138
- rpc :ListChannels, ListChannelsRequest, ListChannelsResponse
139
- # * lncli: `closedchannels`
140
- # ClosedChannels returns a description of all the closed channels that
141
- # this node was a participant in.
142
- rpc :ClosedChannels, ClosedChannelsRequest, ClosedChannelsResponse
143
- # *
144
- # OpenChannelSync is a synchronous version of the OpenChannel RPC call. This
145
- # call is meant to be consumed by clients to the REST proxy. As with all
146
- # other sync calls, all byte slices are intended to be populated as hex
147
- # encoded strings.
148
- rpc :OpenChannelSync, OpenChannelRequest, ChannelPoint
149
- # * lncli: `openchannel`
150
- # OpenChannel attempts to open a singly funded channel specified in the
151
- # request to a remote peer. Users are able to specify a target number of
152
- # blocks that the funding transaction should be confirmed in, or a manual fee
153
- # rate to us for the funding transaction. If neither are specified, then a
154
- # lax block confirmation target is used.
155
- rpc :OpenChannel, OpenChannelRequest, stream(OpenStatusUpdate)
156
- # * lncli: `closechannel`
157
- # CloseChannel attempts to close an active channel identified by its channel
158
- # outpoint (ChannelPoint). The actions of this method can additionally be
159
- # augmented to attempt a force close after a timeout period in the case of an
160
- # inactive peer. If a non-force close (cooperative closure) is requested,
161
- # then the user can specify either a target number of blocks until the
162
- # closure transaction is confirmed, or a manual fee rate. If neither are
163
- # specified, then a default lax, block confirmation target is used.
164
- rpc :CloseChannel, CloseChannelRequest, stream(CloseStatusUpdate)
165
- # * lncli: `abandonchannel`
166
- # AbandonChannel removes all channel state from the database except for a
167
- # close summary. This method can be used to get rid of permanently unusable
168
- # channels due to bugs fixed in newer versions of lnd. Only available
169
- # when in debug builds of lnd.
170
- rpc :AbandonChannel, AbandonChannelRequest, AbandonChannelResponse
171
- # * lncli: `sendpayment`
172
- # SendPayment dispatches a bi-directional streaming RPC for sending payments
173
- # through the Lightning Network. A single RPC invocation creates a persistent
174
- # bi-directional stream allowing clients to rapidly send payments through the
175
- # Lightning Network with a single persistent connection.
176
- rpc :SendPayment, stream(SendRequest), stream(SendResponse)
177
- # *
178
- # SendPaymentSync is the synchronous non-streaming version of SendPayment.
179
- # This RPC is intended to be consumed by clients of the REST proxy.
180
- # Additionally, this RPC expects the destination's public key and the payment
181
- # hash (if any) to be encoded as hex strings.
182
- rpc :SendPaymentSync, SendRequest, SendResponse
183
- # * lncli: `sendtoroute`
184
- # SendToRoute is a bi-directional streaming RPC for sending payment through
185
- # the Lightning Network. This method differs from SendPayment in that it
186
- # allows users to specify a full route manually. This can be used for things
187
- # like rebalancing, and atomic swaps.
188
- rpc :SendToRoute, stream(SendToRouteRequest), stream(SendResponse)
189
- # *
190
- # SendToRouteSync is a synchronous version of SendToRoute. It Will block
191
- # until the payment either fails or succeeds.
192
- rpc :SendToRouteSync, SendToRouteRequest, SendResponse
193
- # * lncli: `addinvoice`
194
- # AddInvoice attempts to add a new invoice to the invoice database. Any
195
- # duplicated invoices are rejected, therefore all invoices *must* have a
196
- # unique payment preimage.
197
- rpc :AddInvoice, Invoice, AddInvoiceResponse
198
- # * lncli: `listinvoices`
199
- # ListInvoices returns a list of all the invoices currently stored within the
200
- # database. Any active debug invoices are ignored. It has full support for
201
- # paginated responses, allowing users to query for specific invoices through
202
- # their add_index. This can be done by using either the first_index_offset or
203
- # last_index_offset fields included in the response as the index_offset of the
204
- # next request. The reversed flag is set by default in order to paginate
205
- # backwards. If you wish to paginate forwards, you must explicitly set the
206
- # flag to false. If none of the parameters are specified, then the last 100
207
- # invoices will be returned.
208
- rpc :ListInvoices, ListInvoiceRequest, ListInvoiceResponse
209
- # * lncli: `lookupinvoice`
210
- # LookupInvoice attempts to look up an invoice according to its payment hash.
211
- # The passed payment hash *must* be exactly 32 bytes, if not, an error is
212
- # returned.
213
- rpc :LookupInvoice, PaymentHash, Invoice
214
- # *
215
- # SubscribeInvoices returns a uni-directional stream (server -> client) for
216
- # notifying the client of newly added/settled invoices. The caller can
217
- # optionally specify the add_index and/or the settle_index. If the add_index
218
- # is specified, then we'll first start by sending add invoice events for all
219
- # invoices with an add_index greater than the specified value. If the
220
- # settle_index is specified, the next, we'll send out all settle events for
221
- # invoices with a settle_index greater than the specified value. One or both
222
- # of these fields can be set. If no fields are set, then we'll only send out
223
- # the latest add/settle events.
224
- rpc :SubscribeInvoices, InvoiceSubscription, stream(Invoice)
225
- # * lncli: `decodepayreq`
226
- # DecodePayReq takes an encoded payment request string and attempts to decode
227
- # it, returning a full description of the conditions encoded within the
228
- # payment request.
229
- rpc :DecodePayReq, PayReqString, PayReq
230
- # * lncli: `listpayments`
231
- # ListPayments returns a list of all outgoing payments.
232
- rpc :ListPayments, ListPaymentsRequest, ListPaymentsResponse
233
- # *
234
- # DeleteAllPayments deletes all outgoing payments from DB.
235
- rpc :DeleteAllPayments, DeleteAllPaymentsRequest, DeleteAllPaymentsResponse
236
- # * lncli: `describegraph`
237
- # DescribeGraph returns a description of the latest graph state from the
238
- # point of view of the node. The graph information is partitioned into two
239
- # components: all the nodes/vertexes, and all the edges that connect the
240
- # vertexes themselves. As this is a directed graph, the edges also contain
241
- # the node directional specific routing policy which includes: the time lock
242
- # delta, fee information, etc.
243
- rpc :DescribeGraph, ChannelGraphRequest, ChannelGraph
244
- # * lncli: `getchaninfo`
245
- # GetChanInfo returns the latest authenticated network announcement for the
246
- # given channel identified by its channel ID: an 8-byte integer which
247
- # uniquely identifies the location of transaction's funding output within the
248
- # blockchain.
249
- rpc :GetChanInfo, ChanInfoRequest, ChannelEdge
250
- # * lncli: `getnodeinfo`
251
- # GetNodeInfo returns the latest advertised, aggregated, and authenticated
252
- # channel information for the specified node identified by its public key.
253
- rpc :GetNodeInfo, NodeInfoRequest, NodeInfo
254
- # * lncli: `queryroutes`
255
- # QueryRoutes attempts to query the daemon's Channel Router for a possible
256
- # route to a target destination capable of carrying a specific amount of
257
- # satoshis. The retuned route contains the full details required to craft and
258
- # send an HTLC, also including the necessary information that should be
259
- # present within the Sphinx packet encapsulated within the HTLC.
260
- rpc :QueryRoutes, QueryRoutesRequest, QueryRoutesResponse
261
- # * lncli: `getnetworkinfo`
262
- # GetNetworkInfo returns some basic stats about the known channel graph from
263
- # the point of view of the node.
264
- rpc :GetNetworkInfo, NetworkInfoRequest, NetworkInfo
265
- # * lncli: `stop`
266
- # StopDaemon will send a shutdown request to the interrupt handler, triggering
267
- # a graceful shutdown of the daemon.
268
- rpc :StopDaemon, StopRequest, StopResponse
269
- # *
270
- # SubscribeChannelGraph launches a streaming RPC that allows the caller to
271
- # receive notifications upon any changes to the channel graph topology from
272
- # the point of view of the responding node. Events notified include: new
273
- # nodes coming online, nodes updating their authenticated attributes, new
274
- # channels being advertised, updates in the routing policy for a directional
275
- # channel edge, and when channels are closed on-chain.
276
- rpc :SubscribeChannelGraph, GraphTopologySubscription, stream(GraphTopologyUpdate)
277
- # * lncli: `debuglevel`
278
- # DebugLevel allows a caller to programmatically set the logging verbosity of
279
- # lnd. The logging can be targeted according to a coarse daemon-wide logging
280
- # level, or in a granular fashion to specify the logging for a target
281
- # sub-system.
282
- rpc :DebugLevel, DebugLevelRequest, DebugLevelResponse
283
- # * lncli: `feereport`
284
- # FeeReport allows the caller to obtain a report detailing the current fee
285
- # schedule enforced by the node globally for each channel.
286
- rpc :FeeReport, FeeReportRequest, FeeReportResponse
287
- # * lncli: `updatechanpolicy`
288
- # UpdateChannelPolicy allows the caller to update the fee schedule and
289
- # channel policies for all channels globally, or a particular channel.
290
- rpc :UpdateChannelPolicy, PolicyUpdateRequest, PolicyUpdateResponse
291
- # * lncli: `fwdinghistory`
292
- # ForwardingHistory allows the caller to query the htlcswitch for a record of
293
- # all HTLC's forwarded within the target time range, and integer offset
294
- # within that time range. If no time-range is specified, then the first chunk
295
- # of the past 24 hrs of forwarding history are returned.
296
- #
297
- # A list of forwarding events are returned. The size of each forwarding event
298
- # is 40 bytes, and the max message size able to be returned in gRPC is 4 MiB.
299
- # As a result each message can only contain 50k entries. Each response has
300
- # the index offset of the last entry. The index offset can be provided to the
301
- # request to allow the caller to skip a series of records.
302
- rpc :ForwardingHistory, ForwardingHistoryRequest, ForwardingHistoryResponse
303
- end
304
-
305
- Stub = Service.rpc_stub_class
306
- end
307
- end