WordPress Abilities API — реализация и тесты

★ 6.9 · web-development

WordPress API Expertise is a Claude Code skill that codifies the conventions for implementing WordPress Abilities: registering them via `wp_register_ability()`, building classes that implement `AbilitiesInterface`, exposing abilities to the REST API and MCP, and writing unit and integration tests. Reach for it when adding a new ability to a WP Rocket-based plugin, when you're unsure how to place an ability class next to its feature and wire it through a `ServiceProvider`, or when you need to write tests that cover both the happy path and the no-permission scenario. The skill provides exact function signatures for `wp_register_ability()` and `wp_register_ability_category()`, a version-compatibility guard for pre-6.9 WordPress, the `vendor/ability-name` naming convention, `check_permissions()` patterns using `current_user_can()`, meta annotation keys (readonly, destructive, idempotent), input/output schema rules for `execute()`, and pointers to reference files inside the WP Rocket repository. The direction is building new abilities, not debugging general-purpose REST endpoints or configuring the broader WordPress Capabilities API for arbitrary plugins. Fits teams targeting WordPress 6.9 and above; not applicable to projects that don't use the Abilities API or that must support older WordPress versions.