hosting

PUT /v1/sites/{siteId}/wordpress/themes/{themeName}

Activate or deactivate a theme on a site.

Dukkan hosting wuraren ƙarshe

Tabbatar da Asali

Aika maɓallin API azaman alamar ɗauka (bearer token). Dole ne maɓallin ya kasance yana da izinin sites.view; idan babu shi, za a ƙi amfani da maɓallin tare da lambar 403, ba 404 ba.

Wannan wurin ƙarewa ba ya buƙatar ID na ƙungiya. Maɓallin ku ya riga ya gano ƙungiyar da yake ciki, kuma an iyakance amsa a kanta.

Gwada

May gurbin komai da ke cikin kusurwa da ƙimar ka, kuma may gurbin maballi da maballi daga allon sarrafa ka.

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

An shiga? Na'urar sarrafa API da ke cikin sashin kulawarka tana cika ainihin lambar ƙungiyarka da maɓallinka naka, sannan tana gudanar da buƙatar a kan ainihin API don haka zaka iya ganin amsar gaske. Buɗe wannan tashar a cikin na'urar kula da API

Bayani

Switches the site's active theme and returns the whole theme list. Activating a theme changes what every visitor sees immediately, so the client confirms first. Refused `422` when the package type does not carry `wp_themes`, or when WordPress is not installed. `404` for a site with no vendor hosting package. Requires `sites.view` and `sites.panel_access`.

Sigogi

SunaNau'iAna buƙataAbin da yake
siteId (path)UuidEhSite ID (UUIDv7).
themeName (path)stringEhThe theme's slug, exactly as `listSiteWordPressThemes` reports it. WordPress's identifier, not ours — percent-encode it.

Jikin buƙata

SunaNau'iAna buƙataAbin da yake
activebooleanEhWhether the theme should be the site's active theme.

Martani

SunaNau'iAna buƙataAbin da yake
dataSiteWordPressTheme[]EhThe installed themes.

Kuskuren da wannan matsaya za ta iya maido wa

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