litespeed/purge-optimization-cache purges only the generated CSS and JS artefacts and leaves the page cache intact.
It is the right call after a theme or plugin update changes a stylesheet.
At a glance
| Ability | litespeed/purge-optimization-cache |
| Toolset | LiteSpeed Cache — toolset/litespeed |
| Group | LiteSpeed Cache › CSS, JS & HTML |
| Requires | LiteSpeed Cache, active on the site |
| Capability | manage_options |
| Safety | Writes data |
| Repeatable | Idempotent — running it twice leaves the same result |
| Ships in | AcrossAI Abilities Manager 0.0.34 and later |
How it works
The generated assets and the page cache are separate stores with separate reasons to go stale. A theme update changes the source CSS, which makes the combined file wrong and the cached pages fine — they reference the asset by name and will pick up the new one.
A full purge would throw away both, which means every page on the site rebuilds to fix a problem that was only in the asset directory. On a large site that is a significant amount of wasted server work at exactly the moment somebody is deploying.
This is also the call after changing any optimisation setting. The settings change what the generated assets should contain, and the existing ones were built under the old rules — they do not regenerate on their own.
Regeneration is lazy: the first visitor after the purge triggers the rebuild. Check litespeed/get-optimization-status afterwards to confirm it happened.
Input
This ability takes no input.
What comes back
| Name | Type | What it is |
|---|---|---|
purged | boolean | Whether the artefacts were purged. |
success | boolean | Whether the call completed. |
message | string | A one-line summary of what happened, suitable for showing a human. |
error_code | string | Present only on failure — a stable machine-readable reason, such as a missing field, a wrong field type or an unmet confirmation. |
Example
Ask your assistant:
We just updated the theme — clear the generated CSS.
It resolves to one call:
{
"ability": "litespeed/purge-optimization-cache",
"parameters": {}
}Worth knowing
- Leaves the page cache alone, which is the point.
- Required after any optimisation settings change.
- Regeneration is lazy — the first visitor pays for it.
- Idempotent.
Related abilities
- Get Optimisation Status — confirm regeneration happened
- Purge Cache — when the pages are stale too
Get the plugins:
AcrossAI Abilities Manager · AcrossAI MCP Manager
Browse the rest: Every ability, by category