api

package
v0.0.0-...-7bd848a Latest Latest
Warning

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

Go to latest
Published: Aug 24, 2022 License: Apache-2.0 Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AddressItem

type AddressItem struct {
	UserID              int64  `json:"user_id"`
	UserRegisterAccount string `json:"user_register_account"`
	UserName            string `json:"user_name"`
	UserEnmail          string `json:"user_email"`
	Curency             int64  `json:"currency"`
	TokenAddress        string `json:"token_address"`
	WalletID            int64  `json:"wallet_id"`
	WalletAddress       string `json:"wallet_address"`
	BalanceInvalidated  bool   `json:"balance_invalidated"`
	Balance             string `json:"balance"`
	BalanceTime         int64  `json:"balance_time"`
	ChainID             int64  `json:"chain_id"`
	WalletName          string `json:"wallet_name,omitempty"`
}

type CommonResponse

type CommonResponse struct {
	Result int64 `json:"result"`
}

type CurrencyInfo

type CurrencyInfo struct {
	Currency             int64  `json:"currency"`
	CurrencyName         string `json:"currency_name"`
	TokenName            string `json:"token_name,omitempty"`
	TokenSymbol          string `json:"token_symbol,omitempty"`
	TokenContractAddress string `json:"token_contract_address,omitempty"`
	TokenDecimals        string `json:"token_decimals,omitempty"`
	TokenVersion         int64  `json:"token_version,omitempty"`
	ChainID              int64  `json:"chain_id"`
}

type CurrencyTransactionInfo

type CurrencyTransactionInfo struct {
	BlockNumber     int64  `json:"blockNumber"`
	ConfirmBlocks   int64  `json:"confirm_blocks"`
	BlockTimeStamp  int64  `json:"blockTimeStamp"`
	ContractAddress string `json:"contract_address"`
	Fee             string `json:"fee"`
	Result          string `json:"result"`
	Success         bool   `json:"success"`
	From            string `json:"from"`
	To              string `json:"to"`
	Amount          string `json:"amount"`
	Data            string `json:"data"`
	TXID            string `json:"txid"`
}

type ErrorCodeResponse

type ErrorCodeResponse struct {
	ErrMsg  string `json:"error,omitempty"`
	ErrCode int    `json:"error_code,omitempty"`
}

type GetCurrencyTransactionsRequest

type GetCurrencyTransactionsRequest struct {
	Currency      int64  `json:"currency"`
	Token         string `json:"token"`
	WalletAddress string `json:"wallet_address"`
	StartIndex    int64  `json:"start_index"`
	Limit         int64  `json:"limit"`
}

type GetCurrencyTransactionsResponse

type GetCurrencyTransactionsResponse struct {
	Transactions []CurrencyTransactionInfo `json:"transactions"`
	TotalCount   int64                     `json:"total_count"`
}

func GetCurrencyTransactions

func GetCurrencyTransactions(request GetCurrencyTransactionsRequest) (response *GetCurrencyTransactionsResponse, err error)

type GetTransactionInfoResponse

type GetTransactionInfoResponse struct {
	BlockNumber     int64  `json:"blockNumber"`
	ConfirmBlocks   int64  `json:"confirm_blocks"`
	BlockTimeStamp  int64  `json:"blockTimeStamp"`
	ContractAddress string `json:"contract_address"`
	Fee             string `json:"fee"`
	Id              string `json:"id"`
	ResMessage      string `json:"resMessage"`
	Result          string `json:"result"`
	Success         bool   `json:"success"`
	From            string `json:"from"`
	To              string `json:"to"`
	Amount          string `json:"amount"`
	Data            string `json:"data"`
}

type GetTransactionsInfoRequest

type GetTransactionsInfoRequest struct {
	Currency int64    `json:"currency"`
	TXIDs    []string `json:"txids"`
}

type GetTransactionsInfoResponse

type GetTransactionsInfoResponse struct {
	TransactionsInfo map[string]GetTransactionInfoResponse `json:"transactions_info"`
}

func GetTransactionInfo

func GetTransactionInfo(request *GetTransactionsInfoRequest) (response *GetTransactionsInfoResponse, err error)

type GetWalletBalanceResponse

type GetWalletBalanceResponse struct {
	Balance string `json:"balance"`
}

func GetWalletBalance

func GetWalletBalance(qs []string) (response *GetWalletBalanceResponse, err error)

type GetWalletsResponse

type GetWalletsResponse struct {
	Address    []*AddressItem `json:"addresses"`
	TotalCount int64          `json:"total_count,omitempty"`
}

func GetUserWalletList

func GetUserWalletList(qs []string) (response *GetWalletsResponse, err error)

func GetWallets

func GetWallets(qs []string) (response *GetWalletsResponse, err error)

type RefreshBalanceRequest

type RefreshBalanceRequest struct {
	Currency int64             `json:"currency"`
	Wallets  []WalletWithToken `json:"wallets"`
}

type RefreshBalanceResponse

type RefreshBalanceResponse struct {
	Currency         int64    `json:"currency"`
	SuccessCount     int      `json:"success_count"`
	UnmatchedWallets []string `json:"unmatched_wallets"`
}

func RefreshBalanceCache

func RefreshBalanceCache(request RefreshBalanceRequest) (response *RefreshBalanceResponse, err error)

type SupportedCurrenciesResponse

type SupportedCurrenciesResponse struct {
	Currenices []CurrencyInfo `json:"currencies"`
}

func GetSupportedCurrencies

func GetSupportedCurrencies() (response *SupportedCurrenciesResponse, err error)

type WalletWithToken

type WalletWithToken struct {
	TokenAddress  string `json:"token_address"`
	WalletAddress string `json:"wallet_address"`
}

Jump to

Keyboard shortcuts

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