{"uid":"cap_faF_4WBq8BOXs4nRXErEb","slug":"mlb-stats-schedule-data-api-9b419235","name":"MLB Stats & Schedule Data API","description":"Pay-per-call structured web data. Failed or empty runs are not charged.","url":"https://api.scrapeforagents.tech/v1/mlb?utm_source=zero.xyz","method":"POST","headers":{},"bodySchema":{"type":"object","properties":{"date":{"type":"string","description":"One schedule or game-details date in YYYY-MM-DD format."},"mode":{"enum":["teams","players","schedule","standings","playerStats","gameDetails","leaders"],"type":"string","default":"teams","description":"Choose teams, roster players, games, standings, player season statistics, team game totals, or ranked leaders."},"gamePk":{"type":"integer","description":"One game ID for game details, merged with Game IDs."},"season":{"type":"integer","description":"Optional single season year; merged with Seasons when both are set."},"teamId":{"type":"integer","description":"One club ID, merged with Team IDs when both are set."},"toDate":{"type":"string","description":"Last schedule or game-details date in YYYY-MM-DD format."},"gamePks":{"type":"array","description":"Game details for these game IDs; leave empty to discover games from dates or seasons."},"seasons":{"type":"array","description":"Season years to collect. Leave empty for the current year."},"teamIds":{"type":"array","description":"Optional club IDs to filter teams, rosters, games, standings, stats, or leaders."},"fromDate":{"type":"string","description":"First schedule or game-details date in YYYY-MM-DD format."},"gameType":{"enum":["R","S","P","W","L","A"],"type":"string","default":"R","description":"Game classification for schedule, game details, and leaderboards."},"leagueId":{"enum":["both","AL","NL"],"type":"string","default":"both","description":"League filter for standings."},"maxItems":{"type":"integer","default":1000,"minimum":1,"description":"Maximum dataset rows to return across all seasons and categories."},"playerId":{"type":"integer","description":"One player ID for player statistics, merged with Player IDs."},"playerIds":{"type":"array","description":"Player statistics for these player IDs; leave empty to use selected club rosters."},"statGroup":{"enum":["hitting","pitching","fielding"],"type":"string","default":"hitting","description":"Player stats or leaders for hitting, pitching, or fielding."},"leaderCategories":{"type":"array","description":"Statistic categories for ranked leaders, such as homeRuns, battingAverage, strikeouts, or saves."}}},"responseSchema":{"type":"json","example":{"count":1,"items":[{"age":null,"avg":null,"active":null,"atBats":null,"airOuts":null,"assists":null,"abbreviation":null,"atBatsPerHomeRun":null}],"product":"mlb"}},"example":null,"exampleRequest":null,"tags":["x402"],"displayCostAmount":"0.08","displayCostAsset":"USDC","priceDynamic":false,"priceHint":null,"priceStatus":"priced","priceSource":"probe","requiresHandshake":false,"reviewCount":0,"rating":{"score":"0.00","successRate":"0.00","reviews":0,"stars":null,"state":"unrated"},"availabilityStatus":"unknown","priceObserved":null,"sessionDeposit":null,"pricing":{"kind":"static","summary":"$0.08/call","primary":{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.08","per":"call","confidence":"exact"},"accepted":[{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.08","per":"call","confidence":"exact"}]},"paymentMethods":[{"uid":"pm_OzSpKgGGNwH6cfvib9g2z","protocol":"x402","methodType":"crypto","chain":"base","mode":"charge","costAmount":"0.08","costPer":"request","priority":0,"asset":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","unit":"request","depositMicros":null,"planRef":null}],"brandName":null,"brandSlug":null,"brandBaseUrl":null,"brandDocsUrl":null,"whatItDoes":"Retrieves structured MLB data including teams, players, schedules, standings, player stats, game details, and leaderboards for any season","exampleAgentPrompt":"Pull up the current AL and NL hitting leaders for the 2024 regular season, showing stats like batting average and home runs — top 50 results.","exampleUseCases":[{"title":"Fantasy baseball player stats lookup","prompt":"Get me the hitting stats for Mike Trout and Shohei Ohtani for the 2023 regular season so I can compare their batting averages, home runs, and RBIs."},{"title":"Team schedule research for upcoming series","prompt":"Show me the New York Yankees schedule from July 1st to July 15th 2024, regular season games only."},{"title":"Live standings check mid-season","prompt":"What are the current MLB standings for both the AL and NL for the 2024 season?"}],"resultDescription":"Returns a JSON object with a count and an items array containing structured MLB data rows. Fields vary by mode — e.g. teams mode returns team names and abbreviations; playerStats mode returns hitting/pitching/fielding numbers like batting average, home runs, ERA, strikeouts; schedule mode returns game dates, opponents, and game IDs; standings mode returns win/loss records and division ranks. Failed or empty result sets are not charged.","failureModes":["Invalid date format (must be YYYY-MM-DD) causing empty result","Unknown teamId or playerId returning empty items array","gamePk not found for specified game type or season","Season year out of range returning no data","maxItems too low truncating results unexpectedly","Network timeout or upstream MLB Stats API unavailability"],"whenToPreferThis":"Use this endpoint when you need structured, queryable MLB data — including historical seasons, player stats, schedules, standings, or leaderboards — without scraping raw HTML. It's ideal for fantasy sports agents, sports analytics workflows, or any application needing clean JSON MLB data on a pay-per-call basis. Prefer this over general web search when you need machine-readable stats fields rather than narrative summaries.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-10-02T00:46:15.218Z","isFirstParty":false,"canonicalSlug":"mlb-stats-schedule-data-api-9b419235"}