As a follow-up to my Scoreboard Pistons found here. I have posted a piston below for individual team alerts.
The current piston sends push notification prior to game, with each team score, and final. Due to the numerous other methods of notifications (i.e TTS via echo/google/sonos or even flashing lights), I did not include those options by default. Feel free to swap out the push notification with any individualized method. For example, I use the cast-web-api to announce the alert over google home based on certain conditions.
- Piston Logic:
- To allow for as many sports as possible, user will need to set specific varaibles
- Sport Index (0-Baseball, 1-Football, 2-Basketball, 3-Hockey, 4-Soccer)
- Team Abbreviation found on ESPN.com
- Professional Boolean (True = Pro, False = College)
- Gender Boolean (True = Male; False = Female)
- League ID for Professional Soccer Only
- Alert Preferences: Set to true if you want to receive that alert
- Pre-game Alert Offset - how far in advance to send the pregame alert