This package is not installable via Composer 1.x, please make sure you upgrade to Composer 2+. Read more about our Composer 1.x deprecation policy.

dev-master 2017-11-03 20:33 UTC

This package is not auto-updated.

Last update: 2021-10-10 00:08:56 UTC


API Explorer for SteamTrades' RESTful API.

This PHP package is automatically generated by the Swagger Codegen project:

  • API version: 1.0
  • Package version: 1.0.0
  • Build package: io.swagger.codegen.languages.PhpClientCodegen


PHP 5.4.0 and later

Installation & Usage


To install the bindings via Composer, add the following to composer.json:

  "repositories": [
      "type": "git",
      "url": ""
  "require": {
    "streamtrades/public-api": "*@dev"

Then run composer install

Manual Installation

Download the files and include autoload.php:


Getting Started

Please follow the installation procedure and then run the following:

require_once(__DIR__ . '/vendor/autoload.php');

// Configure API key authorization: Token
SteamTrades\Configuration::getDefaultConfiguration()->setApiKey('Authorization', 'YOUR API KEY HERE');
SteamTrades\Configuration::getDefaultConfiguration()->setApiKeyPrefix('Authorization', 'Token');

$api_instance = new SteamTrades\Api\TradeApi();

try {
    $result = $api_instance->itemMineGet();
} catch (Exception $e) {
    echo 'Exception when calling TradeApi->itemMineGet: ', $e->getMessage(), PHP_EOL;


Documentation for API Endpoints

All URIs are relative to

Class Method HTTP request Description
TradeApi gameGet GET /game/ List supported games
TradeApi gameIdGet GET /game/{id}/ Info about a game
TradeApi itemMineGet GET /item/mine/ List owned items
TradeApi itemScanUserInventoryPost POST /item/scan_user_inventory/ Scan Steam user inventory
TradeApi itemUserInventoryGet GET /item/user_inventory/ Get inventory scan results
TradeApi tradeGet GET /trade/ List your trades
TradeApi tradeIdGet GET /trade/{id}/ Get trade status
TradeApi tradeRequestItemsPost POST /trade/request_items/ Request items
TradeApi tradeSendItemsPost POST /trade/send_items/ Send items
TradeApi tradeTransferItemsPost POST /trade/transfer_items/ Transfer items
TradeApi userInfoBySteamIdGet GET /user/info_by_steam_id/ Steam user info by Steam ID
TradeApi userInfoByTradeUrlGet GET /user/info_by_trade_url/ Steam user info by trade URL

Documentation For Models

Documentation For Authorization


  • Type: API key
  • API key parameter name: Authorization
  • Location: HTTP header