webapi

package
v1.0.0 Latest Latest
Warning

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

Go to latest
Published: Mar 26, 2024 License: MIT Imports: 14 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GenerateQRCodePNG

func GenerateQRCodePNG(content string, size int, fg string, bg string) ([]byte, error)

func HttpStatusForError

func HttpStatusForError(code giga.ErrorCode) int

Types

type DecodeTxnRequest

type DecodeTxnRequest struct {
	Hex string `json:"hex"`
}

type ListInvoicesPublicResponse

type ListInvoicesPublicResponse struct {
	Items  []giga.PublicInvoice `json:"items"`
	Cursor int                  `json:"cursor"`
}

type PayToAddressRequest

type PayToAddressRequest struct {
	Amount      giga.CoinAmount `json:"amount"`
	PayTo       giga.Address    `json:"to"`
	ExplicitFee giga.CoinAmount `json:"explicit_fee"` // optional fee override (missing or zero: calculate the fee)
	MaxFee      giga.CoinAmount `json:"max_fee"`      // optional maximum fee (missing or zero: maximum is 1 DOGE)
	Pay         []giga.PayTo    `json:"pay"`          // either Pay, or Amount and PayTo.
}

type PayToAddressResponse

type PayToAddressResponse = giga.SendFundsResult

type WebAPI

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

WebAPI implements conductor.Service

func NewWebAPI

func NewWebAPI(config giga.Config, api giga.API) (WebAPI, error)

func (WebAPI) Run

func (t WebAPI) Run(started, stopped chan bool, stop chan context.Context) error

Jump to

Keyboard shortcuts

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