m0veax Posted May 18, 2020 Report Posted May 18, 2020 I want to getĀ number of played hours but idk how Quote
Dr. McKay Posted May 18, 2020 Report Posted May 18, 2020 https://steamapi.xpaw.me/#IPlayerService/GetOwnedGames Quote
4049_1572836826 Posted May 19, 2020 Report Posted May 19, 2020 var request = require("request"); var steamid = '76561197960934690'; var apikey = 'u api key'; request({ url: 'http://api.steampowered.com/IPlayerService/GetOwnedGames/v0001/?key='+apikey+'&steamid='+steamid+'&format=json&include_appinfo=1', json: true }, function (error, response, body) { // console.log(body.response.games); if (!error && response.statusCode === 200) { for (i = 0; i <= body.response.games.length; i++) { console.log(body.response.games[i].name + ' - ' + body.response.games[i].playtime_forever / 60 + ' hrs.') } } }) https://steamcommunity.com/dev/apikey Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.