Skip to main content
Glama

Restore Document From Trash

restore_document
Idempotent

Restore a trashed document back into the Scrivener binder, optionally into a specific target folder.

Instructions

Restore a trashed document back into the binder, optionally into a specific target folder (otherwise it returns to a default location). Use list_trash to find the document id first. This is the inverse of delete_document. Requires an open project and a valid document id.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
forceNoWrite even if the project appears open in Scrivener. Default false, which refuses the write to protect against your changes being overwritten by Scrivener on save.
documentIdYesScrivener document UUID, as returned by get_structure (a binder item "id").
targetFolderIdNoOptional id of the folder to restore into. Omit to restore to a default location.
Behavior4/5

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

Annotations already provide idempotentHint true, destructiveHint false, and readOnlyHint false. The description adds context: it requires an open project, uses list_trash as prerequisite, and describes the optional folder behavior. It does not contradict annotations and adds meaningful behavioral information beyond the structured fields.

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 concise sentences, each contributing distinct value: purpose and option, prerequisite, and relationship to sibling tool. No wasted words, front-loaded with the core action. This is an excellent example of brevity with substance.

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 tool's moderate complexity (restoration with optional folder, prerequisites), and full schema coverage with no output schema, the description covers the essential points: what it does, how to get the required ID, and the required project state. It does not delve into error cases or edge cases, but this is acceptable for typical usage.

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 100%, so baseline is 3. The description adds context for documentId ('use list_trash to find') and targetFolderId ('optionally into a specific target folder'), but does not add extra meaning beyond the schema's descriptions for force or other parameters. This is adequate but not exceptional.

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 clearly states the verb 'Restore', the resource 'trashed document', and the context 'back into the binder, optionally into a specific target folder'. It also explicitly positions itself as the inverse of delete_document, distinguishing it from sibling tools like delete_document or move_document.

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 provides explicit guidance: 'Use list_trash to find the document id first' and 'Requires an open project and a valid document id'. It also states the optional nature of targetFolderId. While it does not list when not to use or alternative tools, the context is clear enough for an agent to decide.

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/writerslogic/scrivener-mcp'

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