hosting
PUT /v1/sites/{siteId}/wordpress/settings
Set one WordPress option on a site.
Πισtoποίηση
Στείλτε ένα κλειδί API ως διακριτικό φορέα (bearer token). Το κλειδί πρέπει να διαθέτει το δικαίωμα sites.view· ένα κλειδί που δεν το διαθέτει απορρίπτεται με 403, όχι 404.
Αυτό το τελικό σημείο δεν δέχεται αναγνωριστικό οργανισμού. Το κλειδί σας προσδιορίζει ήδη τον οργανισμό στον οποίο ανήκει, και η απάντηση περιορίζεται σε αυτόν.
Δοκιμάστε το
Ατικatastήstε ό,τι βρίskεtai μέσα σe γώniaδeς μe τis δikές sas timές, kai to placeholder klεidioύ μe éna klεidi apó ton pinaka ελέgchou sas.
curl -X PUT https://api.zinndigital.com/v1/sites/{siteId}/wordpress/settings \
-H "Authorization: Bearer zdk_live_…" \
-H "Content-Type: application/json" \
-d '{ "option": <string>, "value": <string> }'Συνδεθήκατε; Η κονσόλα API στον πίνακα ελέγχου σας συμπληρώνει το πραγματικό αναγνωριστικό του οργανισμού σας και το δικό σας κλειδί, και εκτελεί το αίτημα στο ζωντανό API, ώστε να μπορείτε να δείτε την πραγματική απόκριση. Ανοίξτε αυτό το τελικό σημείο στην κονσόλα API
Λεπτομέρειες
Writes a single option and returns the whole option map. The option is named in the **body** rather than the path: unlike a plugin slug it is not a resource, and this platform writes one option per call, so one write endpoint is the honest shape. ⛔ An option the vendor does not publish is refused `422` rather than written blindly — writing an unknown key into a live WordPress is how a site gets a setting nothing can read back and nothing can undo. `404` for a site with no vendor hosting package. Requires `sites.view` and `sites.panel_access`.
Παράμετροι
| Όνομα | Τύpος | Υποχρεωτικό | Τι είναι |
|---|---|---|---|
siteId (path) | Uuid | Ναι | Site ID (UUIDv7). |
Σώμα αίτησης
| Όνομα | Τύpος | Υποχρεωτικό | Τι είναι |
|---|---|---|---|
option | string | Ναι | The option name, as `getSiteWordPressSettings` reports it. An option the vendor does not publish is refused. |
value | string | Ναι | The new value. May be empty — clearing a tagline is a legitimate edit, not a mistake to guess at. |
Απάντηση
| Όνομα | Τύpος | Υποχρεωτικό | Τι είναι |
|---|---|---|---|
data | object | Ναι | The options, keyed by name. |
Σφάλματα που μπορεί να επιστρέψει αυτό το τελικό σημείο
401 · 403 · 404 · 409 · 422 · 429 · 503