Home / API Docs
API Documentation
Complete REST API reference for managing VPS servers and proxies programmatically. We offer separate APIs for each product type.
Three APIs, Three Products
Leased Hardware API
Servers on leased third-party hardware. We do not own these machines. Limited OS selection, no FDE, no SSH key support, password auth only.
Proxy API
Datacenter, residential, and rotating proxies. Order proxies, manage credentials, whitelist IPs, renew/top-up, and terminate via API.
Owned Hardware API Coming Soon
Servers running on hardware we own and operate in our own colocation facility. Full control, more OS options, FDE support, SSH key auth, IPv4/IPv6 dual-stack. API access not yet available.
Authentication
All API requests require authentication via the X-Reseller-Key header.
Keep your API key secret. Never expose it in client-side code.
Base URL
Response Format
All endpoints return JSON. Successful responses:
Error responses:
?action=plans
List available VPS plans with your reseller pricing.
?action=locations
List available server locations.
?action=os
List available operating systems. Legacy infrastructure supports: Debian 12, Debian 13, Ubuntu 24, Rocky Linux 9, CentOS 10, and Windows Server 2025.
?action=account
Get reseller account information including balance, discount, and payment method.
Example Response
?action=servers
List all servers belonging to the reseller.
?action=server&id={server_id}
Get detailed information for a specific server including password.
| Parameter | Type | Description |
|---|---|---|
id * | string | 8-character server ID |
Example Response
?action=console&id={server_id}
Get noVNC console URL for a server.
| Parameter | Type | Description |
|---|---|---|
id * | string | 8-character server ID |
?action=create
$ PaidProvision a new server on leased infrastructure. Password is auto-generated by the provider.
| Parameter | Type | Description |
|---|---|---|
plan_id * | integer | Plan ID from /plans endpoint |
hostname * | string | 3-63 alphanumeric characters |
os * | string | debian12, debian13, ubuntu24, rocky9, centos10, winserv25 |
days | integer | 1-365 (default: 31) |
?action=renew&id={server_id}
$ PaidRenew/extend a server subscription.
| Parameter | Type | Description |
|---|---|---|
id * | string | 8-character server ID |
days * | integer | 1-365 |
?action=upgrade&id={server_id}
$ PaidUpgrade server to a higher plan. Prorated charge for remaining days.
| Parameter | Type | Description |
|---|---|---|
id * | string | 8-character server ID |
plan_id * | integer | Target plan ID (must be higher price than current) |
?action=terminate&id={server_id}
Permanently delete a server (no refund).
| Parameter | Type | Description |
|---|---|---|
id * | string | 8-character server ID |
?action=power&id={server_id}
Execute power actions on a server.
| Parameter | Type | Description |
|---|---|---|
id * | string | 8-character server ID |
action * | string | start, stop, or restart |
?action=reinstall&id={server_id}
Reinstall the operating system (wipes all data).
| Parameter | Type | Description |
|---|---|---|
id * | string | 8-character server ID |
os * | string | debian12, debian13, ubuntu24, rocky9, centos10, winserv25 |
?action=hostname&id={server_id}
Update server hostname.
| Parameter | Type | Description |
|---|---|---|
id * | string | 8-character server ID |
hostname * | string | New hostname (alphanumeric and hyphens) |
?action=ip&id={server_id}
$ PaidChange the server's IP address. This is a paid operation.
| Parameter | Type | Description |
|---|---|---|
id * | string | 8-character server ID |
Error Responses
All errors return JSON with success: false and an error message.
401 Unauthorized
404 Not Found
400 Bad Request
PHP Example
<?php
$apiKey = "your_api_key_here";
$baseUrl = "https://servury.com/api/legacy.php";
function apiRequest($endpoint, $apiKey, $method = 'GET', $data = null) {
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, $endpoint);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_HTTPHEADER, [
"X-Reseller-Key: $apiKey",
"Content-Type: application/json"
]);
if ($method === 'POST') {
curl_setopt($ch, CURLOPT_POST, true);
if ($data) {
curl_setopt($ch, CURLOPT_POSTFIELDS, json_encode($data));
}
}
$response = curl_exec($ch);
curl_close($ch);
return json_decode($response, true);
}
// Check balance
$account = apiRequest("$baseUrl?action=account", $apiKey);
echo "Balance: $" . $account['data']['balance'];
// Create a server
$newServer = apiRequest("$baseUrl?action=create", $apiKey, 'POST', [
'plan_id' => 5,
'hostname' => 'myserver',
'os' => 'debian12',
'days' => 31
]);
// Power cycle a server
$result = apiRequest("$baseUrl?action=power&id=abc12345", $apiKey, 'POST', [
'action' => 'restart'
]);