En

KVM Server API

Manage servers with API tokens and grant precise permissions.

The KVM Server API lets you retrieve server details, historical statistics, and network information, control a server, and manage One-Click Apps.

Base URL

  • Production: https://api.key2host.com/api/v1
  • Local development: http://localhost:3000/api/v1

Every endpoint belongs to a server at /servers/{serverId}. Use the public server ID shown in the Customer Center, not the Proxmox VM ID.

Create an API token

  1. Open Security → API Tokens in the Customer Center.
  2. Create a token and copy it immediately. The complete value is shown only once.
  3. Select Manage, assign servers, and enable only the scopes you need.

You can also assign tokens under Advanced → API on a server. Removing every scope removes the server assignment while keeping the token itself.

Authentication

Send the token with every request:

Authorization: Bearer YOUR_API_TOKEN
Content-Type: application/json

Tokens are managed through Better Auth, remain valid for one year, and allow up to 60 requests per minute across their assigned servers. Store them as secrets and never expose them in browser code, URLs, or repositories.

Scopes and locks

Every endpoint requires the scope listed in the endpoint reference. Scopes apply only to the assigned server. Server locks and active reinstallations are enforced in the API just as they are in the Customer Center.

Features not yet available

Backup operations and paid traffic resets are currently reserved. Their endpoints respond with 501 NOT_IMPLEMENTED and do not create backups, charges, schedules, or resets.

Continue with the endpoint reference or examples.