entity

package
v0.9.4 Latest Latest
Warning

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

Go to latest
Published: Nov 7, 2024 License: MIT Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Heartbeat

type Heartbeat struct {
	Type        string
	Sequence    int64
	LastTradeID int64
	ProductID   string
	Time        time.Time
}

Heartbeat model data of response from exchange

type Message

type Message struct {
	Ticker    *Ticker
	Order     *Order
	Heartbeat *Heartbeat
}

type Order

type Order struct {
	Type          string  `db:"type"`
	Timestamp     int64   `db:"timestamp"`
	ProductID     string  `db:"product_id"`
	OrderID       string  `db:"order_id"`
	Funds         float64 `db:"funds"`
	Side          string  `db:"side"`
	Size          float64 `db:"size"`
	Price         float64 `db:"price"`
	OrderType     string  `db:"order_type"`
	ClientOID     string  `db:"client_oid"`
	Sequence      int     `db:"sequence"`
	RemainingSize float64 `db:"remaining_size"`
	Reason        string  `db:"reason"`
	TradeID       int64   `db:"trade_id"`
	MakerOrderID  string  `db:"maker_order_id"`
	TakerOrderID  string  `db:"taker_order_id"`
}

Order model data of response from exchange

type Ticker

type Ticker struct {
	Timestamp int64
	Bid       float64
	Ask       float64
	Symbol    string
}

Ticker model data of response from exchange

Jump to

Keyboard shortcuts

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