Documentation ¶
Overview ¶
Known coins, pools, markets included with the binary. User doesn't need to specify the full type name for those.
Index ¶
Constants ¶
const HippoCoinRegistryUrl = "https://raw.githubusercontent.com/hippospace/aptos-coin-list/main/typescript/src/defaultList.mainnet.json"
HippoCoinRegistryUrl is the default url for mainnet coins
Variables ¶
This section is empty.
Functions ¶
func GetAllCoins ¶
func ReloadHippoCoinRegistry ¶
func ReloadHippoCoinRegistry(url string)
ReloadHippoCoinRegistry reloads the data from hippo registry for mainnet. Can use HippoCoinRegistryUrl for the url.
Types ¶
type HippoCoinRegistryEntry ¶
type HippoCoinRegistryEntry struct { Name string `json:"name"` Symbol string `json:"symbol"` OfficialSymbol string `json:"official_symbol"` CoingeckoId string `json:"coingecko_id"` Decimals uint8 `json:"decimals"` LogoUrl string `json:"logo_url"` ProjectUrl string `json:"project_url"` TokenType TokenType `json:"token_type"` }
HippoCoinRegistryEntry is the information contained in the hippo coin registry for mainnet, and it is in Hippo's github repo. It should come from HippoCoinRegistryUrl.
func GetCoinInfo ¶
func GetCoinInfo(network aptos.Network, typeTag *aptos.MoveStructTag) *HippoCoinRegistryEntry
GetCoinInfo returns the hippo coin registry information for a given type. If the coin is not in the registry, return nil.
func GetCoinInfoBySymbol ¶
func GetCoinInfoBySymbol(network aptos.Network, symbol string) *HippoCoinRegistryEntry
GetCoinInfo returns the hippo coin registry information for a symbol. If the coin is not in the registry, return nil.