Skip to main content

AssetPay Merchant API

AssetPay is a B2B payment gateway for CS2 and Rust in-game item trading. Merchants integrate our API to let their users deposit (sell) and withdraw (buy) skins directly on their platform. This documentation covers the direct API integration, which gives you full control over the trading experience on your site.

Why Direct API?

You could use our Web Component for a faster setup, but most merchants get better results with a direct integration:
  • Your users stay in your UI the entire time. No popups, no redirects.
  • You control the flow, the styling, and the error handling.
  • Deposit and withdrawal conversion improves when the experience feels native to your platform.
The tradeoff is more development work upfront. This documentation walks you through every step.

What You Can Do

Deposit Skins

Users sell their CS2 or Rust skins to your platform. You receive the item value as balance.

Withdraw Skins

Users buy skins from the market using their balance on your platform.

Real-time Updates

WebSocket events and webhook callbacks keep your system in sync with trade state changes.

Multi-Game Support

CS2 and Rust are both supported with game-specific pricing and inventory.

Supported Games

GameApp IDDepositWithdrawal
Counter-Strike 2730YesYes
Rust252490YesYes
All game parameters default to CS2 (730) if omitted.

How It Works

1

Authenticate the user

Your backend calls AssetPay with the user’s Steam ID and trade URL. We return a client token that can be used from your frontend or backend.
2

Fetch inventory or market

Show the user their Steam inventory (for deposits) or the available market items (for withdrawals). Both endpoints return live pricing.
3

Initiate a trade

When the user picks items, a deposit or withdrawal request is sent to AssetPay. For withdrawals, we call your backend first to approve the purchase before anything gets bought.
4

Handle callbacks

As the trade progresses, we send webhook callbacks to your server. You credit balances on completed deposits and handle approvals for withdrawals.

Steam 7-Day Trade Hold

Steam enforces a 7-day trade reversal period on all trades. Deposits go through a HOLD status for 7 days before reaching COMPLETED. Do not credit user balances until the trade hits COMPLETED (unless you use instant deposits with collateral).
Read more in the Trade Lifecycle guide.

Next Steps

Quick Start

Get your first trade working in minutes.

Authentication

How client tokens work and how to generate them.

API Reference

Full endpoint documentation with request and response examples.

Types Reference

All TypeScript interfaces and enums used in the API.