hosting

GET /v1/sites/{siteId}/wordpress/update-policy

What this site is set to update by itself, and where it has drifted.

Tous les points de terminaison hosting

Authentification

Envoyez une clé API en tant que jeton du porteur. La clé doit posséder l'autorisation sites.view ; une clé qui ne l'a pas est refusée avec le code 403, et non 404.

Cet endpoint ne prend aucun identifiant d'organisation. Votre clé identifie déjà l'organisation à laquelle elle appartient, et la réponse y est limitée.

Essayer

Remplacez tout ce qui se trouve entre crochets par vos propres valeurs, et le espace réservé à la clé par une clé de votre tableau de bord.

curl -X GET https://api.zinndigital.com/v1/sites/{siteId}/wordpress/update-policy \
  -H "Authorization: Bearer zdk_live_…"

Connecté ? La console d'API de votre tableau de bord saisit votre véritable ID d'organisation ainsi que votre propre clé, et exécute la requête sur l'API de production afin que vous puissiez voir la réponse réelle. Ouvrir ce point de terminaison dans la console API

Détails

Returns three things that must never be collapsed into one: the **policy** an operator stored, what the site is **actually** configured to do, and the **drift** between them. ⛔ A screen showing only the stored policy cannot tell a customer that the policy was never applied — which is the whole point. A decision is applied when a row changes, and the row that decides whether a WordPress updates itself lives on that WordPress, not in this platform's database. A customer can change any of it from wp-admin, a plugin can change it on activation, and a restored backup carries the old settings back. ⛔ `observed_core` is `""` when `WP_AUTO_UPDATE_CORE` is **not defined at all**, which is NOT the same as `off` — an undefined constant means WordPress applies its own default, which is `minor`. Rendering the first as the second would tell an operator their sites are not taking security releases when in fact they are. ⛔ `observed_read` is `false` when the site could not be read (a managed hosting package, or a box that did not answer). An empty `drift` is only meaningful while it is `true`; otherwise an unreachable site renders as compliant, which is the worst default for a security setting. Ungated read — requires `sites.view`.

Paramètres

NomTypeObligatoireQu'est-ce que c'est
siteId (path)UuidOuiSite ID (UUIDv7).

Réponse

NomTypeObligatoireQu'est-ce que c'est
corestring<off, minor, all>OuiThe stored policy for WordPress core updates.
pluginsbooleanOuiThe stored policy — whether every plugin should auto-update.
themesbooleanOuiThe stored policy — whether every theme should auto-update.
ringstring<canary, early, general>OuiThe staged-rollout ring this site belongs to.
applied_atstringOuiWhen the policy last reached the site, ISO-8601, or `""` if it never has. ⛔ A timestamp and not a flag: "when did this last reach the site" is the question an operator asks, and…
apply_errorstringOuiWhy the last apply failed, or `""`. Kept beside `applied_at` rather than replacing it, so a failed re-apply does not erase that an earlier one worked.
observed_readbooleanOuiWhether the site itself was read. ⛔ An empty `drift` is only meaningful while this is `true`.
observed_corestringOuiWhat `WP_AUTO_UPDATE_CORE` is set to on the site — `off`, `minor`, `all`, or `""` meaning **the constant is not defined at all**, so WordPress applies its own default. ⛔ `""` is…
plugins_offstring[]OuiThe plugins on this site that are NOT auto-updating.
themes_offstring[]OuiThe themes on this site that are NOT auto-updating.
driftstring<core, plugins, themes>[]OuiWhich of `core`, `plugins`, `themes` the site disagrees with the policy about.

Erreurs que cet point de terminaison peut renvoyer

401 · 403 · 404 · 429 · 503