Account Access

Your secure 32-character login credential
or

Want to test our API?

Create an account or log in to get your API key and start testing endpoints.

Reseller API Documentation

Complete API reference for resellers. Default discount starts at 0% and can be increased after demonstrating volume.

Authentication

All API requests require authentication via the X-Reseller-Key header.

Request Header
X-Reseller-Key: your_api_key_here

Keep your API key secret. Never expose it in client-side code.

Base URL

https://servury.com/api/reseller.php

All endpoints return JSON. Successful responses have {"success": true, "data": {...}}. Errors return {"success": false, "error": "message"}.

GET

?action=plans

List available VPS plans with your reseller pricing.

Response

                    
GET

?action=locations

List available server locations.

Response

                    
GET

?action=os

List available operating systems.

Response

                    
GET

?action=account

Get reseller account information (balance, discount, payment method).

Response

                    
GET

?action=servers

List all servers owned by the reseller.

Response

                    
GET

?action=server&id={server_id}

Get detailed information for a specific server.

Response

                    
Example Response
{
    "success": true,
    "data": {
        "server": {
            "id": "abc12345",
            "hostname": "myserver",
            "ip_address": "192.168.1.1",
            "os": "ubuntu24",
            "plan": "S-100",
            "location": "USA",
            "status": "active",
            "username": "root",
            "password": "serverpassword123",
            "created_at": 1770120714,
            "expiration_date": 1772712714
        }
    }
}
GET

?action=console&id={server_id}

Get noVNC console URL for a server.

Response

                    
POST

?action=create

Paid

Provision a new VPS server. This will charge your account.

Response

                    
POST

?action=renew&id={server_id}

Paid

Renew/extend a server subscription.

Response

                    
POST

?action=terminate&id={server_id}

Permanently delete a server (no refund).

Response

                    
POST

?action=power&id={server_id}

Execute power actions on a server.

Response

                    
POST

?action=reinstall&id={server_id}

Reinstall the operating system (wipes all data).

Response

                    
POST

?action=hostname&id={server_id}

Update server hostname.

Response

                    
POST

?action=ip&id={server_id}

Paid

Change server IP address.

Response

                    
POST

?action=upgrade&id={server_id}

Paid

Upgrade server to a higher plan (paid, prorated). Servers can only be upgraded within their product line.

Response

                    
Upgrade Paths

Servers can only be upgraded within their product line. Cross-line upgrades are not supported.

Shared
1. S-100
2. S-150
3. S-200
4. S-250 (max)
Dedicated
1. D-150
2. D-300
3. D-450 (max)
Dedicated Pro
1. D-100
2. D-200
3. D-250
4. D-350
5. D-400 (max)

Error Responses

All errors return a JSON object with success: false and an error message.

401 Unauthorized
{
    "success": false,
    "error": "Invalid or inactive API key."
}
404 Not Found
{
    "success": false,
    "error": "Server not found."
}
400 Bad Request
{
    "success": false,
    "error": "Invalid hostname. Use 3-63 alphanumeric characters."
}

PHP Example

<?php
$apiKey = "your_api_key_here";
$baseUrl = "https://servury.com/api/reseller.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);
}

// Get available plans
$plans = apiRequest("$baseUrl?action=plans", $apiKey);

// Create a server
$newServer = apiRequest("$baseUrl?action=create", $apiKey, 'POST', [
    'plan_id' => 5,
    'hostname' => 'myserver',
    'os' => 'ubuntu24',
    'days' => 31
]);

// Power cycle a server
$result = apiRequest("$baseUrl?action=power&id=abc12345", $apiKey, 'POST', [
    'action' => 'restart'
]);
Confirm

Are you sure?