Skip to content

steamanalyst/python

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 

Repository files navigation

SteamAnalyst Python SDK

The official Python client for the SteamAnalyst CS2 Pricing API.

Get real-time Counter-Strike 2 skin prices aggregated from 30+ marketplaces — including Buff, CSFloat, DMarket, SkinBaron, CS.Money, and more.

PyPI version License: MIT


About SteamAnalyst

SteamAnalyst is the leading price aggregator for CS2 skins, trusted by over 1 million monthly users since 2013. Unlike the Steam Market API, SteamAnalyst provides accurate, manipulation-resistant pricing by aggregating real transaction data from 30+ skin marketplaces.

Learn more about our methodology


Getting Started

1. Get Your API Key

Sign up for a free or paid API key at steamanalyst.com/api-info.

Plan Requests Best For
Hobby (Free) 100/day Personal projects, testing
Pro Custom Trading bots, commercial apps

2. Install

pip install steamanalyst

3. Use

from steamanalyst import SteamAnalyst

client = SteamAnalyst("your_api_key")

# Get a single item price
item = client.get_price("AK-47 | Redline (Field-Tested)")
print(item["price"])  # 25.50

API Reference

Full API documentation is available at api.steamanalyst.com/docs.

get_price(market_name)

Get the current price for a single CS2 item.

item = client.get_price("AWP | Dragon Lore (Factory New)")
# {"market_name": "AWP | Dragon Lore (Factory New)", "price": 12500.00}

get_all_prices()

Get prices for every CS2 item in a single request. Requires a paid API key.

items = client.get_all_prices()
print(f"Loaded {len(items)} items")

get_game_prices(market_name=None)

Get CS2 item data from the v2 endpoint. Pass an optional market_name for a single item.

# All items
all_items = client.get_game_prices()

# Single item
knife = client.get_game_prices("Karambit | Fade (Factory New)")

get_market_prices()

Compare prices across 30+ skin marketplaces — find the best deals instantly. Requires a paid API key.

data = client.get_market_prices()

redline = data["markets_prices"]["AK-47 | Redline (Field-Tested)"]
print(f"Buff: ${redline['buff']}")
print(f"CSFloat: ${redline['float']}")
print(f"DMarket: ${redline['dmarket']}")

Supported marketplaces include: Buff, CSFloat, DMarket, SkinBaron, CS.Money, BitSkins, Tradeit, Waxpeer, ShadowPay, LootFarm, SkinFlow, and many more.


Examples

Price Checker

from steamanalyst import SteamAnalyst

client = SteamAnalyst("your_api_key")

items = [
    "AK-47 | Redline (Field-Tested)",
    "AWP | Asiimov (Field-Tested)",
    "M4A4 | Howl (Factory New)",
]

for name in items:
    item = client.get_price(name)
    print(f"{name}: ${item['price']}")

Find the Cheapest Marketplace

from steamanalyst import SteamAnalyst

client = SteamAnalyst("your_api_key")
data = client.get_market_prices()

item = "AK-47 | Redline (Field-Tested)"
prices = data["markets_prices"][item]

cheapest = min(
    ((market, price) for market, price in prices.items() if price > 0),
    key=lambda x: x[1],
)

print(f"Cheapest for {item}: {cheapest[0]} at ${cheapest[1]}")

Error Handling

from steamanalyst import SteamAnalyst, SteamAnalystError

client = SteamAnalyst("your_api_key")

try:
    item = client.get_price("Nonexistent Skin")
except SteamAnalystError as e:
    print(f"API Error [{e.code}]: {e}")
    # API Error [ITEM_NOT_FOUND]: Item not found

Rate Limits

Rate limits depend on your API plan:

Plan Rate Limit Daily Limit
Hobby (Free) 30 req/min 100 req/day
Pro 300 req/min Unlimited

The SDK raises SteamAnalystError with code RATE_LIMIT_EXCEEDED when you hit the limit.


Requirements

  • Python 3.10+
  • Zero dependencies (uses urllib from the standard library)

Links


License

MIT - see LICENSE

Built and maintained by SteamAnalyst — tracking CS2 skin prices since 2013.

About

Official Python client for the SteamAnalyst CS2 Pricing API — real-time skin prices from 30+ marketplaces

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages