API-Dokumentation

Umbenennen / Verschieben

Datei/Verzeichnis im Webspace-Home umbenennen oder verschieben. Sowohl from als auch to müssen innerhalb ~/ liegen.

Erforderlicher Scope: webspace:manage

Header

Header Erforderlich Wert
Authorization Ja Bearer DEIN_API_SCHLÜSSEL
Content-Type Ja application/json

Body

Parameter Erforderlich Beschreibung
from Ja Quellpfad.
to Ja Zielpfad.

Antwort

{ "data": { "from": "/home/ws_0862c/a.txt", "to": "/home/ws_0862c/b.txt", "renamed": true } }

Beispiel

curl -X POST https://hosting.site.quest/api/v1/webspaces/69e80ac1.../sftp/rename \
  -H "Authorization: Bearer sq_live_..." \
  -H "Content-Type: application/json" \
  -d '{ "from": "/home/ws_0862c/a.txt", "to": "/home/ws_0862c/b.txt" }'

MCP

Diese Aktion ist auch über das webspace_rename MCP-Tool verfügbar.