lndclient

package
v0.0.0-...-12e863f Latest Latest
Warning

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

Go to latest
Published: Sep 5, 2018 License: AGPL-3.0 Imports: 14 Imported by: 0

Documentation

Index

Constants

View Source
const InvoiceExpiry = 3600
View Source
const InvoiceMemo = "Drawbridge Payment (v0)"

Variables

This section is empty.

Functions

This section is empty.

Types

type Client

type Client struct {
	// contains filtered or unexported fields
}

func NewClient

func NewClient(config *ClientConfig) (*Client, error)

func (*Client) AddInvoice

func (c *Client) AddInvoice(amount int64, preimage []byte) (*lnrpc.AddInvoiceResponse, error)

func (*Client) ChannelByCounterparty

func (c *Client) ChannelByCounterparty(pub *crypto.PublicKey) (*lnrpc.Channel, error)

func (*Client) ConnectPeer

func (c *Client) ConnectPeer(pubkey *crypto.PublicKey, host string) error

func (*Client) GetInfo

func (c *Client) GetInfo() (*lnrpc.GetInfoResponse, error)

func (*Client) HasPeer

func (c *Client) HasPeer(pubkey *crypto.PublicKey) (bool, error)

func (*Client) PayInvoice

func (c *Client) PayInvoice(paymentRequest string) (*lnrpc.SendResponse, error)

type ClientConfig

type ClientConfig struct {
	Host         string
	Port         string
	CertFile     string
	MacaroonFile string
	Context      context.Context
}

Jump to

Keyboard shortcuts

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