mercuryo

package
v1.1.0 Latest Latest
Warning

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

Go to latest
Published: Sep 19, 2024 License: MPL-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CommonChainIDToNetwork

func CommonChainIDToNetwork(chainID uint64) string

func NetworkToCommonChainID

func NetworkToCommonChainID(network string) uint64

Types

type Client

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

func NewClient

func NewClient() *Client

func (*Client) FetchCurrencies

func (c *Client) FetchCurrencies(ctx context.Context) ([]CryptoCurrency, error)

type Config

type Config struct {
	CryptoCurrencies []CryptoCurrency `json:"crypto_currencies"`
}

type CryptoCurrency

type CryptoCurrency struct {
	Symbol   string `json:"currency"`
	Network  string `json:"network"`
	Contract string `json:"contract"`
}

type CurrenciesData

type CurrenciesData struct {
	Config Config `json:"config"`
}

type CurrenciesResponse

type CurrenciesResponse struct {
	Data   CurrenciesData `json:"data"`
	Status int            `json:"status"`
}

type Token

type Token struct {
	Symbol   string `json:"symbol"`
	Address  string `json:"address"`
	Decimals uint   `json:"decimals"`
	Img      string `json:"img"`
	Network  int    `json:"network"`
}

Jump to

Keyboard shortcuts

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