bybit

package
v0.4.0 Latest Latest
Warning

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

Go to latest
Published: Mar 16, 2025 License: MIT Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AccountWallet

type AccountWallet struct {
	AccountIMRate          string  `json:"accountIMRate"`
	AccountLTV             string  `json:"accountLTV"`
	AccountMMRate          string  `json:"accountMMRate"`
	AccountType            string  `json:"accountType"`
	Coins                  []*Coin `json:"coin"`
	TotalAvailableBalance  string  `json:"totalAvailableBalance"`
	TotalEquity            string  `json:"totalEquity"`
	TotalInitialMargin     string  `json:"totalInitialMargin"`
	TotalMaintenanceMargin string  `json:"totalMaintenanceMargin"`
	TotalMarginBalance     string  `json:"totalMarginBalance"`
	TotalPerpUPL           string  `json:"totalPerpUPL"`
	TotalWalletBalance     string  `json:"totalWalletBalance"`
}

type AccountWalletResponse

type AccountWalletResponse struct {
	Lists []*AccountWallet `json:"list"`
}

type BybitClient

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

func NewBybitClient

func NewBybitClient(apiKey, apiSecret string) *BybitClient

func (*BybitClient) GetAccountWallets

func (c *BybitClient) GetAccountWallets(ctx context.Context) ([]*AccountWallet, error)

type Coin

type Coin struct {
	AccruedInterest     string `json:"accruedInterest"`
	AvailableToBorrow   string `json:"availableToBorrow"`
	AvailableToWithdraw string `json:"availableToWithdraw"`
	Bonus               string `json:"bonus"`
	BorrowAmount        string `json:"borrowAmount"`
	Coin                string `json:"coin"`
	CollateralSwitch    bool   `json:"collateralSwitch"`
	CumRealisedPnl      string `json:"cumRealisedPnl"`
	Equity              string `json:"equity"`
	Locked              string `json:"locked"`
	MarginCollateral    bool   `json:"marginCollateral"`
	SpotHedgingQty      string `json:"spotHedgingQty"`
	TotalOrderIM        string `json:"totalOrderIM"`
	TotalPositionIM     string `json:"totalPositionIM"`
	TotalPositionMM     string `json:"totalPositionMM"`
	UnrealisedPnl       string `json:"unrealisedPnl"`
	UsdValue            string `json:"usdValue"`
	WalletBalance       string `json:"walletBalance"`
}

type Plugin

type Plugin struct {
	BybitAPIKey    string `toml:"-" env:"BYBIT_API_KEY"`
	ByBitAPISecret string `toml:"-" env:"BYBIT_API_SECRET"`
	// contains filtered or unexported fields
}

func (*Plugin) Gather

func (p *Plugin) Gather(accumulator telegraf.Accumulator) error

func (*Plugin) Init

func (p *Plugin) Init() error

func (*Plugin) SampleConfig

func (p *Plugin) SampleConfig() string

Jump to

Keyboard shortcuts

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