wp-abilities-verify
Skill0 starsChanged 15 days agoMITView on GitHub
Verify a WordPress plugin's Abilities API registrations: enumerate abilities, check that callback behavior matches each annotation's claim (the adversarial readonly-but-writes detection), validate permissions and schemas, and validate audit documents produced by wp-abilities-audit.
1 other project uses a version of this; 1 new project in the last 4 weeks, against 0 the 4 before.
Adopted by
Surging: 1 new project took it in the last 4 weeks, none the 4 weeks before.thin data
Most recently taken up by
- WordPress/agent-skillsword for word, first seen Dec 23, 2025
Other versions1 project uses a version of this.
Word for word · 1
- WordPress/agent-skills★ 2.3k100% same
Edited · 0
None found.
Wrote their own version · 0
None found.
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
In this repository16 other files it gives its agents.
- AGENTS.mdAGENTS.md
- .cursor/AGENTS.mdAGENTS.md
- docs/AGENTS.mdAGENTS.md
- CLAUDE.mdCLAUDE.md
- llms.txtllms.txt
- site/llms.txtllms.txt
- wordpress-routerSkill
- wp-abilities-apiSkill
- wp-abilities-auditSkill
- wp-block-developmentSkill
- wp-block-themesSkill
- wp-patternsSkill
- wp-plugin-developmentSkill
- wp-project-triageSkill
- wp-rest-apiSkill
- wp-wpcli-and-opsSkill
The file
We split this skill into the rules it gives an agent
9 rules. About 0 are common, 2 are distinctive, and 7 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈2
Distinctive · estimate
This author's own choices. Worth a look.
7
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Very specific: line 9
Verify a WordPress plugin's Abilities API registrations.
- Distinctive: line 23
After abilities have been registered in a plugin but before a PR lands.
- Very specific: line 74
Read references/audit-schema-validation.md.
- Very specific: line 83
Read references/static-enumeration.md.
- Very specific: line 92
Read references/runtime-harness.md.
- Very specific: line 100
Read references/annotation-correctness.md.
- Very specific: line 123
Read references/permission-roundtrip.md.
- Very specific: line 133
Read references/schema-lints.md.
- Distinctive: line 179
Every ability is OK, WARN, or FAIL.
≈ “Common” is an estimate: at least 1 in 5 of the 350,495 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
WP Abilities Verify
Verify a WordPress plugin's Abilities API registrations. The
centerpiece is the adversarial annotation correctness check: a
readonly: true ability that actually writes (via $wpdb->update,
update_option, a non-GET delegate, etc.) is a security and UX
disaster because agents plan actions on the basis of the annotations
they introspect. This skill catches those lies by reading the callback
body and comparing what it does against what the annotation claims.
The skill also validates audit docs produced by wp-abilities-audit,
checks permission gates and schema hygiene, and optionally executes
each ability against a live environment.
When to use
- After abilities have been registered in a plugin but before a PR lands.
- As a health-check on an already-shipped plugin (catch regressions where a refactor turned a readonly ability into a writing one).
- To validate an audit document before handing it to an implementer.
Two modes
- Static mode — runs from the plugin checkout. No env. Enumerates via source inspection, runs the adversarial correctness check, runs schema and permission lints, and validates audit docs.
- Runtime mode — requires a running env. Does everything static
does PLUS:
wp_get_abilities()for authoritative enumeration, executes each ability with curated inputs, confirms permission roundtrip against real users, and runs a twin-invocation heuristic onidempotent: trueabilities to flag candidates for review (return-value equality is a signal, not a verdict — core defines idempotent as "no additional effect on the environment").
Both modes produce the same structured report format.
A static-mode PASS means "no obvious-shape violations," not "verified
write-free." For high-stakes plugins, run runtime mode before landing
— it catches bootstrap-order, permission-roundtrip, and idempotency
issues that static can't. See references/annotation-correctness.md
for the static blind spots.
Inputs required
- Plugin checkout path — working tree to verify.
- Mode —
staticorruntime. Default to static if unspecified. - (Runtime only) Env-up command — read the plugin's
AGENTS.md. Common patterns:npm run wp-env start,npx wp-env start, or a composer-based bring-up. Plugin families with their own dev tooling will document their own command. Do NOT assumenpm run wp-envworks. - (Optional) Audit doc path — enables cross-checks between the audit and the registered abilities, and validates the audit itself.
- Report output path — explicit path, typically the user's vault.
Prerequisites
wp-project-triagehas been run on the plugin.- The plugin has at least one registered ability in source. Zero hits
on
wp_register_ability(→ return a clear "no abilities registered" report, not an empty PASS.
Procedure
1. (If audit provided) Validate the audit doc
Read references/audit-schema-validation.md. Validate the audit
against the canonical schema owned by wp-abilities-audit. Surface
missing required fields, multiple reference_ability: true, and
backing: null entries that aren't paired with a surfaced_gaps
entry. backing: null alone is WARN (intentional gap output), not
FAIL.
2. Enumerate abilities statically
Read references/static-enumeration.md. Find each
wp_register_ability( call, extract the name, the annotation block,
and the execute-callback location. Use a multi-line tool (rg
--multiline --pcre2) — the canonical formatting splits the call
across lines. Record each ability's source-file + line + annotations +
callback byte range.
3. (Runtime only) Enumerate via REST + wp-cli
Read references/runtime-harness.md. Bring the env up using the
command from AGENTS.md, then enumerate via wp_get_abilities() over
wp-cli and cross-check against the static inventory. Source-only →
FAIL (registration not firing). Runtime-only → WARN (dynamic
registration path).
4. Annotation correctness (the adversarial core)
Read references/annotation-correctness.md. Read each callback body
and verify it matches the annotation claim:
readonly: true→ callback must not write to the database, the options table, post / user / term / comment data, the filesystem, cron, or via non-GET HTTP / REST delegates.destructive: false→ callback must not delete, refund, void, cancel, or trash.idempotent: true→ repeated calls with the same input have no additional effect on the environment (per theidempotentannotation's docblock inclass-wp-ability.php). Static catches counter writes and per-call cron schedules; runtime adds a twin-invocation heuristic for visible state changes.
The reference lists common write patterns as a starting set, not a checklist — plugin vocabularies vary, and the agent extends with verbs specific to the plugin under verification.
False positives get suppressed via an inline // verify-ignore:
<annotation> -- <reason> comment.
5. Permission roundtrip
Read references/permission-roundtrip.md. Static: classify each
permission_callback against the six shapes (preferred Shape A
current_user_can(...); FAIL on Shape B-bad WP_REST_Request
patterns or Shape E literal true). Runtime: anon and subscriber
denied; admin allowed (unless deliberately public). When an audit was
provided, cross-check the registered cap against the audit's declared
gate.
6. Schema lints
Read references/schema-lints.md. Six small principles applied to
each ability's input_schema: object schemas declare
additionalProperties; required fields have descriptions; enums
non-empty; no $ref; defaults are statically constant (including
(object) array()); reference abilities have no required inputs.
Cross-reference ../wp-abilities-api/references/input-schema-gotchas.md
for the four runtime gotchas (defaults not injected on the
property-level path, pagination key drift, empty() on string IDs,
direct vs indirect invocation strictness).
7. Error-code vocabulary
Cross-reference ../wp-abilities-api/references/error-code-vocabulary.md.
Inspect each callback's WP_Error returns; non-vocabulary codes →
WARN.
Verification
The run produces a structured markdown report at the user-specified path:
---
Last updated: <YYYY-MM-DD HH:MM>
---
# <Plugin> Abilities Verification — <Static|Runtime> Mode
## Status: <PASS|WARN|FAIL>
## Audit doc validation (if provided)
## Static inventory
## Annotation correctness
| Ability | Claim | Result | Evidence |
|---|---|---|---|
## Permission gates
## Schema lints
## Error-code vocabularyEvery ability is OK, WARN, or FAIL. A single FAIL → top-line FAIL; WARNs without FAILs → WARN; otherwise PASS.
Failure modes / debugging
- Env not reachable (runtime) — env-up failed or Docker isn't
running. Re-run
wp-project-triage, then fix the env. Don't fall back silently to static without noting it in the report. - No abilities in source — return a clear "nothing to verify" report.
- Audit schema mismatch — point at
references/audit-schema-validation.md; don't auto-fix the audit. - False positive on readonly-writes — see the
// verify-ignoremechanism inreferences/annotation-correctness.md. Document why each suppression is legitimate. - Runtime enumeration smaller than static — registration hook isn't firing. Check init hook timing, activation state, autoloader order.
Escalation
- Recurring legitimate pattern that trips the adversarial check across
multiple plugins → propose adding it to the suppression guidance in
annotation-correctness.md. Don't broaden the candidate-pattern list speculatively. - Audit-schema validator rejects a legitimate audit → the canonical
schema in
../wp-abilities-audit/references/audit-schema.mdhas evolved. Updatereferences/audit-schema-validation.mdto match.
Out of scope
Token-budget measurement is a separate verification axis — an
annotation-clean, schema-clean, runtime-passing ability set can still
be unshippable if its tools/list form burns through an agent's
context budget. That axis is tracked separately. Do not aggregate
manual or external measurement into this skill's PASS / FAIL verdict.
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

