mirror_node

package
v1.4.1 Latest Latest
Warning

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

Go to latest
Published: Jun 5, 2023 License: Apache-2.0 Imports: 20 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	GetHbarPriceHeaders         = map[string]string{"Accepts": "application/json"}
	TransactionsGetHBARUsdPrice = "transactions?account.id=0.0.57&transactiontype=fileupdate&limit=1"
)

Functions

This section is empty.

Types

type Client

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

func NewClient

func NewClient(mirrorNode config.MirrorNode) *Client

func (Client) AccountExists

func (c Client) AccountExists(accountID hedera.AccountID) bool

func (Client) GetAccount added in v1.4.0

func (c Client) GetAccount(accountID string) (*account.AccountsResponse, error)

GetAccount retrieves an account entity by its id

func (Client) GetAccountCreditTransactionsAfterTimestamp

func (c Client) GetAccountCreditTransactionsAfterTimestamp(accountId hedera.AccountID, from int64) (*transaction.Response, error)

func (Client) GetAccountCreditTransactionsAfterTimestampString added in v1.4.0

func (c Client) GetAccountCreditTransactionsAfterTimestampString(accountId hedera.AccountID, from string) (*transaction.Response, error)

func (Client) GetAccountCreditTransactionsBetween

func (c Client) GetAccountCreditTransactionsBetween(accountId hedera.AccountID, from, to int64) ([]transaction.Transaction, error)

GetAccountCreditTransactionsBetween returns all incoming Transfers for the specified account between timestamp `from` and `to` excluded

func (Client) GetAccountDebitTransactionsAfterTimestampString added in v1.4.0

func (c Client) GetAccountDebitTransactionsAfterTimestampString(accountId hedera.AccountID, from string) (*transaction.Response, error)

func (Client) GetAccountTokenBurnTransactionsAfterTimestamp added in v1.4.0

func (c Client) GetAccountTokenBurnTransactionsAfterTimestamp(accountId hedera.AccountID, from int64) (*transaction.Response, error)

func (Client) GetAccountTokenBurnTransactionsAfterTimestampString added in v1.4.0

func (c Client) GetAccountTokenBurnTransactionsAfterTimestampString(accountId hedera.AccountID, from string) (*transaction.Response, error)

func (Client) GetAccountTokenMintTransactionsAfterTimestamp added in v1.4.0

func (c Client) GetAccountTokenMintTransactionsAfterTimestamp(accountId hedera.AccountID, from int64) (*transaction.Response, error)

func (Client) GetAccountTokenMintTransactionsAfterTimestampString added in v1.4.0

func (c Client) GetAccountTokenMintTransactionsAfterTimestampString(accountId hedera.AccountID, from string) (*transaction.Response, error)

func (Client) GetHBARUsdPrice added in v1.4.0

func (c Client) GetHBARUsdPrice() (price decimal.Decimal, err error)

func (Client) GetLatestMessages added in v1.4.0

func (c Client) GetLatestMessages(topicId hedera.TopicID, limit int64) ([]message.Message, error)

GetLatestMessages returns latest Topic messages

func (Client) GetMessageBySequenceNumber added in v1.4.0

func (c Client) GetMessageBySequenceNumber(topicId hedera.TopicID, sequenceNumber int64) (*message.Message, error)

GetMessageBySequenceNumber returns message from given topic with provided sequence number

func (Client) GetMessagesAfterTimestamp

func (c Client) GetMessagesAfterTimestamp(topicId hedera.TopicID, from int64, limit int64) ([]message.Message, error)

GetMessagesAfterTimestamp returns all Topic messages after the given timestamp

func (Client) GetMessagesForTopicBetween

func (c Client) GetMessagesForTopicBetween(topicId hedera.TopicID, from, to int64) ([]message.Message, error)

GetMessagesForTopicBetween returns all Topic messages for the specified topic between timestamp `from` and `to` excluded

func (Client) GetNft added in v1.4.0

func (c Client) GetNft(tokenID string, serialNum int64) (*transaction.Nft, error)

func (Client) GetNftTransactions added in v1.4.0

func (c Client) GetNftTransactions(tokenID string, serialNum int64) (transaction.NftTransactionsResponse, error)

GetNftTransactions returns the nft transactions for tokenID and serialNum

func (Client) GetSchedule added in v1.4.0

func (c Client) GetSchedule(scheduleID string) (*transaction.Schedule, error)

GetSchedule retrieves a schedule entity by its id

func (Client) GetScheduledTransaction added in v1.4.0

func (c Client) GetScheduledTransaction(transactionID string) (*transaction.Response, error)

GetScheduledTransaction gets the Scheduled transaction of an executed transaction

func (Client) GetStateProof

func (c Client) GetStateProof(transactionID string) ([]byte, error)

func (Client) GetSuccessfulTransaction added in v1.4.0

func (c Client) GetSuccessfulTransaction(transactionID string) (transaction.Transaction, error)

func (Client) GetToken added in v1.4.0

func (c Client) GetToken(tokenID string) (*token.TokenResponse, error)

GetToken retrieves a token entity by its id

func (Client) GetTransaction

func (c Client) GetTransaction(transactionID string) (*transaction.Response, error)

func (Client) GetTransactionsAfterTimestamp added in v1.4.0

func (c Client) GetTransactionsAfterTimestamp(accountId hedera.AccountID, startTimestamp int64, transactionType string) ([]transaction.Transaction, error)

func (Client) QueryDefaultLimit added in v1.4.0

func (c Client) QueryDefaultLimit() int64

QueryDefaultLimit returns the default records limit per query

func (Client) QueryMaxLimit added in v1.4.0

func (c Client) QueryMaxLimit() int64

QueryMaxLimit returns the maximum allowed limit per messages query

func (Client) TopicExists

func (c Client) TopicExists(topicID hedera.TopicID) bool

func (Client) WaitForScheduledTransaction added in v1.4.0

func (c Client) WaitForScheduledTransaction(txId string, onSuccess, onFailure func())

WaitForScheduledTransaction Polls the transaction at intervals. Depending on the result, the corresponding `onSuccess` and `onFailure` functions are called

func (Client) WaitForTransaction

func (c Client) WaitForTransaction(txId string, onSuccess, onFailure func())

WaitForTransaction Polls the transaction at intervals. Depending on the result, the corresponding `onSuccess` and `onFailure` functions are called

Directories

Path Synopsis
model

Jump to

Keyboard shortcuts

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