mlb_player_game_log

Pack: mlb-stats · Endpoint: https://gateway.pipeworx.io/mlb-stats/mcp

MLB player GAME LOG — per-game batting or pitching lines for a season, newest first, from the official MLB Stats API. “How has Yordan Alvarez hit over his last 10 games”, “Gerrit Cole’s last five starts”, ” recent form”. Accepts a player NAME (resolved automatically) or numeric person_id; defaults to the current season and the most recent 15 games. Each row carries the date, opponent, home/away, game result, gamePk, and the line (hitting: AB, H, HR, RBI, BB, K, SB, plus running AVG/OPS; pitching: IP, H, R, ER, BB, K, HR, pitches, decision).

Parameters

NameTypeRequiredDescription
playerstringyesPlayer NAME (e.g. “Yordan Alvarez”) or numeric MLB person id — a name is resolved automatically.
seasonnumber,stringnoSeason year, e.g. 2025. Defaults to the current season.
groupstringnoOptional “hitting” or “pitching”. Defaults to hitting for position players and pitching for pitchers.
lastnumber,stringnoHow many most-recent games to return (default 15, max 200). The full-season count is always reported in games_in_season.

Example call

Arguments

{
  "player": "Yordan Alvarez",
  "last": 10
}

curl

curl -X POST https://gateway.pipeworx.io/mlb-stats/mcp \
  -H 'Content-Type: application/json' \
  -d '{"jsonrpc":"2.0","id":1,"method":"tools/call","params":{"name":"mlb_player_game_log","arguments":{"player":"Yordan Alvarez","last":10}}}'

TypeScript (@pipeworx/sdk)

import { Pipeworx } from '@pipeworx/sdk';
const pipeworx = new Pipeworx();

const result = await pipeworx.call('mlb_player_game_log', {
  "player": "Yordan Alvarez",
  "last": 10
});

More examples

{
  "player": "Gerrit Cole",
  "season": 2026,
  "group": "pitching",
  "last": 5
}

Connect

Add this to your MCP client config, or use one-click install buttons:

{
  "mcpServers": {
    "mlb-stats": {
      "url": "https://gateway.pipeworx.io/mlb-stats/mcp"
    }
  }
}

See Getting Started for client-specific install steps.

Regenerated from source · build September 3, 2026