invoicesrpc

package
v1.0.2 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 3, 2020 License: MIT Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func RegisterInvoicesServer

func RegisterInvoicesServer(s *grpc.Server, srv InvoicesServer)

Types

type AddHoldInvoiceRequest

type AddHoldInvoiceRequest struct {
	//*
	//An optional memo to attach along with the invoice. Used for record keeping
	//purposes for the invoice's creator, and will also be set in the description
	//field of the encoded payment request if the description_hash field is not
	//being used.
	Memo string `protobuf:"bytes,1,opt,name=memo,proto3" json:"memo,omitempty"`
	/// The hash of the preimage
	Hash []byte `protobuf:"bytes,2,opt,name=hash,proto3" json:"hash,omitempty"`
	//*
	//The value of this invoice in satoshis
	//
	//The fields value and value_msat are mutually exclusive.
	Value int64 `protobuf:"varint,3,opt,name=value,proto3" json:"value,omitempty"`
	//*
	//The value of this invoice in millisatoshis
	//
	//The fields value and value_msat are mutually exclusive.
	ValueMsat int64 `protobuf:"varint,10,opt,name=value_msat,json=valueMsat,proto3" json:"value_msat,omitempty"`
	//*
	//Hash (SHA-256) of a description of the payment. Used if the description of
	//payment (memo) is too long to naturally fit within the description field
	//of an encoded payment request.
	DescriptionHash []byte `protobuf:"bytes,4,opt,name=description_hash,json=descriptionHash,proto3" json:"description_hash,omitempty"`
	/// Payment request expiry time in seconds. Default is 3600 (1 hour).
	Expiry int64 `protobuf:"varint,5,opt,name=expiry,proto3" json:"expiry,omitempty"`
	/// Fallback on-chain address.
	FallbackAddr string `protobuf:"bytes,6,opt,name=fallback_addr,json=fallbackAddr,proto3" json:"fallback_addr,omitempty"`
	/// Delta to use for the time-lock of the CLTV extended to the final hop.
	CltvExpiry uint64 `protobuf:"varint,7,opt,name=cltv_expiry,json=cltvExpiry,proto3" json:"cltv_expiry,omitempty"`
	//*
	//Route hints that can each be individually used to assist in reaching the
	//invoice's destination.
	RouteHints []*lnrpc.RouteHint `protobuf:"bytes,8,rep,name=route_hints,json=routeHints,proto3" json:"route_hints,omitempty"`
	/// Whether this invoice should include routing hints for private channels.
	Private              bool     `protobuf:"varint,9,opt,name=private,proto3" json:"private,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*AddHoldInvoiceRequest) Descriptor

func (*AddHoldInvoiceRequest) Descriptor() ([]byte, []int)

func (*AddHoldInvoiceRequest) GetCltvExpiry

func (m *AddHoldInvoiceRequest) GetCltvExpiry() uint64

func (*AddHoldInvoiceRequest) GetDescriptionHash

func (m *AddHoldInvoiceRequest) GetDescriptionHash() []byte

func (*AddHoldInvoiceRequest) GetExpiry

func (m *AddHoldInvoiceRequest) GetExpiry() int64

func (*AddHoldInvoiceRequest) GetFallbackAddr

func (m *AddHoldInvoiceRequest) GetFallbackAddr() string

func (*AddHoldInvoiceRequest) GetHash

func (m *AddHoldInvoiceRequest) GetHash() []byte

func (*AddHoldInvoiceRequest) GetMemo

func (m *AddHoldInvoiceRequest) GetMemo() string

func (*AddHoldInvoiceRequest) GetPrivate

func (m *AddHoldInvoiceRequest) GetPrivate() bool

func (*AddHoldInvoiceRequest) GetRouteHints

func (m *AddHoldInvoiceRequest) GetRouteHints() []*lnrpc.RouteHint

func (*AddHoldInvoiceRequest) GetValue

func (m *AddHoldInvoiceRequest) GetValue() int64

func (*AddHoldInvoiceRequest) GetValueMsat

func (m *AddHoldInvoiceRequest) GetValueMsat() int64

func (*AddHoldInvoiceRequest) ProtoMessage

func (*AddHoldInvoiceRequest) ProtoMessage()

func (*AddHoldInvoiceRequest) Reset

func (m *AddHoldInvoiceRequest) Reset()

func (*AddHoldInvoiceRequest) String

func (m *AddHoldInvoiceRequest) String() string

func (*AddHoldInvoiceRequest) XXX_DiscardUnknown

func (m *AddHoldInvoiceRequest) XXX_DiscardUnknown()

func (*AddHoldInvoiceRequest) XXX_Marshal

func (m *AddHoldInvoiceRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*AddHoldInvoiceRequest) XXX_Merge

func (m *AddHoldInvoiceRequest) XXX_Merge(src proto.Message)

func (*AddHoldInvoiceRequest) XXX_Size

func (m *AddHoldInvoiceRequest) XXX_Size() int

func (*AddHoldInvoiceRequest) XXX_Unmarshal

func (m *AddHoldInvoiceRequest) XXX_Unmarshal(b []byte) error

type AddHoldInvoiceResp

type AddHoldInvoiceResp struct {
	//*
	//A bare-bones invoice for a payment within the Lightning Network.  With the
	//details of the invoice, the sender has all the data necessary to send a
	//payment to the recipient.
	PaymentRequest       string   `protobuf:"bytes,1,opt,name=payment_request,json=paymentRequest,proto3" json:"payment_request,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*AddHoldInvoiceResp) Descriptor

func (*AddHoldInvoiceResp) Descriptor() ([]byte, []int)

func (*AddHoldInvoiceResp) GetPaymentRequest

func (m *AddHoldInvoiceResp) GetPaymentRequest() string

func (*AddHoldInvoiceResp) ProtoMessage

func (*AddHoldInvoiceResp) ProtoMessage()

func (*AddHoldInvoiceResp) Reset

func (m *AddHoldInvoiceResp) Reset()

func (*AddHoldInvoiceResp) String

func (m *AddHoldInvoiceResp) String() string

func (*AddHoldInvoiceResp) XXX_DiscardUnknown

func (m *AddHoldInvoiceResp) XXX_DiscardUnknown()

func (*AddHoldInvoiceResp) XXX_Marshal

func (m *AddHoldInvoiceResp) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*AddHoldInvoiceResp) XXX_Merge

func (m *AddHoldInvoiceResp) XXX_Merge(src proto.Message)

func (*AddHoldInvoiceResp) XXX_Size

func (m *AddHoldInvoiceResp) XXX_Size() int

func (*AddHoldInvoiceResp) XXX_Unmarshal

func (m *AddHoldInvoiceResp) XXX_Unmarshal(b []byte) error

type CancelInvoiceMsg

type CancelInvoiceMsg struct {
	/// Hash corresponding to the (hold) invoice to cancel.
	PaymentHash          []byte   `protobuf:"bytes,1,opt,name=payment_hash,json=paymentHash,proto3" json:"payment_hash,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*CancelInvoiceMsg) Descriptor

func (*CancelInvoiceMsg) Descriptor() ([]byte, []int)

func (*CancelInvoiceMsg) GetPaymentHash

func (m *CancelInvoiceMsg) GetPaymentHash() []byte

func (*CancelInvoiceMsg) ProtoMessage

func (*CancelInvoiceMsg) ProtoMessage()

func (*CancelInvoiceMsg) Reset

func (m *CancelInvoiceMsg) Reset()

func (*CancelInvoiceMsg) String

func (m *CancelInvoiceMsg) String() string

func (*CancelInvoiceMsg) XXX_DiscardUnknown

func (m *CancelInvoiceMsg) XXX_DiscardUnknown()

func (*CancelInvoiceMsg) XXX_Marshal

func (m *CancelInvoiceMsg) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*CancelInvoiceMsg) XXX_Merge

func (m *CancelInvoiceMsg) XXX_Merge(src proto.Message)

func (*CancelInvoiceMsg) XXX_Size

func (m *CancelInvoiceMsg) XXX_Size() int

func (*CancelInvoiceMsg) XXX_Unmarshal

func (m *CancelInvoiceMsg) XXX_Unmarshal(b []byte) error

type CancelInvoiceResp

type CancelInvoiceResp struct {
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*CancelInvoiceResp) Descriptor

func (*CancelInvoiceResp) Descriptor() ([]byte, []int)

func (*CancelInvoiceResp) ProtoMessage

func (*CancelInvoiceResp) ProtoMessage()

func (*CancelInvoiceResp) Reset

func (m *CancelInvoiceResp) Reset()

func (*CancelInvoiceResp) String

func (m *CancelInvoiceResp) String() string

func (*CancelInvoiceResp) XXX_DiscardUnknown

func (m *CancelInvoiceResp) XXX_DiscardUnknown()

func (*CancelInvoiceResp) XXX_Marshal

func (m *CancelInvoiceResp) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*CancelInvoiceResp) XXX_Merge

func (m *CancelInvoiceResp) XXX_Merge(src proto.Message)

func (*CancelInvoiceResp) XXX_Size

func (m *CancelInvoiceResp) XXX_Size() int

func (*CancelInvoiceResp) XXX_Unmarshal

func (m *CancelInvoiceResp) XXX_Unmarshal(b []byte) error

type InvoicesClient

type InvoicesClient interface {
	//*
	//SubscribeSingleInvoice returns a uni-directional stream (server -> client)
	//to notify the client of state transitions of the specified invoice.
	//Initially the current invoice state is always sent out.
	SubscribeSingleInvoice(ctx context.Context, in *SubscribeSingleInvoiceRequest, opts ...grpc.CallOption) (Invoices_SubscribeSingleInvoiceClient, error)
	//*
	//CancelInvoice cancels a currently open invoice. If the invoice is already
	//canceled, this call will succeed. If the invoice is already settled, it will
	//fail.
	CancelInvoice(ctx context.Context, in *CancelInvoiceMsg, opts ...grpc.CallOption) (*CancelInvoiceResp, error)
	//*
	//AddHoldInvoice creates a hold invoice. It ties the invoice to the hash
	//supplied in the request.
	AddHoldInvoice(ctx context.Context, in *AddHoldInvoiceRequest, opts ...grpc.CallOption) (*AddHoldInvoiceResp, error)
	//*
	//SettleInvoice settles an accepted invoice. If the invoice is already
	//settled, this call will succeed.
	SettleInvoice(ctx context.Context, in *SettleInvoiceMsg, opts ...grpc.CallOption) (*SettleInvoiceResp, error)
}

InvoicesClient is the client API for Invoices service.

For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.

func NewInvoicesClient

func NewInvoicesClient(cc grpc.ClientConnInterface) InvoicesClient

type InvoicesServer

type InvoicesServer interface {
	//*
	//SubscribeSingleInvoice returns a uni-directional stream (server -> client)
	//to notify the client of state transitions of the specified invoice.
	//Initially the current invoice state is always sent out.
	SubscribeSingleInvoice(*SubscribeSingleInvoiceRequest, Invoices_SubscribeSingleInvoiceServer) error
	//*
	//CancelInvoice cancels a currently open invoice. If the invoice is already
	//canceled, this call will succeed. If the invoice is already settled, it will
	//fail.
	CancelInvoice(context.Context, *CancelInvoiceMsg) (*CancelInvoiceResp, error)
	//*
	//AddHoldInvoice creates a hold invoice. It ties the invoice to the hash
	//supplied in the request.
	AddHoldInvoice(context.Context, *AddHoldInvoiceRequest) (*AddHoldInvoiceResp, error)
	//*
	//SettleInvoice settles an accepted invoice. If the invoice is already
	//settled, this call will succeed.
	SettleInvoice(context.Context, *SettleInvoiceMsg) (*SettleInvoiceResp, error)
}

InvoicesServer is the server API for Invoices service.

type Invoices_SubscribeSingleInvoiceClient

type Invoices_SubscribeSingleInvoiceClient interface {
	Recv() (*lnrpc.Invoice, error)
	grpc.ClientStream
}

type Invoices_SubscribeSingleInvoiceServer

type Invoices_SubscribeSingleInvoiceServer interface {
	Send(*lnrpc.Invoice) error
	grpc.ServerStream
}

type SettleInvoiceMsg

type SettleInvoiceMsg struct {
	/// Externally discovered pre-image that should be used to settle the hold
	/// invoice.
	Preimage             []byte   `protobuf:"bytes,1,opt,name=preimage,proto3" json:"preimage,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*SettleInvoiceMsg) Descriptor

func (*SettleInvoiceMsg) Descriptor() ([]byte, []int)

func (*SettleInvoiceMsg) GetPreimage

func (m *SettleInvoiceMsg) GetPreimage() []byte

func (*SettleInvoiceMsg) ProtoMessage

func (*SettleInvoiceMsg) ProtoMessage()

func (*SettleInvoiceMsg) Reset

func (m *SettleInvoiceMsg) Reset()

func (*SettleInvoiceMsg) String

func (m *SettleInvoiceMsg) String() string

func (*SettleInvoiceMsg) XXX_DiscardUnknown

func (m *SettleInvoiceMsg) XXX_DiscardUnknown()

func (*SettleInvoiceMsg) XXX_Marshal

func (m *SettleInvoiceMsg) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*SettleInvoiceMsg) XXX_Merge

func (m *SettleInvoiceMsg) XXX_Merge(src proto.Message)

func (*SettleInvoiceMsg) XXX_Size

func (m *SettleInvoiceMsg) XXX_Size() int

func (*SettleInvoiceMsg) XXX_Unmarshal

func (m *SettleInvoiceMsg) XXX_Unmarshal(b []byte) error

type SettleInvoiceResp

type SettleInvoiceResp struct {
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*SettleInvoiceResp) Descriptor

func (*SettleInvoiceResp) Descriptor() ([]byte, []int)

func (*SettleInvoiceResp) ProtoMessage

func (*SettleInvoiceResp) ProtoMessage()

func (*SettleInvoiceResp) Reset

func (m *SettleInvoiceResp) Reset()

func (*SettleInvoiceResp) String

func (m *SettleInvoiceResp) String() string

func (*SettleInvoiceResp) XXX_DiscardUnknown

func (m *SettleInvoiceResp) XXX_DiscardUnknown()

func (*SettleInvoiceResp) XXX_Marshal

func (m *SettleInvoiceResp) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*SettleInvoiceResp) XXX_Merge

func (m *SettleInvoiceResp) XXX_Merge(src proto.Message)

func (*SettleInvoiceResp) XXX_Size

func (m *SettleInvoiceResp) XXX_Size() int

func (*SettleInvoiceResp) XXX_Unmarshal

func (m *SettleInvoiceResp) XXX_Unmarshal(b []byte) error

type SubscribeSingleInvoiceRequest

type SubscribeSingleInvoiceRequest struct {
	/// Hash corresponding to the (hold) invoice to subscribe to.
	RHash                []byte   `protobuf:"bytes,2,opt,name=r_hash,json=rHash,proto3" json:"r_hash,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*SubscribeSingleInvoiceRequest) Descriptor

func (*SubscribeSingleInvoiceRequest) Descriptor() ([]byte, []int)

func (*SubscribeSingleInvoiceRequest) GetRHash

func (m *SubscribeSingleInvoiceRequest) GetRHash() []byte

func (*SubscribeSingleInvoiceRequest) ProtoMessage

func (*SubscribeSingleInvoiceRequest) ProtoMessage()

func (*SubscribeSingleInvoiceRequest) Reset

func (m *SubscribeSingleInvoiceRequest) Reset()

func (*SubscribeSingleInvoiceRequest) String

func (*SubscribeSingleInvoiceRequest) XXX_DiscardUnknown

func (m *SubscribeSingleInvoiceRequest) XXX_DiscardUnknown()

func (*SubscribeSingleInvoiceRequest) XXX_Marshal

func (m *SubscribeSingleInvoiceRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*SubscribeSingleInvoiceRequest) XXX_Merge

func (m *SubscribeSingleInvoiceRequest) XXX_Merge(src proto.Message)

func (*SubscribeSingleInvoiceRequest) XXX_Size

func (m *SubscribeSingleInvoiceRequest) XXX_Size() int

func (*SubscribeSingleInvoiceRequest) XXX_Unmarshal

func (m *SubscribeSingleInvoiceRequest) XXX_Unmarshal(b []byte) error

type UnimplementedInvoicesServer

type UnimplementedInvoicesServer struct {
}

UnimplementedInvoicesServer can be embedded to have forward compatible implementations.

func (*UnimplementedInvoicesServer) AddHoldInvoice

func (*UnimplementedInvoicesServer) CancelInvoice

func (*UnimplementedInvoicesServer) SettleInvoice

func (*UnimplementedInvoicesServer) SubscribeSingleInvoice

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL