Hostinger API playground

Every button sends a real request to the Hostinger API about the lab VPS srv2196542 (ID 2196542), then shows exactly what was sent and what came back. The token stays on the server; you only see its last 4 characters.

Read (GET): safe, changes nothing

Every VPS on the account. (The playground hides all VPSs except the lab one.)
Plan, state (running/stopped), CPUs, RAM, disk, IPs, OS template.
CPU, RAM, disk, traffic and uptime history. Keys are Unix timestamps: look at the gap between them.
Recent actions on the VPS (restart, start, snapshot…) and whether they succeeded.
The VPS can have one snapshot. 404 means there is none yet.
Backup points kept by Hostinger outside the VPS.

Do something (POST)

Stops and starts the lab VPS. Takes about a minute; the lab control page comes back by itself.
Takes a new snapshot. It REPLACES the existing one.

See an error on purpose

Same "VPS details" call, but without the Authorization header.
Same call with an invalid token, like a typo or a revoked token.
Same call with another VPS ID.
Pick a request on the left. Start with VPS details.

Also in the API, but not in this playground (57 operations)

These exist and customers can use them, but they're left out here for safety: they would erase or revert the lab VPS, cost money, change logins, expose other servers on the account, or simply don't apply to this VPS. You just need to know they exist. All paths start with /api/vps/v1; details and examples are in the API documentation.

MethodOperationPathWhy not here
Virtual machines
POSTPurchase new virtual machine/virtual-machinesCosts money / creates a new service
Power
POSTStart virtual machine/virtual-machines/{virtualMachineId}/startPower change (left out together with stop)
POSTStop virtual machine/virtual-machines/{virtualMachineId}/stopTakes the VPS offline
Snapshot
DELETEDelete snapshot/virtual-machines/{virtualMachineId}/snapshotDeletes the only snapshot
POSTRestore snapshot/virtual-machines/{virtualMachineId}/snapshot/restoreReverts the whole VPS
Backups
POSTRestore backup/virtual-machines/{virtualMachineId}/backups/{backupId}/restoreOverwrites everything on the VPS
Rebuild and recovery
DELETEStop recovery mode/virtual-machines/{virtualMachineId}/recoveryReboots the VPS out of rescue mode
POSTStart recovery mode/virtual-machines/{virtualMachineId}/recoveryTakes the VPS offline into rescue mode
POSTRecreate virtual machine/virtual-machines/{virtualMachineId}/recreateErases all data on the VPS
POSTSetup purchased virtual machine/virtual-machines/{virtualMachineId}/setupCosts money / creates a new service
Access
PUTSet panel password/virtual-machines/{virtualMachineId}/panel-passwordChanges login credentials
PUTSet root password/virtual-machines/{virtualMachineId}/root-passwordChanges login credentials
DELETERemove virtual machine SSH keys/virtual-machines/{virtualMachineId}/ssh-keysChanges who can log in
GETList virtual machine SSH keys/virtual-machines/{virtualMachineId}/ssh-keysShows who can log in
POSTAdd virtual machine SSH keys/virtual-machines/{virtualMachineId}/ssh-keysChanges who can log in
Account SSH public keys
GETGet public keys/public-keysShows who can log in
POSTCreate public key/public-keysChanges who can log in
DELETEDelete public key/public-keys/{publicKeyId}Changes who can log in
Post-install scripts
GETGet post-install scripts/post-install-scriptsAccount-wide scripts; can contain secrets
POSTCreate post-install script/post-install-scriptsAccount-wide; runs as root on new installs
DELETEDelete post-install script/post-install-scripts/{postInstallScriptId}Account-wide; runs as root on new installs
GETGet post-install script/post-install-scripts/{postInstallScriptId}Account-wide scripts; can contain secrets
PUTUpdate post-install script/post-install-scripts/{postInstallScriptId}Account-wide; runs as root on new installs
Network
DELETEReset hostname/virtual-machines/{virtualMachineId}/hostnameChanges network identity / DNS
PUTSet hostname/virtual-machines/{virtualMachineId}/hostnameChanges network identity / DNS
PUTSet nameservers/virtual-machines/{virtualMachineId}/nameserversChanges network identity / DNS
DELETEDelete PTR record/virtual-machines/{virtualMachineId}/ptr/{ipAddressId}Changes network identity / DNS
POSTCreate PTR record/virtual-machines/{virtualMachineId}/ptr/{ipAddressId}Changes network identity / DNS
Firewall
GETGet firewall list/firewallAccount-wide: shows other servers' rules
POSTCreate new firewall/firewallAccount-wide, can block access
DELETEDelete firewall/firewall/{firewallId}Account-wide, can block access
GETGet firewall details/firewall/{firewallId}Account-wide: shows other servers' rules
POSTActivate firewall/firewall/{firewallId}/activate/{virtualMachineId}Account-wide, can block access
POSTDeactivate firewall/firewall/{firewallId}/deactivate/{virtualMachineId}Account-wide, can block access
POSTCreate firewall rule/firewall/{firewallId}/rulesAccount-wide, can block access
PUTReplace all firewall rules in group/firewall/{firewallId}/rulesAccount-wide, can block access
DELETEDelete firewall rule/firewall/{firewallId}/rules/{ruleId}Account-wide, can block access
PUTUpdate firewall rule/firewall/{firewallId}/rules/{ruleId}Account-wide, can block access
POSTSync firewall to all assigned VMs/firewall/{firewallId}/syncAccount-wide, can block access
POSTSync firewall/firewall/{firewallId}/sync/{virtualMachineId}Account-wide, can block access
Docker Manager
GETGet project list/virtual-machines/{virtualMachineId}/dockerNot available: the lab VPS has no Docker
POSTCreate new project/virtual-machines/{virtualMachineId}/dockerNot available: the lab VPS has no Docker
GETGet project contents/virtual-machines/{virtualMachineId}/docker/{projectName}Not available: the lab VPS has no Docker
GETGet project containers/virtual-machines/{virtualMachineId}/docker/{projectName}/containersNot available: the lab VPS has no Docker
DELETEDelete project/virtual-machines/{virtualMachineId}/docker/{projectName}/downNot available: the lab VPS has no Docker
GETGet project logs/virtual-machines/{virtualMachineId}/docker/{projectName}/logsNot available: the lab VPS has no Docker
POSTRestart project/virtual-machines/{virtualMachineId}/docker/{projectName}/restartNot available: the lab VPS has no Docker
POSTStart project/virtual-machines/{virtualMachineId}/docker/{projectName}/startPower change (left out together with stop)
POSTStop project/virtual-machines/{virtualMachineId}/docker/{projectName}/stopTakes the VPS offline
POSTUpdate project/virtual-machines/{virtualMachineId}/docker/{projectName}/updateNot available: the lab VPS has no Docker
Monarx malware scanner
DELETEUninstall Monarx/virtual-machines/{virtualMachineId}/monarxInstalls/removes software on the VPS
GETGet scan metrics/virtual-machines/{virtualMachineId}/monarxKept out to keep the lab focused
POSTInstall Monarx/virtual-machines/{virtualMachineId}/monarxInstalls/removes software on the VPS
Actions
GETGet action details/virtual-machines/{virtualMachineId}/actions/{actionId}Kept out to keep the lab focused
Catalog info
GETGet data center list/data-centersKept out to keep the lab focused
GETGet templates/templatesKept out to keep the lab focused
GETGet template details/templates/{templateId}Kept out to keep the lab focused