childorders

package
Version: v0.0.0-...-935a062 Latest Latest
Warning

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

Go to latest
Published: Oct 7, 2020 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

View Source
const (
	APIPath = "/v1/me/getchildorders"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Order

type Order struct {
	Id                     int64                    `json:"id"`
	ChildOrderId           string                   `json:"child_order_id"`
	ProductCode            markets.ProductCode      `json:"product_code"`
	Side                   sendchildorder.Side      `json:"side"`
	ChildOrderType         sendchildorder.OrderType `json:"child_order_type"`
	Price                  float64                  `json:"price"`
	AveragePrice           float64                  `json:"average_price"`
	Size                   float64                  `json:"size"`
	ChildOrderState        OrderState               `json:"child_order_state"`
	ExpireDate             time.Time                `json:"expire_date"`
	ChildOrderDate         time.Time                `json:"child_order_date"`
	ChildOrderAcceptanceId string                   `json:"child_order_acceptance_id"`
	OutstandingSize        float64                  `json:"outstanding_size"`
	CancelSize             float64                  `json:"cancel_size"`
	ExecutedSize           float64                  `json:"executed_size"`
	TotalCommission        float64                  `json:"total_commission"`
}

type OrderState

type OrderState string
const (
	Active    OrderState = "ACTIVE"
	Completed OrderState = "COMPLETED"
	Canceled  OrderState = "CANCELED"
	Expired   OrderState = "EXPIRED"
	Rejected  OrderState = "REJECTED"
)

type Request

type Request struct {
	ProductCode      markets.ProductCode `json:"product_code" url:"product_code"`
	types.Pagination `json:",inline"`
	ChildOrderState  OrderState `json:"child_order_state,omitempty" url:"child_order_state,omitempty"`
	ChildOrderId     string     `json:"child_order_id,omitempty" url:"child_order_id,omitempty"`
	ParentOrderId    string     `json:"parent_order_id,omitempty" url:"parent_order_id,omitempty"`
}

func (*Request) Method

func (req *Request) Method() string

func (*Request) Payload

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

func (*Request) Query

func (req *Request) Query() string

type Response

type Response []Order

Source Files

Jump to

Keyboard shortcuts

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