GroupMe bot that scrapes ESPN Fantasy Football leagues for transaction activities (trade, adds, drops, moves)
npm install mistakia/leaguebot
cp config.sample.js config.js
Edit config.js to include your GroupMe bot credentials: bot_id
& access_token
. The opts property
accepts an array of objects used to fetch league transactions with the following properties:
leagueId
(Number): the league you want to get activities forseasonId
(Number): the year you want to get activies foractivityType
(Number): the type of activity:-2
: All activites except moved-1
: All activites1
: moved2
: added3
: dropped4
: traded5
: drafted
teamId
(Number): the team you want activities for, or-1
for all teamstranType
(Number): should be set to2
to get transactions.
Setup a crontab (or other script scheduler). Currently, it only fetches transactions for the last day so make sure it runs at least daily.
*/20 * * * * node /path/to/leaguebot/index.js
MIT