apyhub
FILE CONVERSION · FILE MANIPULATION

Convert Document with LibreOffice API

What it does

LibreOffice Convert turns an uploaded office document into another file format. Send a binary file in the file field, and set target_format when you need something other than the default pdf. The response is the converted file itself as binary output.

Use it when you need to normalize documents before sharing, store generated files in a different format, or convert incoming office attachments into something your pipeline can process. The API is focused on a single job: file-to-file conversion using LibreOffice’s document handling.

Because the output is a binary file, it fits cleanly into workflows that download, forward, or persist the converted document. Typical uses include turning spreadsheets into PDFs for review, exporting text from office files, or converting documents into another office format for compatibility with downstream systems.

If your application accepts uploaded office documents and needs a predictable conversion step, LibreOffice Convert gives you a direct way to transform the file without exposing LibreOffice itself in your stack.

POST
Convert an uploaded office document with LibreOffice
http://localhost:8080/dosvak/libreoffice-document-convert

QUICKSTART

GUIDE

Quickstart

Convert a document by uploading the source file and choosing the output format.

curl -X POST "http://localhost:8080/dosvak/libreoffice-document-convert" \
  -H "apy-token: $APY_TOKEN" \
  -F "file=@/path/to/document.docx" \
  -F "target_format=pdf"

What you'll get back

Returns a binary file stream (string with format: binary) containing the converted document.

TRY ITLIVE · 100 ATOMS
Loading your default key…
The full key is used to call the gateway and stays in this tab — never sent to orbit or saved.
Max 100MB total per request (all files combined). Larger? Use this API's URL-based endpoint instead, if it has one.
body*
Output format extension, for example `pdf`, `docx`, or `txt`

About this endpoint

What it does

Converts an uploaded office document with LibreOffice and returns the converted file as binary output. The input is an uploaded file plus an optional target output format.

Request Body

ParameterTypeMandatoryDescription
fileStringYesThe uploaded office document to convert. Binary file upload.
target_formatStringNoOutput format extension. Default: pdf. Examples include pdf, docx, and txt.

Response

Returns a binary file as the response body. The output schema is a single binary string, so there is no JSON wrapper or named response field.

ParameterTypeMandatoryDescription
response bodyStringYesConverted document file content returned as binary data.

Body

Name
Type
Description
bodyREQUIRED
object

Max 100MB total per request (all files combined). Larger? Use this API's URL-based endpoint instead, if it has one.

▣ COMMON ERRORS

Errors any endpoint can return

400bad_request

Required parameter missing or malformed body.

401unauthorized

API key missing, revoked, or not authorized for this service.

429rate_limited

Your plan's per-second rate exceeded. Retry with exponential backoff.

503upstream_busy

Backend temporarily unavailable. Try again in a few seconds.