eq.php¶
Equipment Management Module (eq.php): API for server deployment, power management, IPMI, backups, searching, and retrieving detailed hardware configuration information.
API Methods¶
| Method | Action | Description |
|---|---|---|
abort_reinstall | abort_reinstall | Interrupts the server reinstallation process, removes associated tags (reinstall_start, autodeploy_start, autodeploy_timeout), and restores VLAN settings. |
add_ipmi_admin | add_ipmi_admin | Creates a new user with administrator privileges for IPMI management. If admin_user is specified, a user with the given name is created; otherwise, a random login and password are generated. |
add_ipmi_user | add_ipmi_user | Creates a new IPMI user for the server. If the user is an administrator, admin_user and admin_pass parameters are required. |
announceip | announceip | Requests announcement of a specified subnet or a specific server in the BGP network. |
backup_get_schedule | backup_get_schedule | Returns the current automatic backup schedule for the specified server. |
backup_list | backup_list | Returns a list of available backups for the specified equipment (server). |
backup_save_schedule | backup_save_schedule | Saves the configured backup schedule for the specified server. |
boot_dev | boot_dev | Requests switching the server boot mode (PXE or disk), specifying the media type and boot mode. |
check_backup_lock | check_backup_lock | Checks for an active lock on backup operations for the specified server. |
clear_pxe | clear_pxe | Clears the current PXE configuration for the specified host. If the hostname parameter is not provided, the server id is used. |
create_backup | create_backup | Initiates the backup creation process for the specified server. The operation is performed asynchronously. |
create_pxe | create_pxe | Initializes the PXE configuration creation process for server reinstallation or deployment, specifying OS and boot parameters. |
delete_backup | delete_backup | Deletes the specified server backup. A backup name is required. |
deploy | deploy | Starts the server deployment (deploy) process by ID or from a preset, considering configuration, OS, and traffic parameters. |
get_ipmi | get_ipmi | Returns the IP address and model (vendor) of available IPMI interfaces for the specified server. If there are multiple interfaces, an array is returned. |
get_traffic | get_traffic | Returns IPv4 traffic usage data for the specified equipment. |
getserversforannounce | getserversforannounce | Returns a list of available user servers (with status rent or power_off) that have passed subnet mask checks (/23 and /24) to perform an announcement. |
groups | groups | Returns the list of groups for a specific server. |
hard_off | hard_off | Sends a request for immediate (hard) shutdown of the equipment via IPMI/BMC. |
history | history | Returns the server event history. |
list | list | Returns a list of available equipment with filtering capabilities by various parameters (group, location, status, IP, email, etc.). |
off | off | Shuts down the server. |
on | on | Powers on the server. |
order_instance | order_instance | Starts the process of deploying a new server from a preset or reinstalling an existing server with OS and additional software selection. |
reboot | reboot | Sends a request to reboot the server via IPMI or system tools. |
reinstall | reinstall | Starts the server reinstallation preparation process, creates an operation key, and notifies the client. |
remove_ipmi_user | remove_ipmi_user | Deletes an additional IPMI user for the specified server. |
request_backup_link | request_backup_link | Requests the generation of a temporary link to download a server backup. |
restore_backup | restore_backup | Starts the process of restoring the server from the specified backup. The method is asynchronous and returns a callback key. |
search | search | Returns a list of available equipment (servers, VPS, etc.) with filtering by various parameters: location, status, type, IP address, MAC address, group, and others. |
sensors | sensors | Returns sensor status data for the specified server. |
show | show | Returns detailed server data, including hardware configuration (hwconfig), operating system, IP addresses, interfaces, and IPMI. |
status | status | Returns the current server status, its configuration, and related data (IP, interfaces, tags). |
suspend | suspend | Suspends VPS or server operation (depending on resource type). |
unified_server_search | unified_server_search | Unified search for servers by query. |
unit_reset | unit_reset | Requests an IPMI settings reset for the specified server. If the request requires confirmation, a callback is returned. |
unsuspend | unsuspend | Unlocks the server (removes suspension) if permitted by company policies. |
update_servers | update_servers | Updates the list of active and available servers for the user, including billing and pre-bill order checks. |
eq/abort_reinstall¶
Interrupts the server reinstallation process, removes associated tags (reinstall_start, autodeploy_start, autodeploy_timeout), and restores VLAN settings.
HTTP-method: POST
Parameters:
| Parameter | Required | Type | Description |
|---|---|---|---|
| action | ✅ | string | Method identifier: abort_reinstall |
| id | ✅ | integer | Server ID |
| token | ❌ | string | Authorization token |
Example Request
Failure response
``` { "code": -1, "message": "\(module/\)action: invalid server id" }
```
eq/add_ipmi_admin¶
Creates a new user with administrator privileges for IPMI management. If admin_user is specified, a user with the given name is created; otherwise, a random login and password are generated.
HTTP-method: POST
Parameters:
| Parameter | Required | Type | Description |
|---|---|---|---|
| action | ✅ | string | Method identifier: add_ipmi_admin |
| id | ✅ | integer | Equipment (server) ID |
| admin_user | ❌ | string | Username for IPMI administrator |
| admin_pass | ❌ | string | Password for IPMI administrator |
| token | ✅ | string | Authentication API token |
Example Request
Example of a successful response
Failure response
``` { "code": -1, "message": "Add IPMI user request failed" }
```
eq/add_ipmi_user¶
Creates a new IPMI user for the server. If the user is an administrator, admin_user and admin_pass parameters are required.
HTTP-method: POST
Parameters:
| Parameter | Required | Type | Description |
|---|---|---|---|
| action | ✅ | string | Method identifier: add_ipmi_user |
| token | ✅ | string | Authorization token |
| id | ✅ | integer | Server ID |
| admin_user | ❌ | string | Administrator name (if applicable) |
| admin_pass | ❌ | string | Administrator password |
Example Request
Example of a successful response
Failure response
``` { "code": -1, "message": "Add IPMI user request failed" }
```
eq/announceip¶
Requests announcement of a specified subnet or a specific server in the BGP network.
HTTP-method: POST|GET
Parameters:
| Parameter | Required | Type | Description |
|---|---|---|---|
| action | ✅ | string | Method identifier: announceip |
| token | ✅ | string | Authentication API token |
| id | ✅ | int | Equipment/server ID |
| subnet | ❌ | string | Subnet for announcement |
| server | ❌ | string | Server name |
| subnetaddr | ❌ | string | Address in the subnet |
| subnetaddrmask | ❌ | string | Subnet address mask |
| asn | ❌ | string|bool | Autonomous System number (can specify 'own') |
| ownasn | ❌ | string|bool | Use own ASN |
| annonce | ❌ | string|bool | Announcement flag |
| return | ❌ | string|bool | Return result |
| route | ❌ | string|bool | Route |
| cmnt | ❌ | string|bool | Comment |
| checkboxes | ✅ | boolean | Terms confirmation (ASRegistered, RKPIValid, SubNetNotSpamhaus, DataIsCorrect) |
Example Request
Failure response
``` { "code": -2, "message": "Authentication required" }
```
eq/backup_get_schedule¶
Returns the current automatic backup schedule for the specified server.
HTTP-method: GET
Parameters:
| Parameter | Required | Type | Description |
|---|---|---|---|
| action | ✅ | string | Method identifier: backup_get_schedule |
| token | ✅ | string | Authorization token |
| id | ✅ | integer | Equipment (server) ID |
Example Request
Example of a successful response
Failure response
``` { "code": -1, "message": "EQ/backup_get_schedule: invalid server id" }
```
eq/backup_list¶
Returns a list of available backups for the specified equipment (server).
HTTP-method: POST
Parameters:
| Parameter | Required | Type | Description |
|---|---|---|---|
| action | ✅ | string | Method identifier: backup_list |
| token | ✅ | string | Authorization token |
| id | ✅ | integer | Server ID |
Example Request
Example of a successful response
Failure response
``` { "code": -2, "message": "EQ: action required" }
```
eq/backup_save_schedule¶
Saves the configured backup schedule for the specified server.
HTTP-method: POST
Parameters:
| Parameter | Required | Type | Description |
|---|---|---|---|
| action | ✅ | string | Method identifier: backup_save_schedule |
| token | ✅ | string | Authentication token |
| id | ✅ | integer | Equipment (server) ID |
| backup_schedule | ✅ | object | Schedule object: |
Example Request
curl -s "https://invapi.hostkey.com/eq.php" -X POST \
--data "action=backup_save_schedule" \
--data "token=HOSTKEY_TOKEN" \
--data "id=123" \
--data "backup_schedule[days][]=1" \
--data "backup_schedule[days][]=7" \
--data "backup_schedule[time]=03:00" \
--data "backup_schedule[timezone]=Europe/London"
Failure response
``` { "code": -1, "message": "Request execution error" }
```
eq/boot_dev¶
Requests switching the server boot mode (PXE or disk), specifying the media type and boot mode.
HTTP-method: POST|GET
Parameters:
| Parameter | Required | Type | Description |
|---|---|---|---|
| action | ✅ | string | Method identifier: boot_dev |
| token | ✅ | string | Authentication token |
| id | ✅ | int | Server ID |
| media | ✅ | string | Bootable media type (e.g., iso, pxe) |
| boot_mode | ❌ | string | Boot mode: auto (automatic detection), uefi or legacy |
Example Request
Example of a successful response
Failure response
``` { "code": -1, "message": "Bootable media change request failed" }
```
eq/check_backup_lock¶
Checks for an active lock on backup operations for the specified server.
HTTP-method: POST
Parameters:
| Parameter | Required | Type | Description |
|---|---|---|---|
| action | ✅ | string | Method identifier: check_backup_lock |
| id | ✅ | integer | Equipment (server) ID |
| token | ❌ | string | Authorization token |
Example Request
Example of a successful response
Failure response
``` { "code": -1, "message": "EQ/check_backup_lock: invalid server id" }
```
eq/check_pin¶
Checks the PIN code for operations.
HTTP-method: POST
Parameters:
| Parameter | Required | Type | Description |
|---|---|---|---|
| action | ✅ | string | Method identifier: check_pin |
| token | ✅ | string | Authorization token |
| pin | ✅ | string | PIN code for verification |
Example Request
Example of a successful response
eq/clear_pxe¶
Clears the current PXE configuration for the specified host. If the hostname parameter is not provided, the server id is used.
HTTP-method: POST
Parameters:
| Parameter | Required | Type | Description |
|---|---|---|---|
| action | ✅ | string | Method identifier: clear_pxe |
| token | ✅ | string | Authorization token |
| id | ✅ | integer | Equipment ID |
| hostname | ❌ | string | Hostname for configuration clearing |
Example Request
Failure response
``` { "code": -1, "message": "Failed to submit clear PXE config request" }
```
eq/console¶
Requests the launch of the server management console via IPMI/NoVNC.
HTTP-method: POST
Parameters:
| Parameter | Required | Type | Description |
|---|---|---|---|
| action | ✅ | string | Method identifier: console |
| token | ❌ | string | Authorization token |
| id | ✅ | integer | Server ID |
Example Request
Failure response
``` { "code": -1, "message": "Console request failed" }
```
eq/create_backup¶
Initiates the backup creation process for the specified server. The operation is performed asynchronously.
HTTP-method: POST
Parameters:
| Parameter | Required | Type | Description |
|---|---|---|---|
| action | ✅ | string | Method identifier: create_backup |
| token | ❌ | string | Authorization token |
| id | ✅ | integer | Server ID for backup creation |
Example Request
Example of a successful response
Failure response
``` { "code": -1, "message": "Error during backup creation initiation" }
```
eq/create_pxe¶
Initializes the PXE configuration creation process for server reinstallation or deployment, specifying OS and boot parameters.
HTTP-method: POST
Parameters:
| Parameter | Required | Type | Description |
|---|---|---|---|
| action | ✅ | string | Method identifier: create_pxe |
| token | ✅ | string | Authorization token |
| id | ✅ | int | Equipment (server) ID |
| root_pass | ✅ | string | Root password |
| os_id | ✅ | int | Operating system ID |
| hostname | ❌ | string | Hostname |
| ssh_key | ❌ | string | SSH key |
| post_install_script | ❌ | string | Post-installation script |
| post_install_callback | ❌ | string | URL for callback notification |
| reinstall_key | ❌ | string | Reinstallation key |
| ❌ | string | User email | |
| os_name | ❌ | string | OS name (alias) |
| disk_mirror | ❌ | int | Disk mirroring (-1 by default) |
| activate_windows | ❌ | int | Windows activation (0/1) |
| activation_key | ❌ | string | Activation key |
| uefi | ❌ | int | UEFI boot mode (0/1/-1) |
| attendedInstall | ❌ | string | Attended installation |
| root_size | ❌ | int | Root partition size |
| deploy_ticket | ❌ | string | Kayako ticket ID |
| ignore_duplicated_install | ❌ | int | Ignore duplicate installations |
| no_lvm | ❌ | int | Disable LVM (0/1) |
| custom_domain | ❌ | string | Custom domain |
| manual_choice_dsk | ❌ | int | Manual disk selection |
Example Request
Failure response
``` { "code": -1, "message": "Create PXE config request failed: error_details" }
```
eq/delete_backup¶
Deletes the specified server backup. A backup name is required.
HTTP-method: POST
Parameters:
| Parameter | Required | Type | Description |
|---|---|---|---|
| action | ✅ | string | Method identifier: delete_backup |
| token | ✅ | string | Authorization token |
| id | ✅ | integer | Equipment (server) ID |
| name | ✅ | string | Backup name for deletion |
Example Request
Example of a successful response
Failure response
``` { "code": -1, "message": "Backup deletion error" }
```
eq/deploy¶
Starts the server deployment (deploy) process by ID or from a preset, considering configuration, OS, and traffic parameters.
HTTP-method: POST
Parameters:
| Parameter | Required | Type | Description |
|---|---|---|---|
| action | ✅ | string | Method identifier: deploy |
| token | ✅ | string | Authorization token |
| id | ❌ | integer | Specific server ID for deployment |
| preset | ❌ | string | Preset name for deployment |
| location | ❌ | integer | Location (datacenter) ID |
| hostname | ❌ | string | Hostname for the server |
| root_pass | ✅ | string | Root password (minimum 8 characters) |
| os_id | ❌ | integer | Operating system ID |
| ssh_key | ❌ | string | User SSH key |
| post_install_script | ❌ | string | Post-installation script |
| post_install_callback | ❌ | string | URL for callback notification |
| deploy_data | ✅ | string | Billing data (invoice ID or email) |
| deploy_options | ✅ | string | Deployment parameters (e.g., WHMCS location) |
| deploy_period | ❌ | string | Payment period (hourly, quarterly, semi-annually, annually) |
| deploy_notify | ❌ | integer | Client notification flag |
| custom_domain | ❌ | string | Custom domain |
| ipv4_amount | ❌ | integer | Number of IPv4 addresses |
| no_lvm | ❌ | integer | LVM usage flag (0 or 1) |
| traffic_plan | ❌ | integer | Traffic plan ID |
| disk_mirror | ❌ | string | Disk mirroring (RAID level) |
| deploy_comment | ❌ | string | Deployment comment |
| imitate_error | ❌ | integer | Error simulation (0 or 1) |
| imitate_deploy | ❌ | integer | Dry Run mode (0 or 1) |
Example Request
Example of a successful response
Failure response
``` { "code": -1, "message": "Deploy init for server 123 failed: error message" }
```
eq/get_ipmi¶
Returns the IP address and model (vendor) of available IPMI interfaces for the specified server. If there are multiple interfaces, an array is returned.
HTTP-method: GET
Parameters:
| Parameter | Required | Type | Description |
|---|---|---|---|
| action | ✅ | string | Method identifier: get_ipmi |
| id | ✅ | int | Equipment ID |
| token | ❌ | string | Authorization token |
Example Request
Example of a successful response
Failure response
``` { "code": -1, "message": "EQ/get_ipmi: invalid server id" }
```
eq/get_traffic¶
Returns IPv4 traffic usage data for the specified equipment.
HTTP-method: POST
Parameters:
| Parameter | Required | Type | Description |
|---|---|---|---|
| action | ✅ | string | Method identifier: get_traffic |
| id | ✅ | integer | Server ID |
| token | ❌ | string | Authorization token |
Example Request
Example of a successful response
Failure response
``` { "code": -1, "message": "EQ/get_traffic: invalid server id" }
```
eq/get_upgrade_key¶
Returns an upgrade key linked to a specific invoice (invoice_id) via equipment tags.
HTTP-method: POST|GET
Parameters:
| Parameter | Required | Type | Description |
|---|---|---|---|
| action | ❌ | string | Method identifier: get_upgrade_key |
| token | ✅ | string | Authorization token |
| id | ❌ | int | Server ID |
| invoice_id | ✅ | int | Invoice ID to search for the upgrade key |
Example Request
Example of a successful response
Failure response
``` { "code": -1, "message": "Key request error" }
```
eq/getserversforannounce¶
Returns a list of available user servers (with status rent or power_off) that have passed subnet mask checks (/23 and /24) to perform an announcement.
HTTP-method: POST|GET
Parameters:
| Parameter | Required | Type | Description |
|---|---|---|---|
| action | ✅ | string | Method identifier: getserversforannounce |
| token | ✅ | string | User authorization token |
Example Request
Example of a successful response
Failure response
``` { "code": -2, "message": "Authentication required" }
```
eq/groups¶
Returns the list of groups for a specific server.
HTTP-method: POST|GET
Parameters:
| Parameter | Required | Type | Description |
|---|---|---|---|
| action | ✅ | string | Method identifier: groups |
| token | ✅ | string | Authorization token |
| id | ✅ | integer | Equipment ID |
Example Request
Example of a successful response
Failure response
``` { "code": -2, "message": "EQ/groups: invalid server id" }
```
eq/hard_off¶
Sends a request for immediate (hard) shutdown of the equipment via IPMI/BMC.
HTTP-method: POST
Parameters:
| Parameter | Required | Type | Description |
|---|---|---|---|
| action | ✅ | string | Action name |
| token | ❌ | string | Authorization token |
| id | ✅ | integer | Server ID |
Example Request
Failure response
``` { "code": -1, "message": "Stop request failed" }
```
eq/history¶
Returns the server event history.
HTTP-method: POST
Parameters:
| Parameter | Required | Type | Description |
|---|---|---|---|
| action | ✅ | string | Method identifier: history |
| id | ✅ | int | Server ID |
| token | ✅ | string | Authorization token |
| type | ❌ | array<string> | Filter by event types |
| date_from | ❌ | string | Start date (YYYY-MM-DD) |
| date_to | ❌ | string | End date (YYYY-MM-DD) |
Example Request
Example of a successful response
eq/list¶
Returns a list of available equipment with filtering by various parameters (group, location, status, IP, email, etc.).
HTTP-method: GET
Parameters:
| Parameter | Required | Type | Description |
|---|---|---|---|
| action | ✅ | string | Method identifier: list |
| token | ❌ | string | Authorization token |
| group | ❌ | array | Filter by groups (e.g., 1CPU, 2CPU) |
| dc | ❌ | string | Datacenter ID |
| location | ❌ | array | Filter by locations (e.g., US-East, EU-Central) |
| rack | ❌ | string | Filter by rack_id |
| status | ❌ | array | Filter by statuses (rent, power_off, etc.) |
| owner | ❌ | string | Filter by owner |
| component | ❌ | array | Filter by equipment component ID |
| type | ❌ | string | Equipment type (server, switch, etc.) |
| ip | ❌ | array | Filter by IP address |
| mac | ❌ | string | Filter by MAC address |
| account_id | ❌ | array | Filter by billing account ID |
| billing | ❌ | array | Billing language (en/ru) |
| ❌ | array | Filter by client email | |
| name_client | ❌ | string | Filter by client name |
| full | ❌ | boolean | Return full data (for administrators) |
| kvm | ❌ | string | Filter by KVM |
| serialNumber | ❌ | string | Filter by serial number |
| id | ❌ | array | Filter by server IDs |
Example Request
curl -s "https://invapi.hostkey.com/eq.php" -X GET \
--data "action=list" \
--data "group[]=1CPU" \
--data "group[]=2CPU" \
--data "location[]=US-East" \
--data "location[]=EU-Central" \
--data "status[]=rent" \
--data "ip[]=192.168.1.1" \
--data "account_id[]=100" \
--data "billing[]=en" \
--data "email[][email protected]" \
--data "id[]=123" \
--data "id[]=456"
Example of a successful response
Failure response
``` { "code": -2, "message": "EQ: action required" }
```
eq/off¶
Shuts down the server.
HTTP-method: POST
Parameters:
| Parameter | Required | Type | Description |
|---|---|---|---|
| action | ✅ | string | Method identifier: off |
| id | ✅ | int | Server ID |
| token | ❌ | string | Authorization token |
Example Request
Example of a successful response
eq/on¶
Powers on the server.
HTTP-method: POST
Parameters:
| Parameter | Required | Type | Description |
|---|---|---|---|
| action | ✅ | string | Method identifier: on |
| id | ✅ | int | Server ID |
| token | ❌ | string | Authorization token |
Example Request
Example of a successful response
eq/order_instance¶
Starts the process of deploying a new server from a preset or reinstalling an existing server with OS and additional software selection.
HTTP-method: POST
Parameters:
| Parameter | Required | Type | Description |
|---|---|---|---|
| id | ❌ | int | Existing server ID (for reinstallation). If not specified, a new one is created from a preset. |
| preset | ❌ | string | Preset ID or name for ordering a new server. |
| root_pass | ✅ | string | Root password. Cannot contain @ or # characters. |
| os_template | ❌ | string | OS template for deployment from a template (for admins). |
| soft_id | ❌ | int | Additional software ID. |
| ssh_key | ❌ | string | Public SSH key. |
| post_install_script | ❌ | string | Post-installation script. |
| hostname | ❌ | string | Hostname. |
| root_size | ❌ | int | Root partition size (GB). |
| vlan | ❌ | string | Private VLAN ID. |
| ipv4_amount | ❌ | int | Number of IPv4 addresses. |
| custom_domain | ❌ | string | Custom domain. |
| deploy_period | ❌ | string | Payment period (hourly, quarterly, semi-annually, annually). |
| traffic_plan | ❌ | int | Traffic plan ID. |
| token | ✅ | string | Authentication API token |
Example Request
Example of a successful response
Failure response
``` { "code": -1, "message": "Reinstall init for server 123 failed: error message" }
```
eq/ovirt_novnc¶
Requests access to the NoVNC console for the server via the oVirt interface. Returns a callback key to initialize the session.
HTTP-method: POST
Parameters:
| Parameter | Required | Type | Description |
|---|---|---|---|
| action | ❌ | string | Action (ovirt_novnc) |
| token | ✅ | string | Authorization token |
| id | ✅ | integer | Server ID |
| white_ip | ❌ | string | White IP for console access |
Example Request
Example of a successful response
Failure response
``` { "code": -1, "message": "oVirt noVNC console request failed" }
```
eq/reboot¶
Sends a request to reboot the server via IPMI or system tools.
HTTP-method: POST
Parameters:
| Parameter | Required | Type | Description |
|---|---|---|---|
| action | ✅ | string | Action (reboot) |
| token | ✅ | string | Authorization token |
| id | ✅ | integer | Server ID |
Example Request
Example of a successful response
Failure response
``` { "code": -1, "message": "Reboot request failed" }
```
eq/reinstall¶
Starts the server reinstallation preparation process, creates an operation key, and notifies the client.
HTTP-method: POST
Parameters:
| Parameter | Required | Type | Description |
|---|---|---|---|
| action | ❌ | string | Action (reinstall) |
| token | ✅ | string | Authorization token |
| id | ✅ | integer | Server ID |
Example Request
Example of a successful response
Failure response
``` { "code": -1, "message": "EQ/reinstall: invalid server id" }
```
eq/remove_ipmi_user¶
Deletes an additional IPMI user for the specified server.
HTTP-method: POST
Parameters:
| Parameter | Required | Type | Description |
|---|---|---|---|
| action | ✅ | string | Method identifier: remove_ipmi_user |
| id | ✅ | integer | Server ID |
| token | ❌ | string | Authorization token |
Example Request
Example of a successful response
Failure response
``` { "code": -1, "message": "EQ/remove_ipmi_user: action: error_message" }
```
eq/request_backup_link¶
Requests the generation of a temporary link to download a server backup.
HTTP-method: POST
Parameters:
| Parameter | Required | Type | Description |
|---|---|---|---|
| action | ✅ | string | Method identifier: request_backup_link |
| token | ✅ | string | Authorization token |
| id | ✅ | integer | Equipment (server) ID |
| name | ❌ | string | Backup name for the request |
Example Request
Example of a successful response
Failure response
``` { "code": -1, "message": "Request failed: error_details" }
```
eq/restore_backup¶
Starts the process of restoring the server from the specified backup. The method is asynchronous and returns a callback key.
HTTP-method: POST
Parameters:
| Parameter | Required | Type | Description |
|---|---|---|---|
| action | ✅ | string | Method identifier: restore_backup |
| id | ✅ | int | Server ID |
| name | ✅ | string | Backup name for restoration |
Example Request
Example of a successful response
Failure response
``` { "code": -1, "message": "Request failed: error_details" }
```
eq/search¶
Returns a list of available equipment (servers, VPS, etc.) with filtering by various parameters: location, status, type, IP address, MAC address, group, and others.
HTTP-method: POST|GET
Parameters:
| Parameter | Required | Type | Description |
|---|---|---|---|
| action | ✅ | string | Method identifier: search |
| group[] | ❌ | array<string> | Filter by group (e.g.: 1CPU, 2CPU) |
| dc | ❌ | array<int> | Datacenter ID |
| location[] | ❌ | array<string> | Location code (e.g., US-East, EU-Central) |
| rack[] | ❌ | array<int> | Rack ID |
| status[] | ❌ | array<string> | Equipment status (e.g.: rented, prepare_full) |
| owner[] | ❌ | array<string> | Owner (Hostkey, colo, etc.) |
| component[] | ❌ | array<int> | Hardware component ID |
| type[] | ❌ | array<string> | Equipment type (server, switch, etc.) |
| ip[] | ❌ | array<string> | Filter by IP address |
| mac[] | ❌ | array<string> | Filter by MAC address |
| account_id[] | ❌ | array<int> | Billing account ID |
| billing[] | ❌ | array<string> | Billing region (en/ru) |
| email[] | ❌ | array<string> | Filter by client email |
| id[] | ❌ | array<int> | Equipment ID |
| token | ✅ | string | Authentication API token |
Example Request
Example of a successful response
{
"result": "OK",
"module": "eq",
"action": "search",
"servers": [
{
"id": 123,
"name_client": "[email protected]",
"status": "rent",
"type": "Server",
"location": {
"dc_location": -1,
"rack_id": 564,
"rack_position": 10
},
"ip": [
{
"IP": "1.2.3.4",
"status": "active"
}
]
}
],
"is_prebill": false,
"mounted_iso": ""
}
Failure response
``` { "code": -1, "message": "Query error" }
```
eq/sensors¶
Returns sensor status data for the specified server.
HTTP-method: POST
Parameters:
| Parameter | Required | Type | Description |
|---|---|---|---|
| action | ✅ | string | Method identifier: sensors |
| id | ✅ | int | Equipment ID |
| token | ❌ | string | Authorization token |
Example Request
Example of a successful response
Failure response
``` { "code": -1, "message": "Sensors request failed" }
```
eq/set_pin¶
Sets a PIN code for operations.
HTTP-method: POST
Parameters:
| Parameter | Required | Type | Description |
|---|---|---|---|
| action | ✅ | string | Method identifier: set_pin |
| token | ✅ | string | Authorization token |
| new_pin | ✅ | string | New PIN code (4-10 characters) |
| old_pin | ❌ | string | Old PIN code |
| no_pin_req | ❌ | string | Skip PIN check flag (true/false) |
Example Request
Example of a successful response
eq/show¶
Returns detailed server data, including hardware configuration (hwconfig), operating system, IP addresses, interfaces, and IPMI.
HTTP-method: GET
Parameters:
| Parameter | Required | Type | Description |
|---|---|---|---|
| action | ✅ | string | Method identifier: show |
| id | ✅ | int | Equipment ID |
| token | ❌ | string | Authorization token |
Example Request
Example of a successful response
{
"result": "OK",
"server_data": {
"id": 123,
"status": "rent",
"type": "Server",
"hostname": "srv-01.hostkey.com",
"owner": "[email protected]",
"Condition_Component": "power_off",
"hwconfig": {
"cpu": "Intel Xeon E5-2680",
"ram": 64,
"hdd": 1000
},
"location": {
"dc_name": "Amsterdam",
"dc_location": "NL"
}
},
"hardware": {
"cpu": "Intel Xeon E5-2680",
"ram": 64,
"hdd": 1000
},
"groups": [
{
"tag": "group_name",
"value": "val"
}
],
"licenses": [],
"reinstall": null,
"location": {
"dc_location": "NL",
"rack_id": 148,
"rack_position": -1,
"rack_name": "unknown",
"dc_name": "Amsterdam"
},
"OS": {
"id": 50,
"name": "Ubuntu 22.04 LTS",
"active": 1
},
"IP": [
{
"IP": "192.168.1.1",
"status": "active"
}
],
"interfaces": [],
"IPMI": {
"model": "none",
"interfaces": []
},
"tags": [
{
"tag": "server_name",
"value": "my-server"
}
],
"preset": null,
"commitment": ""
}
Failure response
``` { "code": -2, "message": "EQ: action required" }
```
eq/status¶
Returns the current server status, its configuration, and related data (IP, interfaces, tags).
HTTP-method: POST
Parameters:
| Parameter | Required | Type | Description |
|---|---|---|---|
| action | ✅ | string | Method identifier: status |
| id | ✅ | int | Server ID |
| token | ❌ | string | Authorization token |
Example Request
Failure response
``` { "code": -1, "message": "EQ/status: invalid server id" }
```
eq/status_check¶
Returns the current equipment state (status, configuration, tags).
HTTP-method: POST
Parameters:
| Parameter | Required | Type | Description |
|---|---|---|---|
| token | ✅ | string | Authentication token |
Example of a successful response
Failure response
``` { "code": -2, "message": "Authentication required" }
```
eq/suspend¶
Suspends VPS or server operation (depending on resource type).
HTTP-method: POST
Parameters:
| Parameter | Required | Type | Description |
|---|---|---|---|
| token | ✅ | string | Authorization token |
| id | ✅ | int | Server ID for suspension |
Example Request
Example of a successful response
Failure response
``` { "code": -1, "message": "Suspend request failed" }
```
eq/traffic_add¶
Increases the outbound traffic limit for the server and generates an invoice in WHMCS.
HTTP-method: POST|GET
Parameters:
| Parameter | Required | Type | Description |
|---|---|---|---|
| action | ✅ | string | Method identifier: traffic_add |
| id | ✅ | int | Equipment (server) ID |
| new_limit | ✅ | int | New traffic limit in TB |
| token | ✅ | string | Authentication API token |
Example Request
Example of a successful response
Failure response
``` { "code": -1, "message": "EQ/traffic_add: invalid new_limit" }
```
eq/unified_server_search¶
Unified search for servers by query.
HTTP-method: POST
Parameters:
| Parameter | Required | Type | Description |
|---|---|---|---|
| action | ✅ | string | Method identifier: unified_server_search |
| token | ✅ | string | Authorization token |
| query | ✅ | string | Search query (string or numeric ID) |
Example Request
Example of a successful response
{
"result": "OK",
"results": {
"servers": [
{
"id": 123,
"name": "Server 1",
"owner": "[email protected]",
"status": "rent",
"billing": "en",
"type": "server"
}
]
},
"limited": {
"servers": false
},
"category": "servers"
}
eq/unit_reset¶
Requests an IPMI settings reset for the specified server. If the request requires confirmation, a callback is returned.
HTTP-method: POST
Parameters:
| Parameter | Required | Type | Description |
|---|---|---|---|
| action | ✅ | string | Method identifier: unit_reset |
| id | ✅ | int | Equipment (server) ID |
| token | ❌ | string | Authorization token |
Example Request