Skip to main content
Glama

Restore head to a previous state

websiteSourceCode_head_restore
Destructive

Copies an earlier version or published into a new head without publishing or rewriting history. Takes the edit lease when no leaseToken is sent.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "websiteId": "<websiteId>",
      "to": "<to>"
    },
    "name": "websiteSourceCode_head_restore"
  }
}

Input Schema

NameRequiredDescriptionDefault
toYesState to restore to head: a source version number or `published`.
websiteIdYes
leaseTokenNoOmit to have Cactal take the edit lease for you; pass a token from websiteSourceCode.lease.acquire to take over from another editor.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A3.7/5.0
Behavior4/5

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

The description adds behavioral context beyond the annotations: it explicitly says the call will not publish or rewrite history, and that it takes the edit lease when no `leaseToken` is sent — a real side effect not visible elsewhere. It does not disclose what happens to the current head content, which is relevant given destructiveHint=true.

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?

Two compact sentences with no filler; the core effect is front-loaded and the lease behavior follows immediately.

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

Completeness3/5

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

For a destructive, state-changing tool with no output schema, the description omits what happens to the existing head/working state and what a caller should expect back. It does cover the key non-publishing semantics and the lease acquisition behavior, so it is serviceable but incomplete.

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?

At 67% schema coverage, the `to` and `leaseToken` semantics are already documented in the schema, and the description only restates the lease behavior. `websiteId` remains undescribed in both places. Baseline 3 is appropriate since the schema does most of the work.

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?

It states a concrete verb and resource: copies an earlier version or `published` into a new head. The 'without publishing or rewriting history' clause also distinguishes it from siblings such as websiteSourceCode_head_publish and websiteSourceCode_published_rollback, though those siblings are not named explicitly.

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?

Usage is only implied: the reader infers that this is the right tool when you want to move head back without publishing. There is no explicit 'use this when…' guidance, no exclusions, and no naming of alternatives such as published_rollback or head_check.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources