Skip to content

Error Handling ​

All API errors follow a consistent format and use standard HTTP status codes.

Error Response Format ​

json
{
  "success": false,
  "message": "Description of what went wrong"
}

TIP

The data field is only present when there are additional details (e.g., validation errors). It is omitted entirely — not null — for simple errors.

Validation errors include field-level details in data:

json
{
  "success": false,
  "message": "validation error",
  "data": [
    {
      "field": "InventoryRequest.game",
      "code": "required",
      "message": "game is a required field"
    },
    {
      "field": "InventoryRequest.partner",
      "code": "required",
      "message": "partner is a required field"
    }
  ]
}

HTTP Status Codes ​

CodeMeaningWhen
200SuccessRequest completed successfully
400Bad RequestInvalid JSON body, validation errors
401UnauthorizedMissing or invalid API key
403ForbiddenMerchant account disabled, IP not whitelisted, or the endpoint is not enabled for your account
404Not FoundResource doesn't exist (e.g., unknown tx_id or merchant_tx_id)
408Request TimeoutUpstream request timed out
409ConflictResource already exists (e.g., duplicate merchant_tx_id)
500Internal Server ErrorSomething went wrong on our side
502Bad GatewayUpstream service error

Common Errors ​

Missing API Key ​

Status: 401

json
{
  "success": false,
  "message": "missing authorization header"
}

Fix: Include X-Api-Key header in your request.

Invalid API Key ​

Status: 401

json
{
  "success": false,
  "message": "invalid API key"
}

Fix: Check that your API key is correct and active.

Merchant Disabled ​

Status: 403

json
{
  "success": false,
  "message": "merchant account is disabled"
}

Fix: Contact support to reactivate your merchant account.

IP Not Whitelisted ​

Status: 403

json
{
  "success": false,
  "message": "IP not whitelisted: 203.0.113.42"
}

Fix: Add your server's IP address to the merchant whitelist. Entries are exact IPs — ranges (CIDR) are not supported. An empty whitelist allows any IP.

Invalid Request Body ​

Status: 400

json
{
  "success": false,
  "message": "invalid request body"
}

Fix: Ensure the request body is valid JSON.

Validation Error ​

Status: 400

json
{
  "success": false,
  "message": "validation error",
  "data": [
    {
      "field": "InventoryRequest.token",
      "code": "len",
      "message": "token must be exactly 8 characters long"
    }
  ]
}

Fix: Check each field error and correct the input.

Not Found ​

Status: 404

json
{
  "success": false,
  "message": "not found error"
}

Fix: Verify the id, merchant_tx_id, or tx_id is correct.

Timeout ​

Status: 408

json
{
  "success": false,
  "message": "timeout error"
}

Fix: Upstream service was slow. Retry after a few seconds.

Already Exists ​

Status: 409

json
{
  "success": false,
  "message": "already exist error"
}

Fix: The merchant_tx_id has already been used. Use a unique transaction ID.

Too Many Items ​

Status: 400

json
{
  "success": false,
  "message": "deposit exceeds the maximum of 50 items per deposit"
}

Fix: The deposit has more items than the per-deposit limit, so it is rejected before trade creation. The limit is configurable — read the current value from max_items in the Get Inventory response and split the deposit into smaller batches.

Domain-Specific Validation Errors ​

Beyond standard field validation, some errors indicate issues with the user's Steam account or trade eligibility. These are returned as validation errors (400) with specific code values in the data array.

Deposit & Intent Errors ​

These errors may occur when calling Create Intent or Create Deposit:

FieldCodeMessageDescription
merchant_tx_idexistThe specified value already existsThe merchant_tx_id has already been used. Use a unique ID for each deposit.
—price_changedprice_changedfrom_preview deposits only: the cart cannot be accepted as it stands. The response data carries the current pricing of the same items and names the blocking ones in data.rejected — re-show and retry. No deposit was created; the merchant_tx_id can be reused.
—preview_unavailablepreview_unavailablefrom_preview deposits only: preview pricing is temporarily unavailable. Retry later or use the regular Get Inventory flow. No deposit was created.
inventoryinventory_reloadPlease reload the inventoryInventory data is stale. Fetch a fresh inventory before creating a deposit.
tokentrade_link_revokedThe trade link has been revoked by the account ownerThe user has reset their Steam trade URL. Ask them to provide a new one.
partnertrade_link_invalidThe trade link is invalid or has expiredThe Steam trade link is incorrect or no longer valid.
partnertrade_bannedThe account is trade banned on SteamThe user's Steam account has a trade ban. Trading is not possible.
partnerprofile_privateThe user's profile is private, trade is not possibleThe user must set their Steam profile to public for trading.
partnerlimited_accountLimited Steam account — trading is not availableThe user has a limited Steam account (hasn't spent $5 on Steam). Trading is unavailable.
partnerholdA temporary trade restriction is activeThe user's account has a temporary Steam trade hold. They must wait for it to expire.
gamepermissionsInsufficient permissions to access the specified gameThe user's Steam inventory for this game is private or inaccessible.
partnerhold_and_permissionsA trade restriction is active and there are insufficient permissions for the specified gameCombination of trade hold and game permission issues.

Purchase Errors ​

These errors may occur when calling Create Purchase. The user's trade link is checked before the purchase is created: on any of these errors no purchase is created and nothing is charged — fix the trade link and retry, the same merchant_tx_id can be reused.

FieldCodeMessageDescription
tokentrade_link_revokedThe trade link has been revoked by the account ownerThe user has reset their Steam trade URL. Ask them to provide a new one.
partnertrade_link_invalidThe trade link is invalid or has expiredThe Steam trade link is incorrect or no longer valid.
partnertrade_bannedThe account is trade banned on SteamThe user's Steam account has a trade ban.
partnerprofile_privateThe user's profile is private, trade is not possibleThe user must set their Steam profile to public.
partnerlimited_accountLimited Steam account — trading is not availableThe user has a limited Steam account.
gamepermissionsInsufficient permissions to access the specified gameThe user's account cannot receive items in this game.

INFO

A temporary Steam trade hold on the user's account does not block purchases — the account can still receive items. hold and hold_and_permissions apply to deposits only.

Inventory Errors ​

These errors may occur when calling Get Inventory:

FieldCodeMessageDescription
inventoryinventory_reloadPlease reload the inventoryInventory data is stale. Retry the request.
tokentrade_link_revokedThe trade link has been revoked by the account ownerThe user has reset their Steam trade URL. Ask them to provide a new one.
partnertrade_link_invalidThe trade link is invalid or has expiredThe Steam trade link is incorrect or no longer valid.
partnertrade_bannedThe account is trade banned on SteamThe user's Steam account has a trade ban.
partnerprofile_privateThe user's profile is private, trade is not possibleThe user must set their Steam profile to public.
partnerlimited_accountLimited Steam account — trading is not availableThe user has a limited Steam account.
partnerholdA temporary trade restriction is activeThe user's account has a temporary Steam trade hold.
gamepermissionsInsufficient permissions to access the specified gameThe user's Steam inventory for this game is private.
partnerhold_and_permissionsA trade restriction is active and there are insufficient permissions for the specified gameCombination of trade hold and game permission issues.

Example: Steam Account Error ​

Status: 400

json
{
  "success": false,
  "message": "validation error",
  "data": [
    {
      "field": "partner",
      "code": "trade_banned",
      "message": "The account is trade banned on Steam"
    }
  ]
}

Fix: Inform the user about their Steam account issue. These errors require action from the user, not from your integration.

TIP

For the best user experience, map error code values to user-friendly messages in your UI. The code field is stable and can be used for programmatic error handling, while message provides a human-readable description.

Best Practices ​

  1. Always check success — Don't assume a 200 response means success
  2. Handle 502 gracefully — Upstream outages are temporary
  3. Parse validation errors — The data array tells you exactly which fields failed
  4. Log error responses — Include the full response body for debugging
  5. Implement retries — For 408/500/502 errors, retry with exponential backoff