Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func FeeReserve ¶
Types ¶
type Client ¶
type Client interface { InvoiceStatus(paymentHash string) (Payment, error) // InvoiceStatus should return Payment information for a payment hash Pay(paymentRequest string) (Invoice, error) // Pay should pay the payment request. CreateInvoice(amount int64, memo string) (Invoice, error) // CreateInvoice should create an invoice for given amount and memo }
Client should be able to perform lightning services
type Configuration ¶
type Configuration struct { Lightning struct { Enabled bool `json:"enabled" yaml:"enabled"` Lnbits *LnbitsConfig `json:"lnbits" yaml:"lnbits"` } `json:"lightning" json:"lightning"` }
Configuration for lnbits
var Config Configuration
type Invoice ¶
type Invoice interface { cashuLog.Loggable fmt.Stringer // toJson SetHash(h string) // set the payment hash GetHash() string // get the payment hash SetPaid(i bool) // SetPaid to true, if lightning invoice was paid SetIssued(i bool) // SetIssued to true, if lightning invoice was paid IsIssued() bool // IsIssued returns true, if lightning invoice is paid SetAmount(a int64) // SetAmount of the lightning invoice GetAmount() int64 // GetAmount of the lightning invoice GetPaymentRequest() string // GetPaymentRequest should return the payment request (probably bech encoded) SetPaymentRequest(string) // SetPaymentRequest SetTimeCreated(t time.Time) SetTimePaid(t time.Time) }
Invoice should create a lightning invoice somewhere.
type LnbitsConfig ¶
Click to show internal directories.
Click to hide internal directories.