Skip to main content
Glama

export_document

Export Outline wiki documents as Markdown files for backup, sharing, or migration purposes.

Instructions

Export document in Markdown format.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
documentIdYes

Implementation Reference

  • The core handler function for the 'export_document' tool. It receives ExportDocumentInput containing the documentId, makes an API call to Outline's '/documents.export' endpoint, and returns the exported document content (Markdown format).
    async export_document(args: ExportDocumentInput) { const { data } = await apiCall(() => apiClient.post<string>('/documents.export', { id: args.documentId }) ); return data; },
  • Zod schema defining the input for export_document tool: requires a 'documentId' string.
    export const exportDocumentSchema = z.object({ documentId });
  • TypeScript type inferred from the exportDocumentSchema for type safety in handlers.
    export type ExportDocumentInput = z.infer<typeof exportDocumentSchema>;
  • src/lib/tools.ts:68-73 (registration)
    Registers the 'export_document' tool definition, including name, description, and references the Zod schema converted to JSON Schema for MCP protocol.
    createTool( 'export_document', 'Export document in Markdown format.', 'export_document' ),
  • Maps the tool name 'export_document' to its schema in the central toolSchemas object used across the application.
    export_document: exportDocumentSchema,

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