Subscription to this function is not available for your account. To upgrade and receive access to this contact sales@datasportsgroup.com
v2 GET /water_polo/get_tables
Returns the league, home & away tables per season or round.
Request URL
https://dsg-api.com/clients/{client_name}/water_polo/get_tables?type={type}&id={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)
gameweek
int
gameweek value to get table from
lang
string
two-character language code, defaults to 'en'
live
string
only 'yes' is valid which will provide a live table
type
string Required
type is either "season" or "round"
Nodes
competition
details about competition
area_id
unique identifier for an area
area_name
name of the area
competition_id
unique identifier for a competition
format
competition format (domestic_league, domestic_cup, domestic_league_cup, domestic_super_cup, international_cup, international_super_cup, playoff, tournament, race, unofficial)
gender
determines the gender of the competition (male or female)
last_updated
When record was last updated. Format YYYY-MM-DD HH:MM:SS in CET timezone.
name
name of the competition
type
determines if a competition is between club teams (club) or national teams (international)
datasportsgroup
details about the API version, sport, language and generation timestamp
generated_utc
UTC timestamp when the API output was generated
lang
language of the API call
sport
sport value
version
version of the API
list
details about list type
aggregation_type
aggregation type (scores or wins)
id
unique identifier for a group if type = group, if type = playoff then for a playoff
last_updated
When record was last updated. Format YYYY-MM-DD HH:MM:SS in CET timezone.
name
name of either a group or playoff
score_a
playoff score of team_a
score_b
playoff score of team_b
type
list type (regular, group or playoff)
winner_team_id
unique identifier for the winning team of the playoff
method
details about the API function
method_id
unique ID of method
name
name of method
round
details about the round
end_date
end date, format 'yyyy-mm-dd'
end_date_utc
end date in UTC timezone, format 'yyyy-mm-dd'
end_time
end time, format 'HH:mm:ss'
end_time_utc
end time in UTC timezone, format 'HH:mm:ss'
last_updated
When record was last updated. Format YYYY-MM-DD HH:MM:SS in CET timezone.
name
name of round
round_id
unique identifier of round
start_date
start date, format 'yyyy-mm-dd'
start_date_utc
start date in UTC timezone, format 'yyyy-mm-dd'.
start_time
start time, format 'HH:mm:ss'
start_time_utc
start time in UTC timezone, format 'HH:mm:ss'
type
determines if the round contains a table or a cup structure (knock-out)
season
details about the season
end_date
end date, format 'yyyy-mm-dd'
last_updated
When record was last updated. Format YYYY-MM-DD HH:MM:SS in CET timezone.
logo
full path URL of logo for particular season
original_name
competition name during this season
season_id
unique identifier for season
start_date
start date, format 'yyyy-mm-dd'
title
title of season
table
details about the table entry
area_id
unique identifier for an area
form
performance of the last 5 matches in the particular round (W = win, D = draw, L = loss)
live
indicates if there is a live game for the team
next_match_id
match_id of the upcoming match in the particular round
next_opponent_name
current team name of the next opponent in the particular round
next_opponent_team_id
team_id of the next opponent in the particular round
original_team_name
original team name during the season
position
position value
prev_season
defines last season achievements ('C','CW','P','R')
short_name
shortened name of the person
team_id
unique identifier of the team
team_logo
full path URL of team logo
team_name
current team name
zone
name of table zone
zone_id
unique identifier for a table zone
tour
details about the tour
gender
gender of the tour
name
name of the particular tour
tour_id
unique tour identifier
tour_type
defines if the tournament is part of a tour or not. If not then value "non-tour"
tour_season
details about a tour season
logo
full path URL of logo for particular tour_season
name
name of the tour_season
title
title of the particular tour season
tour_season_id
unique identifier of a tour season
values
tables values of the team (water polo/field hockey)
matches_draw
value for total drawn matches
matches_lost
value for total lost matches
matches_total
value for total played matches
matches_won
value for total won matches
points
value for total points gained
score_against
value for total score against
score_difference
value for total score difference
score_for
value for total scored made
Response Headers
200
Success
401
Unauthorized
429
Too Many Requests
Code Samples
<?php
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, "https://dsg-api.com/clients/{client_name}/water_polo/get_tables?type={type}&id={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}/water_polo/get_tables?type={type}&id={id}&client={client_name}&authkey={client_authkey}"
Imports System
Imports System.Net	
Imports System.IO
Imports System.Text

Public Module Module1
	Public Sub Main()
		Dim url As String = "https://dsg-api.com/clients/{client_name}/water_polo/get_tables?type={type}&id={id}&client={client_name}&authkey={client_authkey}"
		Dim myReq As WebRequest = WebRequest.Create(url)
		myReq.Credentials = new System.Net.NetworkCredential("{User}", "{Password}")
		Dim wr As WebResponse = myReq.GetResponse()
		Dim receiveStream As Stream = wr.GetResponseStream()
		Dim reader As StreamReader = New StreamReader(receiveStream, Encoding.UTF8)
		Dim content As String = reader.ReadToEnd()
	End Sub
End Module
response = requests.get("https://dsg-api.com/clients/{client_name}/water_polo/get_tables?type={type}&id={id}&client={client_name}&authkey={client_authkey}", auth=("User", "Password"))
Response Example
200 Success
{"datasportsgroup":{"version":"1.0","sport":"water_polo","lang":"en","method":{"method_id":"222","name":"get_tables"},"competition":{"competition_id":"1961","name":"FINA World Cup","teamtype":"male","type":"international","format":"international_cup","area_id":"1","area_name":"World","last_updated":"2019-06-09 18:57:45","season":{"season_id":"18084","title":"2018 Berlin","original_name":"FINA World Cup","start_date":"2018-09-11","end_date":"2018-09-16","logo":"https:\/\/www.dsg-images.com\/comps\/200x200\/1961_1.png","last_updated":"2018-09-11 13:26:51","rounds":{"round_id":"24153","name":"Preliminary Round","start_date":"2018-09-11","end_date":"2018-09-13","type":"table","last_updated":"2018-09-07 13:54:53","group":[{"group_id":"6326","name":"Group 1","last_updated":"2018-09-07 13:56:38","total":{"table":[{"position":"1","team_id":"36698","team_name":"Germany","short_name":"Germany","original_team_name":"Germany","zone":"","zone_id":"","prev_season":"","form":"L,W,W","next_match_id":"","next_opponent_team_id":"","next_opponent_name":"","matches_total":"3","matches_won":"2","matches_draw":"0","matches_lost":"1","score_for":"35","score_against":"29","score_difference":"6","points":"4"},{"position":"2","team_id":"36697","team_name":"Hungary","short_name":"Hungary","original_team_name":"Hungary","zone":"","zone_id":"","prev_season":"","form":"W,W,L","next_match_id":"","next_opponent_team_id":"","next_opponent_name":"","matches_total":"3","matches_won":"2","matches_draw":"0","matches_lost":"1","score_for":"38","score_against":"34","score_difference":"4","points":"4"},{"position":"3","team_id":"36696","team_name":"Australia","short_name":"Australia","original_team_name":"Australia","zone":"","zone_id":"","prev_season":"","form":"W,L,W","next_match_id":"","next_opponent_team_id":"","next_opponent_name":"","matches_total":"3","matches_won":"2","matches_draw":"0","matches_lost":"1","score_for":"32","score_against":"24","score_difference":"8","points":"4"},{"position":"4","team_id":"36709","team_name":"Japan","short_name":"Japan","original_team_name":"Japan","zone":"","zone_id":"","prev_season":"","form":"L,L,L","next_match_id":"","next_opponent_team_id":"","next_opponent_name":"","matches_total":"3","matches_won":"0","matches_draw":"0","matches_lost":"3","score_for":"29","score_against":"47","score_difference":"-18","points":"0"}]},"home":{"table":[{"position":"1","team_id":"36698","team_name":"Germany","short_name":"Germany","original_team_name":"Germany","matches_total":"3","matches_won":"2","matches_draw":"0","matches_lost":"1","score_for":"35","score_against":"29","score_difference":"6","points":"4"},{"position":"2","team_id":"36696","team_name":"Australia","short_name":"Australia","original_team_name":"Australia","matches_total":"2","matches_won":"1","matches_draw":"0","matches_lost":"1","score_for":"22","score_against":"15","score_difference":"7","points":"2"},{"position":"3","team_id":"36697","team_name":"Hungary","short_name":"Hungary","original_team_name":"Hungary","matches_total":"1","matches_won":"1","matches_draw":"0","matches_lost":"0","score_for":"19","score_against":"14","score_difference":"5","points":"2"},{"position":"4","team_id":"36709","team_name":"Japan","short_name":"Japan","original_team_name":"Japan","matches_total":"0","matches_won":"0","matches_draw":"0","matches_lost":"0","score_for":"0","score_against":"0","score_difference":"0","points":"0"}]},"away":{"table":[{"position":"1","team_id":"36696","team_name":"Australia","short_name":"Australia","original_team_name":"Australia","matches_total":"1","matches_won":"1","matches_draw":"0","matches_lost":"0","score_for":"10","score_against":"9","score_difference":"1","points":"2"},{"position":"2","team_id":"36697","team_name":"Hungary","short_name":"Hungary","original_team_name":"Hungary","matches_total":"2","matches_won":"1","matches_draw":"0","matches_lost":"1","score_for":"19","score_against":"20","score_difference":"-1","points":"2"},{"position":"3","team_id":"36698","team_name":"Germany","short_name":"Germany","original_team_name":"Germany","matches_total":"0","matches_won":"0","matches_draw":"0","matches_lost":"0","score_for":"0","score_against":"0","score_difference":"0","points":"0"},{"position":"4","team_id":"36709","team_name":"Japan","short_name":"Japan","original_team_name":"Japan","matches_total":"3","matches_won":"0","matches_draw":"0","matches_lost":"3","score_for":"29","score_against":"47","score_difference":"-18","points":"0"}]}},{"group_id":"6327","name":"Group 2","last_updated":"2018-09-07 13:56:43","total":{"table":[{"position":"1","team_id":"36694","team_name":"Croatia","short_name":"Croatia","original_team_name":"Croatia","zone":"","zone_id":"","prev_season":"","form":"D,W,W","next_match_id":"","next_opponent_team_id":"","next_opponent_name":"","matches_total":"3","matches_won":"2","matches_draw":"1","matches_lost":"0","score_for":"50","score_against":"22","score_difference":"28","points":"5"},{"position":"2","team_id":"36692","team_name":"Serbia","short_name":"Serbia","original_team_name":"Serbia","zone":"","zone_id":"","prev_season":"","form":"D,W,W","next_match_id":"","next_opponent_team_id":"","next_opponent_name":"","matches_total":"3","matches_won":"2","matches_draw":"1","matches_lost":"0","score_for":"45","score_against":"21","score_difference":"24","points":"5"},{"position":"3","team_id":"36693","team_name":"United States","short_name":"United States","original_team_name":"United States","zone":"","zone_id":"","prev_season":"","form":"W,L,L","next_match_id":"","next_opponent_team_id":"","next_opponent_name":"","matches_total":"3","matches_won":"1","matches_draw":"0","matches_lost":"2","score_for":"33","score_against":"35","score_difference":"-2","points":"2"},{"position":"4","team_id":"36690","team_name":"South Africa","short_name":"South Africa","original_team_name":"South Africa","zone":"","zone_id":"","prev_season":"","form":"L,L,L","next_match_id":"","next_opponent_team_id":"","next_opponent_name":"","matches_total":"3","matches_won":"0","matches_draw":"0","matches_lost":"3","score_for":"11","score_against":"61","score_difference":"-50","points":"0"}]},"home":{"table":[{"position":"1","team_id":"36692","team_name":"Serbia","short_name":"Serbia","original_team_name":"Serbia","matches_total":"3","matches_won":"2","matches_draw":"1","matches_lost":"0","score_for":"45","score_against":"21","score_difference":"24","points":"5"},{"position":"2","team_id":"36694","team_name":"Croatia","short_name":"Croatia","original_team_name":"Croatia","matches_total":"2","matches_won":"2","matches_draw":"0","matches_lost":"0","score_for":"40","score_against":"12","score_difference":"28","points":"4"},{"position":"3","team_id":"36693","team_name":"United States","short_name":"United States","original_team_name":"United States","matches_total":"0","matches_won":"0","matches_draw":"0","matches_lost":"0","score_for":"0","score_against":"0","score_difference":"0","points":"0"},{"position":"4","team_id":"36690","team_name":"South Africa","short_name":"South Africa","original_team_name":"South Africa","matches_total":"1","matches_won":"0","matches_draw":"0","matches_lost":"1","score_for":"6","score_against":"15","score_difference":"-9","points":"0"}]},"away":{"table":[{"position":"1","team_id":"36693","team_name":"United States","short_name":"United States","original_team_name":"United States","matches_total":"3","matches_won":"1","matches_draw":"0","matches_lost":"2","score_for":"33","score_against":"35","score_difference":"-2","points":"2"},{"position":"2","team_id":"36694","team_name":"Croatia","short_name":"Croatia","original_team_name":"Croatia","matches_total":"1","matches_won":"0","matches_draw":"1","matches_lost":"0","score_for":"10","score_against":"10","score_difference":"0","points":"1"},{"position":"3","team_id":"36692","team_name":"Serbia","short_name":"Serbia","original_team_name":"Serbia","matches_total":"0","matches_won":"0","matches_draw":"0","matches_lost":"0","score_for":"0","score_against":"0","score_difference":"0","points":"0"},{"position":"4","team_id":"36690","team_name":"South Africa","short_name":"South Africa","original_team_name":"South Africa","matches_total":"2","matches_won":"0","matches_draw":"0","matches_lost":"2","score_for":"5","score_against":"46","score_difference":"-41","points":"0"}]}}]}}}}}