Steam Trades

PHP Client

Our PHP client provides convenient and complete access to our REST API.


The recommended way of embedding our PHP client is using PHP composer. If you're already using Composer for your project: perfect! Just add our entry to the require section of your composer.json. If you aren't: well, you really should be! It makes resolving dependencies a bliss.

"require": {
    "steamtrades/public-api": "*"

If you prefer to do things the old-fashioned way for whatever reasons, feel free to just manually clone the client from our GitHub repository. It ships with a basic autoload.php that handles resolving imports for you.

git clone https://github.com/SteamTrades/php-api-client

Using the client

With or without Composer, importing our client is as easy as:


// Only ONE of the two options below is required.

// With Composer
require_once(__DIR__ . '/vendor/autoload.php');
// With our simple autoload.php
require_once(__DIR__ . '/php-api-client/autoload.php');

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