fantasy-performance-points
Daily Fantasy Performance Point Predictions
The following describes how to retrieve the predicted DraftKings and FanDuel player Fantasy points for an event.
Method | Description | Availability |
---|---|---|
GET | /sports-data/{sport}/v2/fantasy_performances | MLB, NBA, NFL, NHL |
The fantasy performance API provides pregame fantasy performance points for player props. Data is updated when related event and player information changes such as injury statuses, event depth charts and final box scores.
Information can be updated roughly every 15 mins if a change is required. Please review our Integration Guide for general suggestions on data flow, caching and optimizing queries to our APIs.
NOTE: The API key is a secret key associated with your account. Do not share it or expose it in public web pages. Doing so would allow anyone to make queries as if they were you. If you think your API key may have been compromised, contact your Account representative immediately to disable your current key and receive a new key.
Request
The following describes all the information required to query the fantasy performance API.
Entrypoint
GET https://api.fairplaybettech.com/sports-data/{sport}/v2/fantasy_performances?event.startDate[after]=now&order[event.startDate]=ASC&count=1
Required Path Parameters
sport
the sport api such asamerican-football
.
Required Query Parameters
api_key
Your api key available though the dashboard admin or ask your account representative.
Optional Filter Query Parameters
player.firstName
(partial) the related player’s first nameplayer.lastName
(partial) the related player’s last nameplayer.fullName
(partial) the related player’s full nameplayer.uniform
(exact) the related player’s jersey numberplayer.uuid
(exact) the related player’s uuidteam.location
(partial) the related team’s location (city name, for example Toronto)team.nickName
(partial) the related team’s name (Raptors, for example Raptors)team.uuid
(exact) the related team’s UUIDevent.uuid
(exact) the related event’s UUIDposition
(exact) the position abbreviation such asQB
Optional Sorting Query Parameters
event.startDate
(yyyy-mm-dd hh:mm or now) the related event’s start date in UTC
Optional Ordering Query Parameters
event.startDate
the related event’s start date in UTC
Paging
count
the number of items per page. Default30
page
the page number starting with1
Response
The following describes the expected response.
DFS attributes
The response format follows the standard JSON:API format and includes the following attributes for each player FantasyPerformance
entity:
draftKingsPoints
fanDuelPoints
position
Example
Note: You will need to include your api_key
in the query examples.
Future events
Points for future events as of now
order by event.startDate
Example Query
curl "https://api.fairplaybettech.com/american-football/v2/fantasy_performances?event.startDate[after]=now&order[event.startDate]=ASC&count=1&api_key=YOUR_API_KEY"
Example Result
{
"links": {
"self": "\/american-football\/v2\/fantasy_performances?count=1\u0026event.startDate%5Bafter%5D=now\u0026order%5Bevent.startDate%5D=ASC\u0026page=1",
"first": "\/american-football\/v2\/fantasy_performances?count=1\u0026event.startDate%5Bafter%5D=now\u0026order%5Bevent.startDate%5D=ASC\u0026page=1",
"last": "\/american-football\/v2\/fantasy_performances?count=1\u0026event.startDate%5Bafter%5D=now\u0026order%5Bevent.startDate%5D=ASC\u0026page=1156",
"next": "\/american-football\/v2\/fantasy_performances?count=1\u0026event.startDate%5Bafter%5D=now\u0026order%5Bevent.startDate%5D=ASC\u0026page=2"
},
"meta": {
"totalItems": 1156,
"itemsPerPage": 1,
"currentPage": 1
},
"data": [
{
"id": "\/american-football\/v2\/fantasy_performances\/ea5bdf4e-eede-350d-a881-a206cdbe4ac6",
"type": "FantasyPerformance",
"attributes": {
"uuid": "ea5bdf4e-eede-350d-a881-a206cdbe4ac6",
"position": "K",
"fanDuelPoints": 7.60187,
"draftKingsPoints": 7.60187,
"updatedAt": "2023-07-19T17:59:54+00:00"
},
"relationships": {
"player": {
"data": {
"type": "Player",
"id": "\/american-football\/v2\/players\/c5fcdc3d-c45c-42d7-89db-e0645bac4c18"
}
},
"event": {
"data": {
"type": "Event",
"id": "\/american-football\/v2\/events\/cc1c08fa-6647-4e66-ad31-d82959ce73d7"
}
},
"team": {
"data": {
"type": "Team",
"id": "\/american-football\/v2\/teams\/cfd747f4-6b21-4896-b65a-b90787522092"
}
}
}
}
]
}
To include the related player, event and/or team information in the response you can also use the JSON:API include
query parameter such as:
curl "https://api.fairplaybettech.com/american-football/v2/fantasy_performances?event.startDate[after]=now&order[event.startDate]=ASC&include=player&count=1&api_key=YOUR_API_KEY"
This will then include the team, player and event information in the included
attribute of the result:
{
"links": {
"self": "\/american-football\/v2\/fantasy_performances?count=1\u0026event.startDate%5Bafter%5D=now\u0026include=player\u0026order%5Bevent.startDate%5D=ASC\u0026page=1",
"first": "\/american-football\/v2\/fantasy_performances?count=1\u0026event.startDate%5Bafter%5D=now\u0026include=player\u0026order%5Bevent.startDate%5D=ASC\u0026page=1",
"last": "\/american-football\/v2\/fantasy_performances?count=1\u0026event.startDate%5Bafter%5D=now\u0026include=player\u0026order%5Bevent.startDate%5D=ASC\u0026page=1156",
"next": "\/american-football\/v2\/fantasy_performances?count=1\u0026event.startDate%5Bafter%5D=now\u0026include=player\u0026order%5Bevent.startDate%5D=ASC\u0026page=2"
},
"meta": {
"totalItems": 1156,
"itemsPerPage": 1,
"currentPage": 1
},
"data": [
{
"id": "\/american-football\/v2\/fantasy_performances\/ea5bdf4e-eede-350d-a881-a206cdbe4ac6",
"type": "FantasyPerformance",
"attributes": {
"uuid": "ea5bdf4e-eede-350d-a881-a206cdbe4ac6",
"position": "K",
"fanDuelPoints": 7.60187,
"draftKingsPoints": 7.60187,
"updatedAt": "2023-07-19T17:59:54+00:00"
},
"relationships": {
"player": {
"data": {
"type": "Player",
"id": "\/american-football\/v2\/players\/c5fcdc3d-c45c-42d7-89db-e0645bac4c18"
}
},
"event": {
"data": {
"type": "Event",
"id": "\/american-football\/v2\/events\/cc1c08fa-6647-4e66-ad31-d82959ce73d7"
}
},
"team": {
"data": {
"type": "Team",
"id": "\/american-football\/v2\/teams\/cfd747f4-6b21-4896-b65a-b90787522092"
}
}
}
}
],
"included": [
{
"id": "\/american-football\/v2\/players\/c5fcdc3d-c45c-42d7-89db-e0645bac4c18",
"type": "Player",
"attributes": {
"firstName": "Michael",
"lastName": "Badgley",
"fullName": "Michael Badgley",
"heightInches": 70,
"weightLbs": 188,
"uniform": "17",
"experience": "6",
"birthDate": "1995-07-28T00:00:00+00:00",
"collegeName": "Miami (FL)",
"dfsSalary": null,
"dfsPosition": null,
"dfsPoints": null,
"uuid": "c5fcdc3d-c45c-42d7-89db-e0645bac4c18",
"sportRadarUuid": "375b0d7f-8d03-4111-8c1b-62907f0326a1",
"draftData": {
"draft_year": null,
"rookie_year": 2018,
"draft_round": null,
"draft_pick": null
},
"insightMultiple": null,
"insightNew": false,
"top10Insight": null,
"displayStatus": "active",
"isInjured": false,
"isActive": true,
"isSuspended": false,
"combinedName": "Michael Badgley",
"imageURL": "https:\/\/avatar.api.quarter4.io\/american-football\/avatar\/cfd747f4-6b21-4896-b65a-b90787522092\/256\/uniform\/17.png",
"avatarUrl": "https:\/\/avatar.api.quarter4.io\/american-football\/avatar\/cfd747f4-6b21-4896-b65a-b90787522092\/256\/uniform\/17.png",
"updatedAt": "2023-07-19T16:07:21+00:00"
},
"relationships": {
"team": {
"data": {
"type": "Team",
"id": "\/american-football\/v2\/teams\/cfd747f4-6b21-4896-b65a-b90787522092"
}
},
"league": {
"data": {
"type": "League",
"id": "\/american-football\/v2\/leagues\/38344248-9889-11eb-a8ab-0647cdb505d0"
}
},
"currentSeasonStanding": {
"data": {
"type": "StandingPlayer",
"id": "\/american-football\/v2\/standings\/players\/f12a06ed-d615-455f-bde0-c2d7dd11b5c0"
}
},
"positions": {
"data": [
{
"type": "Position",
"id": "\/american-football\/v2\/positions\/b638cb3c-4f20-4311-8cc9-eac5d30e5650"
}
]
}
}
}
]
}