types

package
v1.0.1 Latest Latest
Warning

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

Go to latest
Published: Aug 18, 2024 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 CancelOrderRequest

type CancelOrderRequest struct {
	TradeID string
}

message to cancel a trade

type PriceOptions

type PriceOptions struct {
	Ticker string
	Token0 string
	Token1 string
	Chain  string
}

options when creating new price watcher

type PriceUpdate

type PriceUpdate struct {
	Ticker    string
	UpdatedAt time.Time
	Price     float64
}

price update from price watcher

type Subscribe

type Subscribe struct {
	Sendto *actor.PID
}

subscribe to price watcher

type TradeInfoRequest

type TradeInfoRequest struct {
	TradeID string
}

message sent to get trade info

type TradeInfoResponse

type TradeInfoResponse struct {
	// info regarding the current position
	// eg price, pnl, etc
	Foo   int
	Bar   int
	Price float64 // using float in example
}

response message for trade info

type TradeOrderRequest

type TradeOrderRequest struct {
	TradeID    string
	Token0     string
	Token1     string
	Chain      string
	Wallet     string
	PrivateKey string
	Expires    time.Time
}

message sent to create a new trade order

type TriggerPriceUpdate

type TriggerPriceUpdate struct{}

used with SendRepeat to trigger price update

type Unsubscribe

type Unsubscribe struct {
	Sendto *actor.PID
}

unsubscribe from price watcher

Jump to

Keyboard shortcuts

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