Fixes for bots running (#22)
* Fixes for bots running * Up botmanager * Add cooldown * Refact can open position * Add cooldown Period and MaxLossStreak * Add agentName * Add env variable for botManager * Always enable Botmanager * Fix bot handle * Fix get positions * Add Ticker url * Dont start stopped bot * fix
This commit is contained in:
@@ -1,6 +1,5 @@
|
||||
using Managing.Application.Abstractions;
|
||||
using Managing.Application.Abstractions.Services;
|
||||
using Managing.Domain.MoneyManagements;
|
||||
using Microsoft.Extensions.Logging;
|
||||
using static Managing.Common.Enums;
|
||||
|
||||
@@ -8,38 +7,17 @@ namespace Managing.Application.Bots
|
||||
{
|
||||
public class ScalpingBot : TradingBot
|
||||
{
|
||||
public ScalpingBot(string accountName,
|
||||
MoneyManagement moneyManagement,
|
||||
string name,
|
||||
string scenarioName,
|
||||
public ScalpingBot(
|
||||
IExchangeService exchangeService,
|
||||
Ticker ticker,
|
||||
ITradingService tradingService,
|
||||
ILogger<TradingBot> logger,
|
||||
Timeframe timeframe,
|
||||
ITradingService tradingService,
|
||||
IAccountService accountService,
|
||||
IMessengerService messengerService,
|
||||
IBotService botService,
|
||||
decimal initialTradingBalance,
|
||||
bool isForBacktest = false,
|
||||
bool isForWatchingOnly = false)
|
||||
: base(accountName,
|
||||
moneyManagement,
|
||||
name,
|
||||
ticker,
|
||||
scenarioName,
|
||||
exchangeService,
|
||||
logger,
|
||||
tradingService,
|
||||
timeframe,
|
||||
accountService,
|
||||
messengerService,
|
||||
botService,
|
||||
initialTradingBalance,
|
||||
isForBacktest,
|
||||
isForWatchingOnly)
|
||||
TradingBotConfig config)
|
||||
: base(exchangeService, logger, tradingService, accountService, messengerService, botService, config)
|
||||
{
|
||||
BotType = BotType.ScalpingBot;
|
||||
Config.BotType = BotType.ScalpingBot;
|
||||
}
|
||||
|
||||
public sealed override void Start()
|
||||
|
||||
Reference in New Issue
Block a user