Skip to main content
Glama

cache_invalidate

Invalidate a cached entry when its source changes, and optionally cascade removal to all derived entries to prevent stale copies.

Instructions

Delete a cache entry, e.g. because the underlying source it was based on changed. With cascade:true, also deletes every entry that declared this one as a derived_from parent, and recursively theirs — dependency-graph invalidation instead of a manual hunt for stale copies.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
idYes
cascadeNoAlso delete entries derived from this one, default false

Schema Changelog

Changes observed during successful MCP inspections. Dates show when Glama detected each change.

  1. First observedv0.1.1

TDQS

A3.9/5.0
Behavior4/5

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

With no annotations provided at all, the description carries the full burden of behavioral disclosure. It does well: it reveals the destructive nature ('Delete'), the cascade semantics ('every entry that declared this one as a derived_from parent'), and recursion behavior. It does not mention edge cases like missing-id handling or irreversibility, but the core behaviors are transparent.

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

Conciseness4/5

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

Two sentences with no filler; the core action is front-loaded and the cascade nuance follows. The second sentence is semantically dense with nested clauses but earns its length by explaining recursive behavior and the rationale. Slightly compressed structure, but every part adds value.

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?

For a destructive 2-parameter tool with no annotations and no output schema, the description covers the main essentials: purpose, trigger scenario, and the cascade option's full behavior. Missing details are limited to edge-case behavior (nonexistent id, error handling, reversibility), which are conventional for cache invalidation and not severe gaps for an agent to proceed.

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 coverage is only 50%: the cascade parameter has a schema description but id does not. The description enriches the cascade semantics well (derived_from parent, recursive invalidation), adding meaning beyond the schema's 'Also delete entries derived from this one'. However, id receives no additional semantic context, and the description doesn't fully compensate for the missing id doc, though the parameter is fairly self-explanatory.

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

Purpose4/5

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

The description clearly states the action ('Delete a cache entry') and the specific resource, with a concrete motivating example ('underlying source it was based on changed'). It is clearly distinct from sibling cache_get/cache_set operations by virtue of being a deletion, though it does not explicitly name and differentiate from sibling tools.

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

Usage Guidelines4/5

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

The description gives a clear when-to-use scenario: invalidate when the underlying source changed. It also explains the key decision between cascading and non-cascading deletion ('dependency-graph invalidation instead of a manual hunt for stale copies'). It lacks explicit exclusions or named alternatives, but the context is sufficiently clear.

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

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/kskurtveit/echocache'

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