Skip to main content
Glama
huiseo

Outline Wiki MCP Server

by huiseo

unarchive_document

Restore archived documents in Outline wiki by providing the document ID to make them accessible again for editing and viewing.

Instructions

Restore an archived document.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
documentIdYes

Implementation Reference

  • The core handler function for the unarchive_document tool. It performs access check and calls the Outline API /documents.unarchive endpoint with the document ID.
    async unarchive_document(args: UnarchiveDocumentInput) {
      checkAccess(config, 'unarchive_document');
      const { data } = await apiCall(() =>
        apiClient.post<OutlineDocument>('/documents.unarchive', { id: args.documentId })
      );
      return { id: data.id, title: data.title, message: MESSAGES.DOCUMENT_UNARCHIVED };
    },
  • Zod schema defining the input for unarchive_document: requires a valid documentId string.
    export const unarchiveDocumentSchema = z.object({ documentId });
  • Registers the unarchive_document tool in the allTools array, providing name, description, and linking to its Zod schema for MCP tool definition.
    createTool(
      'unarchive_document',
      'Restore an archived document.',
      'unarchive_document'
    ),
  • Maps the tool name 'unarchive_document' to its schema in the central toolSchemas object used by tool definitions.
    unarchive_document: unarchiveDocumentSchema,
  • Includes the document handlers (containing unarchive_document) into the complete set of tool handlers.
    ...createDocumentHandlers(ctx),
Behavior2/5

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

No annotations are provided, so the description carries the full burden of behavioral disclosure. 'Restore' implies a mutation operation, but the description doesn't specify permissions required, whether the action is reversible, side effects (e.g., if it affects document visibility or metadata), or error conditions. This leaves significant gaps for a tool that modifies state.

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 a single, clear sentence with no wasted words. It's front-loaded with the core action ('Restore'), making it easy to scan. Every part of the sentence earns its place by conveying essential information without redundancy.

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 complexity (a mutation tool with no annotations and no output schema), the description is incomplete. It doesn't explain what 'restore' entails (e.g., moves from archived to active state), return values, error handling, or dependencies. For a tool that changes document state, more context is needed to ensure correct 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?

The input schema has 1 parameter with 0% description coverage, and the tool description doesn't mention any parameters. Since there's only one parameter and the schema defines it as a required string 'documentId', the baseline is 4 for zero parameters, but the description adds no semantic context (e.g., what format the ID should be or where to find it). This results in a minimal viable score.

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?

The description 'Restore an archived document' clearly states the verb ('restore') and resource ('archived document'), making the purpose immediately understandable. It distinguishes from sibling tools like 'archive_document' (opposite action) and 'restore_document' (likely for trash restoration), though it doesn't explicitly mention these distinctions. The description avoids tautology by not just restating the tool name.

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 no guidance on when to use this tool versus alternatives. It doesn't mention prerequisites (e.g., that the document must be archived first), exclusions (e.g., not for trashed documents), or refer to related tools like 'list_archived_documents' for finding targets or 'restore_document' for a different context. Usage is implied but not explicitly stated.

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/huiseo/outline-smart-mcp'

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