gct

package
v1.0.14 Latest Latest
Warning

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

Go to latest
Published: May 30, 2024 License: MIT Imports: 20 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// ErrParameterConvertFailed error to return when type conversion fails
	ErrParameterConvertFailed = "%v failed conversion"
	// ErrEmptyParameter error to return when empty parameter is received
	ErrEmptyParameter = "received empty parameter for %v"
)

Variables

View Source
var Modules = map[string]map[string]objects.Object{
	"exchange": exchangeModule,
	"common":   commonModule,
	"global":   globalModules,
}

Modules map of all loadable modules

View Source
var OutputDir string

OutputDir is the default script output directory

Functions

func AllModuleNames

func AllModuleNames() []string

AllModuleNames returns a list of all default module names.

func ExchangeAccountInfo

func ExchangeAccountInfo(args ...objects.Object) (objects.Object, error)

ExchangeAccountInfo returns account information for requested exchange

func ExchangeDepositAddress

func ExchangeDepositAddress(args ...objects.Object) (objects.Object, error)

ExchangeDepositAddress returns deposit address (if supported by exchange)

func ExchangeExchanges

func ExchangeExchanges(args ...objects.Object) (objects.Object, error)

ExchangeExchanges returns list of exchanges either enabled or all

func ExchangeOrderCancel

func ExchangeOrderCancel(args ...objects.Object) (objects.Object, error)

ExchangeOrderCancel cancels order on requested exchange

func ExchangeOrderQuery

func ExchangeOrderQuery(args ...objects.Object) (objects.Object, error)

ExchangeOrderQuery query order on exchange

func ExchangeOrderSubmit

func ExchangeOrderSubmit(args ...objects.Object) (objects.Object, error)

ExchangeOrderSubmit submit order on exchange

func ExchangeOrderbook

func ExchangeOrderbook(args ...objects.Object) (objects.Object, error)

ExchangeOrderbook returns orderbook for requested exchange & currencypair

func ExchangePairs

func ExchangePairs(args ...objects.Object) (objects.Object, error)

ExchangePairs returns currency pairs for requested exchange

func ExchangeTicker

func ExchangeTicker(args ...objects.Object) (objects.Object, error)

ExchangeTicker returns ticker data for requested exchange and currency pair

func ExchangeWithdrawCrypto

func ExchangeWithdrawCrypto(args ...objects.Object) (objects.Object, error)

ExchangeWithdrawCrypto submit request to withdraw crypto assets

func ExchangeWithdrawFiat

func ExchangeWithdrawFiat(args ...objects.Object) (objects.Object, error)

ExchangeWithdrawFiat submit request to withdraw fiat assets

func WriteAsCSV

func WriteAsCSV(args ...objects.Object) (objects.Object, error)

WriteAsCSV takes in a slice matrix to save to file

Types

type Context

type Context struct {
	objects.Map
}

Context defines a juncture for script context to go context awareness

func (*Context) TypeName

func (c *Context) TypeName() string

TypeName returns the name of the custom type.

type OHLCV

type OHLCV struct {
	objects.Map
}

OHLCV defines a custom Open High Low Close Volume tengo object

func (*OHLCV) TypeName

func (o *OHLCV) TypeName() string

TypeName returns the name of the custom type.

Jump to

Keyboard shortcuts

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