royal-mcp__wp_update_custom_css
Update the active theme's custom CSS (the whole stylesheet). CSS is filtered through wp_kses (script tags stripped). Requires the "Allow AI to modify theme appearance" admin toggle and unfiltered_html capability. dry_run true returns allowed, the refusal reason, current_sha256 and byte counts, changing nothing. expected_sha256 (sha256 of the CSS you read) refuses with expected_mismatch when the CSS changed since. Refusal codes: insufficient_caps, unfiltered_html_required, theme_writes_off, expected_mismatch, field_dropped (the CSS is put back). When the prior CSS is over the 1 MB undo limit the reply says undo_available false, undo_reason snapshot_too_large. (site: demo.royalplugins.com) Through Royally: waits for a person to approve it in Royally; nothing on the site changes until then.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| css | Yes | ||
| dry_run | No | true previews (default false). | |
| site_id | No | Site to run this tool on: 8ef2e52b-bd07-4671-a363-ebe8b480b65c (https://demo.royalplugins.com) | |
| theme_slug | No | Theme slug (defaults to active theme) | |
| expected_sha256 | No | sha256 (hex) of the current CSS as you read it. |