Skip to content

SDK & Examples

Official SDKs are thin, typed clients for the public API. They preserve HTTP status, request IDs, and pagination controls instead of hiding them.

from steamdeals import Client
client = Client(api_key="sd_live_...", region="US")
for game in client.games.list(query="Hades", limit=10):
    print(game.name, game.lowest_price.amount)
import { SteamDeals } from "@steamdeals/sdk";
const client = new SteamDeals({ apiKey: process.env.STEAMDEALS_API_KEY });
const { data } = await client.deals.list({ region: "US", minDiscount: 40 });
client := steamdeals.NewClient(os.Getenv("STEAMDEALS_API_KEY"))
deals, err := client.Deals.List(ctx, steamdeals.DealsListParams{Region: "US", MinDiscount: 40})

CLI

steamdeals games search "Hades II" --region US and steamdeals deals list --region US --min-discount 40 output JSON by default. Use --format table for terminal inspection. The CLI reads STEAMDEALS_API_KEY and supports --base-url for sandbox.

Production patterns

Set connect and read timeouts, retry only safe operations, propagate X-Request-Id, and cache catalog records separately from current prices. For writing alerts, generate a unique idempotency key per logical action.