API Documentation

Change PHP Version

Switch the PHP version used by the webspace's vhost. Restarts OpenLiteSpeed gracefully.

Required scope: webspace:manage

Headers

Header Required Value
Authorization Yes Bearer YOUR_API_KEY
Content-Type Yes application/json

Request Body

Parameter Required Description
phpVersion Yes One of 8.1, 8.2, 8.3, 8.4, 8.5.

Response

{ "data": { "id": "69e80ac1...", "subdomain": "ws-0862c.sitequest.eu", "phpVersion": "8.4" } }

Error Responses

Status Code Description
400 INVALID_PHP_VERSION Version is not in the supported list.
400 NO_CHANGES Webspace already runs that version.

Example

curl -X PATCH https://hosting.site.quest/api/v1/webspaces/69e80ac1.../php \
  -H "Authorization: Bearer sq_live_..." \
  -H "Content-Type: application/json" \
  -d '{ "phpVersion": "8.4" }'

MCP

This action is also available via the webspace_set_php MCP tool.