Documentation
¶
Index ¶
- type AddressBalanceNotification
- type AddressTransactionSubscriptionParams
- type AddressTxNotification
- type AddressTxUpdate
- type AddressTxUpdateEvent
- type Block
- type BlockEvent
- type BlockSubscriptionParams
- type Client
- func (c *Client) Close() error
- func (c *Client) SubscribeAddressTransactions(ctx context.Context, address string) (<-chan AddressTxUpdateEvent, error)
- func (c *Client) SubscribeBlocks(ctx context.Context) (<-chan BlockEvent, error)
- func (c *Client) SubscribeMempool(ctx context.Context) (<-chan MempoolEvent, error)
- type ContractCall
- type ContractLogEvent
- type ExecutionCost
- type FunctionArg
- type MempoolEvent
- type MempoolSubscriptionParams
- type MempoolTransaction
- type Microblock
- type NFTEvent
- type StacksEvent
- type StxTransfer
- type SubscriptionParams
- type Transaction
- type TransactionInfo
- type TxResult
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AddressTransactionSubscriptionParams ¶
type AddressTransactionSubscriptionParams struct {
Event string `json:"event"`
Address string `json:"address"`
}
func (AddressTransactionSubscriptionParams) GetEvent ¶
func (p AddressTransactionSubscriptionParams) GetEvent() string
type AddressTxNotification ¶
type AddressTxNotification struct {
Address string `json:"address"`
Transaction Transaction `json:"tx"`
}
type AddressTxUpdate ¶
type AddressTxUpdate struct {
Address string `json:"address"`
TxID string `json:"tx_id"`
TxStatus string `json:"tx_status"`
TxType string `json:"tx_type"`
Tx TransactionInfo `json:"tx"`
StxSent string `json:"stx_sent"`
StxReceived string `json:"stx_received"`
StxTransfers []StxTransfer `json:"stx_transfers"`
}
type AddressTxUpdateEvent ¶
type AddressTxUpdateEvent struct {
Method string `json:"method"`
Params AddressTxUpdate `json:"params"`
}
type Block ¶
type Block struct {
Hash string `json:"hash"`
BurnBlockHash string `json:"burn_block_hash"`
ParentBlockHash string `json:"parent_block_hash"`
Height int `json:"height"`
BurnBlockTime int `json:"burn_block_time"`
BlockTime int `json:"block_time"`
Canonical bool `json:"canonical"`
TenureHeight int `json:"tenure_height"`
IndexBlockHash string `json:"index_block_hash"`
ParentMicroblockHash string `json:"parent_microblock_hash"`
ParentMicroblockSequence int `json:"parent_microblock_sequence"`
Txs []string `json:"txs"`
MicroblocksAccepted []interface{} `json:"microblocks_accepted"`
MicroblocksStreamed []interface{} `json:"microblocks_streamed"`
ExecutionCostReadCount int `json:"execution_cost_read_count"`
ExecutionCostReadLength int `json:"execution_cost_read_length"`
ExecutionCostRuntime int `json:"execution_cost_runtime"`
ExecutionCostWriteCount int `json:"execution_cost_write_count"`
ExecutionCostWriteLength int `json:"execution_cost_write_length"`
MicroblockTxCount map[string]int `json:"microblock_tx_count"`
}
type BlockEvent ¶
type BlockSubscriptionParams ¶
type BlockSubscriptionParams struct {
Event string `json:"event"`
}
func (BlockSubscriptionParams) GetEvent ¶
func (p BlockSubscriptionParams) GetEvent() string
type Client ¶
type Client struct {
// contains filtered or unexported fields
}
func (*Client) SubscribeAddressTransactions ¶
func (*Client) SubscribeBlocks ¶
func (c *Client) SubscribeBlocks(ctx context.Context) (<-chan BlockEvent, error)
func (*Client) SubscribeMempool ¶
func (c *Client) SubscribeMempool(ctx context.Context) (<-chan MempoolEvent, error)
type ContractCall ¶
type ContractCall struct {
ContractID string `json:"contract_id"`
FunctionName string `json:"function_name"`
FunctionSignature string `json:"function_signature"`
FunctionArgs []FunctionArg `json:"function_args"`
}
type ContractLogEvent ¶
type ContractLogEvent struct {
ContractID string `json:"contract_id"`
Topic string `json:"topic"`
Value json.RawMessage `json:"value"`
}
type ExecutionCost ¶
type FunctionArg ¶
type MempoolEvent ¶
type MempoolSubscriptionParams ¶
type MempoolSubscriptionParams struct {
Event string `json:"event"`
}
func (MempoolSubscriptionParams) GetEvent ¶
func (p MempoolSubscriptionParams) GetEvent() string
type MempoolTransaction ¶
type Microblock ¶
type StacksEvent ¶
type StacksEvent struct {
Type string `json:"type"`
Value json.RawMessage `json:"value"`
}
type StxTransfer ¶
type SubscriptionParams ¶
type SubscriptionParams interface {
GetEvent() string
}
type Transaction ¶
type TransactionInfo ¶
type TransactionInfo struct {
TxID string `json:"tx_id"`
Nonce int `json:"nonce"`
FeeRate string `json:"fee_rate"`
SenderAddress string `json:"sender_address"`
Sponsored bool `json:"sponsored"`
PostConditionMode string `json:"post_condition_mode"`
PostConditions []interface{} `json:"post_conditions"`
AnchorMode string `json:"anchor_mode"`
IsUnanchored bool `json:"is_unanchored"`
BlockHash string `json:"block_hash"`
ParentBlockHash string `json:"parent_block_hash"`
BlockHeight int `json:"block_height"`
BlockTime int64 `json:"block_time"`
BlockTimeISO string `json:"block_time_iso"`
BurnBlockHeight int `json:"burn_block_height"`
BurnBlockTime int64 `json:"burn_block_time"`
BurnBlockTimeISO string `json:"burn_block_time_iso"`
Canonical bool `json:"canonical"`
TxIndex int `json:"tx_index"`
TxStatus string `json:"tx_status"`
TxResult TxResult `json:"tx_result"`
MicroblockHash string `json:"microblock_hash"`
MicroblockSequence int `json:"microblock_sequence"`
MicroblockCanonical bool `json:"microblock_canonical"`
EventCount int `json:"event_count"`
Events []StacksEvent `json:"events"`
ExecutionCost ExecutionCost `json:"execution_cost"`
TxType string `json:"tx_type"`
ContractCall *ContractCall `json:"contract_call,omitempty"`
}
Click to show internal directories.
Click to hide internal directories.