Documentation
¶
Index ¶
- Constants
- func ContractValidateSplit(c string) ([]string, error)
- type APIClient
- func (c *APIClient) GetAccountBalance(principal string) (BalanceResponse, error)
- func (c *APIClient) GetAllTokens() ([]TokenResult, error)
- func (c *APIClient) GetContractDetails(contractID string) (ContractDetailsResponse, error)
- func (c *APIClient) GetContractReadOnly(id string, function string, responseType string, arguments []string) (string, error)
- func (c *APIClient) GetContractSource(id string) (string, error)
- func (c *APIClient) GetNFTHoldings(principal string) ([]NFTHoldingResponseResults, error)
- func (c *APIClient) GetTokenHolders(contractID string, block int) (ContractHoldersResponse, error)
- type Balance
- type BalanceResponse
- type ContractDetailsResponse
- type ContractHoldersResponse
- type ContractSourceResponse
- type FungibleTokens
- type NFTHoldingResponse
- type NFTHoldingResponseResults
- type NFTHoldingResponseResultsValue
- type NonFungibleTokens
- type ReadOnlyPayload
- type ReadOnlyResponse
- type Response
- type TokenResult
Constants ¶
View Source
const DefaultApiBase = "https://api.hiro.so"
Variables ¶
This section is empty.
Functions ¶
func ContractValidateSplit ¶
Types ¶
type APIClient ¶
func NewAPIClient ¶
func (*APIClient) GetAccountBalance ¶
func (c *APIClient) GetAccountBalance(principal string) (BalanceResponse, error)
func (*APIClient) GetAllTokens ¶
func (c *APIClient) GetAllTokens() ([]TokenResult, error)
func (*APIClient) GetContractDetails ¶
func (c *APIClient) GetContractDetails(contractID string) (ContractDetailsResponse, error)
func (*APIClient) GetContractReadOnly ¶
func (*APIClient) GetContractSource ¶
func (*APIClient) GetNFTHoldings ¶
func (c *APIClient) GetNFTHoldings(principal string) ([]NFTHoldingResponseResults, error)
func (*APIClient) GetTokenHolders ¶
func (c *APIClient) GetTokenHolders(contractID string, block int) (ContractHoldersResponse, error)
type BalanceResponse ¶
type BalanceResponse struct {
Stx Balance `json:"stx"`
FungibleTokens FungibleTokens `json:"fungible_tokens"`
NonFungibleTokens NonFungibleTokens `json:"non_fungible_tokens"`
}
type ContractDetailsResponse ¶
type ContractHoldersResponse ¶
type ContractSourceResponse ¶
type FungibleTokens ¶
type NFTHoldingResponse ¶
type NFTHoldingResponse struct {
Limit int `json:"limit"`
Offset int `json:"offset"`
Total int `json:"total"`
Results []NFTHoldingResponseResults `json:"results"`
}
type NFTHoldingResponseResults ¶
type NFTHoldingResponseResults struct {
AssetIdentifier string `json:"asset_identifier"`
Value NFTHoldingResponseResultsValue `json:"value"`
BlockHeight int `json:"block_height"`
TxID string `json:"tx_id"`
}
type NonFungibleTokens ¶
type ReadOnlyPayload ¶
type ReadOnlyResponse ¶
type Response ¶
type Response struct {
Limit int `json:"limit"`
Offset int `json:"offset"`
Total int `json:"total"`
Results []TokenResult `json:"results"`
}
type TokenResult ¶
type TokenResult struct {
Name string `json:"name"`
Symbol string `json:"symbol"`
Decimals int `json:"decimals"`
TotalSupply string `json:"total_supply"`
TokenURI string `json:"token_uri"`
Description string `json:"description"`
ImageURI string `json:"image_uri"`
ImageCanonicalURI string `json:"image_canonical_uri"`
TxID string `json:"tx_id"`
SenderAddress string `json:"sender_address"`
ContractPrincipal string `json:"contract_principal"`
}
Click to show internal directories.
Click to hide internal directories.