Skip to main content
Glama

clear_snapshot

Remove cached browser snapshots to resolve stale data issues in Firefox automation workflows.

Instructions

Clear snapshot cache. Usually not needed.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Implementation Reference

  • Primary MCP tool handler for 'clear_snapshot'. Acquires Firefox instance via getFirefox and calls its clearSnapshot method, returning a success response.
    export async function handleClearSnapshot(_args: unknown): Promise<McpToolResponse> {
      try {
        const { getFirefox } = await import('../index.js');
        const firefox = await getFirefox();
    
        firefox.clearSnapshot();
    
        return successResponse('🧹 Snapshot cleared');
      } catch (error) {
        return errorResponse(error as Error);
      }
    }
  • Tool schema definition including name 'clear_snapshot', description, and empty input schema.
    export const clearSnapshotTool = {
      name: 'clear_snapshot',
      description: 'Clear snapshot cache. Usually not needed.',
      inputSchema: {
        type: 'object',
        properties: {},
      },
    };
  • src/index.ts:128-128 (registration)
    Registration of the clear_snapshot tool handler in the central toolHandlers Map.
    ['clear_snapshot', tools.handleClearSnapshot],
  • src/index.ts:172-172 (registration)
    Inclusion of clearSnapshotTool in the allTools array for MCP tool listing.
    tools.clearSnapshotTool,
  • FirefoxClient.clearSnapshot() method invoked by the tool handler, which delegates to the SnapshotManager.clear().
    clearSnapshot(): void {
      if (!this.snapshot) {
        throw new Error('Not connected');
      }
      this.snapshot.clear();
    }
Behavior2/5

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

With no annotations provided, the description carries full burden for behavioral disclosure. 'Clear snapshot cache' implies a destructive operation (clearing/deleting), but it doesn't specify whether this is reversible, what permissions are required, or what side effects might occur. The 'Usually not needed' hint adds some caution but lacks concrete behavioral details.

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?

The description is extremely concise with two short sentences: 'Clear snapshot cache. Usually not needed.' Every word earns its place, and it's front-loaded with the core purpose. However, the brevity comes at the cost of completeness, making it somewhat under-specified rather than optimally concise.

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

Completeness2/5

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

Given the tool's apparent destructive nature (clearing cache) with no annotations and no output schema, the description is inadequate. It doesn't explain what 'snapshot cache' means in this system, what gets cleared, whether the operation is safe or has side effects, or what confirmation/response to expect. For a potentially destructive operation, more context is needed.

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?

The tool has 0 parameters with 100% schema description coverage, so no parameter documentation is needed. The description doesn't add parameter semantics beyond the schema, but since there are no parameters, this is appropriate. Baseline 4 applies for zero-parameter tools.

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

Purpose3/5

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

The description states the tool 'Clear snapshot cache', which is a specific verb+resource combination, but it's vague about what 'snapshot cache' refers to in this context. It doesn't clearly distinguish from sibling tools like 'take_snapshot', leaving ambiguity about the relationship between creating and clearing snapshots.

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

Usage Guidelines2/5

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

The description provides minimal guidance with 'Usually not needed', which suggests infrequent use but doesn't specify when it should be used versus alternatives. No explicit when/when-not scenarios or prerequisites are mentioned, leaving the agent without clear operational context.

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/mozilla/firefox-devtools-mcp'

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