API documentation
Accept CS2 skins from your users and get paid in USD. Your server opens deposits with one call; we route every skin to the buyer paying the most for it, credit your balance once the trade is final, and tell your server at every step with a signed webhook. Keys, webhooks and withdrawals live in your merchant dashboard.
How it works
- Your user gives you their SteamID64 and trade URL (or you use the hosted page and we collect them).
- You quote their inventory — each item comes with the amount you would be credited.
- You create deposits for the items they pick, under your own reference (
custom_id). Steam sends them a trade offer. - They accept. Steam's trade protection holds the trade for up to ~8 days; you get
deposit.hold. - When the trade is final we credit your balance and send
deposit.completed. You withdraw in crypto from the dashboard.
A held trade can still be reversed by Steam, which is why your balance is credited only at the end of the hold. Crediting your own user earlier, on deposit.hold, is your decision and your risk.
Authentication
Create a key under API keys in the dashboard and send it as a Bearer token. Keys are secret — call the API from your backend only.
| Limit | Value |
|---|---|
| Requests per key | 120 per minute |
GET /inventory, POST /deposits | 30 per minute per key (they query the buyers live) |
| IP allowlist | Optional, per merchant — ask us to enable it |
Over the limit you get 429 with RateLimit-* headers.
Conventions
| Base URL | https://cashout.skin/api/v1 |
| Format | JSON in, JSON out. Send Content-Type: application/json. |
| Money | Strings with two decimals, USD — "41.17". Never floats. |
| Your references | custom_id: 1–64 characters, letters, digits and _ . : -. |
| Pagination | Lists are newest first. Pass limit (1–100, default 50) and before=<next_before> from the previous page; next_before is null on the last page. |
| Errors | { "error": "<human message>", "code": "<machine code>" } — see Errors. |
GET /me
Your account and balances.
GET /inventory
Quotes a Steam inventory at your rate. Query parameters: steam_id (SteamID64) and trade_url. The trade URL must belong to the same Steam account.
Items are sorted by amount. Only items with tradable: true can be deposited. A private inventory answers 409 user_inventory_is_hidden.
POST /deposits
Creates one deposit per asset — each is its own Steam trade offer, status and credit. Up to 50 assets per call. Prices are always taken from the live inventory, never from your request.
Idempotent: custom_id + asset_id identifies a deposit. Repeating a request — after a timeout, say — returns the existing deposit with existing: true and never sends your user a second trade offer. To deposit the same item again later, use a new custom_id.
A result with deposit_unconfirmed means the buyer didn't confirm the trade offer in time. It may still have been sent — don't retry it under a new reference; its real status arrives by webhook.
GET /deposits · GET /deposits/:id
Filters: custom_id, status (pending · hold · completed · failed), plus pagination.
The deposit object
| Status | Meaning | Webhook |
|---|---|---|
pending | Trade offer sent, not accepted yet. | deposit.created |
hold | Accepted; Steam trade protection is running until hold_until. Not credited yet. | deposit.hold |
completed | Final. amount was added to your balance at credited_at. | deposit.completed |
failed | Declined, expired, cancelled, or reversed by Steam during the hold. Nothing credited. | deposit.failed |
Hosted deposit page
No frontend work: open a session, send your user to its url. They pick items on our page and accept the trade offers; the deposits carry the session's custom_id and arrive by webhook. One session creates one batch of deposits.
Skip the Steam sign-in: your users already signed in with Steam on your site, so pass their steam_id and trade_url and they land straight on their inventory — the same trust as POST /deposits, which never involves a sign-in. Without a trade_url, they sign in with Steam on our page (remembered for 7 days in that browser). Treat the link as personal: whoever opens it can send deposit offers to that Steam account — which still only go through when the account's owner accepts them in Steam.
| Field | |
|---|---|
custom_id | Required. Asking again with the same value while the session is open returns that session. |
steam_id | Optional. Only this Steam account may use the link. |
trade_url | Optional, needs steam_id (same account). Skips the Steam sign-in — see above. |
return_url | Optional https URL for the "Back to …" button when they're done. |
expires_in_minutes | 5–1440, default 60. |
GET /sessions/:id returns the session and the deposits it created.
GET /transactions
Your ledger: every credit and debit, with the balance after it. Your balance always equals the sum of this list.
Types: deposit, withdrawal, withdrawal_reversal (a withdrawal rejected, cancelled or failed), adjustment.
Webhooks
Set your endpoint under Webhooks in the dashboard. Each event is a POST with this body:
| Event | When |
|---|---|
deposit.created | A trade offer was sent to your user. |
deposit.hold | They accepted; Steam's hold started. Not credited yet. |
deposit.completed | Credited to your balance. |
deposit.failed | Declined, expired or reversed. Nothing credited. |
withdrawal.completed | Your withdrawal was sent (chain_tx_id when the network has one). |
withdrawal.rejected | We declined the withdrawal; the amount is back on your balance. |
withdrawal.failed | The transfer failed; the amount is back on your balance. |
test | Sent by the dashboard's "Send test event" button. |
| Header | |
|---|---|
X-Cashout-Signature | t=<unix seconds>,v1=<hex HMAC-SHA256(secret, "<t>.<raw body>")> |
X-Cashout-Event | The event name. |
X-Cashout-Event-Id | Same as the body's id. |
Answer with any 2xx within 10 seconds. Anything else — or no answer — is retried after 1 min, 5 min, 30 min, 2 h, 6 h, 12 h and 24 h, then marked failed; you can redeliver failed events from the dashboard. Redirects are not followed, and the URL must be public https. Delivery is at-least-once and events can arrive out of order, so treat the deposit's status as the truth and ignore event ids you've seen.
Verifying signatures
Always verify before trusting a webhook. Use the raw request body — parsing and re-serialising the JSON changes the bytes and breaks the signature.
Errors
| HTTP | code | Meaning |
|---|---|---|
| 400 | invalid_request | The body or query failed validation (details says which field). |
| 400 | invalid_steam_id · invalid_trade_url | Not a SteamID64 / not a steamcommunity.com trade offer link. |
| 400 | trade_url_mismatch | The trade URL belongs to a different Steam account than steam_id. |
| 401 | unauthenticated | Missing, malformed or revoked API key. |
| 403 | merchant_suspended · ip_not_allowed | Account suspended / request from an IP not on your allowlist. |
| 404 | not_found | No such deposit, session or route. |
| 409 | user_inventory_is_hidden | The user's Steam inventory is private. The message tells them how to fix it. |
| 409 | user_not_tradable | The Steam account can't trade right now (trade ban, Steam Guard, new device). |
| 400 | invalid_trade_token | The trade URL is outdated — the user must copy a fresh one from Steam. |
| 429 | — | Rate limit. |
| 503 | supplier_unavailable · user_inventory_is_unavailable · under_maintenance | Temporary — retry shortly. |
| 502 | supplier_error | Something failed on our side. We're alerted; retry later. |
Per-item codes inside results[]: item_not_found, item_not_tradable, item_not_accepted (no buyer for it right now), deposit_unconfirmed, plus any of the codes above.
The error text is written to be shown to your user as-is.