VPS-Poweraktion
Führe eine Poweraktion auf einem VPS aus: starten, stoppen oder neustarten.
Anfrage
POST /api/v1/vps/{id}/power
Erforderlicher Scope: vps:write
Pfadparameter
| Parameter |
Typ |
Beschreibung |
id |
string |
Die VPS-ID |
Header
| Header |
Erforderlich |
Wert |
Authorization |
Ja |
Bearer DEIN_API_SCHLÜSSEL |
Content-Type |
Ja |
application/json |
Anfragekörper
| Feld |
Typ |
Erforderlich |
Beschreibung |
action |
string |
Ja |
Entweder start, stop oder restart |
{
"action": "restart"
}
Antwort
{
"data": {
"action": "restart",
"success": true
}
}
Antwortfelder
| Feld |
Typ |
Beschreibung |
action |
string |
Die ausgeführte Poweraktion |
success |
boolean |
Ob die Aktion akzeptiert wurde |
Fehler
| Status |
Code |
Beschreibung |
| 400 |
INVALID_ACTION |
Der action-Wert ist nicht start, stop oder restart |
| 404 |
NOT_FOUND |
VPS nicht gefunden oder kein Zugriff |
| 502 |
PROVIDER_ERROR |
Upstream-Anbieterfehler |
Beispiel
curl -X POST "https://site.quest/api/v1/vps/699cdea2ab57a244bb5273fd/power" \
-H "Authorization: Bearer DEIN_API_SCHLÜSSEL" \
-H "Content-Type: application/json" \
-d '{"action": "restart"}'
MCP
Diese Aktion ist auch über das vm_power MCP-Tool verfügbar.