ప్రధాన కంటెంట్‌కు వెళ్లండి
UV pdfTool
Contents

Developer API

The tools

The twelve tools the UV pdfTool API runs on our servers, with the options, limits and output of each.

Last updated 2026-10-29 · Written in English

A job names one of these tools. The options below are the ones the server accepts; an option it does not know is refused with INVALID_REQUEST. The same facts, as JSON Schema, come from GET /tools.

Compress PDF compress

Makes a PDF smaller: pictures re-encoded, page content rewritten, fonts trimmed.

Our engine by default, which keeps the text and the drawings as they are and rewrites the pictures; Ghostscript as an option, which rewrites the whole file at one of its presets and often wins on files whose bulk is not pictures. The output is checked: when nothing can be saved, the file comes back as it was.

Takes
application/pdf
Gives
The PDF, under the same name. (application/pdf)
Largest file
2 GB with a live key, 10 MB with a test key
Time allowed
10 minutes, then the job fails with TIMEOUT

Options

Options of Compress PDF
NameTypeDescription
imageQualitynumber 0.3–0.95JPEG quality for pictures the engine re-encodes, 0.3 to 0.95. Default 0.75.
maxImageDpinumber 20–1200Pictures above this resolution are scaled down to it, 20 to 1200 dots per inch. Default 150.
grayscalebooleanTrue turns colour pictures grey. Default false.
keepImagesbooleanTrue leaves every picture untouched; only the rest of the file is rewritten. Default false.
removeMetadatabooleanTrue drops the document information and XMP metadata. Default false.
targetBytesinteger 1024–10737418240A size to aim for, in bytes (1 KB to 10 GB). The engine tries stronger settings until the file is under it, and says in the job when it could not get there.
method"engine" | "ghostscript""engine" (default) or "ghostscript".
preset"printer" | "ebook" | "screen"With Ghostscript: "printer" (pictures at 300 dpi), "ebook" (150 dpi, the default) or "screen" (72 dpi).
linearizebooleanTrue rewrites the result for fast web view (a linearized PDF): its first page first, so a browser shows it while the rest is still downloading. Default false.
Create a Compress PDF job
# Once, in your shell: the key never goes into a script.
export UVPDF_KEY="uvp_live_..."

curl -X POST "https://uvpdftool.com/api/v1/jobs" \
  -H "Authorization: Bearer $UVPDF_KEY" \
  -H "Content-Type: application/json" \
  -d '{
  "tool": "compress",
  "options": {
    "method": "ghostscript",
    "preset": "ebook"
  },
  "files": [
    {
      "name": "report.pdf",
      "size": 4821130,
      "contentType": "application/pdf"
    }
  ]
}'

Office to PDF office-to-pdf

Word, Excel, PowerPoint, OpenDocument, RTF, CSV or plain text to PDF, by LibreOffice.

Send the file with its real content type (for example application/vnd.openxmlformats-officedocument.wordprocessingml.document for .docx); the list of accepted types is in GET /tools. The layout follows the document’s own page setup.

Takes
application/msword, application/vnd.openxmlformats-officedocument.wordprocessingml.document, application/vnd.ms-excel, application/vnd.openxmlformats-officedocument.spreadsheetml.sheet, application/vnd.ms-powerpoint, application/vnd.openxmlformats-officedocument.presentationml.presentation, application/vnd.oasis.opendocument.text, application/vnd.oasis.opendocument.spreadsheet, application/vnd.oasis.opendocument.presentation, application/rtf, text/csv, text/plain
Gives
A PDF named after the document. (application/pdf)
Largest file
200 MB with a live key, 10 MB with a test key
Time allowed
10 minutes, then the job fails with TIMEOUT

Options

None: send "options": {} or leave it out.

Create a Office to PDF job
# Once, in your shell: the key never goes into a script.
export UVPDF_KEY="uvp_live_..."

curl -X POST "https://uvpdftool.com/api/v1/jobs" \
  -H "Authorization: Bearer $UVPDF_KEY" \
  -H "Content-Type: application/json" \
  -d '{
  "tool": "office-to-pdf",
  "files": [
    {
      "name": "proposal.docx",
      "size": 182400,
      "contentType": "application/vnd.openxmlformats-officedocument.wordprocessingml.document"
    }
  ]
}'

PDF to Office pdf-to-office

A PDF into an editable Word (.docx) or PowerPoint (.pptx) file.

Text, pictures and layout are rebuilt by LibreOffice; a scanned PDF gives pictures, not text (run it through OCR first). Spreadsheets are not made on the server: the site builds them in the browser.

Takes
application/pdf
Gives
The .docx or .pptx file. (application/octet-stream)
Largest file
200 MB with a live key, 10 MB with a test key
Time allowed
15 minutes, then the job fails with TIMEOUT

Options

Options of PDF to Office
NameTypeDescription
formatrequired"docx" | "pptx""docx" or "pptx". Required.
Create a PDF to Office job
# Once, in your shell: the key never goes into a script.
export UVPDF_KEY="uvp_live_..."

curl -X POST "https://uvpdftool.com/api/v1/jobs" \
  -H "Authorization: Bearer $UVPDF_KEY" \
  -H "Content-Type: application/json" \
  -d '{
  "tool": "pdf-to-office",
  "options": {
    "format": "docx"
  },
  "files": [
    {
      "name": "contract.pdf",
      "size": 310212,
      "contentType": "application/pdf"
    }
  ]
}'

Repair PDF repair

Rebuilds a damaged PDF from what can still be read.

A file that is not a PDF at all is refused with NOT_A_PDF; one too broken to read gives CORRUPT_PDF.

Takes
application/pdf, application/octet-stream
Gives
The repaired PDF. (application/pdf)
Largest file
2 GB with a live key, 10 MB with a test key
Time allowed
10 minutes, then the job fails with TIMEOUT

Options

None: send "options": {} or leave it out.

Create a Repair PDF job
# Once, in your shell: the key never goes into a script.
export UVPDF_KEY="uvp_live_..."

curl -X POST "https://uvpdftool.com/api/v1/jobs" \
  -H "Authorization: Bearer $UVPDF_KEY" \
  -H "Content-Type: application/json" \
  -d '{
  "tool": "repair",
  "files": [
    {
      "name": "damaged.pdf",
      "size": 90112,
      "contentType": "application/pdf"
    }
  ]
}'

PDF to PDF/A pdf-to-pdfa

Converts to PDF/A-1b, 2b or 3b for archiving, and checks the result with veraPDF.

A result that does not pass the check fails the job with CONVERSION_FAILED rather than claiming to be PDF/A.

Takes
application/pdf
Gives
The PDF/A file. (application/pdf)
Largest file
500 MB with a live key, 10 MB with a test key
Time allowed
15 minutes, then the job fails with TIMEOUT

Options

Options of PDF to PDF/A
NameTypeDescription
level"1b" | "2b" | "3b""1b", "2b" (default) or "3b".
Create a PDF to PDF/A job
# Once, in your shell: the key never goes into a script.
export UVPDF_KEY="uvp_live_..."

curl -X POST "https://uvpdftool.com/api/v1/jobs" \
  -H "Authorization: Bearer $UVPDF_KEY" \
  -H "Content-Type: application/json" \
  -d '{
  "tool": "pdf-to-pdfa",
  "options": {
    "level": "2b"
  },
  "files": [
    {
      "name": "invoice.pdf",
      "size": 120333,
      "contentType": "application/pdf"
    }
  ]
}'

OCR ocr

Adds a searchable text layer to scanned pages, in 25 languages.

By default only pages without text are read, so a mixed file is never doubled. Languages: eng (English), hin (Hindi), tel (Telugu), tam (Tamil), kan (Kannada), mal (Malayalam), spa (Spanish), por (Portuguese), ind (Indonesian), ben (Bengali), mar (Marathi), guj (Gujarati), pan (Punjabi), ori (Odia), asm (Assamese), urd (Urdu), ara (Arabic), fra (French), deu (German), ita (Italian), rus (Russian), chi_sim (Simplified Chinese), chi_tra (Traditional Chinese), jpn (Japanese), kor (Korean).

Takes
application/pdf
Gives
The same PDF with text under the pictures. (application/pdf)
Largest file
500 MB with a live key, 10 MB with a test key
Time allowed
60 minutes, then the job fails with TIMEOUT

Options

Options of OCR
NameTypeDescription
languagesrequired"eng" | "hin" | "tel" | "tam" | "kan" | "mal" | "spa" | "por" | "ind" | "ben" | "mar" | "guj" | "pan" | "ori" | "asm" | "urd" | "ara" | "fra" | "deu" | "ita" | "rus" | "chi_sim" | "chi_tra" | "jpn" | "kor"[]One to 4 of the codes above, the most likely first; each one more slows every page. Required.
scope"scanned" | "all""scanned" (default: pages without text only) or "all" (every page read again).
engine"tesseract" | "ocrmypdf""tesseract" (default) or "ocrmypdf", which straightens and uprights the pages first and suits long scans.
Create a OCR job
# Once, in your shell: the key never goes into a script.
export UVPDF_KEY="uvp_live_..."

curl -X POST "https://uvpdftool.com/api/v1/jobs" \
  -H "Authorization: Bearer $UVPDF_KEY" \
  -H "Content-Type: application/json" \
  -d '{
  "tool": "ocr",
  "options": {
    "languages": [
      "eng",
      "hin"
    ]
  },
  "files": [
    {
      "name": "scan.pdf",
      "size": 2488112,
      "contentType": "application/pdf"
    }
  ]
}'

Web page to PDF web-to-pdf

Prints a public web page to PDF with a headless browser.

The job takes no file: the address is an option. Only public addresses are printed; private and local ones, and anything the page redirects to that is not public, are refused with INVALID_URL. The page is printed with its print stylesheet, with bookmarks from its headings.

Takes
no file (an address in the options)
Gives
A PDF named after the host. (application/pdf)
Largest file
none
Time allowed
3 minutes, then the job fails with TIMEOUT

Options

Options of Web page to PDF
NameTypeDescription
urlrequiredstringThe page’s address, http or https. Required.
pageSize"A4" | "Letter""A4" (default) or "Letter".
Create a Web page to PDF job
# Once, in your shell: the key never goes into a script.
export UVPDF_KEY="uvp_live_..."

curl -X POST "https://uvpdftool.com/api/v1/jobs" \
  -H "Authorization: Bearer $UVPDF_KEY" \
  -H "Content-Type: application/json" \
  -d '{
  "tool": "web-to-pdf",
  "options": {
    "url": "https://example.com/report"
  },
  "files": []
}'

HTML to PDF html-to-pdf

Prints an HTML file, scripts off and nothing fetched from the network.

Styles and pictures must be inside the file (inline or as data: addresses); a reference to another address is left out.

Takes
text/html, application/xhtml+xml
Gives
The PDF. (application/pdf)
Largest file
20 MB with a live key, 10 MB with a test key
Time allowed
3 minutes, then the job fails with TIMEOUT

Options

Options of HTML to PDF
NameTypeDescription
pageSize"A4" | "Letter""A4" (default) or "Letter".
Create a HTML to PDF job
# Once, in your shell: the key never goes into a script.
export UVPDF_KEY="uvp_live_..."

curl -X POST "https://uvpdftool.com/api/v1/jobs" \
  -H "Authorization: Bearer $UVPDF_KEY" \
  -H "Content-Type: application/json" \
  -d '{
  "tool": "html-to-pdf",
  "files": [
    {
      "name": "statement.html",
      "size": 40221,
      "contentType": "text/html"
    }
  ]
}'

Markdown to PDF markdown-to-pdf

Typesets a Markdown file: headings, lists, tables, code, pictures inside the file.

Takes
text/markdown, text/x-markdown, text/plain
Gives
The PDF. (application/pdf)
Largest file
10 MB with a live key, 10 MB with a test key
Time allowed
3 minutes, then the job fails with TIMEOUT

Options

Options of Markdown to PDF
NameTypeDescription
pageSize"A4" | "Letter""A4" (default) or "Letter".
style"sans" | "serif""sans" (default) or "serif".
Create a Markdown to PDF job
# Once, in your shell: the key never goes into a script.
export UVPDF_KEY="uvp_live_..."

curl -X POST "https://uvpdftool.com/api/v1/jobs" \
  -H "Authorization: Bearer $UVPDF_KEY" \
  -H "Content-Type: application/json" \
  -d '{
  "tool": "markdown-to-pdf",
  "options": {
    "style": "serif"
  },
  "files": [
    {
      "name": "notes.md",
      "size": 8112,
      "contentType": "text/markdown"
    }
  ]
}'

EPUB to PDF epub-to-pdf

Prints an e-book without DRM, chapter by chapter, with its table of contents.

A protected book is refused with EPUB_PROTECTED.

Takes
application/epub+zip
Gives
The PDF. (application/pdf)
Largest file
200 MB with a live key, 10 MB with a test key
Time allowed
10 minutes, then the job fails with TIMEOUT

Options

Options of EPUB to PDF
NameTypeDescription
pageSize"A4" | "Letter" | "A5""A4", "Letter" or "A5" (default A4).
Create a EPUB to PDF job
# Once, in your shell: the key never goes into a script.
export UVPDF_KEY="uvp_live_..."

curl -X POST "https://uvpdftool.com/api/v1/jobs" \
  -H "Authorization: Bearer $UVPDF_KEY" \
  -H "Content-Type: application/json" \
  -d '{
  "tool": "epub-to-pdf",
  "options": {
    "pageSize": "A5"
  },
  "files": [
    {
      "name": "book.epub",
      "size": 1210443,
      "contentType": "application/epub+zip"
    }
  ]
}'

PDF to SVG pdf-to-svg

Each page as an SVG drawing, text as text.

One page comes as a .svg file; several pages come as a ZIP of them.

Takes
application/pdf
Gives
An .svg file, or a .zip of one per page. (image/svg+xml)
Largest file
200 MB with a live key, 10 MB with a test key
Time allowed
10 minutes, then the job fails with TIMEOUT

Options

None: send "options": {} or leave it out.

Create a PDF to SVG job
# Once, in your shell: the key never goes into a script.
export UVPDF_KEY="uvp_live_..."

curl -X POST "https://uvpdftool.com/api/v1/jobs" \
  -H "Authorization: Bearer $UVPDF_KEY" \
  -H "Content-Type: application/json" \
  -d '{
  "tool": "pdf-to-svg",
  "files": [
    {
      "name": "diagram.pdf",
      "size": 55000,
      "contentType": "application/pdf"
    }
  ]
}'

Check PDF/A and PDF/UA pdfa-check

Checks conformance with veraPDF and returns a JSON report; the file is not changed.

The report says what the file claims, and for each standard checked whether it conforms, the rules it breaks (the most broken first) and a few of the places.

Takes
application/pdf
Gives
A JSON report (application/json). (application/json)
Largest file
500 MB with a live key, 10 MB with a test key
Time allowed
10 minutes, then the job fails with TIMEOUT

Options

Options of Check PDF/A and PDF/UA
NameTypeDescription
flavour"4" | "auto" | "1a" | "1b" | "2a" | "2b" | "2u" | "3a" | "3b" | "3u" | "4e" | "4f" | "ua1" | "ua2""auto" (default: the part the file claims, PDF/A-2b when none), a PDF/A level ("1a", "1b", "2a", "2b", "2u", "3a", "3b", "3u", "4", "4e", "4f") or PDF/UA ("ua1", "ua2").
Create a Check PDF/A and PDF/UA job
# Once, in your shell: the key never goes into a script.
export UVPDF_KEY="uvp_live_..."

curl -X POST "https://uvpdftool.com/api/v1/jobs" \
  -H "Authorization: Bearer $UVPDF_KEY" \
  -H "Content-Type: application/json" \
  -d '{
  "tool": "pdfa-check",
  "options": {
    "flavour": "2b"
  },
  "files": [
    {
      "name": "archive.pdf",
      "size": 220118,
      "contentType": "application/pdf"
    }
  ]
}'