Skip to main content
Glama
LibreOffice MCP Server

LibreOffice MCP Server

Server Configuration

Describes the environment variables required to run the server.

NameRequiredDescriptionDefault
PYTHONPATHNoPath to the mcp-libre project directory.
LIBREOFFICE_PATHNoOptional path to the LibreOffice executable, for example /usr/bin/libreoffice.

Instructions

Guidance the server publishes about itself, which clients place ahead of the tool catalog so the model reads it before choosing anything.

This server publishes no instructions, or was last inspected before Glama recorded them.

Capabilities

Features and capabilities supported by this server

Protocol revision2025-11-25

CapabilityDetails
tools
{
  "listChanged": false
}
prompts
{
  "listChanged": false
}
resources
{
  "subscribe": false,
  "listChanged": false
}
experimental
{}

Tools

Functions exposed to the LLM to take actions

NameDescription
create_documentB

Create a new LibreOffice document

Args:
    path: Full path where the document should be created
    doc_type: Type of document to create (writer, calc, impress, draw)
    content: Initial content for the document (for writer documents)
read_document_textC

Extract text content from a LibreOffice document

Args:
    path: Path to the document file
_docx_has_ommlA

检测 docx 是否含 OMML 公式(word/document.xml 里查 <m:oMath)。

2026-10-24:LibreOffice 对 OMML 的 run 字号(m:r/w:rPr/w:sz)完全忽略,
公式全部按 Math 组件默认基准字号渲染(LO Bug 32419,多年未修)——
含公式的 docx 用 LO 转 PDF,公式字号/溢出判断全部失真。
含公式 → 路由 Word COM(真渲染);无公式 → LO 照旧(快)。
get_document_infoC

Get detailed information about a LibreOffice document

Args:
    path: Path to the document file
read_spreadsheet_dataA

Read data from a LibreOffice Calc spreadsheet

Args:
    path: Path to the spreadsheet file (.ods, .xlsx, etc.)
    sheet_name: Name of the specific sheet to read (if None, reads first sheet)
    max_rows: Maximum number of rows to read (default 100)
insert_text_at_positionB

Insert text into a LibreOffice Writer document

Args:
    path: Path to the document file
    text: Text to insert
    position: Where to insert the text ("start", "end", or "replace")
read_impress_layoutA

精确读取 PPT(.pptx)每页每个元素的几何布局:坐标/宽高(厘米)、旋转、占位符角色、z 序、组内子元素、文本摘要。

三层 z 序:masters(最底层装饰) < layouts(版式装饰) < 页面 shapes(最顶层)。
重叠/遮挡判断必须三层合并——"标题压住橙色块"这类问题,装饰块在版式/母版上,只看页面形状查不出来。
页面元素几何为 None 表示未显式设置(继承版式占位符位置)。

用于回答"这个元素在页面哪里/多大面积/有没有重叠出界/层级谁压谁"——read_document_text 只给文字流,
位置信息在文本转换时全部丢失。仅支持 .pptx;.ppt/.odp 先用 convert_document 转 pptx 再读。

Args:
    path: PPT 文件路径(.pptx)
    slides: 可选,页码过滤,如 "1" 或 "1,3-5";缺省读全部页
search_documentsC

Search for documents containing specific text

Args:
    query: Text to search for
    search_path: Directory to search in (default: common document locations)
batch_convert_documentsC

Convert multiple documents in a directory to a different format

Args:
    source_dir: Directory containing source documents
    target_dir: Directory where converted documents should be saved
    target_format: Target format for conversion
    source_extensions: List of source file extensions to convert (default: common formats)
merge_text_documentsA

Merge multiple text documents into a single document

Args:
    document_paths: List of paths to documents to merge
    output_path: Path where merged document should be saved
    separator: Text to insert between merged documents
get_document_statisticsC

Get detailed statistics about a document

Args:
    path: Path to the document file
open_document_in_libreofficeA

Open a document in LibreOffice GUI for live viewing

Args:
    path: Path to the document to open
    readonly: Whether to open in read-only mode (default: False)
refresh_document_in_libreofficeB

Send a refresh signal to LibreOffice to reload a document

Args:
    path: Path to the document that should be refreshed
watch_document_changesB

Watch a document for changes and provide live updates

Args:
    path: Path to the document to watch
    duration_seconds: How long to watch for changes (default: 30 seconds)
create_live_editing_sessionC

Create a live editing session with automatic refresh capabilities

Args:
    path: Path to the document for live editing
    auto_refresh: Whether to enable automatic refresh detection

Prompts

Interactive templates invoked by user choice

NameDescription

No prompts

Resources

Contextual data attached and managed by the client

NameDescription
list_documentsList all LibreOffice documents in common locations

TDQS

B3.4/5.0

Scored across 15 tools

Disambiguation4/5

Most tools target distinct document operations and file types, so selection is generally clear. However, get_document_info overlaps with get_document_statistics, the live-editing cluster (open/refresh/watch/create_live_editing_session) has some boundary ambiguity, and _docx_has_omml looks like an internal helper exposed as a tool.

Naming Consistency4/5

Nearly all tools use snake_case with predictable verb_noun phrasing, such as create_document, read_document_text, and merge_text_documents. The main deviations are the internal-looking _docx_has_omml name and the adjective-prefixed batch_convert_documents, but the set remains mostly consistent.

Tool Count5/5

Fifteen tools is within the expected well-scoped range and covers reading, writing, conversion, search, and live-viewing workflows. The count is not excessive, though one exposed internal helper slightly dilutes the set.

Completeness3/5

The surface covers document creation, reading, search, batch conversion, and Writer text insertion, but editing support is thin for Calc and Impress. There are no clear tools for updating spreadsheet cells, modifying slides, deleting documents, or general single-document export/save workflows.

Maintenance

ActivityMaintained
ResponsivenessNo recent community issues