【问题标题】:Steam web API getting CS:GO inventorySteam Web API 获取 CS:GO 库存
【发布时间】:2014-11-16 15:20:03
【问题描述】:

好的,所以我一直在整个互联网上寻找这个,我发现当你想获得某人的 Steam 库存时,你会使用这个:

http://api.steampowered.com/IEconItems_{appid}/GetPlayerItems/v0001/?key={apikey}&steamid={steamid}&format=json

但问题是,当我为 CS:GO (appid: 730) 执行此操作时,我得到的只是一个空响应,即使用户的库存中有物品。

【问题讨论】:

标签: json steam steam-web-api


【解决方案1】:

如果您想获取 json,只需使用以下链接之一:

一般 Steam 库存:(1:游戏,3:优惠券,6:集换式卡牌,7:奖励)

http://steamcommunity.com/id/<USERURL>/inventory/json/753/1
http://steamcommunity.com/profiles/<STEAMID>/inventory/json/753/1

http://steamcommunity.com/id/<USERURL>/inventory/json/753/3
http://steamcommunity.com/profiles/<STEAMID>/inventory/json/753/3

http://steamcommunity.com/id/<USERURL>/inventory/json/753/6
http://steamcommunity.com/profiles/<STEAMID>/inventory/json/753/6

http://steamcommunity.com/id/<USERURL>/inventory/json/753/7
http://steamcommunity.com/profiles/<STEAMID>/inventory/json/753/7

游戏:

http://steamcommunity.com/id/<USERURL>/inventory/json/<APPID>/2
http://steamcommunity.com/profiles/<STEAMID>/inventory/json/<APPID>/2

问题不在于反恐精英 appid, 您刚刚使用了仅适用于一般 Steam 库存的旧链接。 我建议您使用 STEAMID 的链接,因为并非每个 Steam 用户都设置了自定义网址。

【讨论】:

  • 每分钟20次通话限制后是否阻塞?
  • 那么,如果我的网站每秒流量超过 10000,那我就完蛋了?
  • 如果您的网站调用了这么多电话,那么无论如何您都被搞砸了……您应该认真考虑您的概念并尽可能考虑缓存
  • 我们有任何第三方插件 Shiv 可以做到这一点吗?我认为 Bitskins 具有这种功能,您可以在其中选择是从 Steam 中还是从缓存中显示您的库存。我想知道他们是怎么做到的……
  • 是的,但是大多数网站使用的那个要花一些钱...csgo.steamlytics.xyz/api 看到他们对不同的网站“大小”有不同的计划 - 可能有不同的计划,但大多数网站都使用这个 afaik跨度>
猜你喜欢
  • 2021-12-05
  • 2015-01-23
  • 1970-01-01
  • 2015-02-12
  • 1970-01-01
  • 1970-01-01
  • 2017-01-01
  • 2014-11-04
相关资源
最近更新 更多