mempool

package
v1.0.1 Latest Latest
Warning

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

Go to latest
Published: Dec 3, 2024 License: Apache-2.0 Imports: 13 Imported by: 0

Documentation

Index

Constants

View Source
const (
	ApiUrl         = "https://mempool.space/api"
	ApiUrlTestNet3 = "https://mempool.space/testnet/api"
	ApiUrlSignet   = "https://mempool.space/signet/api"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type MempoolClient

type MempoolClient struct {
	Net btcx.Net
	// contains filtered or unexported fields
}

func NewClient

func NewClient(net btcx.Net) *MempoolClient

func (*MempoolClient) BroadcastTx

func (c *MempoolClient) BroadcastTx(tx *wire.MsgTx) (*chainhash.Hash, error)

func (*MempoolClient) GetAddress

func (c *MempoolClient) GetAddress(addr string) (model.AddressInfo, error)

func (*MempoolClient) GetDifficultyAdjustment

func (c *MempoolClient) GetDifficultyAdjustment() (model.DifficultyAdjust, error)

func (*MempoolClient) GetHashedTransaction

func (c *MempoolClient) GetHashedTransaction(txHash *chainhash.Hash) (*wire.MsgTx, error)

func (*MempoolClient) GetPrices

func (c *MempoolClient) GetPrices() (model.Price, error)

func (*MempoolClient) GetRawTransaction

func (c *MempoolClient) GetRawTransaction(txHash *chainhash.Hash) (*wire.MsgTx, error)

func (*MempoolClient) ListTxs

func (c *MempoolClient) ListTxs(addr string, afterTxid string) ([]*wire.MsgTx, error)

ListTxs Get transaction history for the specified address/scripthash, sorted with newest first. Returns up to 50 mempool transactions plus the first 25 confirmed transactions. You can request more confirmed transactions using an after_txid query parameter.

func (*MempoolClient) ListTxsConfirmed

func (c *MempoolClient) ListTxsConfirmed(addr string, lastTxid string) ([]*wire.MsgTx, error)

ListTxsConfirmed get confirmed transaction history for the specified address/scripthash, sorted with newest first. Returns 25 transactions per page. More can be requested by specifying the last txid seen by the previous query.

func (*MempoolClient) ListTxsUnconfirmed

func (c *MempoolClient) ListTxsUnconfirmed(addr string) ([]*wire.MsgTx, error)

ListTxsUnconfirmed Get unconfirmed transaction history for the specified address/scripthash. Returns up to 50 transactions (no paging).

func (*MempoolClient) ListUnspent

func (c *MempoolClient) ListUnspent(addr string) ([]*btcx.UnspentOutput, error)

func (*MempoolClient) ValidAddress

func (c *MempoolClient) ValidAddress(addr string) (model.ValidAddress, error)

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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