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

Start free trial

Update Browser Cache Settings

litespeed/update-browser-cache-settings turns browser caching on or off and sets its TTL.

This controls the expiry headers sent to visitors’ browsers for static assets.

At a glance

Abilitylitespeed/update-browser-cache-settings
ToolsetLiteSpeed Cache — toolset/litespeed
GroupLiteSpeed Cache › Object & Browser Cache
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

The cache you cannot purge

Every other cache in this suite is on the server, which means it can be cleared. This one is in the visitor’s browser, and nothing you do can reach it.

That asymmetry is the whole design consideration. A long TTL is excellent for returning visitors and means that a file served with a year-long expiry will be held for a year — by browsers you cannot contact — unless its URL changes.

Which is why the query-string version marker matters, and why removing it in the HTML settings is a decision that interacts with this one. With the marker, a changed file gets a new URL and browsers fetch it; without it, a long browser TTL means stale assets for exactly as long as the TTL.

A year is the standard value for genuinely static assets and a mistake for anything a deployment changes without renaming.

The write is a patch, not a replacement. Send one key and one key changes; everything else in the area is left alone. The response names the keys that actually moved, so a payload that matched the existing values comes back with an empty list rather than a misleading success.

Input

NameTypeRequiredWhat it is
settingsobjectYesA map of setting key to new value. Keys outside this area are refused, and the refusal lists what the area accepts.

What comes back

NameTypeWhat it is
updatedarrayThe keys that actually changed. An empty array means every value you sent was already set.
settingsarrayEvery setting in the area after the write, in the read shape.
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:

Turn on browser caching with a one-year expiry.

It resolves to one call:

{
  "ability": "litespeed/update-browser-cache-settings",
  "parameters": {
    "settings": { "cache-browser": true, "cache-browser_ttl": 31557600 }
  }
}

Worth knowing

  • You cannot purge a browser cache. The TTL is a commitment.
  • Pairs with the query-string setting in the HTML area — together they decide whether updates reach visitors.
  • Long TTLs suit assets whose URLs change when their contents do.
  • Seconds, not days.

Related abilities


Get the plugins:
AcrossAI Abilities Manager · AcrossAI MCP Manager

Browse the rest: Every ability, by category


Keep reading