wp-abilities-api

Register WordPress Abilities API components and expose them via REST endpoints.

3|Updated Feb 21, 2026
One-click install
npx skills add https://github.com/ihatesea69/HieuNghi-AI-Skills --skill wp-abilities-api-ihatesea69
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: wp-abilities-api
Source: https://github.com/ihatesea69/HieuNghi-AI-Skills/tree/main/wordpress_skills/wp-abilities-api
Command: npx skills add https://github.com/ihatesea69/HieuNghi-AI-Skills --skill wp-abilities-api-ihatesea69

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

This Skill streamlines the process of working with the WordPress Abilities API, ensuring that abilities and their categories are correctly registered, exposed via the REST API, and accessible to clients. It helps debug issues where abilities are not showing up or are inaccessible.

Core Features & Use Cases

  • Ability Registration: Define and register custom abilities and categories in PHP.
  • REST API Exposure: Configure abilities to be visible through the /wp-json/wp-abilities/v1/ endpoints.
  • Client-Side Consumption: Integrate with @wordpress/abilities for frontend checks and logic.
  • Debugging: Diagnose and resolve "ability not found" or "client can't see ability" issues.
  • Use Case: When developing a new feature that requires granular user permissions, you can use this skill to register a new ability like 'edit_custom_post_type' and ensure it's available to the frontend JavaScript for conditional UI rendering.

Quick Start

Use the wp-abilities-api skill to register a new ability category named 'my-plugin' with the label 'My Plugin'.

Frequently Asked Questions about wp-abilities-api

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I register custom WordPress abilities and permissions in PHP?

Register custom WordPress abilities by defining specific abilities and categories using PHP. This ensures granular user permissions are correctly configured before exposure via the REST API or client-side JavaScript consumption.

How do I expose WordPress abilities through the REST API?

Expose WordPress abilities through the REST API by configuring them to be visible at the `/wp-json/wp-abilities/v1/` endpoints. This allows registered permissions to be accessible for client-side checks and frontend logic integration.

Can I use the WordPress Abilities API with client-side JavaScript?

Yes, you can integrate the WordPress Abilities API with client-side JavaScript using the `@wordpress/abilities` package. This enables frontend permission checks and conditional UI rendering based on registered user abilities.

Why are my custom WordPress abilities not showing up in the REST API?

Custom WordPress abilities may not show up in the REST API if they are not correctly registered in PHP or configured for endpoint visibility. Diagnose the registration logic and ensure proper exposure at the `/wp-json/wp-abilities/v1/` endpoints.

Does the WordPress Abilities API require a specific WordPress version?

The WordPress Abilities API targets WordPress 6.9+ for core integration. It also provides support for plugin and theme implementations, as well as WP-CLI workflows for managing ability registration and exposure.