API Documentation
API Documentation
Every request must be authenticated with an API key. You have two options:
HTTP Header (recommended)
Authorization: Bearer qg___your_key_here
Query Parameter
?api_key=qg__your_key_here
Your account may make at most 5,000 requests per day — regardless of how many keys you use. The counter resets daily at 00:00 UTC. Remaining quota is returned in response headers:
X-RateLimit-Limit: 5000X-RateLimit-Remaining: 874 X-RateLimit-Reset: 2024-12-01
HTTP status codes:
| 200 | OK – Request successful |
| 400 | Bad Request – Missing or invalid parameters |
| 401 | Unauthorized – Key missing or invalid |
| 404 | Not Found – Server ID does not exist |
| 429 | Too Many Requests – Rate limit reached |
| 503 | Service Unavailable – API disabled |
The game parameter accepts the following slugs:
| Slug | Game | App ID | Example URL |
|---|---|---|---|
arksa |
ARK: Survival Ascended | 2399830 | /api/v1/servers?game=arksa&limit=10 |
arkse |
ARK: Survival Evolved | 346110 | /api/v1/servers?game=arkse&limit=10 |
arma3 |
ArmA 3 | 107410 | /api/v1/servers?game=arma3&limit=10 |
atlas |
Atlas | 834910 | /api/v1/servers?game=atlas&limit=10 |
ats |
American Truck Simulator | 270880 | /api/v1/servers?game=ats&limit=10 |
barotrauma |
Barotrauma | 602960 | /api/v1/servers?game=barotrauma&limit=10 |
beamng |
BeamNG.drive | 284160 | /api/v1/servers?game=beamng&limit=10 |
empyrion |
Empyrion - Galactic Survival | 383120 | /api/v1/servers?game=empyrion&limit=10 |
ets2 |
Euro Truck Simulator 2 | 227300 | /api/v1/servers?game=ets2&limit=10 |
garrysmod |
Garry's Mod | 4000 | /api/v1/servers?game=garrysmod&limit=10 |
groundbranch |
GROUND BRANCH | 16900 | /api/v1/servers?game=groundbranch&limit=10 |
hellletloose |
Hell Let Loose | 686810 | /api/v1/servers?game=hellletloose&limit=10 |
icarus |
ICARUS | 1149460 | /api/v1/servers?game=icarus&limit=10 |
insurgency |
Insurgency | 222880 | /api/v1/servers?game=insurgency&limit=10 |
killingfloor2 |
Killing Floor 2 | 232090 | /api/v1/servers?game=killingfloor2&limit=10 |
nmrih |
No More Room in Hell | 224260 | /api/v1/servers?game=nmrih&limit=10 |
rs2vietnam |
Rising Storm 2: Vietnam | 418460 | /api/v1/servers?game=rs2vietnam&limit=10 |
sbox |
s&box | 590830 | /api/v1/servers?game=sbox&limit=10 |
scum |
SCUM | 513710 | /api/v1/servers?game=scum&limit=10 |
sonsoftheforest |
Sons Of The Forest | 1326470 | /api/v1/servers?game=sonsoftheforest&limit=10 |
spaceengineers |
Space Engineers | 244850 | /api/v1/servers?game=spaceengineers&limit=10 |
stormworks |
Stormworks: Build and Rescue | 573090 | /api/v1/servers?game=stormworks&limit=10 |
theforest |
The Forest | 242760 | /api/v1/servers?game=theforest&limit=10 |
unturned |
Unturned | 304930 | /api/v1/servers?game=unturned&limit=10 |
vrising |
V Rising | 1604030 | /api/v1/servers?game=vrising&limit=10 |
Endpoints
Returns a list of game servers sorted by player count.
count is the number of servers in this response (length of servers). It never exceeds limit; on the last page it may be smaller.
| Parameter | Type | Required | Description |
|---|---|---|---|
game |
string | Yes | Which configured server list to query: the game parameter must match the slug of an enabled game in this install (lowercase letters, digits, hyphen). |
limit |
integer | No | Number of results (default: 100, max: 10,000) |
offset |
integer | No | Pagination offset (default: 0) |
online |
integer | No | 1 = online only, 0 = offline only |
country |
string | No | 2-letter country code, e.g. DE, US |
search |
string | No | Free-text search in server name and IP (substring) |
{
"game": "arksa",
"total": 12483,
"limit": 100,
"offset": 0,
"count": 1,
"servers": [
{
"id": 1,
"name": "My Awesome Server",
"ip": "1.2.3.4",
"port": 28015,
"query_port": 28015,
"players": 120,
"max_players": 200,
"map": "Navezgane",
"gamemode": "",
"version": "1.0.0.0",
"gametime": "12:00",
"days": "3",
"password": false,
"official": false,
"country": "DE",
"online": true,
"rank": 1,
"fetched_at": 1714000000,
"first_seen_at": 1700000000,
"owner": {
"name": "SteamUsername",
"steam_id": "76561198000000000",
"avatar_url": "https://…"
}
}
]
}
Returns details for a single server by its numeric ID. Includes owner information if the server has been claimed and verified.
| Parameter | Type | Description |
|---|---|---|
id |
integer | Numeric server ID from the database |
{
"id": 1,
"game": "arksa",
"name": "My Server",
"ip": "1.2.3.4",
"port": 28015,
"query_port": 28015,
"players": 120,
"max_players": 200,
"map": "Navezgane",
"gamemode": "",
"version": "1.0.0.0",
"gametime": "12:00",
"days": "3",
"password": false,
"official": false,
"country": "DE",
"online": true,
"rank": 1,
"fetched_at": 1714000000,
"first_seen_at": 1700000000,
"owner": {
"name": "SteamUsername",
"steam_id": "76561198000000000",
"avatar_url": "https://…"
}
}
Returns player count history for a server. Older data is automatically compacted (hourly snapshots after 24h, daily after 7 days).
| Parameter | Type | Description |
|---|---|---|
id |
integer | Numeric server ID |
hours |
integer | Time range in hours, 1–720 (max. 30 days), default: 24 |
{
"server_id": 1,
"hours": 24,
"peak": 145,
"avg": 87.3,
"points": [
{ "timestamp": 1714000000, "players": 120, "max_players": 200 },
{ "timestamp": 1714003600, "players": 98, "max_players": 200 }
]
}
JavaScript (fetch)
fetch('https://query.games/api/v1/servers?game=arksa&limit=10', {
headers: {
'Authorization': 'Bearer qg_your_key'
}
})
.then(r => r.json())
.then(data => console.log(data.servers));
Python (requests)
import requests
resp = requests.get(
'https://query.games/api/v1/servers',
params={'game': 'arksa', 'limit': 10},
headers={'Authorization': 'Bearer qg_your_key'}
)
data = resp.json()
print(data['servers'])
cURL
curl -H "Authorization: Bearer qg_your_key" \ "https://query.games/api/v1/servers?game=arksa&limit=10"
PHP
$ctx = stream_context_create(['http' => [ 'header' => 'Authorization: Bearer qg_your_key' ]]); $data = json_decode(file_get_contents( 'https://query.games/api/v1/servers?game=arksa', false, $ctx ), true); print_r($data['servers']);