No Subscription to this function
GET /motorsports/get_session
Returns results of a particular session
Request URL
https://dsg-api.com/clients/{client_name}/motorsports/get_session?id={round_id}&client={client_name}&authkey={client_authkey}
Parameters
authkey
string Required
client authentification key
client
string Required
unique client ID
ftype
string
changes feed type from XML to json (ftype=json)
id
int Required
session_id to return
lang
string
two-character language code, defaults to 'en'
Nodes
championship
details about a championship
championship_id
unique championship identifier
name
name of the particular championship
championship_season
details about a championship season
championship_season_id
unique identifier of a championship season
title
title of the particular championship season
method
details about the API function
method_id
unique ID of method.
name
name of method.
people
details about the driver and his performance
common_name
common name of the driver
driver_number
driver number of the driver
first_name
first name of the driver
last_name
last name of the driver
match_name
match name of the driver
nationality
nationality of the driver
nationality_area_code
area code of drivers nationality
nationality_area_id
unique identifier for area.
people_id
unique identifier for the athlete.
picture
full path URL of driver headshot, size can be changed via the picsize parameter
pitstops
number of pitstops in the particular session
position
position of the driver
status
status of the driver for the particular session
team_carbike
model of the car driven for the particular session
team_engine
model of the engine used for the particular session
team_id
unique identifier for a team
team_name
team name
time
total time (races) or best time (practices and qualifyings) in the particular session
track_laps
number of laps in the particular session
race
details about a specific race
area_id
unique identifier for area.
area_name
contains the area name.
city_name
Name of the city where the race was located
end_date
End date of season, format 'yyyy-mm-dd'.
logo
full path URL of logo for particular season
race_id
unique identifier for a race
race_title
title of the race (normally the year of the season used)
season_id
unique identifier of an particular season of the race
season_name
name of the race for this particular year (including sponsor names etc)
season_title
title of season
start_date
Start date of season, format 'yyyy-mm-dd'.
winner
people_id of the race winner
winner_name
name of the race winner
winner_nationality
nationality of the winner (area_id)
session
details about a specific session of a season
end_date_utc
End date of session (UTC), format 'yyyy-mm-dd'.
end_time_utc
End time of session (UTC), format 'hh:ii:ss'.
race_distance
distance of the whole race in kilometers
session_id
unique identifier for a session
session_name
name of the particular session
start_date_utc
Start date of session (UTC), format 'yyyy-mm-dd'.
start_time_utc
Start time of session (UTC), format 'hh:ii:ss'.
track_laps
number of laps for the race session
track_length
distance of one round in kilometers
Response Headers
200
Success
401
Unauthorized
429
Rate limit exceeded
Code Samples
<?php
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, "https://dsg-api.com/clients/{client_name}/motorsports/get_session?id={round_id}&client={client_name}&authkey={client_authkey}");
curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
curl_setopt($ch, CURLOPT_USERPWD, "User:Password");
$content = curl_exec($ch);
curl_close($ch);
?>
curl GET -u "User:Password" "https://dsg-api.com/clients/{client_name}/motorsports/get_session?id={round_id}&client={client_name}&authkey={client_authkey}"
response = requests.get("https://dsg-api.com/clients/{client_name}/motorsports/get_session?id={round_id}&client={client_name}&authkey={client_authkey}", auth=("User", "Password"))
Response Example
200 Success
{"datasportsgroup":{"version":"1.0","sport":"motorsports","lang":"en","method":{"method_id":"324","name":"get_calendar"},"championship":{"championship_id":"7","name":"FIA Formula One World Championship","championship_season":{"championship_season_id":"24","title":"2019","race":{"race_id":"1901","race_name":"Abu Dhabi Grand Prix","area_id":"202","area_name":"United Arab Emirates","season_id":"21113","season_title":"2019","season_name":"Abu Dhabi Grand Prix","winner":"","winner_name":"","start_date":"2019-11-29","end_date":"2019-12-01","logo":"","session":{"session_id":"30691","session_name":"Race","start_date_utc":"2019-12-01","start_time_utc":"12:10:00","end_date_utc":"2019-12-01","end_time_utc":"14:10:00","race_distance":"305.47","track_length":"5.554","track_laps":"55"}}}}}}