Skip to content

Scripts and web app for viewing and analyzing ESPN Fantasy Baseball league data

Notifications You must be signed in to change notification settings

dagrha/FantasyMoneyball

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

18 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Fantasy Moneyball

What?

An ongoing project consisting of scripts and web-app for viewing and analyzing our fantasy baseball league hosted on ESPN Fantasy Baseball

Why?

ESPN Fantasy & Games provides effective tools for draft prep, live drafts and league and roster management. However, we saw a distance between the detail of the provided team stats relative to the volume of available baseball Sabermetrics.

ESPN API

Below is some documentation on of the JSON API endpoints used by ESPN Fantasy Sports to populate their own client views through the fantasy baseball portal. Your experience may vary, so please share any comments!

Daily Stats

BASE URL:

REQUIRED PARAMETERS:

  • INVARIANT:

    • view='stats'
    • mode='bydate'
  • INVARIANT FOR LEAGUE:

    • leagueId=[INTEGER]
  • VARIABLE:

    • filter=[1=batting, 2=pitching]
    • teamId=[INTEGER]
    • start=[YYYYMMDD] (20140322 for 2014)
    • end=[YYYYMMDD] (20141231 for 2014)

Daily Roster

BASE URL:

REQUIRED PARAMS:

  • INVARIANT:
    • view=stats
    • managingIr=false
    • droppingPlayers=false
    • asLM=false
  • INVARIANT FOR LEAGUE:
    • leagueId=[INTEGER]
  • VARIABLE:
    • teamId=[INTEGER]
    • scoringPeriodId=[INTEGER 1-# games in season] (191 for 2014)
    • seasonId=[YYYY]

Condensed roster

BASE = "http://games.espn.go.com/flb/boxscorequick?"

  • INVARIANT:
    • view=scoringperiod
    • version=quick
  • INVARIANT FOR LEAGUE:
    • leagueId=[INTEGER]
  • VARIABLE:
    • teamId=[INTEGER]
    • scoringPeriodId=[INTEGER 1-# games in season] (191 for 2014)
    • seasonId=[YYYY]

About

Scripts and web app for viewing and analyzing ESPN Fantasy Baseball league data

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Python 95.2%
  • JavaScript 3.5%
  • Other 1.3%