# Functions
BroadcastWebsocketMessage meow.
CheckCerts checks and verifies RPC server certificates.
GetCollatedExchangeAccountInfoByCoin collates individual exchange account information and turns it into a map string of exchange.AccountCurrencyInfo.
GetExchangeHighestPriceByCurrencyPair returns the exchange with the highest price for a given currency pair and asset type.
GetExchangeLowestPriceByCurrencyPair returns the exchange with the lowest price for a given currency pair and asset type.
GetRelatableCryptocurrencies returns a list of currency pairs if it can find any relatable currencies (e.g ETHBTC -> ETHLTC -> ETHUSDT -> ETHREP).
GetRelatableCurrencies returns a list of currency pairs if it can find any relatable currencies (e.g BTCUSD -> BTC USDT -> XBT USDT -> XBT USD) incOrig includes the supplied pair if desired.
GetRelatableFiatCurrencies returns a list of currency pairs if it can find any relatable currencies (e.g ETHUSD -> ETHAUD -> ETHGBP -> ETHJPY).
IsRelatablePairs checks to see if the two pairs are relatable.
New starts a new engine.
NewExchangeByNameWithDefaults returns a defaulted exchange by its name if it exists.
NewExchangeManager creates a new exchange manager.
NewFromSettings starts a new engine based on supplied settings.
NewSupportedExchangeByName helps create a new exchange to be loaded that is supported by GCT.
SetupCommunicationManager creates a communications manager.
SetupCurrencyStateManager applies configuration parameters before running.
SetupDatabaseConnectionManager creates a new database manager.
SetupDataHistoryManager creates a data history manager subsystem.
SetupDepositAddressManager returns a DepositAddressManager.
SetupOrderManager will boot up the OrderManager.
SetupSyncManager creates a new CurrencyPairSyncer.
SetupWithdrawManager creates a new withdraw manager.
StartRPCServer starts a gRPC server with TLS auth.
StartWebsocketHandler starts the websocket hub and routine which handles clients.
# Constants
Event const vars.
Event const vars.
Event const vars.
CommunicationsManagerName is an exported subsystem name.
Event const vars.
Event const vars.
Event const vars.
Event const vars.
Event const vars.
ConnectionManagerName is an exported subsystem name.
CurrencyStateManagementName defines the manager name string.
DatabaseConnectionManagerName is an exported subsystem name.
DefaultStateManagerDelay defines the default duration when the manager fetches and updates each exchange for its currency state.
Const vars for websocket.
Event const vars.
Event const vars.
MsgStatusError message to display when failure occurs.
MsgStatusOK message to display when status is "OK".
MsgStatusSuccess message to display when status is successful.
MsgSubSystemShutdown message to return when a subsystem has shutdown.
MsgSubSystemShuttingDown message to return when a subsystem is shutting down.
MsgSubSystemStarted message to return when subsystem has started.
MsgSubSystemStarting message to return when subsystem is starting up.
NTPManagerName is an exported subsystem name.
OrderManagerName is an exported subsystem name.
PortfolioManagerName is an exported subsystem name.
const holds the sync item types.
const holds the sync item types.
const holds the sync item types.
const holds the sync item types.
Const vars for websocket.
Const vars for websocket.
# Variables
Bot is a happy global engine to allow various areas of the application to access its setup services and functions.
vars related to the deposit address helpers.
vars related to the deposit address helpers.
vars related to exchange functions.
vars related to exchange functions.
vars related to exchange functions.
vars related to exchange functions.
ErrNilSubsystem is returned when a subsystem hasn't had its Setup() func run.
vars related to exchange functions.
ErrOrderIDCannotBeEmpty occurs when an order does not have an ID.
ErrOrderNotFound occurs when an order is not found in the orderstore.
ErrOrdersAlreadyExists occurs when the order already exists in the manager.
ErrSubSystemAlreadyStarted message to return when a subsystem is already started.
ErrSubSystemNotStarted message to return when subsystem not started.
ErrWebsocketServiceNotRunning occurs when a message is sent to be broadcast via websocket and its not running.
ErrWithdrawRequestNotFound message to display when no record is found.
vars related to events package.
PortfolioSleepDelay defines the default sleep time between portfolio manager runs.
# Structs
AllEnabledExchangeAccounts holds all enabled accounts info.
AllEnabledExchangeCurrencies holds the enabled exchange currencies.
AllEnabledExchangeOrderbooks holds the enabled exchange orderbooks.
CommunicationManager ensures operations of communications.
CoreSettings defines settings related to core engine operations.
CurrencyStateManager manages currency states.
DatabaseConnectionManager holds the database connection and its status.
DataHistoryJob used to gather candle/trade history and save to the database.
DataHistoryJobResult contains details on the result of a history request.
DataHistoryJobSummary is a human readable summary of the job for quickly understanding the status of a given job.
DataHistoryManager is responsible for synchronising, retrieving and saving candle and trade data from loaded jobs.
DepositAddressManager manages the exchange deposit address store.
EnabledExchangeCurrencies is a sub type for singular exchanges and respective currencies.
EnabledExchangeOrderbooks is a sub type for singular exchanges and respective orderbooks.
Engine contains configuration, portfolio manager, exchange & ticker data and is the overarching type across this code base.
Event struct holds the event variables.
EventConditionParams holds the event condition variables.
ExchangeManager manages what exchanges are loaded.
ExchangeSyncerSettings defines settings for the exchange pair synchronisation.
ExchangeTuningSettings defines settings related to an exchange.
ForexSettings defines settings related to the foreign exchange services.
GCTScriptSettings defines settings related to the GCTScript virtual machine.
OrderManager processes and stores orders across enabled exchanges.
OrderSubmitResponse contains the order response along with an internal order ID.
OrderUpsertResponse contains a copy of the resulting order details and a bool indicating if the order details were inserted (true) or updated (false).
Route is a sub type that holds the request routes.
RPCEndpoint stores an RPC endpoint status and addr.
RPCServer struct.
Settings stores engine params.
SyncManager stores the exchange currency pair syncer object.
WebsocketAuth is a struct used for.
WebsocketEvent is the struct used for websocket events.
WebsocketEventResponse is the struct used for websocket event responses.
WebsocketOrderbookTickerRequest is a struct used for ticker and orderbook requests.
WebsocketRoutineManager is used to process websocket updates from a unified location.
WithdrawManager is responsible for performing withdrawal requests and saving them to the database.
WithdrawSettings defines settings related to Withdrawing cryptocurrency.
# Interfaces
CustomExchangeBuilder interface allows external applications to create custom/unsupported exchanges that satisfy the IBotExchange interface.
# Type aliases
FlagSet defines set flags from command line args for comparison methods.
WebsocketDataHandler defines a function signature for a function that handles data coming from websocket connections.