30 days free. No credit card. Full access from the moment you connect your site.

Start free trial

Purge Generated CSS And JS

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

Abilitylitespeed/purge-optimization-cache
ToolsetLiteSpeed Cache — toolset/litespeed
GroupLiteSpeed Cache › CSS, JS & HTML
RequiresLiteSpeed Cache, active on the site
Capabilitymanage_options
SafetyWrites data
RepeatableIdempotent — running it twice leaves the same result
Ships inAcrossAI 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

NameTypeWhat it is
purgedbooleanWhether the artefacts were purged.
successbooleanWhether the call completed.
messagestringA one-line summary of what happened, suitable for showing a human.
error_codestringPresent 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 the plugins:
AcrossAI Abilities Manager · AcrossAI MCP Manager

Browse the rest: Every ability, by category


Keep reading