Skip to main content
Glama

restore_version

Idempotent

Restore a Nextcloud file to a previous version by file ID and version ID. The current content is preserved as a new version, preventing data loss.

Instructions

Restore a file to a previous version.

The file's current content is replaced with the content from the specified version. The pre-restore content is preserved as a new version in the history, so no data is lost.

Args: file_id: The numeric Nextcloud file ID. version_id: The version identifier from list_versions (a unix timestamp string, e.g. "1711000000").

Returns: Confirmation message.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
file_idYes
version_idYes

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.7.0

TDQS

A4.5/5.0
Behavior4/5

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

Annotations already declare readOnlyHint=false, idempotentHint=true, and destructiveHint=false. The description adds the critical detail that pre-restore content is preserved as a new version, which explains why destructiveHint=false and reassures the agent about data safety. It also states the return value, aligning with the output schema.

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?

The description is efficiently structured with a one-line purpose, a clear behavioral note, and a concise Args section. Every sentence adds value, and the key information is front-loaded. No redundancy or filler.

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 output schema exists (confirmation message), the description appropriately mentions the return type. It covers purpose, behavior, and parameter semantics thoroughly. Minor gaps like error handling are not necessary given the output schema and annotations. It is complete for an agent to call correctly.

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

Parameters5/5

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

Schema coverage is 0%, so the description carries the full burden for parameter meaning. It provides detailed semantics for both parameters: file_id is a numeric Nextcloud file ID, and version_id is a unix timestamp from list_versions. This goes beyond the schema's simple type definitions and gives actionable guidance.

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 clear verb+resource: 'Restore a file to a previous version.' It then explains the exact mechanism (current content replaced, pre-restore preserved) and distinguishes itself from file operations like restore_trash_item by focusing on version history. The purpose is unambiguous and differentiates from siblings.

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?

It explicitly references list_versions as the source for version_id, establishing a clear prerequisite and cross-tool workflow. It does not explicitly state when not to use the tool or name alternatives, but the context is clear enough for an agent to infer the correct usage pattern.

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

Deploy Server

Other Tools