word_export_pdf
Convert a Word document (.docx) to a PDF file using LibreOffice, ensuring concurrent exports with isolated user installations.
Instructions
Convert a .docx file to PDF via LibreOffice headless.
Delegates to :func:office_mcp.exporters.export_to_pdf. A unique
-env:UserInstallation is used per call so multiple exports
can run concurrently (VAL-WORD-079).
Args:
path: Path to an existing .docx file.
output: Target path for the produced PDF. The parent
directory is created if it does not exist. If a relative
path is given, it is resolved against folder (or the
default folder).
folder: Optional base folder for relative paths.
Returns:
{"output_path": "<absolute path of the produced PDF>"}.
Raises:
OfficeMCPError: ERR_FILE_NOT_FOUND if the source is
missing, ERR_UNSUPPORTED_FMT for non-.docx
sources, ERR_LIBREOFFICE_MISSING when soffice is
not on PATH, ERR_EXPORT_FAILED for any other failure.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| path | Yes | ||
| output | Yes | ||
| folder | No |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||