About this template
tldr; this is a pack of reusable automations that you can install into your other bots
I often find myself blocking my short-term strategy bots from trading across major market events: FOMC & CPI reports, ex-dividend dates, earnings reports (earnings week!), etc. I put these detections into reusable automations that I run across many of my bots, and now I'm sharing them.
SPY Big 9 Earnings
Tags the bot with "earnings blockout" whenever any of the 9 largest SPY market cap symbols are due to report earnings. The lead and lag time is configurable via "Days Ahead" and "Days Past".
SPY Ex-Dividend
Tags the bot with "ex dividend trading blockout" when SPY is nearing the next ex-dividend date. The lead time can be adjusted by toggling switches: "1 Day Before", "2 Days Before", etc. Contains dates scheduled until the end of 2024.
Jobs Report
Tags the bot with "jobs trading blockout" prior to the next Employment Situation report (unemployment/jobs report). The lead time can be adjusted by toggling switches: "1 Day Before", "2 Days Before", etc. Contains dates scheduled until the end of 2024.
FOMC/CPI
This one isn't anything particularly new, the functionality is built into the OA decision tree logic. However, I prefer reusing known-working code, so I still use this whenever I want to block my bots from trading across these events.