hosting

PUT /v1/sites/{siteId}/maintenance-mode

Take a site into or out of maintenance.

Gbogbo àwọn hosting endpoints

Gbogbo àwọn ìwé àṣẹ olùgbékalẹ̀ àgbékalẹ̀

Ìfàṣẹ́pọ̀

Fi bọ́ọ̀lù (bearer token) ranṣẹ gẹ́gẹ́ bí kọ́kọ́rọ́ API. Kọ́kọ́rọ́ náà gbọ́dọ̀ ní ìyọ̀ǹda sites.view; a ó kọ̀ ọ́ silẹ pẹlu 403, kii ṣe 404, ti kọ́kọ́rọ́ náà kò bá ní i.

Ojú abánisọ̀rọ̀ yìí kò gba id ajọ kankan. Kọ́kọ́rọ́ rẹ ti mọ ajọ ti o jẹ ti e, a o si fèsì nipa rẹ̀.

Gbiyanju rẹ

Rọ́pọ̀ èyíkéyìí nínú àwọn àmì ìtọ́ka < > pẹ̀lú iye tirẹ̀, àti àmì ìdánimọ̀ bọ́tìnnì náà pẹ̀lú bọ́tìnnì kan láti inú dásibọ̀ọ̀dù rẹ.

curl -X PUT https://api.zinndigital.com/v1/sites/{siteId}/maintenance-mode \
  -H "Authorization: Bearer zdk_live_…" \
  -H "Content-Type: application/json" \
  -d '{ "enabled": <boolean> }'

Ṣé o ti wọlé? Iwọ̀n api ní nú ìgbékalẹ̀ rẹ kún id àjọ gidi rẹ ati bọtini tirẹ, o si nṣiṣẹ ibeere na lòdì si api gidi ki o le rii esi gidi na. Ṣí ojú abáná yìí sílẹ̀ nínú kọnsólù API

Àwọn kúlẹ̀kúlẹ̀

Switches every alias at once and returns the whole new state, so the client re-renders from the server's answer rather than from what it asked for. PUT because the body states the desired end state: sending the same value twice is the same site. ⛔ The customer's own maintenance-page HTML travels with the vendor's row, and this operation carries it through unchanged. A toggle built from scratch blanks it, replacing a page the customer wrote with a default one — which is why the write reads the existing row first. Turning it on takes the site off the internet for every visitor, so the client confirms before calling. Requires sites.view and sites.panel_access. 404 for a site with no managed hosting package.

Àwọn ìpìlẹ̀

OrúkọIruTí a nílòKini o jẹ
siteId (path)UuidBẹẹniSite ID (UUIDv7).

Akoonu ibeere naa

OrúkọIruTí a nílòKini o jẹ
enabledbooleanBẹẹniWhether visitors should be shown the maintenance page. There is no third value: getSiteMaintenanceMode may report a mixed set of aliases, but a caller asking to change it must…

Idahun

OrúkọIruTí a nílòKini o jẹ
availablebooleanBẹẹniWhether the package exposes maintenance mode at all. False renders an explanation rather than an empty list.
enabledbooleanBẹẹnitrue only when every alias is in maintenance. One alias still serving is a live site, and a single rounded boolean would hide that from a customer who believes they took…
aliasesSiteMaintenanceAlias[]BẹẹniEach alias on the package and its own state.
permittedbooleanBẹẹniWhether the package type includes maintenance mode. An absent vendor capability is a refusal, never an assumption that it is probably on.

Awọn aṣiṣe ti ibudo ipari yii le da pada

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