edit-manage-remote-site
Edit and Manage a Remote Site
Use this skill for any work on one of the user's WordPress.com sites. These sites are live: change them only with wpcom_request, never with WP-CLI, Bash, or local site files. Work on a local copy only when the user asks for one (create a local site with site_create, then site_pull the WordPress.com site into it). Without wpcom_request, tell the user you can't change the live site from here, and offer a local copy that site_push can publish back.
First: Check the Plan
Before any change, call GET / with apiNamespace: "". plan.features.active lists the features this site's plan includes, such as global-styles, custom-design, or install-plugins. A change that needs a feature the list lacks isn't available on this site's plan: say so, and link to https://wordpress.com/pricing, which lists what each plan includes. Inline styles and block style attributes are no way around a missing design feature; they produce invalid blocks on WordPress.com.
Block Content
- Use only core WordPress blocks. No custom HTML blocks except for inline SVGs.
- No decorative HTML comments (e.g.
<!-- Hero Section -->); only block delimiter comments. - Color content from the active theme's palette using block color-slug attributes (e.g.
{"backgroundColor":"primary","textColor":"base"}) rather than hardcoded hex values; introduce a custom color only when the palette genuinely lacks one. - No emojis anywhere in generated content.
Tool Shape
wpcom_request supports both the WordPress REST API and WordPress.com REST API endpoints: