One case with its items
API v2 - coming soon.
Coming soon
No key needed
400 bad_request.One case by its id or slug, as its page shows it to everyone: its price, art, kind, category, creator and opens, and every item with its name, image, value, chance and rarity colour, in the page order. Takes no key.
Rate limits: 60 reads a minute per IP across /api/v2 and at most 25 to one path in 2 seconds (429 with Retry-After).
id*stringThe case id or its slug
1 <= length <= 191currency?stringThe currency of the answer's amounts: COINS (the default, the answer as it always was) or USD, EUR or GBP, converted at the rate the site shows and rounded to two decimals as the site writes them. Anything else is a 400 unknown_currency.
"COINS""COINS""USD""EUR""GBP"OK
application/json- response
case*currency?What the amounts were converted to, when currency was USD, EUR or GBP. Absent for coins
curl "https://api.csgowin.com/api/v2/cases/example-creator-case"{ "case": { "id": "7c2e9a41b05d", "name": "Example Creator Case", "kind": "streamer", "category": null, "price": 5, "image": "https://cdn.example.invalid/img/cases/official_small/3.webp", "creator": { "name": "example_creator", "avatar": null }, "opens": 300, "items": [ { "name": "Example Skin (Field-Tested)", "image": "https://example.invalid/skins/1.png", "price": 12.5, "chance": 2.5, "rarityColor": "#eb4b4b" } ] }}Errors
| Status | When | Body |
|---|---|---|
| 400 | bad_request: an input outside its rules, a cookie sent, or a refusal by the site (the message says which). unknown_currency: currency is not one of COINS, USD, EUR, GBP. | {"error":{"code":"bad_request","message":"this read takes no key"}}{"error":{"code":"unknown_currency","message":"currency is one of COINS, USD, EUR, GBP"}} |
| 404 | not_found: no such giveaway, case or period, or the code has no board or giveaways (also every request while API v2 is not open, and every action while actions are not open). | {"error":{"code":"not_found","message":"not found"}} |
| 429 | rate_limited: past a rate limit - wait the Retry-After seconds. | {"error":{"code":"rate_limited","message":"too many requests, please try again later."}} |
| 503 | unavailable: not available for a moment and nothing was done - try again after the Retry-After seconds. | {"error":{"code":"unavailable","message":"temporarily unavailable, please try again shortly."}} |
Create a case POST
Creates a case under your name, as Profile > Cases does: 2 to 100 skins from GET /api/items?sort=asc with chances totalling 100 percent, a name and an art, and the site's rules (at most 10 live cases, the skin value cap, commission and listing from level 5). No balance moves. 10 a day. Rate limits: 5 actions a minute per account (429 rate_limited), this action’s count per UTC day (429 action_limit_reached, Retry-After to 00:00 UTC), and 120 actions a minute across the site (503 unavailable with Retry-After).
Remove one of your cases POST
Removes one of your own cases, as Profile > Cases does. Another account's case answers 404. 10 a day. Rate limits: 5 actions a minute per account (429 rate_limited), this action’s count per UTC day (429 action_limit_reached, Retry-After to 00:00 UTC), and 120 actions a minute across the site (503 unavailable with Retry-After).