Baseball.Matches

Get all matches

Refresh interval: Once a minute

Route returns only general match information. For additional match details check the matches/{matchId} route.

Retrieve a list of matches based on the requested query parameters.

At least one primary query parameter needs to be specified before you can retrieve the data (timezone, limit, offset are considered secondary).

You can specify the timezone field in combination with the date query parameter to get matches relevant to your location.

There are two other important parameters. The limit parameter defines what the number of returned matches will be. If the number of actual matches is above the limit value you can make subsequent requests by increasing the offset value.

Matches have different possible states they can be in:

StateDescription
FinishedMatch has been concluded.
PostponedMatch has been postponed due to certain circumstances that are preventing the game from being played. Event start time will be changed to a moment in the future.
ScheduledMatch has not been started yet.
CanceledGame will not be played.
AbandonedConsidered "abandoned" when it is prematurely ended by the officials and can not be resumed or completed. In the future the game might be resumed from the exact point where it was halted.
In ProgressGame is currently in progress.
Half TimeHalf time pause between first and second half.
SuspendedMatch has already been in play but was suspended. In the future the game will resume from the exact point where it was halted.
UnknownUnknown match coverage or state.
Rain DelayMatch has been delayed due to bad weather conditions. Will either be resumed or suspended.
Period EndBreak time between periods.

Below is an example of what you can aim to achieve with the matches endpoint:

Baseball matches example

get/baseball/matches

Request

Query parameters

leaguestring
Example:MLB
datestring
Example:2024-08-31

Date that follows the YYYY-MM-DD format.

timezonestring
Example:Europe/London

Valid timezone identifier.

seasonnumber
Example:2024
homeTeamIdnumber
Example:10291199
awayTeamIdnumber
Example:10291203
homeTeamNamestring
Example:Rangers
awayTeamNamestring
Example:Athletics
homeTeamAbbreviationstring
Example:TEX
awayTeamAbbreviationstring
Example:OAK
homeTeamDisplayNamestring
Example:Texas Rangers
awayTeamDisplayNamestring
Example:Oakland Athletics
limitnumber
Example:100
offsetnumber

Headers

x-rapidapi-hoststring required

sport-highlights-api.p.rapidapi.com

x-rapidapi-keystring required

Rapid API Token

Response

Example response

{
  "data": [
    {
      "id": 394,
      "round": "regular-season",
      "date": "2024-03-06T00:30:00.000Z",
      "league": "NCAA",
      "season": 2024,
      "awayTeam": {
        "id": 219,
        "logo": "https://example.com/logos/team/219.png",
        "name": "Bears",
        "displayName": "Baylor",
        "abbreviation": "BAY"
      },
      "homeTeam": {
        "id": 219,
        "logo": "https://example.com/logos/team/219.png",
        "name": "Bears",
        "displayName": "Baylor",
        "abbreviation": "BAY"
      },
      "state": {
        "description": "Finished",
        "report": "Final",
        "score": {
          "home": {
            "hits": 4,
            "errors": 2,
            "innings": [
              0,
              0,
              1,
              1,
              0,
              0,
              1,
              1,
              1
            ]
          },
          "away": {
            "hits": 4,
            "errors": 2,
            "innings": [
              0,
              0,
              1,
              1,
              0,
              0,
              1,
              1,
              1
            ]
          },
          "current": "5 - 8"
        }
      }
    }
  ],
  "pagination": {
    "totalCount": 490,
    "offset": 20,
    "limit": 100
  },
  "plan": {
    "tier": "BASIC",
    "message": "Some results might be hidden with FREE tier. Check your API coverage for more information: https://rapidapi.com/highlightly-api-highlightly-api-default/api/sport-highlights-api/details"
  }
}

Changes

No recorded changes to this operation across all 1 revision of this API.