bifrosthelper

package
v1.4.554 Latest Latest
Warning

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

Go to latest
Published: Oct 31, 2024 License: GPL-2.0 Imports: 12 Imported by: 0

Documentation

Index

Constants

View Source
const (
	AssetAddressURI = "AssetRegistry:Assets"
	Blockchain      = "Bifrost"
	ExchangeName    = "Bifrost"
	GetAssetsPath   = "assets"
)
View Source
const (
	DefaultRefreshDelay              = 400 // millisec
	DefaultSleepBetweenContractCalls = 300 // millisec
	DefaultEventsLimit               = 100
	DefaultSwapContractsLimit        = 100
)

Variables

This section is empty.

Functions

This section is empty.

Types

type BifrostAssetMetadata

type BifrostAssetMetadata struct {
	AssetKey       string `json:"assetKey"`
	Name           string `json:"name"`
	Symbol         string `json:"symbol"`
	Decimals       string `json:"decimals"`
	MinimalBalance string `json:"minimalBalance"`
}

type BifrostClient

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

func NewBifrostClient

func NewBifrostClient(logger *logrus.Entry, sleepBetweenCalls time.Duration, isDebug bool) *BifrostClient

func (*BifrostClient) GetAllPoolAssets

func (c *BifrostClient) GetAllPoolAssets() ([]BifrostPoolMetadata, error)

func (*BifrostClient) GetAssetAllAssets

func (c *BifrostClient) GetAssetAllAssets() ([]BifrostAssetMetadata, error)

func (*BifrostClient) ScrapAssets

func (c *BifrostClient) ScrapAssets() ([]*dia.Asset, error)

type BifrostPoolMetadata

type BifrostPoolMetadata struct {
	PoolId         string            `json:"poolId"`
	PoolAsset      map[string]string `json:"poolAsset"`
	Assets         []string          `json:"assets"`
	Precisions     []string          `json:"precisions"`
	MintFee        string            `json:"mintFee"`
	SwapFee        string            `json:"swapFee"`
	RedeemFee      string            `json:"redeemFee"`
	TotalSupply    string            `json:"totalSupply"`
	Balances       []string          `json:"balances"`
	FeeRecipient   string            `json:"feeRecipient"`
	AccountId      string            `json:"accountId"`
	YieldRecipient string            `json:"yieldRecipient"`
	Precision      string            `json:"precision"`
}

Jump to

Keyboard shortcuts

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