Apply a style variation
apply_style_variationApply a style variation from the active theme to your site's global styles. Preview the JSON-path diff first, then confirm to replace or merge customizations, with undo via revisions.
Instructions
Apply one of the active theme's style variations to the site's global styles — what choosing it in Site Editor → Styles does. Without confirm_token it is a dry run showing the JSON-path diff between the current user styles and the result. A full variation replaces the user's global-styles customisations; a colour or typography partial is merged into them. The previous state is kept as a global-styles revision (GET /wp/v2/global-styles/{id}/revisions), which is how to undo.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| kind | No | Disambiguates a title shared by a full variation and a partial. | |
| mode | No | auto: full variations replace the user styles, partials merge into them (Site Editor behaviour). replace: overwrite all user customisations. merge: deep-merge the variation over the current customisations. | auto |
| index | No | Variation index from list_style_variations — an alternative to title. | |
| title | No | Variation title or slug from list_style_variations, e.g. "Evening". | |
| site_id | No | Which configured WordPress site to act on. Optional — with a single site configured it is used automatically; with several, the default site is used unless you name one. Run list_sites for valid ids. | |
| confirm_token | No | Token from this tool's dry-run preview. Omit to preview. |