|
|
@@ -1,13 +1,21 @@
|
|
|
+# pylint: disable=C0303
|
|
|
+
|
|
|
import requests
|
|
|
import json
|
|
|
-SteamUN = "Marorin"
|
|
|
|
|
|
+SteamUN = "Marorin"
|
|
|
key = '231E98D442E52B87110816C3D5114A1D'
|
|
|
|
|
|
def gamesPulling(steamID,key):
|
|
|
- # Returns the JSON data from the Steam API based of one's Steam ID number and returns a dictionary of gameids and minutes played.
|
|
|
- steaminfo = {'key': key, 'steamid': steamID,'format':'JSON','include_appinfo':'1'}
|
|
|
- r = requests.get('http://api.steampowered.com/IPlayerService/GetOwnedGames/v0001/', params=steaminfo)
|
|
|
+ # Returns the JSON data from the Steam API based of one's
|
|
|
+ # Steam ID number and returns a dictionary of gameids and minutes played.
|
|
|
+ steaminfo = {
|
|
|
+ 'key': key,
|
|
|
+ 'steamid': steamID,
|
|
|
+ 'format':'JSON',
|
|
|
+ 'include_appinfo':'1'
|
|
|
+ }
|
|
|
+ r = requests.get('http://api.steampowered.com/IPlayerService/GetOwnedGames/v0001/', params=steaminfo)
|
|
|
d = json.loads(r.content)
|
|
|
return d['response']['games']
|
|
|
|
|
|
@@ -19,6 +27,3 @@ def steamIDPulling(SteamUN,key):
|
|
|
SteamID = k['response']['steamid']
|
|
|
|
|
|
return SteamID
|
|
|
-# steampulling(steamID)
|
|
|
-steamID = steamIDPulling(SteamUN, key)
|
|
|
-gamesPulling(steamID,key)
|