hosting

PUT /v1/sites/{siteId}/php-config

Set a site's PHP settings.

All hosting endpoints

All developer docs →

Authentication

Send an API key as a bearer token. The key must carry the sites.view permission; a key without it is refused with 403, not 404.

This endpoint takes no organisation id. Your key already identifies the organisation it belongs to, and the response is scoped to it.

Try it

Replace anything in angle brackets with your own values, and the key placeholder with a key from your dashboard.

curl -X PUT https://api.zinndigital.com/v1/sites/{siteId}/php-config \
  -H "Authorization: Bearer zdk_live_…" \
  -H "Content-Type: application/json" \
  -d '{ "values": <object> }'

Signed in? The API console in your dashboard fills in your real organisation id and your own key, and runs the request against the live API so you can see the actual response. Open this endpoint in the API console

Details

Applies the complete set of overrides. An omitted name is cleared, and {} resets every setting to the machine's defaults — deliberately not a PATCH, because "return this to the platform default" and "pin it to the value that default happens to have today" are different intentions and only a whole-set write can express the first. Values are validated against the machine's own published range before the vendor sees them, so a bad value is refused in our words rather than failing later as an unexplained vendor error. The write is then read back off the machine and a value it quietly declined is a failure here, never a success the customer discovers is untrue. 409 when the site has no machine to hold the setting. Requires sites.view + sites.panel_access.

Parameters

NameTypeRequiredWhat it is
siteId (path)UuidYesSite ID (UUIDv7).

Request body

NameTypeRequiredWhat it is
valuesobjectYes—

Response

NameTypeRequiredWhat it is
supportedbooleanYesWhether this site's hosting publishes changeable PHP settings.
reasonstringYesWhy there are none, in words a customer can act on. Empty when supported is true.
optionsSitePhpOption[]Yes—
moved_to_plan_settingsstring[]NoDirectives the vendor publishes but whose legal range is OUR policy, so they are returned by getSitePhpSettings (with the plan's cap) instead of here. Named rather than silently…

Errors this endpoint can return

401 · 403 · 404 · 409 · 422 · 429 · 503