Principals features : 
- Create X bots
- Each Trading bot can have multiple strategies
- Each Strategy is run for every new candle that the bot read from the database
- Use exchange worker to retrieve candles for a ticker
- Open one click a long with SL and 2 take profit with defined risk

V1 : 

Part 1 : Running bot
- OK - Create no relationnal database to store all tickers history by exchanges
- OK - Feed the database with a Bot 
- OK - On Bot motherclass, create a method accessible to child to retrieve the last candle since a prompted date
- OK - Create 3 Soldiers strategy
- OK - Create rule "CloseHigherThanThePreviousHigh"
- OK - Create rule "CloseLowerThanThePreviousLow"

Part 2 : Make a trade
- OK - Implement a GetBalance with the value in $
- OK - Calculate risk per for a given trade 
- OK - Open a Long with defined risk level and exchange
- OK - Define and Open Stop loss with risk level
- OK - Define and open 2 Take Profit with risk level
- OK - Register generic candle for every exchanges in database
- OK - Create an endpoint to retrieve all order (with a filter class)
- OK - Create an endpoint to close an order for a given ExchangeOrderId
- OK - Implement OpenMarketTrade for Binance Futures
- OK - Implement GetPrice for Binance Futures
- OK - Implement GetTrade for Binance Futures
- OK - Binance : Handle TimeInForce for limit or market trade

Part 3 : Bot running RSI
- OK - Create RSI for 32period
- OK - Handle multiple divergence point for a candle range
- OK - Create rule to find a divergence for given RSI -> Confidence.High
- OK - Create an identifier for each bot based on name-datetime
- OK - Save price into Signal Object

Part 3.1
- OK - Each bot should be a manager keep in memory the trades executed and execute trade by calling openMarketPosition()
- OK - Create a mother class call TradeManager
- OK - This class should access to the signal return by the Scalping bot
- OK - This class should handle the trade management
- OK - Save Signals into database 

Part 3.2 : 
- OK - Create a unit test to backtest the bot execution
- OK - Get range candle list for a ticker
- OK - Each bot should have a backtest mode. This mode allow the caller to insert his own candles into the list. This mode will be used by the unit tests
- OK - Foreach candle, update the candle list of the bot and implicitly run all strategies

- OK - For each last signal for a ticker check if position is open. If not: Open position.
- OK - If an position is already open, update the position and check the price and trigger a close/flip if there is an inversed signal for that position.
- OK - If there is a inverted signal, close or flip the position depending of the confidence of the signal
- OK - Create a collection for registering the position with pnl, status
- OK - Save in trade table a reference to the position id, bot identifier 
- OK - Create class to calculate PNL
- OK - openMarketPosition () should handle a parameter to make paper trading: just return the object that represent the trade executed by the exchange. That parameter will be set by bot in backtest mode
- OK - Add function to reopen trade that wasnt filled or whatever
- OK - Assert the fact that a list of positions have been created and ending in positive 
- OK - Fix timestamp unix for getting klines for OneMinutes timeframe
- OK - Run bot on past candle
- OK - Extract trading logic from Bot class, to create a (TradingBot : Bot) class.

Part 4: 
- Ok - Create RSIBearishDivergenceStrategy 
- OK - Move Risk level config into appsettings to manipulate easily the user preference
- OK - Implement multi-timeframe to Define MoneyManagement for everyTimeFrame 
- OK - Handle little quantity for trade by multiplying the quantity inside pnl object
- OK - Set the correct quantity for a trade who take profit #1
- OK - Add more tests for ProfitAndLoss object
- OK - Setup optionnal second take profit
- OK - Create DailyBot and Minutes bot to handle 5 ans 14 periods rsi
- OK - Run Bot for little TimeFrame
- OK - Implement GetTrade for an OrderId on Binance
- OK - Add discord connection
- OK - Expose all the API on discord bot
- OK - Run instance of bot for ADA, 5 periods, 15min
- OK - Refactoring bots unit tests to use same method than discord bot
- OK - Create CSV file for backtesting report

Part 5: 
- OK - Improve open position from discord
- OK - Improve multi-risk levels handling
- OK - Improve divergence signal by handeling confidence 
- OK - Implement ExchangeService.CloseTrade for exchanges

Part 6: webapp
- OK - Build front-end app with react 
- OK - Build Tradingview component
- Update trading bot from signalr for everynew run => pass the BotHubContext to ITradingbot interface
- OK - Bots page to manage running bots
-	- OK - Create a modal to start a bot
-	- OK - On backtest page, display a button to start a bot based on defined backtest configuration
-	- Handle stop and restart
- OK - Create scanner page to load all the ticker backtest base on a setup (timeframe, risk, day, bottype)
- OK - Save backtestResult into database to display it into Scanner page
- OK - Display backtest result on scanner page
- Scenario builder => A component to build nested trading strategy https://www.kindacode.com/article/react-typescript-drag-and-drop/
-	- OK - Store scenario into database -> a scenario contain a list of defined strategy
-	- OK - Dynamically insert scenario into ITradingBot
-	- OK - Create a modal form to build a scenario that contains a list of strategies
-	- OK - On backtest page, retrieve scenario list to launch a backtest based on it

Part 7: Improve trading 
- OK - Handle fees
- OK - Create strategy to send rsi div signal on confirmation only
- OK - Make flipping position optionnal
- OK - Candle mapped on the wrong time => 18h30 should be 18h15
- KO - Enable backtesting on very long time range => No historical data more than 1500ohlc per timeframe on FTX

Part 8 : enhance front
- Settings page => 
	- OK - Put money management into database to be able to modify it without rebuild/restart the api
	- OK - Create a tab page on settings page to easily update monymanagement in db
- Improve card informations for bots
-	- OK - Display the signals count for long and short
-	- OK - Add button to toggle start and stop
-	- OK - Add a toggle for isWatchingOnly
- OK - Add filter checkbox on Backtest/Moneymanagement to filter the list
- OK - Create a button to delete all backtests 
- OK - Implement switch network debug/local

Part 9: Improve bot usage
- Save bot config to database to re-run bot on restart
- OK - Create endpoint to restart a bot 
- Ok - Create endpoint to stop all bots
- OK - On signal, if a position is open => Same direction : expired signal | opposition direction : Flip open position
- OK - Implement a flipping function on an open position 
- Ok - Track balance evolution to determine max drawdown
- OK - Determine best parameter for a given scenario : https://www.youtube.com/watch?v=jm-UfVPqUQo (Start with a unit test)
- OK - When a bot start up for a ticker, clean all limit order
- OK - When a bot start up for a ticker, clean open position 
- OK - Before opening a trade clean limit order
- OK - Get status of position before closing it. The position might be already close by the exchange

Part 10: Improve performance
- OK - Calculate the strategies only on the last n*10 period 
- OK - Merge divergence RSI strategy to calculate rsi only once by run
- KO - Prevent Order's notional must be no smaller than 5.0 
- OK - Don't run update Signal and manage position if no new candle

Part 11: Extra
- OK - Create custom exception to handle error
- OK - Add ELK stacks
- OK - Display R/R used on backtestResult
- OK - Update Exchanges libraries
- OK - Integrate FTX exchange
- OK - Display wallet evolution
- OK - Remove API keys from git 
- OK - Add seed for moneymanagement and scenario
