wp-abilities-api

Installation
Summary

WordPress Abilities API registration, REST exposure, and client-side consumption for WordPress 6.9+.

  • Register abilities and categories in PHP using wp_register_ability() and wp_register_ability_category() with stable IDs, labels, and metadata
  • Expose abilities to clients via the /wp-json/wp-abilities/v1/ REST endpoints by setting meta.show_in_rest: true
  • Consume abilities in JavaScript using the @wordpress/abilities package for client-side access and permission checks
  • Requires WordPress 6.9+ (PHP 7.2.24+) and works with WP core, plugins, and themes; some workflows need WP-CLI
SKILL.md

WP Abilities API

When to use

Use this skill when the task involves:

  • registering abilities or ability categories in PHP,
  • exposing abilities to clients via REST (wp-abilities/v1),
  • consuming abilities in JS (notably @wordpress/abilities),
  • diagnosing “ability doesn’t show up” / “client can’t see ability” / “REST returns empty”.

Inputs required

  • Repo root (run wp-project-triage first if you haven’t).
  • Target WordPress version(s) and whether this is WP core or a plugin/theme.
  • Where the change should live (plugin vs theme vs mu-plugin).

Procedure

Related skills

More from wordpress/agent-skills

Installs
1.0K
GitHub Stars
1.5K
First Seen
Feb 1, 2026