backends

package
v1.0.0-beta Latest Latest
Warning

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

Go to latest
Published: Mar 29, 2018 License: MIT Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func UseLogger

func UseLogger(logger logging.Logger)

Types

type Backend

type Backend interface {
	Connect() error

	// Amount in satoshis and expiry in seconds
	GetInvoice(description string, amount int64, expiry int64) (invoice string, err error)
}

type LND

type LND struct {
	GRPCHost     string `long:"grpchost" Description:"Host of the gRPC interface of LND"`
	CertFile     string `long:"certfile" Description:"TLS certificate for the LND gRPC and REST services"`
	MacaroonFile string `long:"macaroonfile" Description:"Admin macaroon file for authentication. Set to an empty string for no macaroon"`
	// contains filtered or unexported fields
}

func (*LND) Connect

func (lnd *LND) Connect() error

func (*LND) GetInvoice

func (lnd *LND) GetInvoice(message string, amount int64, expiry int64) (invoice string, err error)

func (*LND) SubscribeInvoices

func (lnd *LND) SubscribeInvoices(callback PublishInvoiceSettled, eventSrv *eventsource.Server) error

type PublishInvoiceSettled

type PublishInvoiceSettled func(invoice string, eventSrv *eventsource.Server)

For callbacks when an invoice gets settled

Jump to

Keyboard shortcuts

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