Docs
Coverage MatrixDocumentationRelease LogLog InContact Us

Detailed real-time tournament statistics including player statistics at tournament and per-round level.

Syntax

https://api.sportradar.com/golf/{access_level}/stream/{golf_tour}/leaderboards/subscribe?api_key={your_api_key}&locale=en

Replace placeholders with the following query parameters:

ParameterDescription
access_levelDefines the access level of your API key as Production (production) or Trial (trial).
golf_tourpga, lpga, champ, pgad, euro, oly, or liv.
your_api_keyYour API key.

Optional Query String Parameters

In addition to the URL parameters listed above, you can filter the Leaderboard information with one or more of the following optional query string parameters.

📘

Optional query string parameters must be added after your API key with an ampersand (&). If you are filtering for more than one result, separate the results with a comma (,) and no spaces.

Replace placeholders with the following query parameters:

ParameterDescription
tournamentTournament id expressed as: sd:tournament:{tournament_id}.
Example: sd:tournament:9db12181-b55d-4e4f-8c18-936f4c7c7e2d
tournament_typeTournament type expressed as: {tournament_type}.
Example: tournament_type=stroke
scoring_systemScoring system expressed as: {scoring_system}.
Example: scoring_system=match
localeLocale expressed as 2 letter code: locale={language_code}
Example: locale=en
Valid codes: Chinese - simplified (zh), Chinese - traditional (zht), Danish (da), Dutch (nl), English (en), Finnish (fi), French (fr), German (de), Italian (it), Japanese (ja), Korean (ko), Norwegian (no), Spanish (es), Swedish (sv)

Click here for a tabular list of available languages per competition.

Code Samples

require 'uri'
require 'net/http'
require 'openssl'

url = URI("https://api.sportradar.us/golf/trial/stream/pga/leaderboards/subscribe?api_key={your_api_key}")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
http.verify_mode = OpenSSL::SSL::VERIFY_NONE

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
import requests
import json

r = requests.get("https://api.sportradar.com/golf/trial/stream/pga/leaderboards/subscribe",
    params = {'api_key': 'your_api_key'},
    allow_redirects=False)

redirect_url = r.headers['Location']
r = requests.get(redirect_url, stream=True)

for line in r.iter_lines():
    # filter out keep-alive new lines
    if line:
        decoded_line = line.decode('utf-8')
        print(json.loads(decoded_line))
curl -L GET 'api.sportradar.us/golf/trial/stream/pga/leaderboards/subscribe?api_key={your_api_key}'

Samples with Query String Params

require 'uri'
require 'net/http'
require 'openssl'

url = URI("https://api.sportradar.us/golf/trial/stream/pga/leaderboards/subscribe?api_key={your_api_key}&tournament=sd:tournament:9db12181-b55d-4e4f-8c18-936f4c7c7e2d&scoring_system=stroke")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
http.verify_mode = OpenSSL::SSL::VERIFY_NONE

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
import requests
import json

r = requests.get("https://api.sportradar.com/golf/trial/stream/pga/leaderboards/subscribe",
    params = {'api_key': 'your_api_key', 'tournament': 'sd:tournament:9db12181-b55d-4e4f-8c18-936f4c7c7e2d', 'scoring_system': 'stroke'},
    allow_redirects=False)

redirect_url = r.headers['Location']
r = requests.get(redirect_url, stream=True)

for line in r.iter_lines():
    # filter out keep-alive new lines
    if line:
        decoded_line = line.decode('utf-8')
        print(json.loads(decoded_line))
curl -L GET 'api.sportradar.us/golf/trial/stream/pga/leaderboards/subscribe?api_key={your_api_key}&tournament=sd:tournament:9db12181-b55d-4e4f-8c18-936f4c7c7e2d&scoring_system=stroke'


Response Sample

The above commands return json like this.





Data Points

Round Scoring:
AttributeParent ElementTypeDescription
birdiesleaderboard - roundsIntegerNumber of birdies for a player in a tournament round
bogeysleaderboard - roundsIntegerNumber of bogeys for a player in a tournament round
double_bogeysleaderboard - roundsIntegerNumber of double bogeys for a player in a tournament round
eaglesleaderboard - roundsIntegerNumber of eagles for a player in a tournament round
thruleaderboard - roundsIntegerNumber of holes completed for a player in a tournament round
holes_in_oneleaderboard - roundsIntegerNumber of holes in one for a player in a tournament round
other_scoresleaderboard - roundsIntegerNumber of other scores for a player in a tournament round (non- pars, birdies, eagles, holes in one, bogeys, double bogeys)
parsleaderboard - roundsIntegerNumber of pars for a player in a tournament round
sequenceleaderboard - roundsIntegerTournament round number
scoreleaderboard - roundsIntegerPlayer score in a round
ex. -4
strokesleaderboard - roundsShortPlayer strokes in a round
ex. 68
partpartIntegerSequential number of a tournament section/part. Used only in mix format events.
ex. 1 or 2
statuspartStringStatus of a tournament section/part. Used only in mix format events.
ex. inprogress or closed
typepartStringType of a tournament section/part. Used only in mix format events.
ex. stroke or match
Metadata:
AttributeParent ElementTypeDescription
localemetadataStringLanguage code
ex. en (English)
scoring_systemmetadataStringScoring system for a tournament
stroke, stableford
statusmetadataStringThe status of a tournament
ex. inprogress
tourmetadataStringName of tour
ex. pga
tournamentmetadataGUIDUnique ID(s) of a tournament
ex. sd:tournament:0d986e18-cc3d-4391-a37c-903e9097129f,sr:stage:721700
tournament_typemetadataStringType of a tournament
ex. stroke
versionmetadataStringVersion of the API
ex. v2
Player:
AttributeParent ElementTypeDescription
abbr_nameleaderboardStringAbbreviated name of a player
ex. R.McIlroy
amateurleaderboardBooleanSignifies a player is in amateur status when true
countryleaderboardStringCountry of a player
ex. NORTHERN IRELAND
first_nameleaderboardStringFirst name of a player
ex. Rory
idleaderboardGUIDUnique player ID
ex. da226913-b804-48de-adbf-96e956eb75ac
last_nameleaderboardStringLast name of a player
ex. McIlroy
nameleaderboardStringName of a player
ex. McIlroy, Rory
pointsleaderboardFloatFedEX points earned for a player in a tournament
positionleaderboardShortLeaderboard position for a player
moneyleaderboardFloatTournament money won (in US dollars) for a player
scoreleaderboardIntegerOverall player score in a tournament or playoff
ex. -10
statusleaderboardStringStatus of a player for a particular tournament
CUT, WD, MDF, DQ, DNS

See our Golf FAQ for more info and definitions of each status
strokesleaderboardShortOverall player strokes in a tournament or playoff
sr_idleaderboardGUIDUnique Sportradar ID of a player
ex. sr:competitor:46702
tiedleaderboardBooleanSignifies a tie for a leaderboard spot
Tournament:
AttributeParent ElementTypeDescription
coveragepayloadStringCoverage of a tournament. Click *here for a complete breakdown of our tour coverage.
ex. full
currencypayloadStringPrize money currency type of a tournament
ex. USD
end_datepayloaddateTimeEnd date of a tournament
ex. 2022-11-20
event_typepayloaddateTimeScoring type of a tournament
stroke, match, cup, team, mix
idpayloadGUIDUnique ID of a tournament
ex. 42b7bbc2-858a-4c0d-85dc-b30179bb5e9a
namepayloadStringName of a tournament
ex. Wells Fargo Championship
parent_idpayloadGUIDUnique parent ID for a tournament. Use this ID to tie reoccurring events across seasons.
ex. 5c8d8f92-8da7-4d5d-860b-e820d57ff640 (ID for The Masters)
pointspayloadIntegerTotal number of FedEX Cup points for a tournament
pursepayloadFloatTotal prize money for a tournament
ex. 15000000.0
start_datepayloaddateTimeStart date of a tournament
ex. 2022-11-20
statuspayloadGUIDStatus of a tournament
scheduled, inprogress, delayed, cancelled, created, complete, closed, playoff, reopened
winning_sharepayloadFloatPrize money for first place in a tournament
ex. 1080000.0