Skip to main content
Glama

refresh_collection_cache

Flushes Directus server cache after schema changes so new collections or fields become visible, then optionally checks that a specified collection is readable.

Instructions

Flushes the Directus server cache so recent schema changes become visible, then optionally verifies that one collection is readable. Use it after create_collection, create_field or apply_schema when a collection or field is reported as missing; validate_collection_creation answers the narrower question of whether a new collection is ready. Mutating but not destructive: it discards cached data, never stored data, though the next requests are slower while the cache refills. Needs a token allowed to flush the cache, and it affects every client of the instance, not just this session.

Tool call template

This tool declares no required parameters. Add optional parameters from the input schema as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {},
    "name": "refresh_collection_cache"
  }
}

Input Schema

NameRequiredDescriptionDefault
collectionNoSpecific collection to verify after refresh

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv12.3.3

TDQS

A4.9/5.0
Behavior5/5

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

Goes well beyond the annotations: it explains that cached data is discarded but stored data is not, that subsequent requests are slower while the cache refills, that a token permitted to flush the cache is required, and that the effect is instance-wide rather than session-scoped. These are precisely the side effects and authorization constraints an agent cannot infer from readOnlyHint=false / destructiveHint=false.

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 sentences, front-loaded with the core action, then usage routing, then side effects and auth. Every sentence carries distinct information with no restatement of the tool name or filler.

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

Completeness5/5

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

For a single-optional-parameter cache-flush tool with no output schema, the description covers action, trigger conditions, alternatives, side effects, authorization, and blast radius. Nothing an agent needs in order to decide to call it or to call it correctly is missing.

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

Parameters4/5

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

Schema coverage is 100% and the single parameter is documented as 'Specific collection to verify after refresh'. The description adds the meaning that verification is optional and tied to readability of exactly one collection, which clarifies the parameter's role beyond the schema wording, though it does not describe format or error behavior for the value.

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?

States a specific verb and resource ('flushes the Directus server cache') plus the immediate purpose ('so recent schema changes become visible') and the optional verification step. It explicitly contrasts itself with validate_collection_creation, so an agent can distinguish it from the schema-validation siblings without opening any schema.

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

Usage Guidelines5/5

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

Gives concrete triggering conditions: after create_collection, create_field or apply_schema, and when a collection or field is reported as missing. It also names the alternative (validate_collection_creation) and the narrower question that tool answers, which is exactly the routing information an agent needs.

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