Documentation for the Steam Remote Control API, first documented by SteamDB back in October 2013. They later released another blogpost with more information and a link to a repository providing some more functionality than that which is in the headsDown.html file provided with Steam as of December 19th.
Credit mostly goes to the SteamDB guys for this, they did all the leg-work. just extracted the information from their SteamRemoteClient Tool and made a nice documentation out of it for my own reference and for the reference of others.
If you find an error, want to add something I missed or simply want to add a client library just submit a pull request! Or if you know something is wrong but don't know how to fix it, throw up an issue!
- Overview
- Authentication
- Buttons
- Mouse
- Keyboard
- Games
- Music
- Spaces
- State
- Streaming
- UI
- Client Libraries
The remote control has to be enabled in Big Picture's settings.
The base URL for all API requests is https://<your_steam_client_ip>:27037/steam
Data is sent as GET or POST payloads, and returned as JSON.
Supplying incorrect payload data or using an invalid API call will result in a HTTP 404
Error Code being returned.
Unless otherwise stated, it can be assumed that each API call simply returns a JSON response of the following on a successful call:
{
"success": true
}
The first request you make to the API while in Big Picture will prompt you to authorise the remote client by its device token. Every API request requires the passing of at least a device token as GET, POST or COOKIE data and will therefore not be included in the documentation beyond the below as it assumed you are already including these details appropriately for each request.
GET /steam/authorized/
Authorized
{
"success": true,
"data":
{
"tenfoot": 0
}
}
Not Authorized
{
"success": false,
"error": "authorization_needs_prompt"
}
POST /steam/authorization/
Name | Required? | Type | Description |
---|---|---|---|
device_name |
optional | string | Device Name as it will appear in the Steam Big Picture prompt during authorisation. "Unkown Device" used if not supplied. |
device_token |
required | string | Device Token used to authorise your client with Steam. This can be generated locally but must be the same for each request (or authorisation will be required again). Minimum length of 8 characters. |
POST /steam/button/:button/
Simulates the pressing of controller buttons within Steam Big Picture. The buttons are based on an Xbox 360 Gamepad, whether this will change in the future to better reflect the official Steam Controller is unknown.
The button identifier should be used in place of :button in the POST request above.
Button | Identifier |
---|---|
Guide/Overlay | guide |
Left | left |
Right | right |
Up | up |
Down | down |
A | a |
B | b |
X | x |
Y | y |
Right Trigger | rtrigger |
Left Trigger | ltrigger |
Used to control the cursor within Steam Big Picture and simulate Mouse Button presses.
POST /steam/mouse/move
Moves the Big Picture cursor x/y distance relative to its current position.
Name | Required? | Type | Description |
---|---|---|---|
delta_x |
required | int | Distance to move the mouse on the x-axis |
delta_y |
required | int | Distance to move the mouse on the y-axis |
POST /steam/mouse/click
Simulates a mouse click in Steam Big Picture.
Name | Required? | Type | Description |
---|---|---|---|
button |
required | string | The mouse button to simulate a press for, currently tested: mouse_left |
Simulates keyboard functionality within Steam Big Picture.
POST /steam/keyboard/key/
Simulates the key press of functional keys. Cannot be used for typing, this is what Sequences are for. Rather this can be used to simulate key presses such as enter/return (for sending messages), backspace, space, the F1-12 keys, etc. Only those that provide some functional use are listed in the table below. If any are missed, please feel free to add them.
Identifier | Key | Where? | Description |
---|---|---|---|
key_enter |
Enter/Return | Anywhere | Simulates pressing enter, most likely use is to send a message after entering it using a [Sequence](#sequences) when no controller is plugged in (A button in API does not send a message with no controller connected, though this may just be a bug and fixed in the future). |
key_backspace |
Backspace | Input Box | Simulates backspace, useful for deleting after sending a sequence. |
key_end |
End | Input Box | Goes to end of the contents of a text input. |
key_home |
Home | Input Box | Goes to the beginning of a text input. |
key_f1-12 |
F keys (1-12) | Anywhere | Presses the specifies F key (provide a number between 1 and 12) |
key_escape |
Escape | Anywhere | Works the same as the B button for the most part, goes back to the previous screen. |
Name | Required? | Type | Description |
---|---|---|---|
name |
required | string | The key name from the above table to pass to Big Picture (example: key_enter |
POST /steam/keyboard/sequence/
Accepts a string of characters as a POST field and outputs it as a string of characters in the currently selected text input within Steam Big Picture.
Name | Required? | Type | Description |
---|---|---|---|
sequence |
required | string | The string of unicode characters to enter into the currently selected input field. |
Enables the browsing of the currently logged in user's game library and the starting up of games within Steam Big Picture.
GET /steam/games/
Returns a list of all available games in the currently logged in user's library. Each key represents a Steam App ID.
{
"success": true,
"data": {
"3483": {
"name": "Peggle Extreme",
"installed": 1,
"update_running": 0,
"update_paused": 0,
"bytes_downloaded": 14690192,
"bytes_needed": 14690192,
"bytes_per_second": 0,
"type": "game",
"icon": "http://media.steampowered.com/steamcommunity/public/images/apps/3483/427a98a549c3813e13b4062300709000599817b0.jpg",
"logo": "http://media.steampowered.com/steamcommunity/public/images/apps/3483/4b8f3d8f7f94cc5ca420a8586c8dd903edacce12.jpg",
"current_disk_bytes": 23356380,
"estimated_disk_bytes": 23356380,
"minutes_played": {
"forever": 47,
"last_two_weeks": 46
},
"last_played_at": 1387758040
}
}
}
POST /steam/games/:appid/run
Runs the game corresponding to the supplied App ID (if it's installed). If the game isn't installed, it will be installed and a second request to play it must be called once installation has completed in order to run the game.
POST /steam/music/:action/
The action identifier should be used in place of :action in the POST request above.
Action | Identifier |
---|---|
Guide/Play | play |
Pause | pause |
Next | next |
Previous | previous |
POST|GET /steam/music/volume/
Name | Required? | Type | Description |
---|---|---|---|
volume |
optional | double | Decimal point value between 0 and 1, where 0 is muted and 1 is max volume. |
POST /steam/music/mode/
Used to set the current music modes.
Name | Required? | Type | Description |
---|---|---|---|
looped |
optional | bool (0|1) | Enable or disable looping mode |
shuffled |
optional | bool (0|1) | Enable or disable shuffled mode |
{
"success": true,
"data":
{
"looped": 0,
"shuffled": 0
}
}
GET /steam/music/
{
"success": true,
"data":
{
"playback":
{
"status": "playing",
"looped": 0,
"shuffled": 0,
"volume": 0.75,
"queue_count": 1
},
"current":
{
"artist": "Darude",
"album": "Sandstorm",
"track": "Sandstorm"
}
}
}
'Spaces' in Steam Big Picture refer to different sections of the Big Picture client. Currently only a few spaces have been implemented.
Name | Identifier | Description |
---|---|---|
Library | library | Currently the default space and associated with the store, game library and community sections. |
Friends | friends | The space from where you can send and receive messages and interact with your friends list. |
Web Browser | webbrowser | The Steam Big Picture web browser. |
GET /steam/space/
Gets the currently active Space from Big Picture. Refer to the mappings table above for more information.
{
"success": true,
"data": {
"space": "library"
}
}
POST /steam/space/
Changes the currently active Space in Big Picture.
Name | Required? | Type | Description |
---|---|---|---|
space |
required | string | The space identifier to navigate to. Refer to the mappings table above. |
Used to get the current state of Steam
GET /steam/state/
Name | Required? | Type | Description |
---|---|---|---|
long_poll |
optional | bool | Will cause the request to return only when the state has changed |
session_name |
optional | string | Unknown |
Sample Response
{
"success": true,
"data":
{
"tenfoot": 1,
"space": "library",
"music":
{
"playback":
{
"status": "paused",
"looped": 0,
"shuffled": 0,
"volume": 0.5,
"queue_count": 1
},
"current":
{
"artist": "Darude",
"album": "Sandstorm",
"track": "Sandstorm"
}
}
}
}
POST /steam/stream/
{
"success": true,
"data":
{
"stream_port": 27031,
"auth_token": "fb3b606ba869c9834632c2d9e12d5c94968220d1e9b1397f0bf7c84b330a802f"
}
}
POST /ui/tenfoot/
Used to launch the tenfoot interface
Primarily made for use with the RemoteUI.html tool (included in the repository), but for non-local access can be easily modified. It's worth noting that the API does not provide an Access-Control-Allow-Origin
header, let alone one with a wildcard value, so most browsers won't work with it from a different origin without disabling some security features. JSONP doesn't support POST requests, so that option is out the window too.
======
If you have a library, please do add it above under the necessary language heading (if the language isn't there, add it)!