types

package
v0.0.0-...-1d71415 Latest Latest
Warning

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

Go to latest
Published: Mar 12, 2024 License: Apache-2.0 Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AccountInfo

type AccountInfo struct {
	MakerCommission  int    `json:"makerCommission"`
	TakerCommission  int    `json:"takerCommission"`
	BuyerCommission  int    `json:"buyerCommission"`
	SellerCommission int    `json:"sellerCommission"`
	CanTrade         bool   `json:"canTrade"`
	CanWithdraw      bool   `json:"canWithdraw"`
	CanDeposit       bool   `json:"canDeposit"`
	UpdateTime       int    `json:"updateTime"`
	AccountType      string `json:"accountType"`
	Balances         []struct {
		Asset  string `json:"asset"`
		Free   string `json:"free"`
		Locked string `json:"locked"`
	} `json:"balances"`
	Permissions []string `json:"permissions"`
}

type CreateOrderParam

type CreateOrderParam struct {
	Symbol        string   `url:"symbol"`
	Side          string   `url:"side"`                    // ENUM: Order Side
	Type          string   `url:"type"`                    // ENUM: Order Type
	Quantity      *float64 `url:"quantity,omitempty"`      // DECIMAL
	QuoteOrderQty *float64 `url:"quoteOrderQty,omitempty"` // DECIMAL
	Price         *float64 `url:"price,omitempty"`         // DECIMAL
}

type CreateOrderParams

type CreateOrderParams struct {
	CreateOrderParam
	utils.DefaultParam
}

type CreateOrderResp

type CreateOrderResp struct {
	Symbol       string `json:"symbol"`
	OrderID      string `json:"orderId"`
	OrderListId  int64  `json:"orderListId"`
	Price        string `json:"price"`
	OrigQty      string `json:"origQty"`
	Type         string `json:"type"`
	Side         string `json:"side"`
	TransactTime int64  `json:"transactTime"`
}

{"symbol":"USDCUSDT","orderId":"C01__379608025012453377","orderListId":-1,"price":"1.0505","origQty":"32.36","type":"MARKET","side":"BUY","transactTime":1706287841805}

type Order

type Order struct {
	Symbol              string `json:"symbol"`
	OrigClientOrderID   string `json:"origClientOrderId"`
	OrderID             string `json:"orderId"`
	ClientOrderID       string `json:"clientOrderId"`
	Price               string `json:"price"`
	OrigQty             string `json:"origQty"`
	ExecutedQty         string `json:"executedQty"`
	CummulativeQuoteQty string `json:"cummulativeQuoteQty"`
	Status              string `json:"status"`
	TimeInForce         string `json:"timeInForce"`
	Type                string `json:"type"`
	Side                string `json:"side"`
	StopPrice           string `json:"stopPrice"`
	Time                int64  `json:"time"`
	UpdateTime          int64  `json:"updateTime"`
	IsWorking           bool   `json:"isWorking"`
	OrigQuoteOrderQty   string `json:"origQuoteOrderQty"`
}

type QueryOrderParam

type QueryOrderParam struct {
	Symbol  string `url:"symbol"`
	OrderID string `url:"orderId"`
}

type QueryOrderParams

type QueryOrderParams struct {
	QueryOrderParam
	utils.DefaultParam
}

type TransferParam

type TransferParam struct {
	FromAccountType string `url:"fromAccountType" validate:"required,oneof=SPOT FUTURES"`
	ToAccountType   string `url:"toAccountType" validate:"required,oneof=SPOT FUTURES"`
	Asset           string `url:"asset" validate:"required"`
	Amount          string `url:"amount" validate:"required"`
}

type TransferParams

type TransferParams struct {
	TransferParam
	utils.DefaultParam
}

Jump to

Keyboard shortcuts

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