account

package
v0.0.0-...-cdfdfff Latest Latest
Warning

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

Go to latest
Published: Oct 4, 2022 License: MIT Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Position

type Position struct {
	Future string `json:"future"`
	Side   string `json:"side"`

	InitialMarginRequirement     float64 `json:"initialMarginRequirement"`
	MaintenanceMarginRequirement float64 `json:"maintenanceMarginRequirement"`

	EntryPrice                float64 `json:"entryPrice"`
	EstimatedLiquidationPrice float64 `json:"estimatedLiquidationPrice,omitempty"`

	Size           float64 `json:"size"`
	NetSize        float64 `json:"netSize"`
	OpenSize       float64 `json:"openSize"`
	LongOrderSize  float64 `json:"longOrderSize"`
	ShortOrderSize float64 `json:"shortOrderSize"`

	Cost          float64 `json:"cost"`
	UnrealizedPnl float64 `json:"unrealizedPnl"`
	RealizedPnl   float64 `json:"realizedPnl"`

	CollateralUsed         float64 `json:"collateralUsed,omitempty"`
	RecentAverageOpenPrice float64 `json:"recentAverageOpenPrice,omitempty"`
	RecentPnl              float64 `json:"recentPnl,omitempty"`
	RecentBreakEvenPrice   float64 `json:"recentBreakEvenPrice,omitempty"`
	CumulativeBuySize      float64 `json:"cumulativeBuySize,omitempty"`
	CumulativeSellSize     float64 `json:"cumulativeSellSize,omitempty"`
}

type RequestForInformation

type RequestForInformation struct {
}

func (*RequestForInformation) Method

func (req *RequestForInformation) Method() string

func (*RequestForInformation) Path

func (req *RequestForInformation) Path() string

func (*RequestForInformation) Payload

func (req *RequestForInformation) Payload() []byte

func (*RequestForInformation) Query

func (req *RequestForInformation) Query() string

type RequestForLeverage

type RequestForLeverage struct {
	Leverage int `json:"leverage"`
}

func (*RequestForLeverage) Method

func (req *RequestForLeverage) Method() string

func (*RequestForLeverage) Path

func (req *RequestForLeverage) Path() string

func (*RequestForLeverage) Payload

func (req *RequestForLeverage) Payload() []byte

func (*RequestForLeverage) Query

func (req *RequestForLeverage) Query() string

type RequestForPositions

type RequestForPositions struct {
	ShowAvgPrice bool `json:"showAvgPrice"`
}

func (*RequestForPositions) Method

func (req *RequestForPositions) Method() string

func (*RequestForPositions) Path

func (req *RequestForPositions) Path() string

func (*RequestForPositions) Payload

func (req *RequestForPositions) Payload() []byte

func (*RequestForPositions) Query

func (req *RequestForPositions) Query() string

type ResponseForInformation

type ResponseForInformation struct {
	Username string `json:"username"`

	Collateral               float64 `json:"collateral"`
	FreeCollateral           float64 `json:"freeCollateral"`
	TotalAccountValue        float64 `json:"totalAccountValue"`
	TotalPositionSize        float64 `json:"totalPositionSize"`
	InitialMarginRequirement float64 `json:"initialMarginRequirement"`
	Leverage                 float64 `json:"leverage"`

	MakerFee                     float64 `json:"makerFee"`
	TakerFee                     float64 `json:"takerFee"`
	MaintenanceMarginRequirement float64 `json:"maintenanceMarginRequirement"`

	MarginFraction     float64 `json:"marginFraction"`
	OpenMarginFraction float64 `json:"openMarginFraction"`

	Positions []Position `json:"positions"`

	BackstopProvider bool `json:"backstopProvider"`
	Liquidating      bool `json:"liquidating"`
}

type ResponseForLeverage

type ResponseForLeverage interface{}

type ResponseForPositions

type ResponseForPositions []Position

Jump to

Keyboard shortcuts

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