Skip to main content
Glama

Purge old page versions

purge_page_history
Destructive

Purge page history older than a specified cutoff across the wiki. Confirm with a token to permanently delete old versions.

Instructions

Deletes stored page versions older than a cutoff, across the whole wiki. The versions are gone permanently — this is the one maintenance operation that destroys data. Requires a confirmation token.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
older_thanYesISO-8601 duration cutoff, as Wiki.js’ own admin UI offers: P1D (a day), P1M, P3M, P6M, P1Y, P2Y, P3Y. Versions older than this are deleted.
confirm_tokenNoToken from this tool’s previous, unconfirmed call. Omit it to receive one.
Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Even with destructiveHint=true already present in annotations, the description adds critical non-obvious behavior: deletion is permanent ('gone permanently'), it applies wiki-wide, and it requires a confirmation token. This materially raises the caution level for an agent invoking the tool.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Three short sentences, each earning its place: the action comes first, followed by the permanence warning and the invocation prerequisite. There is no filler or repetition of what the schema already provides.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the rich enum schema and the confirm_token description, the definition covers what an agent needs to invoke the tool safely, including the non-reversible nature. It could be more explicit that the first call returns a token for the second call, but the schema already states that, so this is not a serious gap.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 100%, so the baseline applies. The older_than parameter is fully enumerated with ISO-8601 durations, and confirm_token's two-step behavior is documented in the schema. The description repeats 'confirmation token' but adds no extra parameter-level meaning.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description opens with a specific verb, object, and scope: 'Deletes stored page versions older than a cutoff, across the whole wiki.' This goes beyond the title by adding the cutoff and whole-wiki semantics, and it clearly distinguishes the tool from siblings like list_page_history, get_page_version, and restore_page_version.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description implies the maintenance use case ('this is the one maintenance operation that destroys data') and states the confirmation prerequisite, but it does not explicitly say when to choose this tool over alternatives or when not to run it. An agent has to infer the cleanup scenario from the title and first sentence.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/ni-c/wikijs-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server