SportsData API
  1. sportsdata
SportsData API
  • sportsdata
    • Retrieves a list of competitions for a given class id.
      GET
    • Retrieves a list of events for a given class id.
      GET
    • Retrieves a specific competition
      GET
    • Retrieves a list of events for a given competition id.
      GET
    • Retrieves a list of market groups for a given competition id
      GET
    • Retrieves a list of events/markets/selections where markets within said event match selected sort/groupId
      GET
    • Retrieves a list of events for the provided IDs.
      GET
    • Retrieves a single event by ID.
      GET
    • Gets one or more specific markets
      GET
    • Gets one or more selections for a market
      GET
    • Gets a list of all sports
      GET
    • Retrieves a list of classes for a given sport id.
      GET
    • Retrieves a list of competitions for a given sport id.
      GET
    • Retrieves a weighted list of Selections.
      GET
  • competitors
    • Retrieves competitors for a single event by ID.
      GET
  1. sportsdata

Gets one or more specific markets

GET
/events/{eventId}/markets/
sportsdata
Retrieves one or more specific markets. Markets with Live at the end are always In-Play markets. However, not ALL In-Play markets have Live at the end of the market name.
Request Request Example
Shell
JavaScript
Java
Swift
curl --location --request GET 'https://sandbox.whapi.com/v2/sportsdata/events//markets/' \
--header 'apiKey;'
Response Response Example
200 - response
{
 "markets": [
 {
 "id": "OB_MA2493",
 "name": "90 Minutes",
 "status": "A"
 },
 {
 "id": "OB_MA2559",
 "name": "Correct Score",
 "status": "A"
 }
 ]
}

Request

Path Params
eventId
string 
required
The event ID to retrieve information for.
Query Params
ids
array[string]
optional
A comma-separated list of selectionIds
includeAllDescendants
string 
optional
Include every descendant in the below heirarchy
fields
array[string]
optional
Specify an absolute field list to return (Comma-Separated List)
include
array[string]
optional
Specify fields in addition to the default to return (Comma-Separated List)
exclude
array[string]
optional
Specify fields from the default to exclude (Comma-Separated List)
includeEmpty
string 
optional
When declared as false it should exclude markets and events that have no selections / markets
culture
string 
optional
Code used to return responses in language other than English, acceptable values are en-GB|de-DE|es-ES|fr-FR|nn-NO|fi-FI|ru-RU|pt-PT|hu-HU|sl-SL|ga-IE|en-CA|sr-Latn|sv-SE|el=GR|zh-CHS|it-IT|zh-CHT|cs-CZ|de-AT|ja-JP|pl-PL|da-DK|ro-RO|nl-NL|tr-TR
marketPublished
string 
optional
Specify whether only active entities should be returned, according to the William Hill definition of active
marketStatus
string 
optional
Specify a status to filter results by. This is currently A (active) or S (suspended)
marketDisplayed
string 
optional
Specify whether to return displayed entities or not
marketChannel
string 
optional
Specify a channel filter and only results from that channel will be returned
marketSort
string 
optional
Filter by market sort (e.g. MR (match result) -- (Outright)).
marketEW
string 
optional
Specify whether to return markets with each way betting or those without
selectionStatus
string 
optional
Specify a status to filter results by. This is currently A (active) or S (suspended)
selectionChannel
string 
optional
Specify a channel filter and only results from that channel will be returned
selectionPublished
string 
optional
Specify whether only active entities should be returned, according to the William Hill definition of active
Header Params
apiKey
string 
required
Your API Key available from your developer portal

Responses

🟢200Success
application/json
Body
markets
array[object (market) {34}] 
optional
antepostMarket
boolean 
optional
Antepost Market
bestOddsGuaranteed
boolean 
optional
BOG Available
betInRunningDelay
number 
optional
channels
string 
optional
A channel indicates where an entry can be accessed. Its made up of a string containing a number of characters
description
string 
optional
Additional market information
displayed
boolean 
optional
Indicates if the item should be displayed
eachWay
boolean 
optional
Indicates if each way betting is available
eachWayFactorDen
number 
optional
Where each way terms are stored with the bet, this holds the denominator for the each way
factor. For example, if the each way terms are: 5 places pay ¼, this value will be 4
eachWayFactorNum
number 
optional
Where each way terms are stored with the bet, this holds the numerator for the each way
factor. For example, if the each way terms are: 5 places pay ¼, this value will be 1
eachWayPlaces
number 
optional
Where each way terms are stored with the bet, this holds the number of places paid. For
example, if the each way terms are: 5 places pay ¼, this value will be 5
earlyPriceAvailable
boolean 
optional
Early Pricing Active
fcAvailable
boolean 
optional
Is tricast betting available
firstFourAvailable
boolean 
optional
Is firstFour betting available
firstPriceAvailable
boolean 
optional
Is firstPrice betting available
flags
string 
optional
Flags for the market
hcapMakeup
number 
optional
Handicap score
hcapValue
number 
optional
This value indicates the current handicap set on the Event Market, assuming it has a handicap type.
id
string 
required
ID (e.g. OB_MA{id} (e.g. OB_MA1), OB_SP (Sport), OB_CL (Class), OB_TY (Competition / type), OB_EV (event) OB_MA (Market), OB_OU (Selection / outcome)
isInPlayMarket
boolean 
optional
Is this an in-play market
isPublished
boolean 
optional
Indicates if the item is published
livePriceAvailable
boolean 
optional
Live Price
marketGroupCollectionId
string 
optional
The collectionId of the Market Group inherited from
marketGroupId
string 
optional
The group id the market was inherited from
marketGroupName
string 
optional
The group name the market was inherited from
marketSort
string 
optional
The sort defines the market template
name
string 
required
Human-friendly name of the market
order
number 
optional
Display order of the items (Ascending)
parentIds
array[string]
optional
A list of IDs of parent entities
quinellaAvailable
boolean 
optional
Is firstFour betting available
selections
array[object (selection) {22}] 
optional
A list of selections belonging to the market
settled
boolean 
optional
Whether the market is settled or not
startingPriceAvailable
boolean 
optional
Starting Price Available
status
string 
required
Indicates the status of the Market (A = Active/S = Suspended)
tcAvailable
boolean 
optional
Is forecast betting available
🟠400Incorrect or Missing Parameter
🟠404No data found for request
Modified at 2023-08-15 06:10:46
Previous
Retrieves a single event by ID.
Next
Gets one or more selections for a market
Built with