API reference
Server
Server status, services, processes, settings, hostname, updates.
Get the defaults for new accounts
GET/api/v1/server/account-settings
Responses
- 200 OK
Body
Field Type default_bandwidth_pagestring default_suspended_pagestring settingsHostingAccountSettings - 401 Unauthorized: no session, or an invalid or expired token
- 403 Forbidden: the caller can't use this (privileges, token scope, feature turned off)
- 500 Internal Server Error: internal
Save the defaults for new accounts
PUT/api/v1/server/account-settings
Request body
| Field | Type |
|---|---|
bandwidth_exceeded_action | string |
bandwidth_page_html | string |
suspended_page_html | string |
Responses
- 200 OK
Body
Field Type job_idstring settingsHostingAccountSettings - 400 Bad Request: validation
- 401 Unauthorized: no session, or an invalid or expired token
- 403 Forbidden: the caller can't use this (privileges, token scope, feature turned off)
- 500 Internal Server Error: internal
Web server status
GET/api/v1/server/apache
Responses
- 200 OK
Body
map of any
- 400 Bad Request: rejected
- 401 Unauthorized: no session, or an invalid or expired token
- 403 Forbidden: the caller can't use this (privileges, token scope, feature turned off)
- 500 Internal Server Error: internal
Get the basic setup (contact, nameservers)
GET/api/v1/server/basic
Responses
- 200 OK
Body
Field Type contact_emailstring contact_email2string default_home_rootstring hostnamestring main_ipv4string nameserversarray of string shared_ipstring shared_ip_idstring - 401 Unauthorized: no session, or an invalid or expired token
- 403 Forbidden: the caller can't use this (privileges, token scope, feature turned off)
- 500 Internal Server Error: internal
Save the basic setup
PUT/api/v1/server/basic
Request body
| Field | Type |
|---|---|
contact_email | string |
contact_email2 | string |
default_home_root | string |
nameservers | array of string |
Responses
- 200 OK
Body
Field Type contact_emailstring contact_email2string default_home_rootstring hostnamestring main_ipv4string nameserversarray of string shared_ipstring shared_ip_idstring - 400 Bad Request: validation
- 401 Unauthorized: no session, or an invalid or expired token
- 403 Forbidden: the caller can't use this (privileges, token scope, feature turned off)
- 500 Internal Server Error: internal
Database server overview
GET/api/v1/server/databases
Parameters
| Name | In |
|---|---|
server | query |
Responses
- 200 OK
- 400 Bad Request: rejected, wrong-server
- 401 Unauthorized: no session, or an invalid or expired token
- 403 Forbidden: the caller can't use this (privileges, token scope, feature turned off)
- 404 Not Found: not-found
- 500 Internal Server Error: internal
List database processes
GET/api/v1/server/databases/processes
Parameters
| Name | In |
|---|---|
server | query |
Responses
- 200 OK
Body
map of any
- 400 Bad Request: rejected, wrong-server
- 401 Unauthorized: no session, or an invalid or expired token
- 403 Forbidden: the caller can't use this (privileges, token scope, feature turned off)
- 404 Not Found: not-found
- 500 Internal Server Error: internal
Kill a database process
POST/api/v1/server/databases/processes/{pid}/kill
Parameters
| Name | In |
|---|---|
pid | path |
server | query |
Request body
| Field | Type |
|---|---|
query_only | boolean |
Responses
- 204 Done, no content
- 400 Bad Request: rejected, validation, wrong-server
- 401 Unauthorized: no session, or an invalid or expired token
- 403 Forbidden: the caller can't use this (privileges, token scope, feature turned off)
- 404 Not Found: not-found
- 500 Internal Server Error: internal
Database root access status
GET/api/v1/server/databases/root
Parameters
| Name | In |
|---|---|
server | query |
Responses
- 200 OK
Body
map of any
- 400 Bad Request: rejected, wrong-server
- 401 Unauthorized: no session, or an invalid or expired token
- 403 Forbidden: the caller can't use this (privileges, token scope, feature turned off)
- 404 Not Found: not-found
- 500 Internal Server Error: internal
Repair database root access
POST/api/v1/server/databases/root/repair
Parameters
| Name | In |
|---|---|
server | query |
Responses
- 200 OK
Body
map of any
- 400 Bad Request: rejected, wrong-server
- 401 Unauthorized: no session, or an invalid or expired token
- 403 Forbidden: the caller can't use this (privileges, token scope, feature turned off)
- 404 Not Found: not-found
- 500 Internal Server Error: internal
Disk I/O per device
GET/api/v1/server/disk-io
Parameters
| Name | In |
|---|---|
server | query |
Responses
- 200 OK
Body
map of any
- 400 Bad Request: rejected, wrong-server
- 401 Unauthorized: no session, or an invalid or expired token
- 403 Forbidden: the caller can't use this (privileges, token scope, feature turned off)
- 404 Not Found: not-found
- 500 Internal Server Error: internal
Hardware (CPU, memory, disks)
GET/api/v1/server/hardware
Parameters
| Name | In |
|---|---|
server | query |
Responses
- 200 OK
Body
map of any
- 400 Bad Request: rejected, wrong-server
- 401 Unauthorized: no session, or an invalid or expired token
- 403 Forbidden: the caller can't use this (privileges, token scope, feature turned off)
- 404 Not Found: not-found
- 500 Internal Server Error: internal
Change the server's hostname
PUT/api/v1/server/hostname
Request body
| Field | Type |
|---|---|
hostname | string |
Responses
- 200 OK
Body
Field Type certificate_job_idstring hostnamestring messagestring - 400 Bad Request: rejected, validation
- 401 Unauthorized: no session, or an invalid or expired token
- 403 Forbidden: the caller can't use this (privileges, token scope, feature turned off)
- 409 Conflict: validation
- 500 Internal Server Error: internal
Count the recipients of a message to all users
GET/api/v1/server/mass-mail
How many addresses Email All Users (or ?resellers=1) reaches.
Parameters
| Name | In |
|---|---|
resellers | query |
Responses
- 200 OK
Body
Field Type default_fromstring recipientsinteger - 401 Unauthorized: no session, or an invalid or expired token
- 403 Forbidden: the caller can't use this (privileges, token scope, feature turned off)
- 500 Internal Server Error: internal
Email all users or resellers
POST/api/v1/server/mass-mail
Email All Users / Email All Resellers (a task: one message per address).
Request body
| Field | Type |
|---|---|
body | string |
from_email | string |
from_name | string |
hostname | string |
reseller_id | string |
resellers | boolean |
subject | string |
Responses
- 202 Accepted (runs in the background)
Body
Field Type job_idstring - 400 Bad Request: validation
- 401 Unauthorized: no session, or an invalid or expired token
- 403 Forbidden: the caller can't use this (privileges, token scope, feature turned off)
- 500 Internal Server Error: internal
List processes
GET/api/v1/server/processes
Parameters
| Name | In |
|---|---|
server | query |
Responses
- 200 OK
Body
Field Type itemsarray of AgentprotoProcess - 400 Bad Request: rejected, wrong-server
- 401 Unauthorized: no session, or an invalid or expired token
- 403 Forbidden: the caller can't use this (privileges, token scope, feature turned off)
- 404 Not Found: not-found
- 500 Internal Server Error: internal
Kill a process
POST/api/v1/server/processes/{pid}/kill
Parameters
| Name | In |
|---|---|
pid | path |
server | query |
Request body
| Field | Type |
|---|---|
signal | string |
Responses
- 204 Done, no content
- 400 Bad Request: rejected, validation, wrong-server
- 401 Unauthorized: no session, or an invalid or expired token
- 403 Forbidden: the caller can't use this (privileges, token scope, feature turned off)
- 404 Not Found: not-found
- 500 Internal Server Error: internal
Kill every process of a user
POST/api/v1/server/processes/kill-user
Request body
| Field | Type |
|---|---|
signal | string |
user | string |
Responses
- 200 OK
Body
map of any
- 400 Bad Request: rejected, validation
- 401 Unauthorized: no session, or an invalid or expired token
- 403 Forbidden: the caller can't use this (privileges, token scope, feature turned off)
- 500 Internal Server Error: internal
Reboot the server
POST/api/v1/server/reboot
Parameters
| Name | In |
|---|---|
server | query |
Request body
| Field | Type |
|---|---|
confirm | string |
mode | string |
Responses
- 202 Accepted (runs in the background)
Body
Field Type messagestring - 400 Bad Request: confirmation-required, rejected, wrong-server
- 401 Unauthorized: no session, or an invalid or expired token
- 403 Forbidden: the caller can't use this (privileges, token scope, feature turned off)
- 404 Not Found: not-found
- 500 Internal Server Error: internal
Get the DNS resolvers
GET/api/v1/server/resolvers
Parameters
| Name | In |
|---|---|
server | query |
Responses
- 200 OK
Body
map of any
- 400 Bad Request: rejected, wrong-server
- 401 Unauthorized: no session, or an invalid or expired token
- 403 Forbidden: the caller can't use this (privileges, token scope, feature turned off)
- 404 Not Found: not-found
- 500 Internal Server Error: internal
Save the DNS resolvers
PUT/api/v1/server/resolvers
Parameters
| Name | In |
|---|---|
server | query |
Request body
| Field | Type |
|---|---|
resolvers | array of string |
Responses
- 200 OK
Body
map of any
- 400 Bad Request: rejected, wrong-server
- 401 Unauthorized: no session, or an invalid or expired token
- 403 Forbidden: the caller can't use this (privileges, token scope, feature turned off)
- 404 Not Found: not-found
- 500 Internal Server Error: internal
Resource usage of every account
GET/api/v1/server/resource-usage
Every account's last-24h use and faults, heaviest CPU first (admin overview).
Responses
- 200 OK
Body
Field Type itemsarray of map of any rangestring - 401 Unauthorized: no session, or an invalid or expired token
- 403 Forbidden: the caller can't use this (privileges, token scope, feature turned off)
- 500 Internal Server Error: internal
Change the system root password
POST/api/v1/server/root-password
Parameters
| Name | In |
|---|---|
server | query |
Request body
| Field | Type |
|---|---|
confirm | string |
password | string |
Responses
- 204 Done, no content
- 400 Bad Request: rejected, validation, wrong-server
- 401 Unauthorized: no session, or an invalid or expired token
- 403 Forbidden: the caller can't use this (privileges, token scope, feature turned off)
- 404 Not Found: not-found
- 500 Internal Server Error: internal
List services
GET/api/v1/server/services
Parameters
| Name | In |
|---|---|
server | query |
Responses
- 200 OK
Body
Field Type itemsarray of ServiceView monitorboolean - 400 Bad Request: rejected, wrong-server
- 401 Unauthorized: no session, or an invalid or expired token
- 403 Forbidden: the caller can't use this (privileges, token scope, feature turned off)
- 404 Not Found: not-found
- 500 Internal Server Error: internal
Start, stop or restart a service
POST/api/v1/server/services/{name}/{action}
Parameters
| Name | In |
|---|---|
name | path |
action | path |
server | query |
Responses
- 200 OK
Body
Field Type activealwaysstring enabledalwaysboolean failedarray of string groupstring installedalwaysboolean labelstring main_pidalwaysinteger memory_bytesalwaysinteger namestring protectedboolean restartsalwaysinteger sinceinteger subalwaysstring unitstring - 400 Bad Request: rejected, wrong-server
- 401 Unauthorized: no session, or an invalid or expired token
- 403 Forbidden: the caller can't use this (privileges, token scope, feature turned off)
- 404 Not Found: not-found
- 500 Internal Server Error: internal
Monitor a service or stop monitoring it
PUT/api/v1/server/services/{name}/monitor
Parameters
| Name | In |
|---|---|
name | path |
Request body
| Field | Type |
|---|---|
enabled | boolean |
Responses
- 204 Done, no content
- 401 Unauthorized: no session, or an invalid or expired token
- 403 Forbidden: the caller can't use this (privileges, token scope, feature turned off)
- 500 Internal Server Error: internal
Get the server settings
GET/api/v1/server/settings
Responses
- 200 OK
Body
Field Type mailGlobalcfgMail smarthost_password_setalwaysboolean webGlobalcfgWeb - 401 Unauthorized: no session, or an invalid or expired token
- 403 Forbidden: the caller can't use this (privileges, token scope, feature turned off)
- 500 Internal Server Error: internal
Save the server settings
PUT/api/v1/server/settings
Request body
| Field | Type |
|---|---|
mail | GlobalcfgMail |
smarthost_password | string |
smarthost_password_set | boolean |
web | GlobalcfgWeb |
Responses
- 200 OK
Body
Field Type mailGlobalcfgMail smarthost_password_setalwaysboolean webGlobalcfgWeb - 400 Bad Request: rejected, validation
- 401 Unauthorized: no session, or an invalid or expired token
- 403 Forbidden: the caller can't use this (privileges, token scope, feature turned off)
- 500 Internal Server Error: internal
Server status (load, memory, disks, services)
GET/api/v1/server/status
Parameters
| Name | In |
|---|---|
server | query |
Responses
- 200 OK
Body
Field Type agent_versionstring cgroup_v2boolean cpu_modelalwaysstring cpusinteger disksalwaysarray of AgentprotoDiskUsage hostnamestring kernelstring load1alwaysnumber load15alwaysnumber load5alwaysnumber mem_available_bytesalwaysinteger mem_total_bytesinteger os_idstring os_pretty_namestring os_versionstring selinuxstring swap_free_bytesalwaysinteger swap_total_bytesalwaysinteger uptime_secondsalwaysinteger virtualizationalwaysstring - 400 Bad Request: rejected, wrong-server
- 401 Unauthorized: no session, or an invalid or expired token
- 403 Forbidden: the caller can't use this (privileges, token scope, feature turned off)
- 404 Not Found: not-found
- 500 Internal Server Error: internal
List tweak settings
GET/api/v1/server/tweak-settings
Parameters
| Name | In |
|---|---|
category | query |
q | query |
Responses
- 200 OK
Body
Field Type categoriesarray of SettingsCategory itemsarray of TweakItem - 401 Unauthorized: no session, or an invalid or expired token
- 403 Forbidden: the caller can't use this (privileges, token scope, feature turned off)
- 500 Internal Server Error: internal
Save tweak settings
PUT/api/v1/server/tweak-settings
Parameters
| Name | In |
|---|---|
category | query |
q | query |
Request body
| Field | Type |
|---|---|
values | map of any |
Responses
- 200 OK
Body
Field Type categoriesarray of SettingsCategory itemsarray of TweakItem - 400 Bad Request: rejected, validation
- 401 Unauthorized: no session, or an invalid or expired token
- 403 Forbidden: the caller can't use this (privileges, token scope, feature turned off)
- 500 Internal Server Error: internal
Reset a tweak setting to its default
DELETE/api/v1/server/tweak-settings/{key}
Parameters
| Name | In |
|---|---|
key | path |
Responses
- 204 Done, no content
- 400 Bad Request: rejected, validation
- 401 Unauthorized: no session, or an invalid or expired token
- 403 Forbidden: the caller can't use this (privileges, token scope, feature turned off)
- 404 Not Found: not-found
- 500 Internal Server Error: internal
Panel update status
GET/api/v1/server/updates
Responses
- 200 OK
Body
Field Type applyingstring availableboolean configUpdateConfig current_buildinteger current_versionstring last_check_atinteger last_check_errorstring last_resultUpdateResult latestUpdateManifest nodesalwaysarray of NodeVersion - 401 Unauthorized: no session, or an invalid or expired token
- 403 Forbidden: the caller can't use this (privileges, token scope, feature turned off)
- 503 Service Unavailable: updates-off
Install the available panel update
POST/api/v1/server/updates/apply
Responses
- 202 Accepted (runs in the background)
Body
Field Type messagestring versionstring - 401 Unauthorized: no session, or an invalid or expired token
- 403 Forbidden: the caller can't use this (privileges, token scope, feature turned off)
- 409 Conflict: up-to-date
- 502 Bad Gateway: update-failed
- 503 Service Unavailable: updates-off
Change the update channel
PUT/api/v1/server/updates/channel
Request body
| Field | Type |
|---|---|
auto | boolean |
channel | string |
Responses
- 200 OK
Body
Field Type applyingstring availableboolean configUpdateConfig current_buildinteger current_versionstring last_check_atinteger last_check_errorstring last_resultUpdateResult latestUpdateManifest nodesalwaysarray of NodeVersion - 400 Bad Request: validation
- 401 Unauthorized: no session, or an invalid or expired token
- 403 Forbidden: the caller can't use this (privileges, token scope, feature turned off)
- 502 Bad Gateway: nodes-unreachable
- 503 Service Unavailable: updates-off
Check for panel updates now
POST/api/v1/server/updates/check
Responses
- 200 OK
Body
Field Type applyingstring availableboolean configUpdateConfig current_buildinteger current_versionstring last_check_atinteger last_check_errorstring last_resultUpdateResult latestUpdateManifest nodesalwaysarray of NodeVersion - 401 Unauthorized: no session, or an invalid or expired token
- 403 Forbidden: the caller can't use this (privileges, token scope, feature turned off)
- 502 Bad Gateway: update-check-failed
- 503 Service Unavailable: updates-off
Operating system update settings and status
GET/api/v1/server/updates/os
Responses
- 200 OK
Body
Field Type houralwaysinteger runningalwaysboolean serversalwaysarray of HostingOSUpdateServer - 401 Unauthorized: no session, or an invalid or expired token
- 403 Forbidden: the caller can't use this (privileges, token scope, feature turned off)
- 500 Internal Server Error: internal
Save the operating system update settings
PUT/api/v1/server/updates/os
Request body
| Field | Type |
|---|---|
enabled | boolean |
Responses
- 200 OK
Body
Field Type houralwaysinteger runningalwaysboolean serversalwaysarray of HostingOSUpdateServer - 400 Bad Request: validation
- 401 Unauthorized: no session, or an invalid or expired token
- 403 Forbidden: the caller can't use this (privileges, token scope, feature turned off)
- 500 Internal Server Error: internal
- 502 Bad Gateway: nodes-unreachable
Update the operating system now
POST/api/v1/server/updates/os/run
Parameters
| Name | In |
|---|---|
server | query |
Responses
- 202 Accepted (runs in the background)
Body
Field Type job_idstring - 401 Unauthorized: no session, or an invalid or expired token
- 403 Forbidden: the caller can't use this (privileges, token scope, feature turned off)
- 404 Not Found: not-found
- 409 Conflict: already-running
- 500 Internal Server Error: internal
First-run setup status
GET/api/v1/setup
Responses
- 200 OK
Body
Field Type completedalwaysboolean contact_emailalwaysstring hostnamealwaysstring license_statusalwaysstring main_ipv4alwaysstring nameserversalwaysarray of string terms_acceptedalwaysboolean trial_ends_atinteger - 401 Unauthorized: no session, or an invalid or expired token
- 403 Forbidden: the caller can't use this (privileges, token scope, feature turned off)
- 500 Internal Server Error: internal
Finish the first-run setup
POST/api/v1/setup
Request body
| Field | Type |
|---|---|
accept_terms | boolean |
contact_email | string |
nameservers | array of string |
Responses
- 200 OK
Body
Field Type setupStoreSetupState warningsmap of string - 400 Bad Request: validation
- 401 Unauthorized: no session, or an invalid or expired token
- 403 Forbidden: the caller can't use this (privileges, token scope, feature turned off)
- 500 Internal Server Error: internal