Difference between revisions of "WebAPI/GetGlobalStatsForGame"

From Team Fortress Wiki
Jump to: navigation, search
(Method-specific Parameters)
('''Main article about WebAPI.''')
 
(2 intermediate revisions by 2 users not shown)
Line 1: Line 1:
 +
'''Main article about [[WebAPI]].'''
 
== URL ==
 
== URL ==
 
<nowiki>http://api.steampowered.com/ISteamUserStats/GetGlobalStatsForGame/v0001</nowiki>
 
<nowiki>http://api.steampowered.com/ISteamUserStats/GetGlobalStatsForGame/v0001</nowiki>
Line 10: Line 11:
 
;{{API optional|enddate}}: End date for daily totals (unix epoch timestamp).
 
;{{API optional|enddate}}: End date for daily totals (unix epoch timestamp).
  
== Result Data ==
+
== Result data ==
 +
;response:
 +
:;result: Returns result code.
 +
:;globalstats: An array of results.
 +
::;[name of stat]: The name of the requested stat.
 +
:::;total: The value of the stat.
  
{{Languages|WebAPI/GetGlobalStatsForGame}}
 
 
[[Category:WebAPI|GetGlobalStatsForGame]]
 
[[Category:WebAPI|GetGlobalStatsForGame]]

Latest revision as of 20:13, 18 December 2021

Main article about WebAPI.

URL

http://api.steampowered.com/ISteamUserStats/GetGlobalStatsForGame/v0001

Method-specific Parameters

appid
The ID of the game to retrieve global stats for. This can be the ID of any Steamworks game with global stats available.
count
Number of stats to get data for.
name[0]
Names of the stats to get. For more than one value, use a parameter for each request. (name[0], name[1], ...)
Not all stats are globally aggregated. The developer of the game must mark the stat as globally aggregated.
startdate (Optional)
Start date for daily totals (unix epoch timestamp).
enddate (Optional)
End date for daily totals (unix epoch timestamp).

Result data

response
result
Returns result code.
globalstats
An array of results.
[name of stat]
The name of the requested stat.
total
The value of the stat.