Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/Haehnchen/crypto-trading-bot
/ functions
Functions
500 in github.com/Haehnchen/crypto-trading-bot
⨍
Functions
500
◇
Types & classes
267
↓ 2 callers
Method
fetchBalances
(profile: Profile)
src/profile/profile_service.ts:82
↓ 2 callers
Function
fetchMarketData
(exchange: ccxt.Exchange, pair: string)
src/profile/profile_order_service.ts:9
↓ 2 callers
Method
fetchOpenPositions
* Fetch open swap/futures positions for a profile
src/profile/profile_service.ts:212
↓ 2 callers
Method
fetchRaw
(exchange: string, symbol: string, period: string)
src/modules/system/ccxt_candle_prefill_service.ts:90
↓ 2 callers
Method
formatStrategyName
* Format strategy name for display (convert snake_case to Title Case)
src/modules/strategy/v2/strategy_registry.ts:275
↓ 2 callers
Method
generateId
()
src/profile/profile_service.ts:25
↓ 2 callers
Method
getAllCcxtExchanges
()
src/controller/ccxt_exchanges_controller.ts:147
↓ 2 callers
Method
getCcxtCandlePrefillService
()
src/modules/services.ts:184
↓ 2 callers
Method
getConfig
()
src/modules/system/dashboard_config_service.ts:8
↓ 2 callers
Function
getCrossedSince
(lookbacks: number[])
src/modules/ta.ts:18
↓ 2 callers
Method
getDashboardSettingsController
(templateHelpers: any)
src/modules/services.ts:182
↓ 2 callers
Method
getDeskService
()
src/modules/services.ts:200
↓ 2 callers
Method
getExchangeCandleCombine
()
src/modules/services.ts:175
↓ 2 callers
Method
getFileCache
()
src/modules/services.ts:203
↓ 2 callers
Method
getLastPrices
Get the last N close prices (most recent last)
src/strategy/strategy.ts:158
↓ 2 callers
Method
getLogsRepository
()
src/modules/services.ts:169
↓ 2 callers
Method
getLookbacksForPair
( exchange: string, symbol: string, period: string, limit: number = 750, olderThen?: numbe
src/repository/candlestick_repository.ts:22
↓ 2 callers
Method
getLookbacksSince
(exchange: string, symbol: string, period: string, start: number)
src/repository/candlestick_repository.ts:51
↓ 2 callers
Method
getMarketsForExchange
* Get markets for an exchange with caching (public data, no auth needed)
src/modules/profile_pair_service.ts:123
↓ 2 callers
Method
getNotifier
()
src/modules/services.ts:164
↓ 2 callers
Method
getPairs
(req: express.Request, res: express.Response)
src/controller/profile_controller.ts:237
↓ 2 callers
Method
getPairsForProfile
(profile: Profile)
src/controller/profile_controller.ts:324
↓ 2 callers
Method
getProfileExchange
* Returns a cached authenticated exchange instance for the given profile. * Creates a new instance on first call, after the 1-hour TTL expires, or
src/modules/system/exchange_instance_service.ts:52
↓ 2 callers
Method
getSignalRepository
()
src/modules/services.ts:160
↓ 2 callers
Method
getStrategies
* Get all available v2 strategies
src/controller/backtest_controller.ts:173
↓ 2 callers
Method
getStrategiesWithDefaults
()
src/controller/profile_controller.ts:334
↓ 2 callers
Method
getStrategyExecutor
()
src/modules/services.ts:165
↓ 2 callers
Function
getTalib
()
test/modules/strategy/v2/indicator_calculator.test.ts:11
↓ 2 callers
Function
getTrendingDirectionLastItem
(lookbacks: number[])
src/modules/ta.ts:14
↓ 2 callers
Method
getUsdtPrices
* Get USDT prices for all coins. * Returns a record of coin -> USDT price. * Uses cache if available and not expired.
src/utils/binance_price_service.ts:26
↓ 2 callers
Method
getWatchedPairs
* Returns all unique (exchange, symbol) pairs currently being watched via websocket. * Combines pairs from dashboard config and bot configs.
src/modules/system/ccxt_candle_watch_service.ts:42
↓ 2 callers
Method
invalidateProfile
* Removes the cached authenticated instance for a profile. * Call this whenever a profile's credentials or exchange name change.
src/modules/system/exchange_instance_service.ts:83
↓ 2 callers
Method
isPathWithinStrategiesDir
* Validate that a resolved file path is within the allowed strategies directory. * Prevents path traversal attacks.
src/modules/strategy/v2/strategy_registry.ts:64
↓ 2 callers
Method
loadFromFile
* Load a strategy class from file (fresh, not cached)
src/modules/strategy/v2/strategy_registry.ts:128
↓ 2 callers
Method
nodeVersion
()
src/controller/base_controller.ts:13
↓ 2 callers
Method
onTick
()
src/strategy/bot_runner.ts:72
↓ 2 callers
Method
parseDeskForm
(body: any)
src/controller/desks_controller.ts:166
↓ 2 callers
Method
parseIntOrNull
(value: string | undefined)
src/controller/settings_controller.ts:167
↓ 2 callers
Method
parsePair
* Parse pair into asset and currency (e.g., "BTC/USDT:USDT" -> { asset: "BTC", currency: "USDT" })
src/controller/orders_controller.ts:197
↓ 2 callers
Method
resolveFilePath
* Resolve strategy name/path to a file path
src/modules/strategy/v2/strategy_registry.ts:73
↓ 2 callers
Method
runBacktest
* Run a backtest with the v2 engine
src/controller/backtest_controller.ts:203
↓ 2 callers
Method
saveBotSettings
(settings: Partial<BotSettings>)
src/modules/system/config_service.ts:214
↓ 2 callers
Method
start
()
src/modules/http.ts:93
↓ 2 callers
Method
startSubscriptions
()
src/modules/system/ccxt_candle_watch_service.ts:123
↓ 2 callers
Method
transaction
(fn: () => void)
src/repository/candlestick_repository.ts:6
↓ 2 callers
Method
trendChange
* Detect trend change based on Heikin Ashi candle patterns * - 'up' trend: 3 bearish candles followed by 3 bullish candles * - 'down' trend: 3 b
var/strategies/playground/playground.ts:53
↓ 1 callers
Method
boot
(projectDir: string, portOverride?: number)
src/modules/services.ts:156
↓ 1 callers
Function
buildCandleChartData
* Build candle chart data from backtest result (presentation logic)
src/controller/backtest_controller.ts:49
↓ 1 callers
Function
buildTalibRequestFromCandles
* Build talib request from candles or price array
src/utils/indicators.ts:144
↓ 1 callers
Function
buildTalibRequestFromPrices
* Build talib request from price array
src/utils/indicators.ts:176
↓ 1 callers
Function
calculateDashboardIndicators
(candles: Candlestick[])
src/modules/ta.ts:32
↓ 1 callers
Method
cancelAllOrders
* Cancel all orders for a pair
src/profile/profile_service.ts:228
↓ 1 callers
Function
cancelOrder
( exchange: ccxt.Exchange, orderId: string, pair: string )
src/profile/profile_order_service.ts:349
↓ 1 callers
Method
cancelOrder
* Cancel an order
src/profile/profile_service.ts:204
↓ 1 callers
Function
chunkArray
(array: T[], size: number)
src/modules/system/candle_importer.ts:4
↓ 1 callers
Method
classNameToId
* Convert class name to strategy identifier * e.g., "DcaDipperV2" -> "dca_dipper_v2"
src/modules/strategy/v2/strategy_registry.ts:170
↓ 1 callers
Method
closePosition
(req: express.Request, res: express.Response)
src/controller/profile_controller.ts:212
↓ 1 callers
Method
closePosition
* Close a swap/futures position via limit or market order
src/profile/profile_service.ts:220
↓ 1 callers
Function
createCandleFixtures
()
test/modules/strategy/v2/strategies/obv_pump_dump.test.ts:17
↓ 1 callers
Function
createCandleFixtures
* Test fixture: BTC/USDT 15m candles (DESC order - newest first)
test/modules/strategy/v2/strategies/playground.test.ts:23
↓ 1 callers
Function
createCandleFixtures
()
test/modules/strategy/v2/strategies/cci.test.ts:17
↓ 1 callers
Function
createCandleFixtures
()
test/modules/strategy/v2/strategies/parabolicsar.test.ts:17
↓ 1 callers
Function
createCandleFixtures
()
test/modules/strategy/v2/strategies/trader.test.ts:17
↓ 1 callers
Function
createCandleFixtures
()
test/modules/strategy/v2/strategies/pivot_reversal_strategy.test.ts:17
↓ 1 callers
Function
createCandleFixtures
()
test/modules/strategy/v2/strategies/cci_macd.test.ts:17
↓ 1 callers
Function
createCandleFixtures
* Test fixture: BTC/USDT 15m candles (DESC order - newest first)
test/modules/strategy/v2/strategies/dca_dipper.test.ts:23
↓ 1 callers
Function
createCandleFixtures
()
test/modules/strategy/v2/strategies/noop.test.ts:17
↓ 1 callers
Function
createCandleFixtures
()
test/modules/strategy/v2/strategies/dip_catcher.test.ts:17
↓ 1 callers
Function
createCandleFixtures
()
test/modules/strategy/v2/strategies/awesome_oscillator_cross_zero.test.ts:17
↓ 1 callers
Function
createCandleFixtures
()
test/modules/strategy/v2/strategies/macd.test.ts:17
↓ 1 callers
Function
createCandleFixtures
()
test/utils/technical_pattern.test.ts:31
↓ 1 callers
Function
createCandleFixtures
* Test fixture: BTC/USD 5m candles * * IMPORTANT: This fixture is in DESC order (newest first) * Indicators expect ASC order (oldest first) * Test
test/utils/indicators.test.ts:13
↓ 1 callers
Function
createCandlestickInstances
* Create Candlestick instances from raw fixture data
test/modules/strategy/v2/indicator_calculator.test.ts:240
↓ 1 callers
Method
createMailer
()
src/modules/services.ts:177
↓ 1 callers
Method
createProfile
(data: Partial<Profile>)
src/profile/profile_service.ts:39
↓ 1 callers
Method
createTelegram
()
src/modules/services.ts:178
↓ 1 callers
Method
createTradeInstance
()
src/modules/services.ts:176
↓ 1 callers
Method
createUUID
()
src/utils/winston_sqlite_transport.ts:50
↓ 1 callers
Method
createWebserverInstance
()
src/modules/services.ts:166
↓ 1 callers
Method
execute
* Execute strategy on candles and return raw signals * This is the core method reusable for both backtesting and live trading
src/modules/strategy/v2/typed_backtest.ts:97
↓ 1 callers
Method
executeSignal
* Execute a trade signal via CCXT through ProfileService. * * close + futures pair → closePosition() at market * close + spot pair → sel
src/strategy/bot_runner.ts:137
↓ 1 callers
Method
executeStrategy
* Execute a strategy for live trading — fetches candles, runs strategy, returns the latest signal. * Requires live trading deps to be passed to the
src/modules/strategy/v2/typed_backtest.ts:172
↓ 1 callers
Method
fetchAndStore
([exchange, symbol, period]: PrefillJob)
src/modules/system/ccxt_candle_prefill_service.ts:84
↓ 1 callers
Method
fetchCoinGeckoRankings
* Fetch top coins from CoinGecko (cached for 6 hours)
src/modules/profile_pair_service.ts:38
↓ 1 callers
Method
fetchCombinedCandles
( mainExchange: string, symbol: string, period: string, exchanges: ExchangeSymbolPair[] = [],
src/modules/exchange/exchange_candle_combine.ts:12
↓ 1 callers
Method
fetchCombinedCandlesSince
( mainExchange: string, symbol: string, period: string, exchanges: ExchangeSymbolPair[] = [],
src/modules/exchange/exchange_candle_combine.ts:28
↓ 1 callers
Method
fetchDirect
* Fetch 500 candles from the exchange REST API and return them immediately. * No DB storage — caller uses the candles directly.
src/modules/system/ccxt_candle_prefill_service.ts:80
↓ 1 callers
Method
fetchJSON
(url: string)
src/modules/system/symbol_search_service.ts:36
↓ 1 callers
Function
fetchOpenOrders
( exchange: ccxt.Exchange, pair?: string )
src/profile/profile_order_service.ts:176
↓ 1 callers
Method
fetchTickerPublic
* Fetch ticker/market data using public (unauthenticated) exchange. * Use this for watch mode bots that don't need authentication.
src/profile/profile_service.ts:155
↓ 1 callers
Method
flush
()
src/modules/system/ccxt_candle_watch_service.ts:111
↓ 1 callers
Function
formatPrice
(price)
web/static/js/orders.js:13
↓ 1 callers
Method
formatResultForView
* Format backtest result for view template
src/controller/backtest_controller.ts:225
↓ 1 callers
Method
getAvailableStrategies
* Get list of all available strategy names (built-in + discovered from files)
src/modules/strategy/v2/strategy_registry.ts:187
↓ 1 callers
Method
getBacktestController
(templateHelpers: any)
src/modules/services.ts:190
↓ 1 callers
Method
getBacktestPairs
* Get available pairs for backtest dropdown
src/controller/backtest_controller.ts:191
↓ 1 callers
Method
getBinancePriceService
()
src/modules/services.ts:205
↓ 1 callers
Function
getBollingerBandPercent
(currentPrice: number, upper: number, lower: number)
src/modules/ta.ts:2
↓ 1 callers
Method
getBot
(profileId: string, botId: string)
src/profile/profile_service.ts:240
↓ 1 callers
Method
getBotRunner
()
src/modules/services.ts:204
← previous
next →
101–200 of 500, ranked by callers