Skip to main content
Glama

archive_document

Archive documents in Outline wiki to remove them from active view while preserving content for future reference or compliance needs.

Instructions

Archive a document.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
documentIdYes

Implementation Reference

  • Handler function that archives a document by calling the Outline API's /documents.archive endpoint.
    async archive_document(args: ArchiveDocumentInput) { checkAccess(config, 'archive_document'); const { data } = await apiCall(() => apiClient.post<OutlineDocument>('/documents.archive', { id: args.documentId }) ); return { id: data.id, title: data.title, archivedAt: data.archivedAt, message: MESSAGES.DOCUMENT_ARCHIVED }; },
  • Zod input schema for the archive_document tool, requiring a documentId.
    export const archiveDocumentSchema = z.object({ documentId });
  • src/lib/tools.ts:92-96 (registration)
    Registration of the archive_document tool definition, including name, description, and schema reference.
    createTool( 'archive_document', 'Archive a document.', 'archive_document' ),
  • Mapping of archive_document tool name to its schema in the toolSchemas object.
    archive_document: archiveDocumentSchema,
  • Handler registration: spreading document handlers (including archive_document) into the main ToolHandlers object.
    ...createSmartHandlers(ctx), } as ToolHandlers;

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-wiki-mcp'

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