Skip to content

Get Event Results (API v4)

abler98 edited this page Dec 8, 2023 · 3 revisions
  1. Send REST GET request

Request URL template: https://api-mst.oddsmarket.org/v4/eventResults?apiKey={apiKey}&sportIds={sportIds}&leagueId={leagueId}&startedFrom={startedFrom}&startedTo={startedTo}

Examples:

https://api-mst.oddsmarket.org/v4/eventResults?sportIds=1&leagueId=2&startedFrom=2016-05-01T12:00:00Z&startedTo=2016-05-02T12:00:00Z&apiKey=your_API_key_here
https://api-mst.oddsmarket.org/v4/eventResults?sportIds=21&apiKey=your_API_key_here

Check the request parameters specification below in this document.

  1. In the response you will get a hierarchy of objects which contain arrays of requested events.

Example:

{
"sports": [
  {
    "id": 7,
    "name": "Soccer",
    "countries": [
      {
        "id": 11,
        "name": "Europe",
        "leagues": [
          {
            "id": 9428,
            "name": "Europe. UEFA Europa League",
            "nameRu": "Европа. Лига Европы УЕФА",
            "events": [
              {
                "ids": [138057818,142852241],
                "home": {
                  "id": 538,
                  "name": "Rapid Wien",
                  "nameRu": "Рапид Вена"
                },
               "away": {
                  "id": 8802,
                  "name": "Villarreal",
                  "nameRu": "Вильярреал"
                },
                "startedAt": "2018-11-08T18:55:00Z",
                "marketPrefix": "CNR",
                "score": "{\"0\":[5,5],\"1\":[1,4],\"2\":[4,1]}"
              }
            ]
          }
        ]
      }
    ]
  }
  ],
  "errors": {}
}

Check the response objects structure specification below in this document.

Request parameters specification

Parameter Description Required Type
apiKey Your secret api key true VARCHAR
sportIds Comma-separated list of sport IDs false VARCHAR
leagueId league ID false BIGINT
startedFrom Return matches that started after this timestamp. If this parameter is not specified, all results for the last 24 hours are returned by default. Timestamp is expected in YYYY-MM-DDThh:mm:ssZ format in UTC timezone. false VARCHAR
startedTo Return matches that started before this timestamp. If this parameter is not specified, current time is used by default. Timestamp is expected in YYYY-MM-DDThh:mm:ssZ format in UTC timezone. false VARCHAR

Note: interval between startedFrom and startedTo should not exceed 30 days.

Response objects structure specification

Sport type

Field name Description Type
id Id SHORT
name sport name VARCHAR
countries Countries container Array of Countries

Country type

Field name Description Type
id Id SHORT
name Country name VARCHAR
leagues leagues array Array of Leagues

League type

Field name Description Type
id Id INT
name league name VARCHAR
nameRu league name in Russian (if exists) VARCHAR
events Events container Array of Events

Event type

Field name Description Type
ids array of event IDs Array of BIGINT
home Home Team Team
away Away Team Team
score match score VARCHAR
marketPrefix Score type identifier. If not specified (NULL or "") then it is a main score. Other variants:
YC - yellow cards
SUBS - substitution
SHOT - shots on goal
FOUL - foul
POS - possession of the ball
OFS - offside
ACE - Ace
DBF - Double fault
VARCHAR
startedAt match start timestamp in YYYY-MM-DDThh:mm:ssZ format in UTC timezone VARCHAR

Team type

Field name Description Type
id Id BIGINT
name Team Name VARCHAR
nameRu Team Name in Russian (of exists) VARCHAR
Clone this wiki locally