API & Automation
Connection
- Default port: 22100 (configurable, 1024–65535)
- Authentication: Bearer token in the
Authorization: Bearer <token> header - API documentation: Interactive Redoc UI at
/api/v1/docs - OpenAPI specification:
/api/v1/openapi.json
REST API
The API provides 42 endpoints. Here are the most important ones:
VM Lifecycle
| Method | Endpoint | Description |
|---|
| GET | /api/v1/vms | List all VMs |
| GET | /api/v1/vms/:id | VM details |
| POST | /api/v1/vms/:id/start | Start VM |
| POST | /api/v1/vms/:id/stop | Stop VM (ACPI) |
| POST | /api/v1/vms/:id/force-stop | Force stop VM |
| POST | /api/v1/vms/:id/pause | Pause VM |
| POST | /api/v1/vms/:id/resume | Resume VM |
Snapshots
| Method | Endpoint | Description |
|---|
| GET | /api/v1/vms/:id/snapshots | List snapshots |
| POST | /api/v1/vms/:id/snapshots | Create snapshot |
| POST | /api/v1/vms/:id/snapshots/:sid/restore | Restore |
| DELETE | /api/v1/vms/:id/snapshots/:sid | Delete |
Console
| Method | Endpoint | Description |
|---|
| GET | /api/v1/vms/:id/console | Read output |
| POST | /api/v1/vms/:id/console | Send text |
| POST | /api/v1/vms/:id/console/execute | Execute command |
| DELETE | /api/v1/vms/:id/console | Clear buffer |
Real-Time Events
Live events are available via WebSocket or Server-Sent Events (SSE) at /api/v1/events:
vm.started, vm.stopped, vm.paused, vm.resumed, vm.errorsnapshot.created, snapshot.restored, snapshot.deletedconsole.outputdownload.started, download.completed, download.failed
Webhooks
- Event filter: Choose specific events or receive all
- HMAC secret: Optional signature validation via
X-Nemeton-Secret header - Async delivery: Non-blocking with automatic retry
MCP (Model Context Protocol)
A JSON-RPC 2.0 interface with 24 tools is available at /mcp:
| Tool | Description |
|---|
list_vms | List all VMs |
start_vm / stop_vm | Start / stop VM |
send_console | Send command to console |
read_console | Read console output |
take_screenshot | Screenshot as Base64 JPEG |
create_snapshot | Create snapshot |
clone_vm | Duplicate VM as CoW clone |
resize_disk | Enlarge disk image |
get_host_info | Host system information |