mempool

package module
v0.0.0-...-95b2573 Latest Latest
Warning

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

Go to latest
Published: Feb 15, 2020 License: MIT Imports: 10 Imported by: 0

README

mempool

Go mempool watcher using blockstream.info

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Start

func Start(ctx context.Context, testnet bool, handler Handler)

Types

type Handler

type Handler = func(ctx context.Context, tx Transaction)

type Output

type Output struct {
	Address string         `json:"scriptpubkey_address"`
	Amount  btcutil.Amount `json:"value"`
}

type Transaction

type Transaction struct {
	ID      string         `json:"txid"`
	Outputs []Output       `json:"vout"`
	Fee     btcutil.Amount `json:"fee"`
}

func GetTx

func GetTx(ctx context.Context, testnet bool, txid string) (Transaction, error)

Jump to

Keyboard shortcuts

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