Servers
List servers
Retrieves all servers
Available include parameters
| Parameter | Description |
|---|---|
| allocations | List of allocations assigned to the server |
| user | Information about the server owner |
| subusers | List of users added to the server |
| nest | Information about the server's egg nest |
| egg | Information about the server's egg |
| variables | List of server variables |
| location | Information about server's node location |
| node | Information about the server's node |
| databases | List of databases on the server |
| transfer | Information about the server's transfer (null unless a transfer is in progress) |
GET
/api/application/serversAuthorization
ApplicationToken AuthorizationBearer <token>
Application API key (generated at /admin/api)
In: header
Query Parameters
include?string
Comma-separated list of related resources to embed in each returned object. Accepted values are listed in the include-parameters table above.
filter[uuid]?string
Partial match on the server UUID.
filter[uuidShort]?string
Partial match on the short server identifier.
filter[name]?string
Partial match on the server name.
filter[description]?string
Partial match on the server description.
filter[image]?string
Partial match on the Docker image.
filter[external_id]?string
Partial match on the external ID.
sort?string
Sort by id or uuid; prefix with - for descending.
Value in
"id" | "-id" | "uuid" | "-uuid"page?integer
Page of results to return.
per_page?integer
Number of results per page (default 50).
Default
50Response Body
application/json
curl -X GET "https://pterodactyl.file.properties/api/application/servers?include=allocations%2Cuser&filter%5Buuid%5D=d557c19c&filter%5BuuidShort%5D=d557c19c&filter%5Bname%5D=Survival&filter%5Bdescription%5D=community&filter%5Bimage%5D=yolks%3Ajava_17&filter%5Bexternal_id%5D=store-1234&sort=-id&page=1&per_page=50" \ -H "Authorization: Bearer ptla_xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx" \ -H "Accept: application/json"{
"object": "list",
"data": [
{
"object": "server",
"attributes": {
"id": 5,
"external_id": "RemoteId1",
"uuid": "1a7ce997-259b-452e-8b4e-cecc464142ca",
"identifier": "1a7ce997",
"name": "Wuhu Island",
"description": "Matt from Wii Sports",
"status": null,
"suspended": false,
"limits": {
"memory": 512,
"swap": 0,
"disk": 200,
"io": 500,
"cpu": 0,
"threads": null,
"oom_disabled": false
},
"feature_limits": {
"databases": 5,
"allocations": 5,
"backups": 2
},
"user": 1,
"node": 1,
"allocation": 1,
"nest": 1,
"egg": 5,
"container": {
"startup_command": "java -Xms128M -Xmx{{SERVER_MEMORY}}M -jar {{SERVER_JARFILE}}",
"image": "quay.io/pterodactyl/core:java",
"installed": 1,
"environment": {
"SERVER_JARFILE": "server.jar",
"VANILLA_VERSION": "latest",
"STARTUP": "java -Xms128M -Xmx{{SERVER_MEMORY}}M -jar {{SERVER_JARFILE}}",
"P_SERVER_LOCATION": "Test",
"P_SERVER_UUID": "1a7ce997-259b-452e-8b4e-cecc464142ca"
}
},
"updated_at": "2020-06-13T04:20:53+00:00",
"created_at": "2019-12-23T06:46:27+00:00",
"relationships": {
"databases": {
"object": "list",
"data": [
{
"object": "server_database",
"attributes": {
"id": 1,
"server": 5,
"host": 4,
"database": "s5_perms",
"username": "u5_QsIAp1jhvS",
"remote": "%",
"max_connections": 0,
"created_at": "2020-06-12T23:00:13+01:00",
"updated_at": "2020-06-12T23:00:13+01:00"
}
},
{
"object": "server_database",
"attributes": {
"id": 2,
"server": 5,
"host": 4,
"database": "s5_coreprotect",
"username": "u5_2jtJx1nO1d",
"remote": "%",
"max_connections": 0,
"created_at": "2020-06-12T23:00:20+01:00",
"updated_at": "2020-06-12T23:00:20+01:00"
}
}
]
}
}
}
}
],
"meta": {
"pagination": {
"total": 1,
"count": 1,
"per_page": 50,
"current_page": 1,
"total_pages": 1,
"links": {}
}
}
}