Blueshift bot end date

How do I set the end date for my bot when I go into paper/live trading in Alpaca? My bot just stops at the end of the day and I have to restart it the next day. 



The end date just defaults to the current date always.

Hi David, 



One reason for this might be the way the API is designed by Alpaca. It is likely related to session or connection management by the API. Alpaca may have specific limitations or requirements for session durations. You can get in touch with the Alpaca team at support@alpaca.markets and check the same.



Hope this helps!

It will be great is someone from the Blueshift team can take a look at this, as the documented steps are not working. Steps 5 onwards as described in the quantra course and the site are not working: Blueshift By QuantInsti and the Alpaca API: Tools for Algorithmic Trading

The strategy is exiting without taking any trades and there is no popup for converting backtesting code to live format as described in the steps, nor any place to specify the date, postion size etc.

Here are full console logs for one of the example strategy runs:

Your algo execution will start shortly. Please note the details below for future reference

Execution name (hash): vol_reversal (abf81d67-b8ef-4670-a1a6-24adb609f3ec) 
Strategy name (hash): volume_reversal (aef600f2-2040-4dd3-a616-4695c2a22600) 
Starting capital: 1,000 
Mode: live 
Order confirmation: auto 
Launch-time: 26 April 2025 
End date: 26 April 2025 

Once the algo is initialized, performance and other details will be updated in the dashboard.
Creating necessary resources for the algo execution ...
 
[PLATFORM]
Showing maximum last 2000 entries. For full logs, click  here  to download.
 
[LOG]
Reticulating spline, setting up algorithm environment...
 
[LOG]
Done.
 
[LOG]
Integrating volatility over z-axis...
 
[LOG]
Done.
 
[LOG]
Configuring lunchtime ...
 
[LOG]
Done.
 
[LOG]
Tokenizing gravity...
 
[LOG]
Done.
 
[LOG]
Evaluating gene expression...
 
[USER]
Connecting to the broker ... 
 
[USER]
Resetting data store on connect... 
 
[USER]
Done
 
[USER]
Fetching trade data ... 
 
[USER]
Done
 
[USER]
Done
 
[USER]
setting up callbacks for events.
 
[PLATFORM]
Blueshift Alert(abf81d67-b8ef-4670-a1a6-24adb609f3ec)[2025-04-27 16:07:50.624780-04:00](PLATFORM): Algo reported status created:Algo abf81d67-b8ef-4670-a1a6-24adb609f3ec is created successfully.
 
[PLATFORM]
starting LIVE with algo:algo.py, engine:4.0.0(DEBUG)[2025-04-01 15:00:00+00:00], broker:alpaca-paper, timezone:US/Eastern
 
[WARNING]
Blueshift Alert(abf81d67-b8ef-4670-a1a6-24adb609f3ec)[2025-04-27 16:07:50.631861-04:00](WARNING): risk management: kill switch is disabled. Algo kill switch will be off.
 
[PLATFORM]
Blueshift Alert(abf81d67-b8ef-4670-a1a6-24adb609f3ec)[2025-04-27 16:07:50.634991-04:00](PLATFORM): Algorithm setup complete. Executing initialze routines.
 
[PLATFORM]
Blueshift Alert(abf81d67-b8ef-4670-a1a6-24adb609f3ec)[2025-04-27 16:07:50.638198-04:00](PLATFORM): successfully read saved blotter data at 2025-04-27 16:07:50.634035-04:00.
 
[PLATFORM]
Blueshift Alert(abf81d67-b8ef-4670-a1a6-24adb609f3ec)[2025-04-27 16:07:50.638660-04:00](PLATFORM): Algo reported status running:Algo abf81d67-b8ef-4670-a1a6-24adb609f3ec started running.
 
[PLATFORM]
Blueshift Alert(abf81d67-b8ef-4670-a1a6-24adb609f3ec)[2025-04-27 16:08:50.635360-04:00](PLATFORM): Clock routine is exited.
 
[PLATFORM]
Blueshift Alert(abf81d67-b8ef-4670-a1a6-24adb609f3ec)[2025-04-27 16:08:50.636497-04:00](PLATFORM): Algorithm run complete. Will shut down.
 
[PLATFORM]
Blueshift Alert(abf81d67-b8ef-4670-a1a6-24adb609f3ec)[2025-04-27 16:08:50.662029-04:00](PLATFORM): successfully saved blotter data at 2025-04-27 16:08:50.635932-04:00.
 
[PLATFORM]
Blueshift Alert(abf81d67-b8ef-4670-a1a6-24adb609f3ec)[2025-04-27 16:08:55.675844-04:00](PLATFORM): Successfully updated algo positions and valuation on exit for algo abf81d67-b8ef-4670-a1a6-24adb609f3ec.
 
[PLATFORM]
Blueshift Alert(abf81d67-b8ef-4670-a1a6-24adb609f3ec)[2025-04-27 16:08:55.676725-04:00](PLATFORM): finalizing the environment
 
[PLATFORM]
Blueshift Alert(abf81d67-b8ef-4670-a1a6-24adb609f3ec)[2025-04-27 16:08:55.677245-04:00](PLATFORM): Algo reported status done:Algo abf81d67-b8ef-4670-a1a6-24adb609f3ec run complete.
 
[PLATFORM]
Blueshift Alert(abf81d67-b8ef-4670-a1a6-24adb609f3ec)[2025-04-27 16:08:55.684894-04:00](PLATFORM): Removing algo abf81d67-b8ef-4670-a1a6-24adb609f3ec
 
[PLATFORM]
Blueshift Alert(abf81d67-b8ef-4670-a1a6-24adb609f3ec)[2025-04-27 16:08:55.686272-04:00](PLATFORM): Algo run abf81d67-b8ef-4670-a1a6-24adb609f3ec finished.
 
[PLATFORM]
Blueshift Alert(abf81d67-b8ef-4670-a1a6-24adb609f3ec)[2025-04-27 16:08:55.686780-04:00](PLATFORM): Risk monitor channel shutting down...

Hello,

Let me go through the query and reply to you.

Thanks

Hello Geeta,

I think you received a reply from the Blueshift team.
Thanks.

Unfortunately with the current restrictions on having to restart bot everyday, things don’t work for me. I am based in US Pacific timezone, which requires me to either keep awake till 12 midnight so that I can restart the bot for next day or wake up before 6:30am PST in the morning ie before the US Market open time to restart the bot again for processing orders for the next day.