Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Block ¶
type Block struct { Hash string `json:"hash,omitempty"` Header *struct { ParentHash string `json:"parentHash"` Sha3Uncles string `json:"sha3Uncles"` Miner string `json:"miner"` StateRoot string `json:"stateRoot"` TransactionsRoot string `json:"transactionsRoot"` ReceiptsRoot string `json:"receiptsRoot"` LogsBloom string `json:"logsBloom"` Difficulty string `json:"difficulty"` Number string `json:"number"` GasLimit string `json:"gasLimit"` GasUsed string `json:"gasUsed"` Timestamp string `json:"timestamp"` ExtraData string `json:"extraData"` MixHash string `json:"mixHash"` Nonce string `json:"nonce"` } `json:"header,omitempty"` Transactions []TxContents `json:"transactions,omitempty"` Uncles []interface{} `json:"uncles,omitempty"` }
bloXroute block
type EthOnBlockResponse ¶
type PairReserves ¶ added in v0.4.8
type PairReserves struct { Pair common.Address `json:"pair"` Reserve0 *big.Int `json:"reserve0"` Reserve1 *big.Int `json:"reserve1"` BlockTimestampLast uint32 `json:"block_timestamp_last"` BlockNumber int64 `json:"block_number"` }
func (*PairReserves) Hash ¶ added in v0.4.8
func (p *PairReserves) Hash() uint64
type SubscriptionResponse ¶
type SubscriptionResponse struct { Id int64 `json:"id"` Result string `json:"result"` // subscription ID is here JsonRPC string `json:"jsonrpc"` }
The first response after a subscription is sent.
type TokenBalance ¶ added in v0.4.8
type TokenBalance struct { Owner common.Address `json:"owner"` // Zero address means ETH/BNB Token common.Address `json:"token"` Balance *big.Int BlockNumber int64 `json:"block_number"` }
Token balance of a owner at given block number.
type Transaction ¶
type Transaction struct { LocalRegion bool `json:"localRegion,omitempty"` TxHash string `json:"txHash"` TxContents *TxContents `json:"txContents,omitempty"` RawTx string `json:"rawTx,omitempty"` }
type TxContents ¶
type TxContents struct { From string `json:"from"` Gas string `json:"gas"` GasPrice string `json:"gasPrice"` Hash string `json:"hash"` Input string `json:"input"` Nonce string `json:"nonce"` R string `json:"r"` S string `json:"s"` To string `json:"to"` Type string `json:"type"` V string `json:"v"` Value string `json:"value"` MaxFeePerGas string `json:"maxFeePerGas,omitempty"` MaxPriorityFeePerGas string `json:"maxPriorityFeePerGas,omitempty"` }
bloXroute tx
func (*TxContents) ToRaw ¶ added in v0.4.3
func (txContents *TxContents) ToRaw() ([]byte, error)
ToRaw converts a TxContents to its RLP encoded byte array.
type TxReceipt ¶
type TxReceipt struct { BlockHash string `json:"block_hash"` BlockNumber string `json:"block_number"` CumulativeGasUsed string `json:"cumulative_gas_used"` ContractAddress string `json:"contract_address,omitempty"` From string `json:"from"` GasUsed string `json:"gas_used"` Logs []struct { Address string `json:"address"` BlockNumber string `json:"blockNumber"` BlockHash string `json:"blockHash"` Data string `json:"data"` LogIndex string `json:"logIndex"` Removed bool `json:"removed"` Topics []string `json:"topics,omitempty"` TransactionHash string `json:"transactionHash"` TransactionIndex string `json:"transactionIndex"` } `json:"logs,omitempty"` LogsBloom string `json:"logs_bloom"` Status string `json:"status"` To string `json:"to,omitempty"` TransactionHash string `json:"transaction_hash"` TransactionIndex string `json:"transaction_index"` Type_ string `json:"type,omitempty"` }
type WebsocketMsg ¶
type WebsocketMsg[T any] struct { JsonRPC string `json:"jsonrpc"` Method string `json:"method"` Params struct { Result T `json:"result"` Subscription string `json:"subscription"` } `json:"params"` Error map[string]interface{} `json:"error,omitempty"` }
bloXroute websocket message
Click to show internal directories.
Click to hide internal directories.