#baseball
2 APIs with this tag
Baseball Stats API
Baseball sabermetrics as an API, computed locally and deterministically — turn raw counting numbers into the rate stats that actually rank players. The batting endpoint takes at-bats, hits, doubles, triples, home runs, walks, hit-by-pitch and sacrifice flies and returns the batting average (H/AB), on-base percentage ((H+BB+HBP)/(AB+BB+HBP+SF)), slugging percentage (total bases/AB), OPS (on-base plus slugging), isolated power (SLG−AVG) and, when strikeouts are supplied, BABIP — a classic .300/.366/.530 line comes straight out. The pitching endpoint takes innings pitched, earned runs, hits, walks, strikeouts and home runs and returns the earned run average (9·ER/IP), WHIP ((BB+H)/IP), strikeouts and walks per nine innings, the strikeout-to-walk ratio and FIP, the fielding-independent pitching estimator (13·HR + 3·(BB+HBP) − 2·K)/IP + constant. Innings pitched is a true decimal, with an exact "outs" input for the 6.1/6.2 box-score convention. Everything is computed locally and deterministically, so it is instant and private. Ideal for fantasy-baseball, sports-analytics, sabermetrics and box-score app developers, scouting and stat-line tools, and teaching material. Pure local computation — no key, no third-party service, instant. Live, nothing stored. 2 compute endpoints. This computes the stats from your numbers; for live scores, standings, teams and players use a sports-data API.
api.oanor.com/baseball-api
MLB Baseball Stats API
Major League Baseball as an API, from the official MLB Stats API. Get the 30 clubs, live division standings (wins, losses, win pct, games back, current streak, run differential), the full schedule and final scores for any date, team rosters, player profiles with complete season hitting and pitching stats (HR, AVG, OPS, RBI, ERA, strikeouts, W-L and more), and inning-by-inning line scores for any game. Resolve teams by abbreviation (NYY), id (147) or name (Yankees), and players by name (Aaron Judge) or MLB id. Perfect for building scoreboards and standings widgets, fantasy-baseball tools, stat dashboards, Discord/Slack bots, and sports-data apps. No key for the upstream, no accounts to manage.
api.oanor.com/mlb-api