2014-11-23 56 views
3

關於來自蒸汽市場的物品,我想知道是否有辦法在一段時間內檢索物品的價格歷史記錄。在蒸汽市場檢索物品的價格歷史

我知道Steam爲希望將特定於市場的數據集成到自己的網站的開發者提供了一個特殊API,但我一直無法找到任何關於以json的形式檢索物品的價格歷史記錄的任何信息。

有沒有人已經做過這個?

回答

6

我已經做了一些更多的研究,並找到了檢索物品價格歷史的方法。

對於那些誰是好奇,這個隨機項「專Killstreak銅獸」的價格歷史可以以這種方式來獲取一個例子:

http://steamcommunity.com/market/pricehistory/?country=DE&currency=3&appid=440&market_hash_name=Specialized%20Killstreak%20Brass%20Beast

+0

它現在不工作 – sfszh 2016-04-15 10:39:26

+0

@sfszh它確實有效。您需要先登錄。 – 2016-04-27 17:59:43

0

如果從代碼中調用

url ="http://steamcommunity.com/market/pricehistory/" 

和查詢字符串的有效載荷是:

{ 
    "country" = "US",  # two letter ISO country code 
    "currency"= 1,  # 1 is USD, 3 is EUR, not sure what others are 
    "appid" = 753,  # this is the application id. 753 is for steam cards 
    "market_hash_name" ="322330-Shadows and Hexes" # this is the name of the item in the steam market. 
} 

國家代碼是ISO Country Code

您可以從其商店頁面的網址中找到遊戲的應用ID。示例:遊戲「CS:GO」應用程序ID爲730. Store page

您可以從其市場頁面的URL中找到市場散列名稱。例如:This CS:GO item散列名稱是「手套案例密鑰」。

手套箱鑰匙的價格歷史爲here