lnrpc: add cursory REST support to the RPC server

This commit adds a REST interface to the existing gRPC server by
employing a simple http proxy auto-generated from the existing protobuf
files. Currently full-support for any streaming RPC’s are currently
untested. In addition to auto-generating a REST proxy server, a
swagger.json is also generated which allows for gRPC-like native
objects with higher-level clients, and also for auto-generated
documentation.

Due to limitations with accepting raw byte strings as parameters, some
RPC’s have been modified to take both raw-bytes and string arguments.
Additionally a new RPC has been added ‘NewWitnessAddress’ since the
proxy doesn’t currently support enum-based arguments.

Currently the proxy server is embedded within the daemon as an active
HTTP server, however we may want to package the proxy server as a
separate binary in the future. Similarly, we may want to add additional
configuration information which controls the optional inclusion of the
REST proxy.

Atm, just like the current gRPC interface, the REST API is fully
unauthenticated. Before moving to an initial alpha release after making
the necessary changes to meet the spec drafted in Milan, authentication
of the RPC interfaces will be addressed.
This commit is contained in:
Olaoluwa Osuntokun 2016-10-15 14:38:47 -07:00
parent bea555e61d
commit 566cd86a1d
No known key found for this signature in database
GPG Key ID: 9CC5B105D03521A2
8 changed files with 2667 additions and 293 deletions

34
glide.lock generated

@ -1,13 +1,14 @@
hash: 3047655dd4d303e49360573568bb046155e047519243c0ed8b1f8be2fcaf02de
updated: 2016-09-20T16:28:15.627923101-07:00
hash: db69bdd1de1bff79275a16649b87f5c5769a7ce6e889a9babf96dea470d931bf
updated: 2016-10-15T14:19:38.70874686-07:00
imports:
- name: github.com/awalterschulze/gographviz
version: 761fd5fbb34e4c2c138c280395b65b48e4ff5a53
version: d4d8514752339899250316f88a7907468e8eca7e
subpackages:
- ast
- parser
- scanner
- token
- errors
- lexer
- name: github.com/BitfuryLightning/tools
version: b36ae00916b800503504455f7afeb3159bd5ee35
subpackages:
@ -55,11 +56,20 @@ imports:
subpackages:
- spew
- name: github.com/golang/protobuf
version: 1f49d83d9aa00e6ce4fc8258c71cc7786aec968a
version: 98fa357170587e470c5f27d3c3ea0947b71eb455
subpackages:
- proto
- jsonpb
- protoc-gen-go/descriptor
- name: github.com/grpc-ecosystem/grpc-gateway
version: a8f25bd1ab549f8b87afd48aa9181221e9d439bb
subpackages:
- runtime
- third_party/googleapis/google/api
- utilities
- runtime/internal
- name: github.com/howeyc/gopass
version: 26c6e1184fd5255fa5f5289d0b789a4819c203a4
version: f5387c492211eb133053880d23dfae62aa14123d
- name: github.com/lightningnetwork/lightning-onion
version: 81647ffa2c5e17c0447d359e1963a54e18be85c4
- name: github.com/roasbeef/btcd
@ -84,7 +94,7 @@ imports:
- txsort
- base58
- name: github.com/roasbeef/btcwallet
version: 1fd2d6224698e14591d06f2a10b24e86494cc19f
version: 7acd18a96697b180b631631108f1a15448de369f
subpackages:
- chain
- waddrmgr
@ -104,7 +114,7 @@ imports:
- name: github.com/urfave/cli
version: a14d7d367bc02b1f57d88de97926727f2d936387
- name: golang.org/x/crypto
version: 6ab629be5e31660579425a738ba8870beb5b7404
version: 5f31782cfb2b6373211f8f9fbf31283fa234b570
subpackages:
- hkdf
- nacl/secretbox
@ -115,7 +125,7 @@ imports:
- pbkdf2
- ssh/terminal
- name: golang.org/x/net
version: f4fe4abe3c785295ddf81c7f1823bcd3bad391b6
version: 8b4af36cd21a1f85a7484b49feb7c79363106d8e
subpackages:
- context
- http2
@ -125,17 +135,17 @@ imports:
- lex/httplex
- internal/timeseries
- name: golang.org/x/sys
version: 8f0908ab3b2457e2e15403d3697c9ef5cb4b57a9
version: 9bb9f0998d48b31547d975974935ae9b48c7a03c
subpackages:
- unix
- name: google.golang.org/grpc
version: 0032a855ba5c8a3c8e0d71c2deef354b70af1584
version: b1a2821ca5a4fd6b6e48ddfbb7d6d7584d839d21
subpackages:
- grpclog
- codes
- metadata
- credentials
- internal
- metadata
- naming
- transport
- peer

@ -57,3 +57,5 @@ import:
- package: google.golang.org/grpc
version: ^1.0.0
- package: github.com/lightningnetwork/lightning-onion
- package: github.com/grpc-ecosystem/grpc-gateway
version: ^1.1.0

28
lnd.go

@ -1,6 +1,7 @@
package main
import (
"context"
"encoding/hex"
"fmt"
"io/ioutil"
@ -14,11 +15,13 @@ import (
"google.golang.org/grpc"
proxy "github.com/grpc-ecosystem/grpc-gateway/runtime"
"github.com/lightningnetwork/lnd/chainntnfs/btcdnotify"
"github.com/lightningnetwork/lnd/channeldb"
"github.com/lightningnetwork/lnd/lnrpc"
"github.com/lightningnetwork/lnd/lnwallet"
"github.com/lightningnetwork/lnd/lnwallet/btcwallet"
"github.com/roasbeef/btcrpcclient"
)
@ -175,8 +178,9 @@ func lndMain() error {
grpcServer := grpc.NewServer(opts...)
lnrpc.RegisterLightningServer(grpcServer, server.rpcServer)
// Finally, start the grpc server listening for HTTP/2 connections.
lis, err := net.Listen("tcp", fmt.Sprintf("localhost:%d", loadedConfig.RPCPort))
// Next, Start the grpc server listening for HTTP/2 connections.
grpcEndpoint := fmt.Sprintf("localhost:%d", loadedConfig.RPCPort)
lis, err := net.Listen("tcp", grpcEndpoint)
if err != nil {
fmt.Printf("failed to listen: %v", err)
return err
@ -186,6 +190,26 @@ func lndMain() error {
grpcServer.Serve(lis)
}()
// Finally, start the REST proxy for our gRPC server above.
ctx := context.Background()
ctx, cancel := context.WithCancel(ctx)
defer cancel()
mux := proxy.NewServeMux()
swaggerPattern := proxy.MustPattern(proxy.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "swagger"}, ""))
// TODO(roasbeef): accept path to swagger file as command-line option
mux.Handle("GET", swaggerPattern, func(w http.ResponseWriter, r *http.Request, p map[string]string) {
http.ServeFile(w, r, "lnrpc/rpc.swagger.json")
})
proxyOpts := []grpc.DialOption{grpc.WithInsecure()}
err = lnrpc.RegisterLightningHandlerFromEndpoint(ctx, mux, grpcEndpoint, proxyOpts)
if err != nil {
return err
}
go func() {
rpcsLog.Infof("gRPC proxy started")
http.ListenAndServe(":8080", mux)
}()
// Wait for shutdown signal from either a graceful server stop or from
// the interrupt handler.
<-shutdownChannel

@ -1,3 +1,24 @@
#!/bin/sh
protoc -I . rpc.proto --go_out=plugins=grpc:.
# Generate the protos.
protoc -I/usr/local/include -I. \
-I$GOPATH/src \
-I$GOPATH/src/github.com/grpc-ecosystem/grpc-gateway/third_party/googleapis \
--go_out=Mgoogle/api/annotations.proto=github.com/grpc-ecosystem/grpc-gateway/third_party/googleapis/google/api,plugins=grpc:. \
rpc.proto
# Generate the REST reverse prozxy.
protoc -I/usr/local/include -I. \
-I$GOPATH/src \
-I$GOPATH/src/github.com/grpc-ecosystem/grpc-gateway/third_party/googleapis \
--grpc-gateway_out=logtostderr=true:. \
rpc.proto
# Finally, generate the swagger file which describes the REST API in detail.
protoc -I/usr/local/include -I. \
-I$GOPATH/src \
-I$GOPATH/src/github.com/grpc-ecosystem/grpc-gateway/third_party/googleapis \
--swagger_out=logtostderr=true:. \
rpc.proto

@ -9,6 +9,9 @@ It is generated from these files:
rpc.proto
It has these top-level messages:
Transaction
GetTransactionsRequest
TransactionDetails
SendRequest
SendResponse
ChannelPoint
@ -18,6 +21,7 @@ It has these top-level messages:
SendCoinsRequest
SendCoinsResponse
NewAddressRequest
NewWitnessAddressRequest
NewAddressResponse
ConnectPeerRequest
ConnectPeerResponse
@ -52,12 +56,14 @@ It has these top-level messages:
PaymentHash
ListInvoiceRequest
ListInvoiceResponse
InvoiceSubscription
*/
package lnrpc
import proto "github.com/golang/protobuf/proto"
import fmt "fmt"
import math "math"
import _ "github.com/grpc-ecosystem/grpc-gateway/third_party/googleapis/google/api"
import (
context "golang.org/x/net/context"
@ -122,7 +128,46 @@ func (x NewAddressRequest_AddressType) String() string {
return proto.EnumName(NewAddressRequest_AddressType_name, int32(x))
}
func (NewAddressRequest_AddressType) EnumDescriptor() ([]byte, []int) {
return fileDescriptor0, []int{8, 0}
return fileDescriptor0, []int{11, 0}
}
type Transaction struct {
TxHash string `protobuf:"bytes,1,opt,name=tx_hash" json:"tx_hash,omitempty"`
Amount float64 `protobuf:"fixed64,2,opt,name=amount" json:"amount,omitempty"`
NumConfirmations int32 `protobuf:"varint,3,opt,name=num_confirmations" json:"num_confirmations,omitempty"`
BlockHash string `protobuf:"bytes,4,opt,name=block_hash" json:"block_hash,omitempty"`
BlockHeight int32 `protobuf:"varint,5,opt,name=block_height" json:"block_height,omitempty"`
TimeStamp int64 `protobuf:"varint,6,opt,name=time_stamp" json:"time_stamp,omitempty"`
TotalFees int64 `protobuf:"varint,7,opt,name=total_fees" json:"total_fees,omitempty"`
}
func (m *Transaction) Reset() { *m = Transaction{} }
func (m *Transaction) String() string { return proto.CompactTextString(m) }
func (*Transaction) ProtoMessage() {}
func (*Transaction) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{0} }
type GetTransactionsRequest struct {
}
func (m *GetTransactionsRequest) Reset() { *m = GetTransactionsRequest{} }
func (m *GetTransactionsRequest) String() string { return proto.CompactTextString(m) }
func (*GetTransactionsRequest) ProtoMessage() {}
func (*GetTransactionsRequest) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{1} }
type TransactionDetails struct {
Transactions []*Transaction `protobuf:"bytes,1,rep,name=transactions" json:"transactions,omitempty"`
}
func (m *TransactionDetails) Reset() { *m = TransactionDetails{} }
func (m *TransactionDetails) String() string { return proto.CompactTextString(m) }
func (*TransactionDetails) ProtoMessage() {}
func (*TransactionDetails) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{2} }
func (m *TransactionDetails) GetTransactions() []*Transaction {
if m != nil {
return m.Transactions
}
return nil
}
type SendRequest struct {
@ -135,7 +180,7 @@ type SendRequest struct {
func (m *SendRequest) Reset() { *m = SendRequest{} }
func (m *SendRequest) String() string { return proto.CompactTextString(m) }
func (*SendRequest) ProtoMessage() {}
func (*SendRequest) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{0} }
func (*SendRequest) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{3} }
type SendResponse struct {
}
@ -143,17 +188,18 @@ type SendResponse struct {
func (m *SendResponse) Reset() { *m = SendResponse{} }
func (m *SendResponse) String() string { return proto.CompactTextString(m) }
func (*SendResponse) ProtoMessage() {}
func (*SendResponse) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{1} }
func (*SendResponse) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{4} }
type ChannelPoint struct {
FundingTxid []byte `protobuf:"bytes,1,opt,name=funding_txid,proto3" json:"funding_txid,omitempty"`
OutputIndex uint32 `protobuf:"varint,2,opt,name=output_index" json:"output_index,omitempty"`
FundingTxid []byte `protobuf:"bytes,1,opt,name=funding_txid,proto3" json:"funding_txid,omitempty"`
FundingTxidStr string `protobuf:"bytes,2,opt,name=funding_txid_str" json:"funding_txid_str,omitempty"`
OutputIndex uint32 `protobuf:"varint,3,opt,name=output_index" json:"output_index,omitempty"`
}
func (m *ChannelPoint) Reset() { *m = ChannelPoint{} }
func (m *ChannelPoint) String() string { return proto.CompactTextString(m) }
func (*ChannelPoint) ProtoMessage() {}
func (*ChannelPoint) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{2} }
func (*ChannelPoint) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{5} }
type LightningAddress struct {
PubKeyHash string `protobuf:"bytes,1,opt,name=pubKeyHash" json:"pubKeyHash,omitempty"`
@ -163,7 +209,7 @@ type LightningAddress struct {
func (m *LightningAddress) Reset() { *m = LightningAddress{} }
func (m *LightningAddress) String() string { return proto.CompactTextString(m) }
func (*LightningAddress) ProtoMessage() {}
func (*LightningAddress) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{3} }
func (*LightningAddress) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{6} }
type SendManyRequest struct {
AddrToAmount map[string]int64 `protobuf:"bytes,1,rep,name=AddrToAmount" json:"AddrToAmount,omitempty" protobuf_key:"bytes,1,opt,name=key" protobuf_val:"varint,2,opt,name=value"`
@ -172,7 +218,7 @@ type SendManyRequest struct {
func (m *SendManyRequest) Reset() { *m = SendManyRequest{} }
func (m *SendManyRequest) String() string { return proto.CompactTextString(m) }
func (*SendManyRequest) ProtoMessage() {}
func (*SendManyRequest) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{4} }
func (*SendManyRequest) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{7} }
func (m *SendManyRequest) GetAddrToAmount() map[string]int64 {
if m != nil {
@ -188,7 +234,7 @@ type SendManyResponse struct {
func (m *SendManyResponse) Reset() { *m = SendManyResponse{} }
func (m *SendManyResponse) String() string { return proto.CompactTextString(m) }
func (*SendManyResponse) ProtoMessage() {}
func (*SendManyResponse) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{5} }
func (*SendManyResponse) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{8} }
type SendCoinsRequest struct {
Addr string `protobuf:"bytes,1,opt,name=addr" json:"addr,omitempty"`
@ -198,7 +244,7 @@ type SendCoinsRequest struct {
func (m *SendCoinsRequest) Reset() { *m = SendCoinsRequest{} }
func (m *SendCoinsRequest) String() string { return proto.CompactTextString(m) }
func (*SendCoinsRequest) ProtoMessage() {}
func (*SendCoinsRequest) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{6} }
func (*SendCoinsRequest) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{9} }
type SendCoinsResponse struct {
Txid string `protobuf:"bytes,1,opt,name=txid" json:"txid,omitempty"`
@ -207,7 +253,7 @@ type SendCoinsResponse struct {
func (m *SendCoinsResponse) Reset() { *m = SendCoinsResponse{} }
func (m *SendCoinsResponse) String() string { return proto.CompactTextString(m) }
func (*SendCoinsResponse) ProtoMessage() {}
func (*SendCoinsResponse) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{7} }
func (*SendCoinsResponse) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{10} }
type NewAddressRequest struct {
Type NewAddressRequest_AddressType `protobuf:"varint,1,opt,name=type,enum=lnrpc.NewAddressRequest_AddressType" json:"type,omitempty"`
@ -216,7 +262,15 @@ type NewAddressRequest struct {
func (m *NewAddressRequest) Reset() { *m = NewAddressRequest{} }
func (m *NewAddressRequest) String() string { return proto.CompactTextString(m) }
func (*NewAddressRequest) ProtoMessage() {}
func (*NewAddressRequest) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{8} }
func (*NewAddressRequest) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{11} }
type NewWitnessAddressRequest struct {
}
func (m *NewWitnessAddressRequest) Reset() { *m = NewWitnessAddressRequest{} }
func (m *NewWitnessAddressRequest) String() string { return proto.CompactTextString(m) }
func (*NewWitnessAddressRequest) ProtoMessage() {}
func (*NewWitnessAddressRequest) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{12} }
type NewAddressResponse struct {
Address string `protobuf:"bytes,1,opt,name=address" json:"address,omitempty"`
@ -225,7 +279,7 @@ type NewAddressResponse struct {
func (m *NewAddressResponse) Reset() { *m = NewAddressResponse{} }
func (m *NewAddressResponse) String() string { return proto.CompactTextString(m) }
func (*NewAddressResponse) ProtoMessage() {}
func (*NewAddressResponse) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{9} }
func (*NewAddressResponse) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{13} }
type ConnectPeerRequest struct {
Addr *LightningAddress `protobuf:"bytes,1,opt,name=addr" json:"addr,omitempty"`
@ -234,7 +288,7 @@ type ConnectPeerRequest struct {
func (m *ConnectPeerRequest) Reset() { *m = ConnectPeerRequest{} }
func (m *ConnectPeerRequest) String() string { return proto.CompactTextString(m) }
func (*ConnectPeerRequest) ProtoMessage() {}
func (*ConnectPeerRequest) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{10} }
func (*ConnectPeerRequest) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{14} }
func (m *ConnectPeerRequest) GetAddr() *LightningAddress {
if m != nil {
@ -250,7 +304,7 @@ type ConnectPeerResponse struct {
func (m *ConnectPeerResponse) Reset() { *m = ConnectPeerResponse{} }
func (m *ConnectPeerResponse) String() string { return proto.CompactTextString(m) }
func (*ConnectPeerResponse) ProtoMessage() {}
func (*ConnectPeerResponse) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{11} }
func (*ConnectPeerResponse) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{15} }
type HTLC struct {
Incoming bool `protobuf:"varint,1,opt,name=incoming" json:"incoming,omitempty"`
@ -263,7 +317,7 @@ type HTLC struct {
func (m *HTLC) Reset() { *m = HTLC{} }
func (m *HTLC) String() string { return proto.CompactTextString(m) }
func (*HTLC) ProtoMessage() {}
func (*HTLC) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{12} }
func (*HTLC) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{16} }
type ActiveChannel struct {
RemotePubkey string `protobuf:"bytes,1,opt,name=remote_pubkey" json:"remote_pubkey,omitempty"`
@ -279,7 +333,7 @@ type ActiveChannel struct {
func (m *ActiveChannel) Reset() { *m = ActiveChannel{} }
func (m *ActiveChannel) String() string { return proto.CompactTextString(m) }
func (*ActiveChannel) ProtoMessage() {}
func (*ActiveChannel) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{13} }
func (*ActiveChannel) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{17} }
func (m *ActiveChannel) GetPendingHtlcs() []*HTLC {
if m != nil {
@ -294,7 +348,7 @@ type ListChannelsRequest struct {
func (m *ListChannelsRequest) Reset() { *m = ListChannelsRequest{} }
func (m *ListChannelsRequest) String() string { return proto.CompactTextString(m) }
func (*ListChannelsRequest) ProtoMessage() {}
func (*ListChannelsRequest) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{14} }
func (*ListChannelsRequest) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{18} }
type ListChannelsResponse struct {
Channels []*ActiveChannel `protobuf:"bytes,9,rep,name=channels" json:"channels,omitempty"`
@ -303,7 +357,7 @@ type ListChannelsResponse struct {
func (m *ListChannelsResponse) Reset() { *m = ListChannelsResponse{} }
func (m *ListChannelsResponse) String() string { return proto.CompactTextString(m) }
func (*ListChannelsResponse) ProtoMessage() {}
func (*ListChannelsResponse) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{15} }
func (*ListChannelsResponse) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{19} }
func (m *ListChannelsResponse) GetChannels() []*ActiveChannel {
if m != nil {
@ -326,7 +380,7 @@ type Peer struct {
func (m *Peer) Reset() { *m = Peer{} }
func (m *Peer) String() string { return proto.CompactTextString(m) }
func (*Peer) ProtoMessage() {}
func (*Peer) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{16} }
func (*Peer) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{20} }
type ListPeersRequest struct {
}
@ -334,7 +388,7 @@ type ListPeersRequest struct {
func (m *ListPeersRequest) Reset() { *m = ListPeersRequest{} }
func (m *ListPeersRequest) String() string { return proto.CompactTextString(m) }
func (*ListPeersRequest) ProtoMessage() {}
func (*ListPeersRequest) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{17} }
func (*ListPeersRequest) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{21} }
type ListPeersResponse struct {
Peers []*Peer `protobuf:"bytes,1,rep,name=peers" json:"peers,omitempty"`
@ -343,7 +397,7 @@ type ListPeersResponse struct {
func (m *ListPeersResponse) Reset() { *m = ListPeersResponse{} }
func (m *ListPeersResponse) String() string { return proto.CompactTextString(m) }
func (*ListPeersResponse) ProtoMessage() {}
func (*ListPeersResponse) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{18} }
func (*ListPeersResponse) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{22} }
func (m *ListPeersResponse) GetPeers() []*Peer {
if m != nil {
@ -358,7 +412,7 @@ type GetInfoRequest struct {
func (m *GetInfoRequest) Reset() { *m = GetInfoRequest{} }
func (m *GetInfoRequest) String() string { return proto.CompactTextString(m) }
func (*GetInfoRequest) ProtoMessage() {}
func (*GetInfoRequest) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{19} }
func (*GetInfoRequest) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{23} }
type GetInfoResponse struct {
LightningId string `protobuf:"bytes,1,opt,name=lightning_id" json:"lightning_id,omitempty"`
@ -372,7 +426,7 @@ type GetInfoResponse struct {
func (m *GetInfoResponse) Reset() { *m = GetInfoResponse{} }
func (m *GetInfoResponse) String() string { return proto.CompactTextString(m) }
func (*GetInfoResponse) ProtoMessage() {}
func (*GetInfoResponse) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{20} }
func (*GetInfoResponse) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{24} }
type ConfirmationUpdate struct {
BlockSha []byte `protobuf:"bytes,1,opt,name=block_sha,proto3" json:"block_sha,omitempty"`
@ -383,7 +437,7 @@ type ConfirmationUpdate struct {
func (m *ConfirmationUpdate) Reset() { *m = ConfirmationUpdate{} }
func (m *ConfirmationUpdate) String() string { return proto.CompactTextString(m) }
func (*ConfirmationUpdate) ProtoMessage() {}
func (*ConfirmationUpdate) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{21} }
func (*ConfirmationUpdate) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{25} }
type ChannelOpenUpdate struct {
ChannelPoint *ChannelPoint `protobuf:"bytes,1,opt,name=channel_point" json:"channel_point,omitempty"`
@ -392,7 +446,7 @@ type ChannelOpenUpdate struct {
func (m *ChannelOpenUpdate) Reset() { *m = ChannelOpenUpdate{} }
func (m *ChannelOpenUpdate) String() string { return proto.CompactTextString(m) }
func (*ChannelOpenUpdate) ProtoMessage() {}
func (*ChannelOpenUpdate) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{22} }
func (*ChannelOpenUpdate) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{26} }
func (m *ChannelOpenUpdate) GetChannelPoint() *ChannelPoint {
if m != nil {
@ -409,7 +463,7 @@ type ChannelCloseUpdate struct {
func (m *ChannelCloseUpdate) Reset() { *m = ChannelCloseUpdate{} }
func (m *ChannelCloseUpdate) String() string { return proto.CompactTextString(m) }
func (*ChannelCloseUpdate) ProtoMessage() {}
func (*ChannelCloseUpdate) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{23} }
func (*ChannelCloseUpdate) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{27} }
type CloseChannelRequest struct {
ChannelPoint *ChannelPoint `protobuf:"bytes,1,opt,name=channel_point" json:"channel_point,omitempty"`
@ -420,7 +474,7 @@ type CloseChannelRequest struct {
func (m *CloseChannelRequest) Reset() { *m = CloseChannelRequest{} }
func (m *CloseChannelRequest) String() string { return proto.CompactTextString(m) }
func (*CloseChannelRequest) ProtoMessage() {}
func (*CloseChannelRequest) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{24} }
func (*CloseChannelRequest) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{28} }
func (m *CloseChannelRequest) GetChannelPoint() *ChannelPoint {
if m != nil {
@ -440,7 +494,7 @@ type CloseStatusUpdate struct {
func (m *CloseStatusUpdate) Reset() { *m = CloseStatusUpdate{} }
func (m *CloseStatusUpdate) String() string { return proto.CompactTextString(m) }
func (*CloseStatusUpdate) ProtoMessage() {}
func (*CloseStatusUpdate) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{25} }
func (*CloseStatusUpdate) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{29} }
type isCloseStatusUpdate_Update interface {
isCloseStatusUpdate_Update()
@ -588,7 +642,7 @@ type PendingUpdate struct {
func (m *PendingUpdate) Reset() { *m = PendingUpdate{} }
func (m *PendingUpdate) String() string { return proto.CompactTextString(m) }
func (*PendingUpdate) ProtoMessage() {}
func (*PendingUpdate) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{26} }
func (*PendingUpdate) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{30} }
type OpenChannelRequest struct {
TargetPeerId int32 `protobuf:"varint,1,opt,name=target_peer_id" json:"target_peer_id,omitempty"`
@ -602,7 +656,7 @@ type OpenChannelRequest struct {
func (m *OpenChannelRequest) Reset() { *m = OpenChannelRequest{} }
func (m *OpenChannelRequest) String() string { return proto.CompactTextString(m) }
func (*OpenChannelRequest) ProtoMessage() {}
func (*OpenChannelRequest) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{27} }
func (*OpenChannelRequest) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{31} }
type OpenStatusUpdate struct {
// Types that are valid to be assigned to Update:
@ -615,7 +669,7 @@ type OpenStatusUpdate struct {
func (m *OpenStatusUpdate) Reset() { *m = OpenStatusUpdate{} }
func (m *OpenStatusUpdate) String() string { return proto.CompactTextString(m) }
func (*OpenStatusUpdate) ProtoMessage() {}
func (*OpenStatusUpdate) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{28} }
func (*OpenStatusUpdate) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{32} }
type isOpenStatusUpdate_Update interface {
isOpenStatusUpdate_Update()
@ -763,7 +817,7 @@ type PendingChannelRequest struct {
func (m *PendingChannelRequest) Reset() { *m = PendingChannelRequest{} }
func (m *PendingChannelRequest) String() string { return proto.CompactTextString(m) }
func (*PendingChannelRequest) ProtoMessage() {}
func (*PendingChannelRequest) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{29} }
func (*PendingChannelRequest) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{33} }
type PendingChannelResponse struct {
PendingChannels []*PendingChannelResponse_PendingChannel `protobuf:"bytes,1,rep,name=pending_channels" json:"pending_channels,omitempty"`
@ -772,7 +826,7 @@ type PendingChannelResponse struct {
func (m *PendingChannelResponse) Reset() { *m = PendingChannelResponse{} }
func (m *PendingChannelResponse) String() string { return proto.CompactTextString(m) }
func (*PendingChannelResponse) ProtoMessage() {}
func (*PendingChannelResponse) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{30} }
func (*PendingChannelResponse) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{34} }
func (m *PendingChannelResponse) GetPendingChannels() []*PendingChannelResponse_PendingChannel {
if m != nil {
@ -796,7 +850,7 @@ func (m *PendingChannelResponse_PendingChannel) Reset() { *m = PendingCh
func (m *PendingChannelResponse_PendingChannel) String() string { return proto.CompactTextString(m) }
func (*PendingChannelResponse_PendingChannel) ProtoMessage() {}
func (*PendingChannelResponse_PendingChannel) Descriptor() ([]byte, []int) {
return fileDescriptor0, []int{30, 0}
return fileDescriptor0, []int{34, 0}
}
type WalletBalanceRequest struct {
@ -806,7 +860,7 @@ type WalletBalanceRequest struct {
func (m *WalletBalanceRequest) Reset() { *m = WalletBalanceRequest{} }
func (m *WalletBalanceRequest) String() string { return proto.CompactTextString(m) }
func (*WalletBalanceRequest) ProtoMessage() {}
func (*WalletBalanceRequest) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{31} }
func (*WalletBalanceRequest) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{35} }
type WalletBalanceResponse struct {
Balance float64 `protobuf:"fixed64,1,opt,name=balance" json:"balance,omitempty"`
@ -815,7 +869,7 @@ type WalletBalanceResponse struct {
func (m *WalletBalanceResponse) Reset() { *m = WalletBalanceResponse{} }
func (m *WalletBalanceResponse) String() string { return proto.CompactTextString(m) }
func (*WalletBalanceResponse) ProtoMessage() {}
func (*WalletBalanceResponse) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{32} }
func (*WalletBalanceResponse) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{36} }
type ChannelBalanceRequest struct {
}
@ -823,7 +877,7 @@ type ChannelBalanceRequest struct {
func (m *ChannelBalanceRequest) Reset() { *m = ChannelBalanceRequest{} }
func (m *ChannelBalanceRequest) String() string { return proto.CompactTextString(m) }
func (*ChannelBalanceRequest) ProtoMessage() {}
func (*ChannelBalanceRequest) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{33} }
func (*ChannelBalanceRequest) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{37} }
type ChannelBalanceResponse struct {
Balance int64 `protobuf:"varint,1,opt,name=balance" json:"balance,omitempty"`
@ -832,7 +886,7 @@ type ChannelBalanceResponse struct {
func (m *ChannelBalanceResponse) Reset() { *m = ChannelBalanceResponse{} }
func (m *ChannelBalanceResponse) String() string { return proto.CompactTextString(m) }
func (*ChannelBalanceResponse) ProtoMessage() {}
func (*ChannelBalanceResponse) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{34} }
func (*ChannelBalanceResponse) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{38} }
type RoutingTableLink struct {
Id1 string `protobuf:"bytes,1,opt,name=id1" json:"id1,omitempty"`
@ -845,7 +899,7 @@ type RoutingTableLink struct {
func (m *RoutingTableLink) Reset() { *m = RoutingTableLink{} }
func (m *RoutingTableLink) String() string { return proto.CompactTextString(m) }
func (*RoutingTableLink) ProtoMessage() {}
func (*RoutingTableLink) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{35} }
func (*RoutingTableLink) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{39} }
type ShowRoutingTableRequest struct {
}
@ -853,7 +907,7 @@ type ShowRoutingTableRequest struct {
func (m *ShowRoutingTableRequest) Reset() { *m = ShowRoutingTableRequest{} }
func (m *ShowRoutingTableRequest) String() string { return proto.CompactTextString(m) }
func (*ShowRoutingTableRequest) ProtoMessage() {}
func (*ShowRoutingTableRequest) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{36} }
func (*ShowRoutingTableRequest) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{40} }
type ShowRoutingTableResponse struct {
Channels []*RoutingTableLink `protobuf:"bytes,1,rep,name=channels" json:"channels,omitempty"`
@ -862,7 +916,7 @@ type ShowRoutingTableResponse struct {
func (m *ShowRoutingTableResponse) Reset() { *m = ShowRoutingTableResponse{} }
func (m *ShowRoutingTableResponse) String() string { return proto.CompactTextString(m) }
func (*ShowRoutingTableResponse) ProtoMessage() {}
func (*ShowRoutingTableResponse) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{37} }
func (*ShowRoutingTableResponse) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{41} }
func (m *ShowRoutingTableResponse) GetChannels() []*RoutingTableLink {
if m != nil {
@ -883,7 +937,7 @@ type Invoice struct {
func (m *Invoice) Reset() { *m = Invoice{} }
func (m *Invoice) String() string { return proto.CompactTextString(m) }
func (*Invoice) ProtoMessage() {}
func (*Invoice) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{38} }
func (*Invoice) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{42} }
type AddInvoiceResponse struct {
RHash []byte `protobuf:"bytes,1,opt,name=r_hash,proto3" json:"r_hash,omitempty"`
@ -892,16 +946,17 @@ type AddInvoiceResponse struct {
func (m *AddInvoiceResponse) Reset() { *m = AddInvoiceResponse{} }
func (m *AddInvoiceResponse) String() string { return proto.CompactTextString(m) }
func (*AddInvoiceResponse) ProtoMessage() {}
func (*AddInvoiceResponse) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{39} }
func (*AddInvoiceResponse) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{43} }
type PaymentHash struct {
RHash []byte `protobuf:"bytes,1,opt,name=r_hash,proto3" json:"r_hash,omitempty"`
RHashStr string `protobuf:"bytes,1,opt,name=r_hash_str" json:"r_hash_str,omitempty"`
RHash []byte `protobuf:"bytes,2,opt,name=r_hash,proto3" json:"r_hash,omitempty"`
}
func (m *PaymentHash) Reset() { *m = PaymentHash{} }
func (m *PaymentHash) String() string { return proto.CompactTextString(m) }
func (*PaymentHash) ProtoMessage() {}
func (*PaymentHash) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{40} }
func (*PaymentHash) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{44} }
type ListInvoiceRequest struct {
PendingOnly bool `protobuf:"varint,1,opt,name=pending_only" json:"pending_only,omitempty"`
@ -910,7 +965,7 @@ type ListInvoiceRequest struct {
func (m *ListInvoiceRequest) Reset() { *m = ListInvoiceRequest{} }
func (m *ListInvoiceRequest) String() string { return proto.CompactTextString(m) }
func (*ListInvoiceRequest) ProtoMessage() {}
func (*ListInvoiceRequest) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{41} }
func (*ListInvoiceRequest) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{45} }
type ListInvoiceResponse struct {
Invoices []*Invoice `protobuf:"bytes,1,rep,name=invoices" json:"invoices,omitempty"`
@ -919,7 +974,7 @@ type ListInvoiceResponse struct {
func (m *ListInvoiceResponse) Reset() { *m = ListInvoiceResponse{} }
func (m *ListInvoiceResponse) String() string { return proto.CompactTextString(m) }
func (*ListInvoiceResponse) ProtoMessage() {}
func (*ListInvoiceResponse) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{42} }
func (*ListInvoiceResponse) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{46} }
func (m *ListInvoiceResponse) GetInvoices() []*Invoice {
if m != nil {
@ -928,7 +983,18 @@ func (m *ListInvoiceResponse) GetInvoices() []*Invoice {
return nil
}
type InvoiceSubscription struct {
}
func (m *InvoiceSubscription) Reset() { *m = InvoiceSubscription{} }
func (m *InvoiceSubscription) String() string { return proto.CompactTextString(m) }
func (*InvoiceSubscription) ProtoMessage() {}
func (*InvoiceSubscription) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{47} }
func init() {
proto.RegisterType((*Transaction)(nil), "lnrpc.Transaction")
proto.RegisterType((*GetTransactionsRequest)(nil), "lnrpc.GetTransactionsRequest")
proto.RegisterType((*TransactionDetails)(nil), "lnrpc.TransactionDetails")
proto.RegisterType((*SendRequest)(nil), "lnrpc.SendRequest")
proto.RegisterType((*SendResponse)(nil), "lnrpc.SendResponse")
proto.RegisterType((*ChannelPoint)(nil), "lnrpc.ChannelPoint")
@ -938,6 +1004,7 @@ func init() {
proto.RegisterType((*SendCoinsRequest)(nil), "lnrpc.SendCoinsRequest")
proto.RegisterType((*SendCoinsResponse)(nil), "lnrpc.SendCoinsResponse")
proto.RegisterType((*NewAddressRequest)(nil), "lnrpc.NewAddressRequest")
proto.RegisterType((*NewWitnessAddressRequest)(nil), "lnrpc.NewWitnessAddressRequest")
proto.RegisterType((*NewAddressResponse)(nil), "lnrpc.NewAddressResponse")
proto.RegisterType((*ConnectPeerRequest)(nil), "lnrpc.ConnectPeerRequest")
proto.RegisterType((*ConnectPeerResponse)(nil), "lnrpc.ConnectPeerResponse")
@ -973,6 +1040,7 @@ func init() {
proto.RegisterType((*PaymentHash)(nil), "lnrpc.PaymentHash")
proto.RegisterType((*ListInvoiceRequest)(nil), "lnrpc.ListInvoiceRequest")
proto.RegisterType((*ListInvoiceResponse)(nil), "lnrpc.ListInvoiceResponse")
proto.RegisterType((*InvoiceSubscription)(nil), "lnrpc.InvoiceSubscription")
proto.RegisterEnum("lnrpc.ChannelStatus", ChannelStatus_name, ChannelStatus_value)
proto.RegisterEnum("lnrpc.NewAddressRequest_AddressType", NewAddressRequest_AddressType_name, NewAddressRequest_AddressType_value)
}
@ -990,20 +1058,25 @@ const _ = grpc.SupportPackageIsVersion3
type LightningClient interface {
WalletBalance(ctx context.Context, in *WalletBalanceRequest, opts ...grpc.CallOption) (*WalletBalanceResponse, error)
ChannelBalance(ctx context.Context, in *ChannelBalanceRequest, opts ...grpc.CallOption) (*ChannelBalanceResponse, error)
SendMany(ctx context.Context, in *SendManyRequest, opts ...grpc.CallOption) (*SendManyResponse, error)
GetTransactions(ctx context.Context, in *GetTransactionsRequest, opts ...grpc.CallOption) (*TransactionDetails, error)
SendCoins(ctx context.Context, in *SendCoinsRequest, opts ...grpc.CallOption) (*SendCoinsResponse, error)
SubscribeTransactions(ctx context.Context, in *GetTransactionsRequest, opts ...grpc.CallOption) (Lightning_SubscribeTransactionsClient, error)
SendMany(ctx context.Context, in *SendManyRequest, opts ...grpc.CallOption) (*SendManyResponse, error)
NewAddress(ctx context.Context, in *NewAddressRequest, opts ...grpc.CallOption) (*NewAddressResponse, error)
NewWitnessAddress(ctx context.Context, in *NewWitnessAddressRequest, opts ...grpc.CallOption) (*NewAddressResponse, error)
ConnectPeer(ctx context.Context, in *ConnectPeerRequest, opts ...grpc.CallOption) (*ConnectPeerResponse, error)
ListPeers(ctx context.Context, in *ListPeersRequest, opts ...grpc.CallOption) (*ListPeersResponse, error)
GetInfo(ctx context.Context, in *GetInfoRequest, opts ...grpc.CallOption) (*GetInfoResponse, error)
OpenChannel(ctx context.Context, in *OpenChannelRequest, opts ...grpc.CallOption) (Lightning_OpenChannelClient, error)
CloseChannel(ctx context.Context, in *CloseChannelRequest, opts ...grpc.CallOption) (Lightning_CloseChannelClient, error)
// TODO(roasbeef): merge with below with bool?
PendingChannels(ctx context.Context, in *PendingChannelRequest, opts ...grpc.CallOption) (*PendingChannelResponse, error)
ListChannels(ctx context.Context, in *ListChannelsRequest, opts ...grpc.CallOption) (*ListChannelsResponse, error)
OpenChannel(ctx context.Context, in *OpenChannelRequest, opts ...grpc.CallOption) (Lightning_OpenChannelClient, error)
CloseChannel(ctx context.Context, in *CloseChannelRequest, opts ...grpc.CallOption) (Lightning_CloseChannelClient, error)
SendPayment(ctx context.Context, opts ...grpc.CallOption) (Lightning_SendPaymentClient, error)
AddInvoice(ctx context.Context, in *Invoice, opts ...grpc.CallOption) (*AddInvoiceResponse, error)
LookupInvoice(ctx context.Context, in *PaymentHash, opts ...grpc.CallOption) (*Invoice, error)
ListInvoices(ctx context.Context, in *ListInvoiceRequest, opts ...grpc.CallOption) (*ListInvoiceResponse, error)
LookupInvoice(ctx context.Context, in *PaymentHash, opts ...grpc.CallOption) (*Invoice, error)
SubscribeInvoices(ctx context.Context, in *InvoiceSubscription, opts ...grpc.CallOption) (Lightning_SubscribeInvoicesClient, error)
ShowRoutingTable(ctx context.Context, in *ShowRoutingTableRequest, opts ...grpc.CallOption) (*ShowRoutingTableResponse, error)
}
@ -1033,9 +1106,9 @@ func (c *lightningClient) ChannelBalance(ctx context.Context, in *ChannelBalance
return out, nil
}
func (c *lightningClient) SendMany(ctx context.Context, in *SendManyRequest, opts ...grpc.CallOption) (*SendManyResponse, error) {
out := new(SendManyResponse)
err := grpc.Invoke(ctx, "/lnrpc.Lightning/SendMany", in, out, c.cc, opts...)
func (c *lightningClient) GetTransactions(ctx context.Context, in *GetTransactionsRequest, opts ...grpc.CallOption) (*TransactionDetails, error) {
out := new(TransactionDetails)
err := grpc.Invoke(ctx, "/lnrpc.Lightning/GetTransactions", in, out, c.cc, opts...)
if err != nil {
return nil, err
}
@ -1051,6 +1124,47 @@ func (c *lightningClient) SendCoins(ctx context.Context, in *SendCoinsRequest, o
return out, nil
}
func (c *lightningClient) SubscribeTransactions(ctx context.Context, in *GetTransactionsRequest, opts ...grpc.CallOption) (Lightning_SubscribeTransactionsClient, error) {
stream, err := grpc.NewClientStream(ctx, &_Lightning_serviceDesc.Streams[0], c.cc, "/lnrpc.Lightning/SubscribeTransactions", opts...)
if err != nil {
return nil, err
}
x := &lightningSubscribeTransactionsClient{stream}
if err := x.ClientStream.SendMsg(in); err != nil {
return nil, err
}
if err := x.ClientStream.CloseSend(); err != nil {
return nil, err
}
return x, nil
}
type Lightning_SubscribeTransactionsClient interface {
Recv() (*Transaction, error)
grpc.ClientStream
}
type lightningSubscribeTransactionsClient struct {
grpc.ClientStream
}
func (x *lightningSubscribeTransactionsClient) Recv() (*Transaction, error) {
m := new(Transaction)
if err := x.ClientStream.RecvMsg(m); err != nil {
return nil, err
}
return m, nil
}
func (c *lightningClient) SendMany(ctx context.Context, in *SendManyRequest, opts ...grpc.CallOption) (*SendManyResponse, error) {
out := new(SendManyResponse)
err := grpc.Invoke(ctx, "/lnrpc.Lightning/SendMany", in, out, c.cc, opts...)
if err != nil {
return nil, err
}
return out, nil
}
func (c *lightningClient) NewAddress(ctx context.Context, in *NewAddressRequest, opts ...grpc.CallOption) (*NewAddressResponse, error) {
out := new(NewAddressResponse)
err := grpc.Invoke(ctx, "/lnrpc.Lightning/NewAddress", in, out, c.cc, opts...)
@ -1060,6 +1174,15 @@ func (c *lightningClient) NewAddress(ctx context.Context, in *NewAddressRequest,
return out, nil
}
func (c *lightningClient) NewWitnessAddress(ctx context.Context, in *NewWitnessAddressRequest, opts ...grpc.CallOption) (*NewAddressResponse, error) {
out := new(NewAddressResponse)
err := grpc.Invoke(ctx, "/lnrpc.Lightning/NewWitnessAddress", in, out, c.cc, opts...)
if err != nil {
return nil, err
}
return out, nil
}
func (c *lightningClient) ConnectPeer(ctx context.Context, in *ConnectPeerRequest, opts ...grpc.CallOption) (*ConnectPeerResponse, error) {
out := new(ConnectPeerResponse)
err := grpc.Invoke(ctx, "/lnrpc.Lightning/ConnectPeer", in, out, c.cc, opts...)
@ -1087,8 +1210,26 @@ func (c *lightningClient) GetInfo(ctx context.Context, in *GetInfoRequest, opts
return out, nil
}
func (c *lightningClient) PendingChannels(ctx context.Context, in *PendingChannelRequest, opts ...grpc.CallOption) (*PendingChannelResponse, error) {
out := new(PendingChannelResponse)
err := grpc.Invoke(ctx, "/lnrpc.Lightning/PendingChannels", in, out, c.cc, opts...)
if err != nil {
return nil, err
}
return out, nil
}
func (c *lightningClient) ListChannels(ctx context.Context, in *ListChannelsRequest, opts ...grpc.CallOption) (*ListChannelsResponse, error) {
out := new(ListChannelsResponse)
err := grpc.Invoke(ctx, "/lnrpc.Lightning/ListChannels", in, out, c.cc, opts...)
if err != nil {
return nil, err
}
return out, nil
}
func (c *lightningClient) OpenChannel(ctx context.Context, in *OpenChannelRequest, opts ...grpc.CallOption) (Lightning_OpenChannelClient, error) {
stream, err := grpc.NewClientStream(ctx, &_Lightning_serviceDesc.Streams[0], c.cc, "/lnrpc.Lightning/OpenChannel", opts...)
stream, err := grpc.NewClientStream(ctx, &_Lightning_serviceDesc.Streams[1], c.cc, "/lnrpc.Lightning/OpenChannel", opts...)
if err != nil {
return nil, err
}
@ -1120,7 +1261,7 @@ func (x *lightningOpenChannelClient) Recv() (*OpenStatusUpdate, error) {
}
func (c *lightningClient) CloseChannel(ctx context.Context, in *CloseChannelRequest, opts ...grpc.CallOption) (Lightning_CloseChannelClient, error) {
stream, err := grpc.NewClientStream(ctx, &_Lightning_serviceDesc.Streams[1], c.cc, "/lnrpc.Lightning/CloseChannel", opts...)
stream, err := grpc.NewClientStream(ctx, &_Lightning_serviceDesc.Streams[2], c.cc, "/lnrpc.Lightning/CloseChannel", opts...)
if err != nil {
return nil, err
}
@ -1151,26 +1292,8 @@ func (x *lightningCloseChannelClient) Recv() (*CloseStatusUpdate, error) {
return m, nil
}
func (c *lightningClient) PendingChannels(ctx context.Context, in *PendingChannelRequest, opts ...grpc.CallOption) (*PendingChannelResponse, error) {
out := new(PendingChannelResponse)
err := grpc.Invoke(ctx, "/lnrpc.Lightning/PendingChannels", in, out, c.cc, opts...)
if err != nil {
return nil, err
}
return out, nil
}
func (c *lightningClient) ListChannels(ctx context.Context, in *ListChannelsRequest, opts ...grpc.CallOption) (*ListChannelsResponse, error) {
out := new(ListChannelsResponse)
err := grpc.Invoke(ctx, "/lnrpc.Lightning/ListChannels", in, out, c.cc, opts...)
if err != nil {
return nil, err
}
return out, nil
}
func (c *lightningClient) SendPayment(ctx context.Context, opts ...grpc.CallOption) (Lightning_SendPaymentClient, error) {
stream, err := grpc.NewClientStream(ctx, &_Lightning_serviceDesc.Streams[2], c.cc, "/lnrpc.Lightning/SendPayment", opts...)
stream, err := grpc.NewClientStream(ctx, &_Lightning_serviceDesc.Streams[3], c.cc, "/lnrpc.Lightning/SendPayment", opts...)
if err != nil {
return nil, err
}
@ -1209,6 +1332,15 @@ func (c *lightningClient) AddInvoice(ctx context.Context, in *Invoice, opts ...g
return out, nil
}
func (c *lightningClient) ListInvoices(ctx context.Context, in *ListInvoiceRequest, opts ...grpc.CallOption) (*ListInvoiceResponse, error) {
out := new(ListInvoiceResponse)
err := grpc.Invoke(ctx, "/lnrpc.Lightning/ListInvoices", in, out, c.cc, opts...)
if err != nil {
return nil, err
}
return out, nil
}
func (c *lightningClient) LookupInvoice(ctx context.Context, in *PaymentHash, opts ...grpc.CallOption) (*Invoice, error) {
out := new(Invoice)
err := grpc.Invoke(ctx, "/lnrpc.Lightning/LookupInvoice", in, out, c.cc, opts...)
@ -1218,13 +1350,36 @@ func (c *lightningClient) LookupInvoice(ctx context.Context, in *PaymentHash, op
return out, nil
}
func (c *lightningClient) ListInvoices(ctx context.Context, in *ListInvoiceRequest, opts ...grpc.CallOption) (*ListInvoiceResponse, error) {
out := new(ListInvoiceResponse)
err := grpc.Invoke(ctx, "/lnrpc.Lightning/ListInvoices", in, out, c.cc, opts...)
func (c *lightningClient) SubscribeInvoices(ctx context.Context, in *InvoiceSubscription, opts ...grpc.CallOption) (Lightning_SubscribeInvoicesClient, error) {
stream, err := grpc.NewClientStream(ctx, &_Lightning_serviceDesc.Streams[4], c.cc, "/lnrpc.Lightning/SubscribeInvoices", opts...)
if err != nil {
return nil, err
}
return out, nil
x := &lightningSubscribeInvoicesClient{stream}
if err := x.ClientStream.SendMsg(in); err != nil {
return nil, err
}
if err := x.ClientStream.CloseSend(); err != nil {
return nil, err
}
return x, nil
}
type Lightning_SubscribeInvoicesClient interface {
Recv() (*Invoice, error)
grpc.ClientStream
}
type lightningSubscribeInvoicesClient struct {
grpc.ClientStream
}
func (x *lightningSubscribeInvoicesClient) Recv() (*Invoice, error) {
m := new(Invoice)
if err := x.ClientStream.RecvMsg(m); err != nil {
return nil, err
}
return m, nil
}
func (c *lightningClient) ShowRoutingTable(ctx context.Context, in *ShowRoutingTableRequest, opts ...grpc.CallOption) (*ShowRoutingTableResponse, error) {
@ -1241,20 +1396,25 @@ func (c *lightningClient) ShowRoutingTable(ctx context.Context, in *ShowRoutingT
type LightningServer interface {
WalletBalance(context.Context, *WalletBalanceRequest) (*WalletBalanceResponse, error)
ChannelBalance(context.Context, *ChannelBalanceRequest) (*ChannelBalanceResponse, error)
SendMany(context.Context, *SendManyRequest) (*SendManyResponse, error)
GetTransactions(context.Context, *GetTransactionsRequest) (*TransactionDetails, error)
SendCoins(context.Context, *SendCoinsRequest) (*SendCoinsResponse, error)
SubscribeTransactions(*GetTransactionsRequest, Lightning_SubscribeTransactionsServer) error
SendMany(context.Context, *SendManyRequest) (*SendManyResponse, error)
NewAddress(context.Context, *NewAddressRequest) (*NewAddressResponse, error)
NewWitnessAddress(context.Context, *NewWitnessAddressRequest) (*NewAddressResponse, error)
ConnectPeer(context.Context, *ConnectPeerRequest) (*ConnectPeerResponse, error)
ListPeers(context.Context, *ListPeersRequest) (*ListPeersResponse, error)
GetInfo(context.Context, *GetInfoRequest) (*GetInfoResponse, error)
OpenChannel(*OpenChannelRequest, Lightning_OpenChannelServer) error
CloseChannel(*CloseChannelRequest, Lightning_CloseChannelServer) error
// TODO(roasbeef): merge with below with bool?
PendingChannels(context.Context, *PendingChannelRequest) (*PendingChannelResponse, error)
ListChannels(context.Context, *ListChannelsRequest) (*ListChannelsResponse, error)
OpenChannel(*OpenChannelRequest, Lightning_OpenChannelServer) error
CloseChannel(*CloseChannelRequest, Lightning_CloseChannelServer) error
SendPayment(Lightning_SendPaymentServer) error
AddInvoice(context.Context, *Invoice) (*AddInvoiceResponse, error)
LookupInvoice(context.Context, *PaymentHash) (*Invoice, error)
ListInvoices(context.Context, *ListInvoiceRequest) (*ListInvoiceResponse, error)
LookupInvoice(context.Context, *PaymentHash) (*Invoice, error)
SubscribeInvoices(*InvoiceSubscription, Lightning_SubscribeInvoicesServer) error
ShowRoutingTable(context.Context, *ShowRoutingTableRequest) (*ShowRoutingTableResponse, error)
}
@ -1298,20 +1458,20 @@ func _Lightning_ChannelBalance_Handler(srv interface{}, ctx context.Context, dec
return interceptor(ctx, in, info, handler)
}
func _Lightning_SendMany_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
in := new(SendManyRequest)
func _Lightning_GetTransactions_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
in := new(GetTransactionsRequest)
if err := dec(in); err != nil {
return nil, err
}
if interceptor == nil {
return srv.(LightningServer).SendMany(ctx, in)
return srv.(LightningServer).GetTransactions(ctx, in)
}
info := &grpc.UnaryServerInfo{
Server: srv,
FullMethod: "/lnrpc.Lightning/SendMany",
FullMethod: "/lnrpc.Lightning/GetTransactions",
}
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
return srv.(LightningServer).SendMany(ctx, req.(*SendManyRequest))
return srv.(LightningServer).GetTransactions(ctx, req.(*GetTransactionsRequest))
}
return interceptor(ctx, in, info, handler)
}
@ -1334,6 +1494,45 @@ func _Lightning_SendCoins_Handler(srv interface{}, ctx context.Context, dec func
return interceptor(ctx, in, info, handler)
}
func _Lightning_SubscribeTransactions_Handler(srv interface{}, stream grpc.ServerStream) error {
m := new(GetTransactionsRequest)
if err := stream.RecvMsg(m); err != nil {
return err
}
return srv.(LightningServer).SubscribeTransactions(m, &lightningSubscribeTransactionsServer{stream})
}
type Lightning_SubscribeTransactionsServer interface {
Send(*Transaction) error
grpc.ServerStream
}
type lightningSubscribeTransactionsServer struct {
grpc.ServerStream
}
func (x *lightningSubscribeTransactionsServer) Send(m *Transaction) error {
return x.ServerStream.SendMsg(m)
}
func _Lightning_SendMany_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
in := new(SendManyRequest)
if err := dec(in); err != nil {
return nil, err
}
if interceptor == nil {
return srv.(LightningServer).SendMany(ctx, in)
}
info := &grpc.UnaryServerInfo{
Server: srv,
FullMethod: "/lnrpc.Lightning/SendMany",
}
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
return srv.(LightningServer).SendMany(ctx, req.(*SendManyRequest))
}
return interceptor(ctx, in, info, handler)
}
func _Lightning_NewAddress_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
in := new(NewAddressRequest)
if err := dec(in); err != nil {
@ -1352,6 +1551,24 @@ func _Lightning_NewAddress_Handler(srv interface{}, ctx context.Context, dec fun
return interceptor(ctx, in, info, handler)
}
func _Lightning_NewWitnessAddress_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
in := new(NewWitnessAddressRequest)
if err := dec(in); err != nil {
return nil, err
}
if interceptor == nil {
return srv.(LightningServer).NewWitnessAddress(ctx, in)
}
info := &grpc.UnaryServerInfo{
Server: srv,
FullMethod: "/lnrpc.Lightning/NewWitnessAddress",
}
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
return srv.(LightningServer).NewWitnessAddress(ctx, req.(*NewWitnessAddressRequest))
}
return interceptor(ctx, in, info, handler)
}
func _Lightning_ConnectPeer_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
in := new(ConnectPeerRequest)
if err := dec(in); err != nil {
@ -1406,6 +1623,42 @@ func _Lightning_GetInfo_Handler(srv interface{}, ctx context.Context, dec func(i
return interceptor(ctx, in, info, handler)
}
func _Lightning_PendingChannels_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
in := new(PendingChannelRequest)
if err := dec(in); err != nil {
return nil, err
}
if interceptor == nil {
return srv.(LightningServer).PendingChannels(ctx, in)
}
info := &grpc.UnaryServerInfo{
Server: srv,
FullMethod: "/lnrpc.Lightning/PendingChannels",
}
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
return srv.(LightningServer).PendingChannels(ctx, req.(*PendingChannelRequest))
}
return interceptor(ctx, in, info, handler)
}
func _Lightning_ListChannels_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
in := new(ListChannelsRequest)
if err := dec(in); err != nil {
return nil, err
}
if interceptor == nil {
return srv.(LightningServer).ListChannels(ctx, in)
}
info := &grpc.UnaryServerInfo{
Server: srv,
FullMethod: "/lnrpc.Lightning/ListChannels",
}
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
return srv.(LightningServer).ListChannels(ctx, req.(*ListChannelsRequest))
}
return interceptor(ctx, in, info, handler)
}
func _Lightning_OpenChannel_Handler(srv interface{}, stream grpc.ServerStream) error {
m := new(OpenChannelRequest)
if err := stream.RecvMsg(m); err != nil {
@ -1448,42 +1701,6 @@ func (x *lightningCloseChannelServer) Send(m *CloseStatusUpdate) error {
return x.ServerStream.SendMsg(m)
}
func _Lightning_PendingChannels_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
in := new(PendingChannelRequest)
if err := dec(in); err != nil {
return nil, err
}
if interceptor == nil {
return srv.(LightningServer).PendingChannels(ctx, in)
}
info := &grpc.UnaryServerInfo{
Server: srv,
FullMethod: "/lnrpc.Lightning/PendingChannels",
}
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
return srv.(LightningServer).PendingChannels(ctx, req.(*PendingChannelRequest))
}
return interceptor(ctx, in, info, handler)
}
func _Lightning_ListChannels_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
in := new(ListChannelsRequest)
if err := dec(in); err != nil {
return nil, err
}
if interceptor == nil {
return srv.(LightningServer).ListChannels(ctx, in)
}
info := &grpc.UnaryServerInfo{
Server: srv,
FullMethod: "/lnrpc.Lightning/ListChannels",
}
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
return srv.(LightningServer).ListChannels(ctx, req.(*ListChannelsRequest))
}
return interceptor(ctx, in, info, handler)
}
func _Lightning_SendPayment_Handler(srv interface{}, stream grpc.ServerStream) error {
return srv.(LightningServer).SendPayment(&lightningSendPaymentServer{stream})
}
@ -1528,6 +1745,24 @@ func _Lightning_AddInvoice_Handler(srv interface{}, ctx context.Context, dec fun
return interceptor(ctx, in, info, handler)
}
func _Lightning_ListInvoices_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
in := new(ListInvoiceRequest)
if err := dec(in); err != nil {
return nil, err
}
if interceptor == nil {
return srv.(LightningServer).ListInvoices(ctx, in)
}
info := &grpc.UnaryServerInfo{
Server: srv,
FullMethod: "/lnrpc.Lightning/ListInvoices",
}
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
return srv.(LightningServer).ListInvoices(ctx, req.(*ListInvoiceRequest))
}
return interceptor(ctx, in, info, handler)
}
func _Lightning_LookupInvoice_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
in := new(PaymentHash)
if err := dec(in); err != nil {
@ -1546,22 +1781,25 @@ func _Lightning_LookupInvoice_Handler(srv interface{}, ctx context.Context, dec
return interceptor(ctx, in, info, handler)
}
func _Lightning_ListInvoices_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
in := new(ListInvoiceRequest)
if err := dec(in); err != nil {
return nil, err
func _Lightning_SubscribeInvoices_Handler(srv interface{}, stream grpc.ServerStream) error {
m := new(InvoiceSubscription)
if err := stream.RecvMsg(m); err != nil {
return err
}
if interceptor == nil {
return srv.(LightningServer).ListInvoices(ctx, in)
}
info := &grpc.UnaryServerInfo{
Server: srv,
FullMethod: "/lnrpc.Lightning/ListInvoices",
}
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
return srv.(LightningServer).ListInvoices(ctx, req.(*ListInvoiceRequest))
}
return interceptor(ctx, in, info, handler)
return srv.(LightningServer).SubscribeInvoices(m, &lightningSubscribeInvoicesServer{stream})
}
type Lightning_SubscribeInvoicesServer interface {
Send(*Invoice) error
grpc.ServerStream
}
type lightningSubscribeInvoicesServer struct {
grpc.ServerStream
}
func (x *lightningSubscribeInvoicesServer) Send(m *Invoice) error {
return x.ServerStream.SendMsg(m)
}
func _Lightning_ShowRoutingTable_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
@ -1595,17 +1833,25 @@ var _Lightning_serviceDesc = grpc.ServiceDesc{
Handler: _Lightning_ChannelBalance_Handler,
},
{
MethodName: "SendMany",
Handler: _Lightning_SendMany_Handler,
MethodName: "GetTransactions",
Handler: _Lightning_GetTransactions_Handler,
},
{
MethodName: "SendCoins",
Handler: _Lightning_SendCoins_Handler,
},
{
MethodName: "SendMany",
Handler: _Lightning_SendMany_Handler,
},
{
MethodName: "NewAddress",
Handler: _Lightning_NewAddress_Handler,
},
{
MethodName: "NewWitnessAddress",
Handler: _Lightning_NewWitnessAddress_Handler,
},
{
MethodName: "ConnectPeer",
Handler: _Lightning_ConnectPeer_Handler,
@ -1630,20 +1876,25 @@ var _Lightning_serviceDesc = grpc.ServiceDesc{
MethodName: "AddInvoice",
Handler: _Lightning_AddInvoice_Handler,
},
{
MethodName: "LookupInvoice",
Handler: _Lightning_LookupInvoice_Handler,
},
{
MethodName: "ListInvoices",
Handler: _Lightning_ListInvoices_Handler,
},
{
MethodName: "LookupInvoice",
Handler: _Lightning_LookupInvoice_Handler,
},
{
MethodName: "ShowRoutingTable",
Handler: _Lightning_ShowRoutingTable_Handler,
},
},
Streams: []grpc.StreamDesc{
{
StreamName: "SubscribeTransactions",
Handler: _Lightning_SubscribeTransactions_Handler,
ServerStreams: true,
},
{
StreamName: "OpenChannel",
Handler: _Lightning_OpenChannel_Handler,
@ -1660,6 +1911,11 @@ var _Lightning_serviceDesc = grpc.ServiceDesc{
ServerStreams: true,
ClientStreams: true,
},
{
StreamName: "SubscribeInvoices",
Handler: _Lightning_SubscribeInvoices_Handler,
ServerStreams: true,
},
},
Metadata: fileDescriptor0,
}
@ -1667,117 +1923,143 @@ var _Lightning_serviceDesc = grpc.ServiceDesc{
func init() { proto.RegisterFile("rpc.proto", fileDescriptor0) }
var fileDescriptor0 = []byte{
// 1781 bytes of a gzipped FileDescriptorProto
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x09, 0x6e, 0x88, 0x02, 0xff, 0xb4, 0x58, 0xdd, 0x6e, 0x13, 0xd7,
0x16, 0xc6, 0xb1, 0x1d, 0xdb, 0xcb, 0x3f, 0x71, 0x76, 0xfe, 0x1c, 0x43, 0xce, 0xe1, 0x8c, 0x00,
0x05, 0x04, 0x01, 0xcc, 0x91, 0x40, 0xa0, 0xc3, 0x51, 0x08, 0x29, 0x49, 0x31, 0x49, 0x8a, 0x83,
0x50, 0xaf, 0xa6, 0x93, 0xf1, 0x4e, 0x3c, 0xca, 0x78, 0x66, 0xea, 0xd9, 0x4e, 0x70, 0x1f, 0xa0,
0x0f, 0xd0, 0xab, 0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 0x87, 0x07, 0x9a, 0xa5, 0xa9, 0x6e, 0x37, 0x6f, 0x49, 0xf9, 0x1e,
0x40, 0x3b, 0x4d, 0xe9, 0xe4, 0x5f, 0x41, 0x86, 0xf9, 0x6d, 0xa0, 0xfb, 0xef, 0x2b, 0xd7, 0xa5,
0xd1, 0x93, 0x79, 0xf1, 0x0f, 0xd3, 0x93, 0xbf, 0x02, 0x00, 0x00, 0xff, 0xff, 0x24, 0x8f, 0x46,
0x46, 0x6e, 0x12, 0x00, 0x00,
// 2208 bytes of a gzipped FileDescriptorProto
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x09, 0x6e, 0x88, 0x02, 0xff, 0xb4, 0x58, 0x49, 0x6f, 0x1c, 0xc7,
0x15, 0xd6, 0x70, 0xb8, 0xcc, 0xbc, 0x59, 0x34, 0x53, 0xdc, 0x86, 0x4d, 0x4a, 0x96, 0x2b, 0xb2,
0x41, 0x13, 0x32, 0x69, 0xd1, 0x01, 0x12, 0xd8, 0x88, 0x03, 0x8a, 0x66, 0x4c, 0xc1, 0x34, 0x45,
0x9b, 0x94, 0x85, 0x6c, 0x68, 0x37, 0x67, 0x8a, 0x64, 0x9b, 0x3d, 0xdd, 0x9d, 0xee, 0x1e, 0x52,
0x13, 0x43, 0x97, 0x1c, 0xf2, 0x07, 0x72, 0x09, 0x10, 0x20, 0xe7, 0x20, 0x08, 0x82, 0xfc, 0x8f,
0xdc, 0x92, 0x53, 0xee, 0xf9, 0x21, 0x79, 0xb5, 0x75, 0x57, 0x2f, 0x12, 0xe0, 0x43, 0x4e, 0x64,
0xbf, 0xaa, 0x7a, 0xcb, 0xf7, 0xf6, 0x81, 0x66, 0x14, 0x0e, 0xb7, 0xc3, 0x28, 0x48, 0x02, 0x32,
0xe7, 0xf9, 0xf8, 0x61, 0x6d, 0x5c, 0x06, 0xc1, 0xa5, 0xc7, 0x76, 0x9c, 0xd0, 0xdd, 0x71, 0x7c,
0x3f, 0x48, 0x9c, 0xc4, 0x0d, 0xf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92,
0x8c, 0x5c, 0x2b, 0x4c, 0x65, 0xc4, 0x9a, 0x27, 0x02, 0x7f, 0x0a, 0xbd, 0xe2, 0x10, 0x45, 0xee,
0x6b, 0x5f, 0x56, 0x0f, 0x5e, 0xd6, 0x5b, 0xaf, 0x3d, 0x97, 0xa0, 0x9d, 0xcf, 0x8b, 0x9f, 0xbe,
0x3f, 0xfc, 0x5f, 0x00, 0x00, 0x00, 0xff, 0xff, 0x79, 0x99, 0xf1, 0x9f, 0x2c, 0x17, 0x00, 0x00,
}

953
lnrpc/rpc.pb.gw.go Normal file

@ -0,0 +1,953 @@
// Code generated by protoc-gen-grpc-gateway
// source: rpc.proto
// DO NOT EDIT!
/*
Package lnrpc is a reverse proxy.
It translates gRPC into RESTful JSON APIs.
*/
package lnrpc
import (
"io"
"net/http"
"github.com/golang/protobuf/proto"
"github.com/grpc-ecosystem/grpc-gateway/runtime"
"github.com/grpc-ecosystem/grpc-gateway/utilities"
"golang.org/x/net/context"
"google.golang.org/grpc"
"google.golang.org/grpc/codes"
"google.golang.org/grpc/grpclog"
)
var _ codes.Code
var _ io.Reader
var _ = runtime.String
var _ = utilities.NewDoubleArray
var (
filter_Lightning_WalletBalance_0 = &utilities.DoubleArray{Encoding: map[string]int{}, Base: []int(nil), Check: []int(nil)}
)
func request_Lightning_WalletBalance_0(ctx context.Context, marshaler runtime.Marshaler, client LightningClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {
var protoReq WalletBalanceRequest
var metadata runtime.ServerMetadata
if err := runtime.PopulateQueryParameters(&protoReq, req.URL.Query(), filter_Lightning_WalletBalance_0); err != nil {
return nil, metadata, grpc.Errorf(codes.InvalidArgument, "%v", err)
}
msg, err := client.WalletBalance(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD))
return msg, metadata, err
}
func request_Lightning_ChannelBalance_0(ctx context.Context, marshaler runtime.Marshaler, client LightningClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {
var protoReq ChannelBalanceRequest
var metadata runtime.ServerMetadata
msg, err := client.ChannelBalance(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD))
return msg, metadata, err
}
func request_Lightning_GetTransactions_0(ctx context.Context, marshaler runtime.Marshaler, client LightningClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {
var protoReq GetTransactionsRequest
var metadata runtime.ServerMetadata
msg, err := client.GetTransactions(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD))
return msg, metadata, err
}
func request_Lightning_SendCoins_0(ctx context.Context, marshaler runtime.Marshaler, client LightningClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {
var protoReq SendCoinsRequest
var metadata runtime.ServerMetadata
if err := marshaler.NewDecoder(req.Body).Decode(&protoReq); err != nil {
return nil, metadata, grpc.Errorf(codes.InvalidArgument, "%v", err)
}
msg, err := client.SendCoins(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD))
return msg, metadata, err
}
func request_Lightning_NewWitnessAddress_0(ctx context.Context, marshaler runtime.Marshaler, client LightningClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {
var protoReq NewWitnessAddressRequest
var metadata runtime.ServerMetadata
msg, err := client.NewWitnessAddress(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD))
return msg, metadata, err
}
func request_Lightning_ConnectPeer_0(ctx context.Context, marshaler runtime.Marshaler, client LightningClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {
var protoReq ConnectPeerRequest
var metadata runtime.ServerMetadata
if err := marshaler.NewDecoder(req.Body).Decode(&protoReq); err != nil {
return nil, metadata, grpc.Errorf(codes.InvalidArgument, "%v", err)
}
msg, err := client.ConnectPeer(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD))
return msg, metadata, err
}
func request_Lightning_ListPeers_0(ctx context.Context, marshaler runtime.Marshaler, client LightningClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {
var protoReq ListPeersRequest
var metadata runtime.ServerMetadata
msg, err := client.ListPeers(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD))
return msg, metadata, err
}
func request_Lightning_GetInfo_0(ctx context.Context, marshaler runtime.Marshaler, client LightningClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {
var protoReq GetInfoRequest
var metadata runtime.ServerMetadata
msg, err := client.GetInfo(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD))
return msg, metadata, err
}
var (
filter_Lightning_PendingChannels_0 = &utilities.DoubleArray{Encoding: map[string]int{}, Base: []int(nil), Check: []int(nil)}
)
func request_Lightning_PendingChannels_0(ctx context.Context, marshaler runtime.Marshaler, client LightningClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {
var protoReq PendingChannelRequest
var metadata runtime.ServerMetadata
if err := runtime.PopulateQueryParameters(&protoReq, req.URL.Query(), filter_Lightning_PendingChannels_0); err != nil {
return nil, metadata, grpc.Errorf(codes.InvalidArgument, "%v", err)
}
msg, err := client.PendingChannels(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD))
return msg, metadata, err
}
func request_Lightning_ListChannels_0(ctx context.Context, marshaler runtime.Marshaler, client LightningClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {
var protoReq ListChannelsRequest
var metadata runtime.ServerMetadata
msg, err := client.ListChannels(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD))
return msg, metadata, err
}
func request_Lightning_OpenChannel_0(ctx context.Context, marshaler runtime.Marshaler, client LightningClient, req *http.Request, pathParams map[string]string) (Lightning_OpenChannelClient, runtime.ServerMetadata, error) {
var protoReq OpenChannelRequest
var metadata runtime.ServerMetadata
if err := marshaler.NewDecoder(req.Body).Decode(&protoReq); err != nil {
return nil, metadata, grpc.Errorf(codes.InvalidArgument, "%v", err)
}
stream, err := client.OpenChannel(ctx, &protoReq)
if err != nil {
return nil, metadata, err
}
header, err := stream.Header()
if err != nil {
return nil, metadata, err
}
metadata.HeaderMD = header
return stream, metadata, nil
}
var (
filter_Lightning_CloseChannel_0 = &utilities.DoubleArray{Encoding: map[string]int{"channel_point": 0, "funding_txid": 1, "output_index": 2, "force": 3}, Base: []int{1, 1, 1, 2, 3, 0, 0, 0}, Check: []int{0, 1, 2, 2, 1, 3, 4, 5}}
)
func request_Lightning_CloseChannel_0(ctx context.Context, marshaler runtime.Marshaler, client LightningClient, req *http.Request, pathParams map[string]string) (Lightning_CloseChannelClient, runtime.ServerMetadata, error) {
var protoReq CloseChannelRequest
var metadata runtime.ServerMetadata
var (
val string
ok bool
err error
_ = err
)
val, ok = pathParams["channel_point.funding_txid"]
if !ok {
return nil, metadata, grpc.Errorf(codes.InvalidArgument, "missing parameter %s", "channel_point.funding_txid")
}
err = runtime.PopulateFieldFromPath(&protoReq, "channel_point.funding_txid", val)
if err != nil {
return nil, metadata, err
}
val, ok = pathParams["channel_point.output_index"]
if !ok {
return nil, metadata, grpc.Errorf(codes.InvalidArgument, "missing parameter %s", "channel_point.output_index")
}
err = runtime.PopulateFieldFromPath(&protoReq, "channel_point.output_index", val)
if err != nil {
return nil, metadata, err
}
val, ok = pathParams["force"]
if !ok {
return nil, metadata, grpc.Errorf(codes.InvalidArgument, "missing parameter %s", "force")
}
protoReq.Force, err = runtime.Bool(val)
if err != nil {
return nil, metadata, err
}
if err := runtime.PopulateQueryParameters(&protoReq, req.URL.Query(), filter_Lightning_CloseChannel_0); err != nil {
return nil, metadata, grpc.Errorf(codes.InvalidArgument, "%v", err)
}
stream, err := client.CloseChannel(ctx, &protoReq)
if err != nil {
return nil, metadata, err
}
header, err := stream.Header()
if err != nil {
return nil, metadata, err
}
metadata.HeaderMD = header
return stream, metadata, nil
}
func request_Lightning_SendPayment_0(ctx context.Context, marshaler runtime.Marshaler, client LightningClient, req *http.Request, pathParams map[string]string) (Lightning_SendPaymentClient, runtime.ServerMetadata, error) {
var metadata runtime.ServerMetadata
stream, err := client.SendPayment(ctx)
if err != nil {
grpclog.Printf("Failed to start streaming: %v", err)
return nil, metadata, err
}
dec := marshaler.NewDecoder(req.Body)
handleSend := func() error {
var protoReq SendRequest
err = dec.Decode(&protoReq)
if err == io.EOF {
return err
}
if err != nil {
grpclog.Printf("Failed to decode request: %v", err)
return err
}
if err = stream.Send(&protoReq); err != nil {
grpclog.Printf("Failed to send request: %v", err)
return err
}
return nil
}
if err := handleSend(); err != nil {
if cerr := stream.CloseSend(); cerr != nil {
grpclog.Printf("Failed to terminate client stream: %v", cerr)
}
if err == io.EOF {
return stream, metadata, nil
}
return nil, metadata, err
}
go func() {
for {
if err := handleSend(); err != nil {
break
}
}
if err := stream.CloseSend(); err != nil {
grpclog.Printf("Failed to terminate client stream: %v", err)
}
}()
header, err := stream.Header()
if err != nil {
grpclog.Printf("Failed to get header from client: %v", err)
return nil, metadata, err
}
metadata.HeaderMD = header
return stream, metadata, nil
}
func request_Lightning_AddInvoice_0(ctx context.Context, marshaler runtime.Marshaler, client LightningClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {
var protoReq Invoice
var metadata runtime.ServerMetadata
if err := marshaler.NewDecoder(req.Body).Decode(&protoReq); err != nil {
return nil, metadata, grpc.Errorf(codes.InvalidArgument, "%v", err)
}
msg, err := client.AddInvoice(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD))
return msg, metadata, err
}
func request_Lightning_ListInvoices_0(ctx context.Context, marshaler runtime.Marshaler, client LightningClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {
var protoReq ListInvoiceRequest
var metadata runtime.ServerMetadata
var (
val string
ok bool
err error
_ = err
)
val, ok = pathParams["pending_only"]
if !ok {
return nil, metadata, grpc.Errorf(codes.InvalidArgument, "missing parameter %s", "pending_only")
}
protoReq.PendingOnly, err = runtime.Bool(val)
if err != nil {
return nil, metadata, err
}
msg, err := client.ListInvoices(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD))
return msg, metadata, err
}
var (
filter_Lightning_LookupInvoice_0 = &utilities.DoubleArray{Encoding: map[string]int{"r_hash_str": 0}, Base: []int{1, 1, 0}, Check: []int{0, 1, 2}}
)
func request_Lightning_LookupInvoice_0(ctx context.Context, marshaler runtime.Marshaler, client LightningClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {
var protoReq PaymentHash
var metadata runtime.ServerMetadata
var (
val string
ok bool
err error
_ = err
)
val, ok = pathParams["r_hash_str"]
if !ok {
return nil, metadata, grpc.Errorf(codes.InvalidArgument, "missing parameter %s", "r_hash_str")
}
protoReq.RHashStr, err = runtime.String(val)
if err != nil {
return nil, metadata, err
}
if err := runtime.PopulateQueryParameters(&protoReq, req.URL.Query(), filter_Lightning_LookupInvoice_0); err != nil {
return nil, metadata, grpc.Errorf(codes.InvalidArgument, "%v", err)
}
msg, err := client.LookupInvoice(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD))
return msg, metadata, err
}
func request_Lightning_SubscribeInvoices_0(ctx context.Context, marshaler runtime.Marshaler, client LightningClient, req *http.Request, pathParams map[string]string) (Lightning_SubscribeInvoicesClient, runtime.ServerMetadata, error) {
var protoReq InvoiceSubscription
var metadata runtime.ServerMetadata
stream, err := client.SubscribeInvoices(ctx, &protoReq)
if err != nil {
return nil, metadata, err
}
header, err := stream.Header()
if err != nil {
return nil, metadata, err
}
metadata.HeaderMD = header
return stream, metadata, nil
}
// RegisterLightningHandlerFromEndpoint is same as RegisterLightningHandler but
// automatically dials to "endpoint" and closes the connection when "ctx" gets done.
func RegisterLightningHandlerFromEndpoint(ctx context.Context, mux *runtime.ServeMux, endpoint string, opts []grpc.DialOption) (err error) {
conn, err := grpc.Dial(endpoint, opts...)
if err != nil {
return err
}
defer func() {
if err != nil {
if cerr := conn.Close(); cerr != nil {
grpclog.Printf("Failed to close conn to %s: %v", endpoint, cerr)
}
return
}
go func() {
<-ctx.Done()
if cerr := conn.Close(); cerr != nil {
grpclog.Printf("Failed to close conn to %s: %v", endpoint, cerr)
}
}()
}()
return RegisterLightningHandler(ctx, mux, conn)
}
// RegisterLightningHandler registers the http handlers for service Lightning to "mux".
// The handlers forward requests to the grpc endpoint over "conn".
func RegisterLightningHandler(ctx context.Context, mux *runtime.ServeMux, conn *grpc.ClientConn) error {
client := NewLightningClient(conn)
mux.Handle("GET", pattern_Lightning_WalletBalance_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {
ctx, cancel := context.WithCancel(ctx)
defer cancel()
if cn, ok := w.(http.CloseNotifier); ok {
go func(done <-chan struct{}, closed <-chan bool) {
select {
case <-done:
case <-closed:
cancel()
}
}(ctx.Done(), cn.CloseNotify())
}
inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)
rctx, err := runtime.AnnotateContext(ctx, req)
if err != nil {
runtime.HTTPError(ctx, outboundMarshaler, w, req, err)
}
resp, md, err := request_Lightning_WalletBalance_0(rctx, inboundMarshaler, client, req, pathParams)
ctx = runtime.NewServerMetadataContext(ctx, md)
if err != nil {
runtime.HTTPError(ctx, outboundMarshaler, w, req, err)
return
}
forward_Lightning_WalletBalance_0(ctx, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)
})
mux.Handle("GET", pattern_Lightning_ChannelBalance_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {
ctx, cancel := context.WithCancel(ctx)
defer cancel()
if cn, ok := w.(http.CloseNotifier); ok {
go func(done <-chan struct{}, closed <-chan bool) {
select {
case <-done:
case <-closed:
cancel()
}
}(ctx.Done(), cn.CloseNotify())
}
inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)
rctx, err := runtime.AnnotateContext(ctx, req)
if err != nil {
runtime.HTTPError(ctx, outboundMarshaler, w, req, err)
}
resp, md, err := request_Lightning_ChannelBalance_0(rctx, inboundMarshaler, client, req, pathParams)
ctx = runtime.NewServerMetadataContext(ctx, md)
if err != nil {
runtime.HTTPError(ctx, outboundMarshaler, w, req, err)
return
}
forward_Lightning_ChannelBalance_0(ctx, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)
})
mux.Handle("GET", pattern_Lightning_GetTransactions_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {
ctx, cancel := context.WithCancel(ctx)
defer cancel()
if cn, ok := w.(http.CloseNotifier); ok {
go func(done <-chan struct{}, closed <-chan bool) {
select {
case <-done:
case <-closed:
cancel()
}
}(ctx.Done(), cn.CloseNotify())
}
inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)
rctx, err := runtime.AnnotateContext(ctx, req)
if err != nil {
runtime.HTTPError(ctx, outboundMarshaler, w, req, err)
}
resp, md, err := request_Lightning_GetTransactions_0(rctx, inboundMarshaler, client, req, pathParams)
ctx = runtime.NewServerMetadataContext(ctx, md)
if err != nil {
runtime.HTTPError(ctx, outboundMarshaler, w, req, err)
return
}
forward_Lightning_GetTransactions_0(ctx, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)
})
mux.Handle("POST", pattern_Lightning_SendCoins_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {
ctx, cancel := context.WithCancel(ctx)
defer cancel()
if cn, ok := w.(http.CloseNotifier); ok {
go func(done <-chan struct{}, closed <-chan bool) {
select {
case <-done:
case <-closed:
cancel()
}
}(ctx.Done(), cn.CloseNotify())
}
inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)
rctx, err := runtime.AnnotateContext(ctx, req)
if err != nil {
runtime.HTTPError(ctx, outboundMarshaler, w, req, err)
}
resp, md, err := request_Lightning_SendCoins_0(rctx, inboundMarshaler, client, req, pathParams)
ctx = runtime.NewServerMetadataContext(ctx, md)
if err != nil {
runtime.HTTPError(ctx, outboundMarshaler, w, req, err)
return
}
forward_Lightning_SendCoins_0(ctx, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)
})
mux.Handle("GET", pattern_Lightning_NewWitnessAddress_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {
ctx, cancel := context.WithCancel(ctx)
defer cancel()
if cn, ok := w.(http.CloseNotifier); ok {
go func(done <-chan struct{}, closed <-chan bool) {
select {
case <-done:
case <-closed:
cancel()
}
}(ctx.Done(), cn.CloseNotify())
}
inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)
rctx, err := runtime.AnnotateContext(ctx, req)
if err != nil {
runtime.HTTPError(ctx, outboundMarshaler, w, req, err)
}
resp, md, err := request_Lightning_NewWitnessAddress_0(rctx, inboundMarshaler, client, req, pathParams)
ctx = runtime.NewServerMetadataContext(ctx, md)
if err != nil {
runtime.HTTPError(ctx, outboundMarshaler, w, req, err)
return
}
forward_Lightning_NewWitnessAddress_0(ctx, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)
})
mux.Handle("POST", pattern_Lightning_ConnectPeer_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {
ctx, cancel := context.WithCancel(ctx)
defer cancel()
if cn, ok := w.(http.CloseNotifier); ok {
go func(done <-chan struct{}, closed <-chan bool) {
select {
case <-done:
case <-closed:
cancel()
}
}(ctx.Done(), cn.CloseNotify())
}
inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)
rctx, err := runtime.AnnotateContext(ctx, req)
if err != nil {
runtime.HTTPError(ctx, outboundMarshaler, w, req, err)
}
resp, md, err := request_Lightning_ConnectPeer_0(rctx, inboundMarshaler, client, req, pathParams)
ctx = runtime.NewServerMetadataContext(ctx, md)
if err != nil {
runtime.HTTPError(ctx, outboundMarshaler, w, req, err)
return
}
forward_Lightning_ConnectPeer_0(ctx, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)
})
mux.Handle("GET", pattern_Lightning_ListPeers_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {
ctx, cancel := context.WithCancel(ctx)
defer cancel()
if cn, ok := w.(http.CloseNotifier); ok {
go func(done <-chan struct{}, closed <-chan bool) {
select {
case <-done:
case <-closed:
cancel()
}
}(ctx.Done(), cn.CloseNotify())
}
inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)
rctx, err := runtime.AnnotateContext(ctx, req)
if err != nil {
runtime.HTTPError(ctx, outboundMarshaler, w, req, err)
}
resp, md, err := request_Lightning_ListPeers_0(rctx, inboundMarshaler, client, req, pathParams)
ctx = runtime.NewServerMetadataContext(ctx, md)
if err != nil {
runtime.HTTPError(ctx, outboundMarshaler, w, req, err)
return
}
forward_Lightning_ListPeers_0(ctx, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)
})
mux.Handle("GET", pattern_Lightning_GetInfo_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {
ctx, cancel := context.WithCancel(ctx)
defer cancel()
if cn, ok := w.(http.CloseNotifier); ok {
go func(done <-chan struct{}, closed <-chan bool) {
select {
case <-done:
case <-closed:
cancel()
}
}(ctx.Done(), cn.CloseNotify())
}
inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)
rctx, err := runtime.AnnotateContext(ctx, req)
if err != nil {
runtime.HTTPError(ctx, outboundMarshaler, w, req, err)
}
resp, md, err := request_Lightning_GetInfo_0(rctx, inboundMarshaler, client, req, pathParams)
ctx = runtime.NewServerMetadataContext(ctx, md)
if err != nil {
runtime.HTTPError(ctx, outboundMarshaler, w, req, err)
return
}
forward_Lightning_GetInfo_0(ctx, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)
})
mux.Handle("GET", pattern_Lightning_PendingChannels_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {
ctx, cancel := context.WithCancel(ctx)
defer cancel()
if cn, ok := w.(http.CloseNotifier); ok {
go func(done <-chan struct{}, closed <-chan bool) {
select {
case <-done:
case <-closed:
cancel()
}
}(ctx.Done(), cn.CloseNotify())
}
inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)
rctx, err := runtime.AnnotateContext(ctx, req)
if err != nil {
runtime.HTTPError(ctx, outboundMarshaler, w, req, err)
}
resp, md, err := request_Lightning_PendingChannels_0(rctx, inboundMarshaler, client, req, pathParams)
ctx = runtime.NewServerMetadataContext(ctx, md)
if err != nil {
runtime.HTTPError(ctx, outboundMarshaler, w, req, err)
return
}
forward_Lightning_PendingChannels_0(ctx, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)
})
mux.Handle("GET", pattern_Lightning_ListChannels_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {
ctx, cancel := context.WithCancel(ctx)
defer cancel()
if cn, ok := w.(http.CloseNotifier); ok {
go func(done <-chan struct{}, closed <-chan bool) {
select {
case <-done:
case <-closed:
cancel()
}
}(ctx.Done(), cn.CloseNotify())
}
inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)
rctx, err := runtime.AnnotateContext(ctx, req)
if err != nil {
runtime.HTTPError(ctx, outboundMarshaler, w, req, err)
}
resp, md, err := request_Lightning_ListChannels_0(rctx, inboundMarshaler, client, req, pathParams)
ctx = runtime.NewServerMetadataContext(ctx, md)
if err != nil {
runtime.HTTPError(ctx, outboundMarshaler, w, req, err)
return
}
forward_Lightning_ListChannels_0(ctx, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)
})
mux.Handle("POST", pattern_Lightning_OpenChannel_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {
ctx, cancel := context.WithCancel(ctx)
defer cancel()
if cn, ok := w.(http.CloseNotifier); ok {
go func(done <-chan struct{}, closed <-chan bool) {
select {
case <-done:
case <-closed:
cancel()
}
}(ctx.Done(), cn.CloseNotify())
}
inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)
rctx, err := runtime.AnnotateContext(ctx, req)
if err != nil {
runtime.HTTPError(ctx, outboundMarshaler, w, req, err)
}
resp, md, err := request_Lightning_OpenChannel_0(rctx, inboundMarshaler, client, req, pathParams)
ctx = runtime.NewServerMetadataContext(ctx, md)
if err != nil {
runtime.HTTPError(ctx, outboundMarshaler, w, req, err)
return
}
forward_Lightning_OpenChannel_0(ctx, outboundMarshaler, w, req, func() (proto.Message, error) { return resp.Recv() }, mux.GetForwardResponseOptions()...)
})
mux.Handle("DELETE", pattern_Lightning_CloseChannel_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {
ctx, cancel := context.WithCancel(ctx)
defer cancel()
if cn, ok := w.(http.CloseNotifier); ok {
go func(done <-chan struct{}, closed <-chan bool) {
select {
case <-done:
case <-closed:
cancel()
}
}(ctx.Done(), cn.CloseNotify())
}
inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)
rctx, err := runtime.AnnotateContext(ctx, req)
if err != nil {
runtime.HTTPError(ctx, outboundMarshaler, w, req, err)
}
resp, md, err := request_Lightning_CloseChannel_0(rctx, inboundMarshaler, client, req, pathParams)
ctx = runtime.NewServerMetadataContext(ctx, md)
if err != nil {
runtime.HTTPError(ctx, outboundMarshaler, w, req, err)
return
}
forward_Lightning_CloseChannel_0(ctx, outboundMarshaler, w, req, func() (proto.Message, error) { return resp.Recv() }, mux.GetForwardResponseOptions()...)
})
mux.Handle("POST", pattern_Lightning_SendPayment_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {
ctx, cancel := context.WithCancel(ctx)
defer cancel()
if cn, ok := w.(http.CloseNotifier); ok {
go func(done <-chan struct{}, closed <-chan bool) {
select {
case <-done:
case <-closed:
cancel()
}
}(ctx.Done(), cn.CloseNotify())
}
inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)
rctx, err := runtime.AnnotateContext(ctx, req)
if err != nil {
runtime.HTTPError(ctx, outboundMarshaler, w, req, err)
}
resp, md, err := request_Lightning_SendPayment_0(rctx, inboundMarshaler, client, req, pathParams)
ctx = runtime.NewServerMetadataContext(ctx, md)
if err != nil {
runtime.HTTPError(ctx, outboundMarshaler, w, req, err)
return
}
forward_Lightning_SendPayment_0(ctx, outboundMarshaler, w, req, func() (proto.Message, error) { return resp.Recv() }, mux.GetForwardResponseOptions()...)
})
mux.Handle("POST", pattern_Lightning_AddInvoice_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {
ctx, cancel := context.WithCancel(ctx)
defer cancel()
if cn, ok := w.(http.CloseNotifier); ok {
go func(done <-chan struct{}, closed <-chan bool) {
select {
case <-done:
case <-closed:
cancel()
}
}(ctx.Done(), cn.CloseNotify())
}
inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)
rctx, err := runtime.AnnotateContext(ctx, req)
if err != nil {
runtime.HTTPError(ctx, outboundMarshaler, w, req, err)
}
resp, md, err := request_Lightning_AddInvoice_0(rctx, inboundMarshaler, client, req, pathParams)
ctx = runtime.NewServerMetadataContext(ctx, md)
if err != nil {
runtime.HTTPError(ctx, outboundMarshaler, w, req, err)
return
}
forward_Lightning_AddInvoice_0(ctx, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)
})
mux.Handle("GET", pattern_Lightning_ListInvoices_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {
ctx, cancel := context.WithCancel(ctx)
defer cancel()
if cn, ok := w.(http.CloseNotifier); ok {
go func(done <-chan struct{}, closed <-chan bool) {
select {
case <-done:
case <-closed:
cancel()
}
}(ctx.Done(), cn.CloseNotify())
}
inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)
rctx, err := runtime.AnnotateContext(ctx, req)
if err != nil {
runtime.HTTPError(ctx, outboundMarshaler, w, req, err)
}
resp, md, err := request_Lightning_ListInvoices_0(rctx, inboundMarshaler, client, req, pathParams)
ctx = runtime.NewServerMetadataContext(ctx, md)
if err != nil {
runtime.HTTPError(ctx, outboundMarshaler, w, req, err)
return
}
forward_Lightning_ListInvoices_0(ctx, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)
})
mux.Handle("GET", pattern_Lightning_LookupInvoice_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {
ctx, cancel := context.WithCancel(ctx)
defer cancel()
if cn, ok := w.(http.CloseNotifier); ok {
go func(done <-chan struct{}, closed <-chan bool) {
select {
case <-done:
case <-closed:
cancel()
}
}(ctx.Done(), cn.CloseNotify())
}
inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)
rctx, err := runtime.AnnotateContext(ctx, req)
if err != nil {
runtime.HTTPError(ctx, outboundMarshaler, w, req, err)
}
resp, md, err := request_Lightning_LookupInvoice_0(rctx, inboundMarshaler, client, req, pathParams)
ctx = runtime.NewServerMetadataContext(ctx, md)
if err != nil {
runtime.HTTPError(ctx, outboundMarshaler, w, req, err)
return
}
forward_Lightning_LookupInvoice_0(ctx, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)
})
mux.Handle("GET", pattern_Lightning_SubscribeInvoices_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {
ctx, cancel := context.WithCancel(ctx)
defer cancel()
if cn, ok := w.(http.CloseNotifier); ok {
go func(done <-chan struct{}, closed <-chan bool) {
select {
case <-done:
case <-closed:
cancel()
}
}(ctx.Done(), cn.CloseNotify())
}
inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)
rctx, err := runtime.AnnotateContext(ctx, req)
if err != nil {
runtime.HTTPError(ctx, outboundMarshaler, w, req, err)
}
resp, md, err := request_Lightning_SubscribeInvoices_0(rctx, inboundMarshaler, client, req, pathParams)
ctx = runtime.NewServerMetadataContext(ctx, md)
if err != nil {
runtime.HTTPError(ctx, outboundMarshaler, w, req, err)
return
}
forward_Lightning_SubscribeInvoices_0(ctx, outboundMarshaler, w, req, func() (proto.Message, error) { return resp.Recv() }, mux.GetForwardResponseOptions()...)
})
return nil
}
var (
pattern_Lightning_WalletBalance_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "balance", "blockchain"}, ""))
pattern_Lightning_ChannelBalance_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "balance", "channels"}, ""))
pattern_Lightning_GetTransactions_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "transactions"}, ""))
pattern_Lightning_SendCoins_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "transactions"}, ""))
pattern_Lightning_NewWitnessAddress_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "newaddress"}, ""))
pattern_Lightning_ConnectPeer_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "peers"}, ""))
pattern_Lightning_ListPeers_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "peers"}, ""))
pattern_Lightning_GetInfo_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "getinfo"}, ""))
pattern_Lightning_PendingChannels_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "channels", "pending"}, ""))
pattern_Lightning_ListChannels_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "channels"}, ""))
pattern_Lightning_OpenChannel_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "channels"}, ""))
pattern_Lightning_CloseChannel_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 1, 0, 4, 1, 5, 2, 1, 0, 4, 1, 5, 3, 1, 0, 4, 1, 5, 4}, []string{"v1", "channels", "channel_point.funding_txid", "channel_point.output_index", "force"}, ""))
pattern_Lightning_SendPayment_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "channels", "transactions"}, ""))
pattern_Lightning_AddInvoice_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "invoices"}, ""))
pattern_Lightning_ListInvoices_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 1, 0, 4, 1, 5, 2}, []string{"v1", "invoices", "pending_only"}, ""))
pattern_Lightning_LookupInvoice_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 1, 0, 4, 1, 5, 2}, []string{"v1", "invoices", "r_hash_str"}, ""))
pattern_Lightning_SubscribeInvoices_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "invoices", "subscribe"}, ""))
)
var (
forward_Lightning_WalletBalance_0 = runtime.ForwardResponseMessage
forward_Lightning_ChannelBalance_0 = runtime.ForwardResponseMessage
forward_Lightning_GetTransactions_0 = runtime.ForwardResponseMessage
forward_Lightning_SendCoins_0 = runtime.ForwardResponseMessage
forward_Lightning_NewWitnessAddress_0 = runtime.ForwardResponseMessage
forward_Lightning_ConnectPeer_0 = runtime.ForwardResponseMessage
forward_Lightning_ListPeers_0 = runtime.ForwardResponseMessage
forward_Lightning_GetInfo_0 = runtime.ForwardResponseMessage
forward_Lightning_PendingChannels_0 = runtime.ForwardResponseMessage
forward_Lightning_ListChannels_0 = runtime.ForwardResponseMessage
forward_Lightning_OpenChannel_0 = runtime.ForwardResponseStream
forward_Lightning_CloseChannel_0 = runtime.ForwardResponseStream
forward_Lightning_SendPayment_0 = runtime.ForwardResponseStream
forward_Lightning_AddInvoice_0 = runtime.ForwardResponseMessage
forward_Lightning_ListInvoices_0 = runtime.ForwardResponseMessage
forward_Lightning_LookupInvoice_0 = runtime.ForwardResponseMessage
forward_Lightning_SubscribeInvoices_0 = runtime.ForwardResponseStream
)

@ -1,34 +1,131 @@
syntax = "proto3";
import "google/api/annotations.proto";
package lnrpc;
service Lightning {
rpc WalletBalance(WalletBalanceRequest) returns (WalletBalanceResponse);
rpc ChannelBalance(ChannelBalanceRequest) returns (ChannelBalanceResponse);
rpc WalletBalance(WalletBalanceRequest) returns (WalletBalanceResponse) {
option (google.api.http) = {
get: "/v1/balance/blockchain"
};
}
rpc ChannelBalance(ChannelBalanceRequest) returns (ChannelBalanceResponse) {
option (google.api.http) = {
get: "/v1/balance/channels"
};
}
rpc GetTransactions(GetTransactionsRequest) returns (TransactionDetails) {
option (google.api.http) = {
get: "/v1/transactions"
};
}
rpc SendCoins(SendCoinsRequest) returns (SendCoinsResponse) {
option (google.api.http) = {
post: "/v1/transactions"
body: "*"
};
}
rpc SubscribeTransactions(GetTransactionsRequest) returns (stream Transaction);
rpc SendMany(SendManyRequest) returns (SendManyResponse);
rpc SendCoins(SendCoinsRequest) returns (SendCoinsResponse);
rpc NewAddress(NewAddressRequest) returns (NewAddressResponse);
rpc NewWitnessAddress(NewWitnessAddressRequest) returns (NewAddressResponse) {
option (google.api.http) = {
get: "/v1/newaddress"
};
}
rpc ConnectPeer(ConnectPeerRequest) returns (ConnectPeerResponse);
rpc ListPeers(ListPeersRequest) returns (ListPeersResponse);
rpc GetInfo(GetInfoRequest) returns (GetInfoResponse);
rpc ConnectPeer(ConnectPeerRequest) returns (ConnectPeerResponse) {
option (google.api.http) = {
post: "/v1/peers"
body: "*"
};
}
rpc ListPeers(ListPeersRequest) returns (ListPeersResponse) {
option (google.api.http) = {
get: "/v1/peers"
};
}
rpc GetInfo(GetInfoRequest) returns (GetInfoResponse) {
option (google.api.http) = {
get: "/v1/getinfo"
};
}
rpc OpenChannel(OpenChannelRequest) returns (stream OpenStatusUpdate);
rpc CloseChannel(CloseChannelRequest) returns (stream CloseStatusUpdate);
// TODO(roasbeef): merge with below with bool?
rpc PendingChannels(PendingChannelRequest) returns (PendingChannelResponse) {
option (google.api.http) = {
get: "/v1/channels/pending"
};
}
rpc ListChannels(ListChannelsRequest) returns (ListChannelsResponse) {
option (google.api.http) = {
get: "/v1/channels"
};
}
rpc OpenChannel(OpenChannelRequest) returns (stream OpenStatusUpdate) {
option (google.api.http) = {
post: "/v1/channels"
body: "*"
};
}
rpc CloseChannel(CloseChannelRequest) returns (stream CloseStatusUpdate) {
option (google.api.http) = {
delete: "/v1/channels/{channel_point.funding_txid}/{channel_point.output_index}/{force}"
};
}
rpc PendingChannels(PendingChannelRequest) returns (PendingChannelResponse);
rpc ListChannels(ListChannelsRequest) returns (ListChannelsResponse);
rpc SendPayment(stream SendRequest) returns (stream SendResponse) {
option (google.api.http) = {
post: "/v1/channels/transactions"
body: "*"
};
}
rpc SendPayment(stream SendRequest) returns (stream SendResponse);
rpc AddInvoice(Invoice) returns (AddInvoiceResponse);
rpc LookupInvoice(PaymentHash) returns (Invoice);
rpc ListInvoices(ListInvoiceRequest) returns (ListInvoiceResponse);
rpc AddInvoice(Invoice) returns (AddInvoiceResponse) {
option (google.api.http) = {
post: "/v1/invoices"
body: "*"
};
}
rpc ListInvoices(ListInvoiceRequest) returns (ListInvoiceResponse) {
option (google.api.http) = {
get: "/v1/invoices/{pending_only}"
};
}
rpc LookupInvoice(PaymentHash) returns (Invoice) {
option (google.api.http) = {
get: "/v1/invoices/{r_hash_str}"
};
}
rpc SubscribeInvoices(InvoiceSubscription) returns (stream Invoice) {
option (google.api.http) = {
get: "/v1/invoices/subscribe"
};
}
rpc ShowRoutingTable(ShowRoutingTableRequest) returns (ShowRoutingTableResponse);
}
message Transaction {
string tx_hash = 1;
double amount = 2;
int32 num_confirmations = 3;
string block_hash = 4;
int32 block_height = 5;
int64 time_stamp = 6;
int64 total_fees = 7;
}
message GetTransactionsRequest {
}
message TransactionDetails {
repeated Transaction transactions = 1;
}
message SendRequest {
bytes dest = 1;
int64 amt = 2;
@ -36,13 +133,14 @@ message SendRequest {
bool fast_send = 4;
}
message SendResponse{
message SendResponse {
// TODO(roasbeef): info about route? stats?
}
message ChannelPoint {
bytes funding_txid = 1;
uint32 output_index = 2;
string funding_txid_str = 2;
uint32 output_index = 3;
}
message LightningAddress {
@ -71,9 +169,9 @@ message NewAddressRequest {
NESTED_PUBKEY_HASH = 1;
PUBKEY_HASH = 2;
}
AddressType type = 1;
}
message NewWitnessAddressRequest {}
message NewAddressResponse {
string address = 1;
}
@ -267,7 +365,8 @@ message AddInvoiceResponse {
bytes r_hash = 1;
}
message PaymentHash {
bytes r_hash = 1;
string r_hash_str = 1;
bytes r_hash = 2;
}
message ListInvoiceRequest {
bool pending_only = 1;
@ -275,3 +374,5 @@ message ListInvoiceRequest {
message ListInvoiceResponse {
repeated Invoice invoices = 1;
}
message InvoiceSubscription {}

981
lnrpc/rpc.swagger.json Normal file

@ -0,0 +1,981 @@
{
"swagger": "2.0",
"info": {
"title": "rpc.proto",
"version": "version not set"
},
"schemes": [
"http",
"https"
],
"consumes": [
"application/json"
],
"produces": [
"application/json"
],
"paths": {
"/v1/balance/blockchain": {
"get": {
"operationId": "WalletBalance",
"responses": {
"200": {
"description": "",
"schema": {
"$ref": "#/definitions/lnrpcWalletBalanceResponse"
}
}
},
"tags": [
"Lightning"
]
}
},
"/v1/balance/channels": {
"get": {
"operationId": "ChannelBalance",
"responses": {
"200": {
"description": "",
"schema": {
"$ref": "#/definitions/lnrpcChannelBalanceResponse"
}
}
},
"tags": [
"Lightning"
]
}
},
"/v1/channels": {
"get": {
"operationId": "ListChannels",
"responses": {
"200": {
"description": "",
"schema": {
"$ref": "#/definitions/lnrpcListChannelsResponse"
}
}
},
"tags": [
"Lightning"
]
},
"post": {
"operationId": "OpenChannel",
"responses": {
"200": {
"description": "(streaming responses)",
"schema": {
"$ref": "#/definitions/lnrpcOpenStatusUpdate"
}
}
},
"parameters": [
{
"name": "body",
"in": "body",
"required": true,
"schema": {
"$ref": "#/definitions/lnrpcOpenChannelRequest"
}
}
],
"tags": [
"Lightning"
]
}
},
"/v1/channels/pending": {
"get": {
"operationId": "PendingChannels",
"responses": {
"200": {
"description": "",
"schema": {
"$ref": "#/definitions/lnrpcPendingChannelResponse"
}
}
},
"tags": [
"Lightning"
]
}
},
"/v1/channels/transactions": {
"post": {
"operationId": "SendPayment",
"responses": {
"200": {
"description": "(streaming responses)",
"schema": {
"$ref": "#/definitions/lnrpcSendResponse"
}
}
},
"parameters": [
{
"name": "body",
"description": "(streaming inputs)",
"in": "body",
"required": true,
"schema": {
"$ref": "#/definitions/lnrpcSendRequest"
}
}
],
"tags": [
"Lightning"
]
}
},
"/v1/channels/{channel_point.funding_txid}/{channel_point.output_index}/{force}": {
"delete": {
"summary": "TODO(roasbeef): merge with below with bool?",
"operationId": "CloseChannel",
"responses": {
"200": {
"description": "(streaming responses)",
"schema": {
"$ref": "#/definitions/lnrpcCloseStatusUpdate"
}
}
},
"parameters": [
{
"name": "channel_point.funding_txid",
"in": "path",
"required": true,
"type": "string",
"format": "byte"
},
{
"name": "channel_point.output_index",
"in": "path",
"required": true,
"type": "integer",
"format": "int64"
},
{
"name": "force",
"in": "path",
"required": true,
"type": "boolean",
"format": "boolean"
}
],
"tags": [
"Lightning"
]
}
},
"/v1/getinfo": {
"get": {
"operationId": "GetInfo",
"responses": {
"200": {
"description": "",
"schema": {
"$ref": "#/definitions/lnrpcGetInfoResponse"
}
}
},
"tags": [
"Lightning"
]
}
},
"/v1/invoices": {
"post": {
"operationId": "AddInvoice",
"responses": {
"200": {
"description": "",
"schema": {
"$ref": "#/definitions/lnrpcAddInvoiceResponse"
}
}
},
"parameters": [
{
"name": "body",
"in": "body",
"required": true,
"schema": {
"$ref": "#/definitions/lnrpcInvoice"
}
}
],
"tags": [
"Lightning"
]
}
},
"/v1/invoices/subscribe": {
"get": {
"operationId": "SubscribeInvoices",
"responses": {
"200": {
"description": "(streaming responses)",
"schema": {
"$ref": "#/definitions/lnrpcInvoice"
}
}
},
"tags": [
"Lightning"
]
}
},
"/v1/invoices/{pending_only}": {
"get": {
"operationId": "ListInvoices",
"responses": {
"200": {
"description": "",
"schema": {
"$ref": "#/definitions/lnrpcListInvoiceResponse"
}
}
},
"parameters": [
{
"name": "pending_only",
"in": "path",
"required": true,
"type": "boolean",
"format": "boolean"
}
],
"tags": [
"Lightning"
]
}
},
"/v1/invoices/{r_hash_str}": {
"get": {
"operationId": "LookupInvoice",
"responses": {
"200": {
"description": "",
"schema": {
"$ref": "#/definitions/lnrpcInvoice"
}
}
},
"parameters": [
{
"name": "r_hash_str",
"in": "path",
"required": true,
"type": "string",
"format": "string"
}
],
"tags": [
"Lightning"
]
}
},
"/v1/newaddress": {
"get": {
"operationId": "NewWitnessAddress",
"responses": {
"200": {
"description": "",
"schema": {
"$ref": "#/definitions/lnrpcNewAddressResponse"
}
}
},
"tags": [
"Lightning"
]
}
},
"/v1/peers": {
"get": {
"operationId": "ListPeers",
"responses": {
"200": {
"description": "",
"schema": {
"$ref": "#/definitions/lnrpcListPeersResponse"
}
}
},
"tags": [
"Lightning"
]
},
"post": {
"operationId": "ConnectPeer",
"responses": {
"200": {
"description": "",
"schema": {
"$ref": "#/definitions/lnrpcConnectPeerResponse"
}
}
},
"parameters": [
{
"name": "body",
"in": "body",
"required": true,
"schema": {
"$ref": "#/definitions/lnrpcConnectPeerRequest"
}
}
],
"tags": [
"Lightning"
]
}
},
"/v1/transactions": {
"get": {
"operationId": "GetTransactions",
"responses": {
"200": {
"description": "",
"schema": {
"$ref": "#/definitions/lnrpcTransactionDetails"
}
}
},
"tags": [
"Lightning"
]
},
"post": {
"operationId": "SendCoins",
"responses": {
"200": {
"description": "",
"schema": {
"$ref": "#/definitions/lnrpcSendCoinsResponse"
}
}
},
"parameters": [
{
"name": "body",
"in": "body",
"required": true,
"schema": {
"$ref": "#/definitions/lnrpcSendCoinsRequest"
}
}
],
"tags": [
"Lightning"
]
}
}
},
"definitions": {
"PendingChannelResponsePendingChannel": {
"type": "object",
"properties": {
"capacity": {
"type": "string",
"format": "int64"
},
"channel_point": {
"type": "string",
"format": "string"
},
"closing_txid": {
"type": "string",
"format": "string"
},
"lightning_id": {
"type": "string",
"format": "string"
},
"local_balance": {
"type": "string",
"format": "int64"
},
"peer_id": {
"type": "integer",
"format": "int32"
},
"remote_balance": {
"type": "string",
"format": "int64"
},
"status": {
"$ref": "#/definitions/lnrpcChannelStatus"
}
}
},
"lnrpcActiveChannel": {
"type": "object",
"properties": {
"capacity": {
"type": "string",
"format": "int64"
},
"channel_point": {
"type": "string",
"format": "string"
},
"local_balance": {
"type": "string",
"format": "int64"
},
"num_updates": {
"type": "string",
"format": "uint64"
},
"pending_htlcs": {
"type": "array",
"items": {
"$ref": "#/definitions/lnrpcHTLC"
}
},
"remote_balance": {
"type": "string",
"format": "int64"
},
"remote_pubkey": {
"type": "string",
"format": "string"
},
"unsettled_balance": {
"type": "string",
"format": "int64"
}
}
},
"lnrpcAddInvoiceResponse": {
"type": "object",
"properties": {
"r_hash": {
"type": "string",
"format": "byte"
}
}
},
"lnrpcChannelBalanceRequest": {
"type": "object"
},
"lnrpcChannelBalanceResponse": {
"type": "object",
"properties": {
"balance": {
"type": "string",
"format": "int64"
}
}
},
"lnrpcChannelCloseUpdate": {
"type": "object",
"properties": {
"closing_txid": {
"type": "string",
"format": "byte"
},
"success": {
"type": "boolean",
"format": "boolean"
}
}
},
"lnrpcChannelOpenUpdate": {
"type": "object",
"properties": {
"channel_point": {
"$ref": "#/definitions/lnrpcChannelPoint"
}
}
},
"lnrpcChannelPoint": {
"type": "object",
"properties": {
"funding_txid": {
"type": "string",
"format": "byte"
},
"funding_txid_str": {
"type": "string",
"format": "string"
},
"output_index": {
"type": "integer",
"format": "int64"
}
}
},
"lnrpcChannelStatus": {
"type": "string",
"enum": [
"ALL",
"OPENING",
"CLOSING"
],
"default": "ALL"
},
"lnrpcCloseChannelRequest": {
"type": "object",
"properties": {
"channel_point": {
"$ref": "#/definitions/lnrpcChannelPoint"
},
"force": {
"type": "boolean",
"format": "boolean"
},
"time_limit": {
"type": "string",
"format": "int64"
}
}
},
"lnrpcCloseStatusUpdate": {
"type": "object",
"properties": {
"chan_close": {
"$ref": "#/definitions/lnrpcChannelCloseUpdate"
},
"close_pending": {
"$ref": "#/definitions/lnrpcPendingUpdate"
},
"confirmation": {
"$ref": "#/definitions/lnrpcConfirmationUpdate"
}
}
},
"lnrpcConfirmationUpdate": {
"type": "object",
"properties": {
"block_height": {
"type": "integer",
"format": "int32"
},
"block_sha": {
"type": "string",
"format": "byte"
},
"num_confs_left": {
"type": "integer",
"format": "int64"
}
}
},
"lnrpcConnectPeerRequest": {
"type": "object",
"properties": {
"addr": {
"$ref": "#/definitions/lnrpcLightningAddress"
}
}
},
"lnrpcConnectPeerResponse": {
"type": "object",
"properties": {
"peer_id": {
"type": "integer",
"format": "int32"
}
}
},
"lnrpcGetInfoRequest": {
"type": "object"
},
"lnrpcGetInfoResponse": {
"type": "object",
"properties": {
"identity_address": {
"type": "string",
"format": "string"
},
"identity_pubkey": {
"type": "string",
"format": "string"
},
"lightning_id": {
"type": "string",
"format": "string"
},
"num_active_channels": {
"type": "integer",
"format": "int64"
},
"num_peers": {
"type": "integer",
"format": "int64"
},
"num_pending_channels": {
"type": "integer",
"format": "int64"
}
}
},
"lnrpcGetTransactionsRequest": {
"type": "object"
},
"lnrpcHTLC": {
"type": "object",
"properties": {
"amount": {
"type": "string",
"format": "int64"
},
"expiration_height": {
"type": "integer",
"format": "int64"
},
"hash_lock": {
"type": "string",
"format": "byte"
},
"incoming": {
"type": "boolean",
"format": "boolean"
},
"revocation_delay": {
"type": "integer",
"format": "int64"
}
}
},
"lnrpcInvoice": {
"type": "object",
"properties": {
"memo": {
"type": "string",
"format": "string"
},
"r_hash": {
"type": "string",
"format": "byte"
},
"r_preimage": {
"type": "string",
"format": "byte"
},
"receipt": {
"type": "string",
"format": "byte"
},
"settled": {
"type": "boolean",
"format": "boolean"
},
"value": {
"type": "string",
"format": "int64"
}
}
},
"lnrpcInvoiceSubscription": {
"type": "object"
},
"lnrpcLightningAddress": {
"type": "object",
"properties": {
"host": {
"type": "string",
"format": "string"
},
"pubKeyHash": {
"type": "string",
"format": "string"
}
}
},
"lnrpcListChannelsRequest": {
"type": "object"
},
"lnrpcListChannelsResponse": {
"type": "object",
"properties": {
"channels": {
"type": "array",
"items": {
"$ref": "#/definitions/lnrpcActiveChannel"
}
}
}
},
"lnrpcListInvoiceRequest": {
"type": "object",
"properties": {
"pending_only": {
"type": "boolean",
"format": "boolean"
}
}
},
"lnrpcListInvoiceResponse": {
"type": "object",
"properties": {
"invoices": {
"type": "array",
"items": {
"$ref": "#/definitions/lnrpcInvoice"
}
}
}
},
"lnrpcListPeersRequest": {
"type": "object"
},
"lnrpcListPeersResponse": {
"type": "object",
"properties": {
"peers": {
"type": "array",
"items": {
"$ref": "#/definitions/lnrpcPeer"
}
}
}
},
"lnrpcNewAddressResponse": {
"type": "object",
"properties": {
"address": {
"type": "string",
"format": "string"
}
}
},
"lnrpcNewWitnessAddressRequest": {
"type": "object"
},
"lnrpcOpenChannelRequest": {
"type": "object",
"properties": {
"commission_size": {
"type": "string",
"format": "int64"
},
"local_funding_amount": {
"type": "string",
"format": "int64"
},
"num_confs": {
"type": "integer",
"format": "int64"
},
"remote_funding_amount": {
"type": "string",
"format": "int64"
},
"target_node": {
"type": "string",
"format": "byte"
},
"target_peer_id": {
"type": "integer",
"format": "int32"
}
}
},
"lnrpcOpenStatusUpdate": {
"type": "object",
"properties": {
"chan_open": {
"$ref": "#/definitions/lnrpcChannelOpenUpdate"
},
"chan_pending": {
"$ref": "#/definitions/lnrpcPendingUpdate"
},
"confirmation": {
"$ref": "#/definitions/lnrpcConfirmationUpdate"
}
}
},
"lnrpcPaymentHash": {
"type": "object",
"properties": {
"r_hash": {
"type": "string",
"format": "byte"
},
"r_hash_str": {
"type": "string",
"format": "string"
}
}
},
"lnrpcPeer": {
"type": "object",
"properties": {
"address": {
"type": "string",
"format": "string"
},
"bytes_recv": {
"type": "string",
"format": "uint64"
},
"bytes_sent": {
"type": "string",
"format": "uint64"
},
"inbound": {
"type": "boolean",
"format": "boolean"
},
"lightning_id": {
"type": "string",
"format": "string"
},
"peer_id": {
"type": "integer",
"format": "int32"
},
"sat_recv": {
"type": "string",
"format": "int64"
},
"sat_sent": {
"type": "string",
"format": "int64"
}
}
},
"lnrpcPendingChannelRequest": {
"type": "object",
"properties": {
"status": {
"$ref": "#/definitions/lnrpcChannelStatus"
}
}
},
"lnrpcPendingChannelResponse": {
"type": "object",
"properties": {
"pending_channels": {
"type": "array",
"items": {
"$ref": "#/definitions/PendingChannelResponsePendingChannel"
}
}
}
},
"lnrpcPendingUpdate": {
"type": "object",
"properties": {
"txid": {
"type": "string",
"format": "byte"
}
}
},
"lnrpcSendCoinsRequest": {
"type": "object",
"properties": {
"addr": {
"type": "string",
"format": "string"
},
"amount": {
"type": "string",
"format": "int64"
}
}
},
"lnrpcSendCoinsResponse": {
"type": "object",
"properties": {
"txid": {
"type": "string",
"format": "string"
}
}
},
"lnrpcSendRequest": {
"type": "object",
"properties": {
"amt": {
"type": "string",
"format": "int64"
},
"dest": {
"type": "string",
"format": "byte"
},
"fast_send": {
"type": "boolean",
"format": "boolean"
},
"payment_hash": {
"type": "string",
"format": "byte"
}
}
},
"lnrpcSendResponse": {
"type": "object"
},
"lnrpcTransaction": {
"type": "object",
"properties": {
"amount": {
"type": "number",
"format": "double"
},
"block_hash": {
"type": "string",
"format": "string"
},
"block_height": {
"type": "integer",
"format": "int32"
},
"num_confirmations": {
"type": "integer",
"format": "int32"
},
"time_stamp": {
"type": "string",
"format": "int64"
},
"total_fees": {
"type": "string",
"format": "int64"
},
"tx_hash": {
"type": "string",
"format": "string"
}
}
},
"lnrpcTransactionDetails": {
"type": "object",
"properties": {
"transactions": {
"type": "array",
"items": {
"$ref": "#/definitions/lnrpcTransaction"
}
}
}
},
"lnrpcWalletBalanceRequest": {
"type": "object",
"properties": {
"witness_only": {
"type": "boolean",
"format": "boolean"
}
}
},
"lnrpcWalletBalanceResponse": {
"type": "object",
"properties": {
"balance": {
"type": "number",
"format": "double"
}
}
}
}
}