Skip to main content
ComPDF logo
  • Category: documents
  • Auth: API_KEY
  • Composio-managed OAuth available? N/A
  • Tools: 19
  • Triggers: 0
  • Slug: COMPDF
  • Version: 20261101_00

Tools

Slug: COMPDF_ADD_PDF_WATERMARKAdd a text or image watermark to selected pages of one PDF. This consumes ComPDF quota; do not retry an ambiguous submission automatically.

Input Parameters

object
required
The single source PDF to process.
string
Pages to watermark, such as 1-3,6. Omit to use the provider default.
integer ("1" | "2")
Response language: 1 for English or 2 for Chinese.
string
Password for opening the source PDF, when it is protected.
string
required
Required text or image watermark content and placement settings.
string
Webhook callback URL for asynchronous processing.
string ("sync" | "async")
Use sync for a small interactive PDF or async to return a task ID.
string
Requested file name for the generated PDF.

Output

string
required
Data from the action execution
string
Error if any occurred during the execution of the action
boolean
required
Whether or not the action execution was successful or not
Slug: COMPDF_COMPRESS_PDFCompress one PDF with typed document and image optimization controls. This consumes ComPDF quota; do not retry an ambiguous submission automatically.

Input Parameters

object
required
The single source PDF to process.
integer ("1" | "2")
Response language: 1 for English or 2 for Chinese.
string
Password for opening the source PDF, when it is protected.
string
Webhook callback URL for asynchronous processing.
integer
General image quality from 0 to 100.
array
Optimization flags to combine. Cleanup: RMNOTUSE unused objects, RMEPTOBJ empty objects, RMSPEATTR special attributes, RMEMBFONT embedded fonts, RMINVALINK invalid links, RMINVABK invalid bookmarks, RMUNUSEDTARGET unused targets. Content removal: RMBK bookmarks, RMANNOT annotations, RMFORM forms, RMMULMEDIA multimedia, RMDOCINFO document info, RMMEDTADATA metadata, RMOBJDATA object data, RMFILEATTACHMENT attachments, RMEXTERNCROSSREF external references, RMOTHERAPPDATA app data, RMHIDERLAYER hidden layers, RMFORMCOMMITIMPORTRESETACTION form actions, RMJSACTION JavaScript, RMPAGETHUMBNAIL thumbnails, RMLABEL page labels, RMPRINTSETTINGS print settings, RMSEARCHINDEX search index. Compression/layout: BCOMPRESSIMAGE compresses images, RMREPLACEIMAGE replaces images, MERGEVISIBLELAYER merges visible layers, USEFLATE uses Flate, FLAT_REPLACELZW replaces LZW with Flate, OPTIMIZEPAGECONTENT optimizes page content, and OPTIMIZEPDFFASTWEBVIEW enables Fast Web View.
string ("sync" | "async")
Use sync for a small interactive PDF or async to return a task ID.
string
Requested file name for the generated PDF.
integer
Color-image quality from 0 to 100.
integer
Maximum color-image resolution in PPI.
integer
Target color-image resolution in PPI.
integer
Maximum grayscale-image resolution in PPI.
integer
Target grayscale-image resolution in PPI.
integer
Maximum monochrome-image resolution in PPI.
integer
Target monochrome-image resolution in PPI.
string ("jpeg" | "flate")
Color-image compression algorithm.
string ("jbig2" | "flate")
Monochrome-image compression algorithm.

Output

string
required
Data from the action execution
string
Error if any occurred during the execution of the action
boolean
required
Whether or not the action execution was successful or not
Slug: COMPDF_CONVERT_DOCUMENTConvert one PDF, office document, text file, CSV, HTML file, RTF file, or image to a supported output format, synchronously or as an asynchronous task. Processing consumes ComPDF account quota. Do not automatically retry an ambiguous submission because it may already be consuming quota. Synchronous download URLs are temporary and should be used promptly.

Input Parameters

object
required
The single source document to upload and convert.
object
Typed operation-specific conversion settings. Options not supported by the selected operation are rejected.
integer ("1" | "2")
Response language: 1 for English or 2 for Chinese.
string
Password for opening a protected source document.
string ("pdf/docx" | "pdf/xlsx" | "pdf/pptx" | "pdf/html" | "pdf/rtf" | "pdf/img" | "pdf/csv" | "pdf/txt" | "pdf/json" | "pdf/markdown" | "pdf/ofd" | "pdf/editable" | "docx/pdf" | "xlsx/pdf" | "pptx/pdf" | "html/pdf" | "rtf/pdf" | "txt/pdf" | "csv/pdf" | "img/pdf" | "img/docx" | "img/xlsx" | "img/pptx" | "img/html" | "img/rtf" | "img/csv" | "img/txt" | "img/json")
required
Conversion route to run, such as pdf/docx, txt/pdf, or img/json. Only the documented canonical routes in this field’s enum are accepted.
string
Webhook callback URL, supported only when processing_mode is async.
string ("sync" | "async")
Use sync for a small interactive file, or async to return a task ID for later status checks.

Output

string
required
Data from the action execution
string
Error if any occurred during the execution of the action
boolean
required
Whether or not the action execution was successful or not
Slug: COMPDF_CONVERT_PDF_STANDARDConvert one PDF to a supported PDF/A, PDF/X-4, or PDF/E-1 standard using the required ICC color profile. This consumes ComPDF quota; do not retry an ambiguous submission automatically.

Input Parameters

object
required
The single source PDF to process.
integer ("1" | "2")
Response language: 1 for English or 2 for Chinese.
string
Password for opening the source PDF, when it is protected.
string ("pdfa1a" | "pdfa1b" | "pdfa2a" | "pdfa2u" | "pdfa2b" | "pdfx4" | "pdfe1")
required
Target PDF/A, PDF/X-4, or PDF/E-1 standard.
object
required
Valid ICC color profile required by ComPDF for this conversion, such as an appropriate RGB or CMYK output profile for the intended standard.
string
Webhook callback URL for asynchronous processing.
string ("sync" | "async")
Use sync for a small interactive PDF or async to return a task ID.
string
Requested file name for the generated PDF.

Output

string
required
Data from the action execution
string
Error if any occurred during the execution of the action
boolean
required
Whether or not the action execution was successful or not
Slug: COMPDF_CONVERT_PDF_TO_PDF_UAConvert one PDF to the PDF/UA-1 accessibility standard, optionally embedding a document title and language. This consumes ComPDF quota; do not retry an ambiguous submission automatically.

Input Parameters

object
required
The single source PDF to process.
integer ("1" | "2")
Response language: 1 for English or 2 for Chinese.
string
Password for opening the source PDF, when it is protected.
string
Document title to embed in the PDF/UA-1 output.
string ("unspecified" | "cs_CZ" | "de_DE" | "en_GB" | "en_US" | "es_ES" | "fi_FI" | "fr_FR" | "hu_HU" | "it_IT" | "ja_JP" | "ko_KR" | "nl_BE" | "nl_NL" | "no_NO" | "pl_PL" | "pt_BR" | "pt_PT" | "ru_RU" | "sk_SK" | "sv_SE" | "tr_TR" | "zh_CN" | "zh_TW" | "zh_HK" | "zh_MO")
ComPDF PDF/UA language enum to embed in the output.
string
Webhook callback URL for asynchronous processing.
string ("sync" | "async")
Use sync for a small interactive PDF or async to return a task ID.
string
Requested file name for the generated PDF.

Output

string
required
Data from the action execution
string
Error if any occurred during the execution of the action
boolean
required
Whether or not the action execution was successful or not
Slug: COMPDF_DECRYPT_PDFDecrypt one password-protected PDF. This consumes ComPDF quota; do not retry an ambiguous submission automatically.

Input Parameters

object
required
The single source PDF to process.
integer ("1" | "2")
Response language: 1 for English or 2 for Chinese.
string
required
Password required to open and decrypt the source PDF.
string
Webhook callback URL for asynchronous processing.
string ("sync" | "async")
Use sync for a small interactive PDF or async to return a task ID.

Output

string
required
Data from the action execution
string
Error if any occurred during the execution of the action
boolean
required
Whether or not the action execution was successful or not
Slug: COMPDF_DELETE_PDF_PAGESCreate a new PDF with selected pages removed. This consumes ComPDF quota; do not retry an ambiguous submission automatically.

Input Parameters

object
required
The single source PDF to process.
string
required
Pages to delete, such as 1-3,6. Page numbers start at 1.
integer ("1" | "2")
Response language: 1 for English or 2 for Chinese.
string
Password for opening the source PDF, when it is protected.
string
Webhook callback URL for asynchronous processing.
string ("sync" | "async")
Use sync for a small interactive PDF or async to return a task ID.
string
Requested file name for the generated PDF.

Output

string
required
Data from the action execution
string
Error if any occurred during the execution of the action
boolean
required
Whether or not the action execution was successful or not
Slug: COMPDF_ENCRYPT_PDFEncrypt one PDF with at least a user password or owner password and optional permission controls. This consumes ComPDF quota; do not retry an ambiguous submission automatically.

Input Parameters

object
required
The single source PDF to process.
integer ("1" | "2")
Response language: 1 for English or 2 for Chinese.
string
Password for opening the source PDF, when it is protected.
string ("rc4" | "aes128" | "aes256")
Encryption algorithm; ComPDF defaults to rc4.
boolean
Whether the encrypted PDF permits copying content.
boolean
Whether the encrypted PDF permits printing.
string
Webhook callback URL for asynchronous processing.
string
Password users must enter to open the encrypted output PDF.
string
Owner password used to control output PDF permissions.
string ("sync" | "async")
Use sync for a small interactive PDF or async to return a task ID.
boolean
Whether the encrypted PDF permits commenting.
string
Requested file name for the generated PDF.
boolean
Whether the encrypted PDF permits document changes.
boolean
Whether the encrypted PDF permits form filling.
boolean
Whether the encrypted PDF permits page assembly.

Output

string
required
Data from the action execution
string
Error if any occurred during the execution of the action
boolean
required
Whether or not the action execution was successful or not
Slug: COMPDF_EXTRACT_DOCUMENT_FIELDSExtract fields from one uploaded document using a fixed schema, synchronously or asynchronously; the default async submission returns a task ID rather than the extracted result. Processing consumes AI quota; do not automatically retry an ambiguous submission.

Input Parameters

object
required
The single document to process.
object
Typed options for fixed-schema field extraction.
integer ("1" | "2")
API error message language: 1 for English or 2 for Chinese.
string
Password for opening a protected source document.
boolean
Enable OCR while processing the document.
string
Pages to process, starting at 1, such as 1-3,6; omit for all pages.
object
required
Required fixed schema containing the fields and tables to extract.
string ("sync" | "async")
AI work defaults to async; choose sync only for a small document expected to complete quickly.
string ("AUTO" | "CHINESE" | "CHINESE_TRAD" | "ENGLISH" | "KOREAN" | "JAPANESE" | "LATIN" | "DEVANAGARI" | "CYRILLIC" | "ARABIC" | "TAMIL" | "TELUGU" | "KANNADA" | "THAI" | "GREEK" | "ESLAV")
Language used by OCR; AUTO lets ComPDF detect the language.

Output

string
required
Data from the action execution
string
Error if any occurred during the execution of the action
boolean
required
Whether or not the action execution was successful or not
Slug: COMPDF_EXTRACT_PDF_PAGESExtract selected pages from one PDF into a new PDF. This consumes ComPDF quota; do not retry an ambiguous submission automatically.

Input Parameters

object
required
The single source PDF to process.
string
Pages to extract, such as 1-3,6. Omit to use the provider default.
integer ("1" | "2")
Response language: 1 for English or 2 for Chinese.
string
Password for opening the source PDF, when it is protected.
string
Webhook callback URL for asynchronous processing.
string ("sync" | "async")
Use sync for a small interactive PDF or async to return a task ID.
string
Requested file name for the generated PDF.

Output

string
required
Data from the action execution
string
Error if any occurred during the execution of the action
boolean
required
Whether or not the action execution was successful or not
Slug: COMPDF_GET_ACCOUNT_QUOTAReturn available and withheld ComPDF processing balances for the connected project account.

Output

string
required
Data from the action execution
string
Error if any occurred during the execution of the action
boolean
required
Whether or not the action execution was successful or not
Slug: COMPDF_GET_TASKGet the current status, aggregate counts, and per-file results for one ComPDF processing task. Result download URLs are temporary and should be used promptly.

Input Parameters

string
required
Task ID returned by an asynchronous or presigned processing request.
integer ("1" | "2")
Response language: 1 for English or 2 for Chinese.

Output

string
required
Data from the action execution
string
Error if any occurred during the execution of the action
boolean
required
Whether or not the action execution was successful or not
Slug: COMPDF_LIST_SUPPORTED_OPERATIONSList the document-processing operation routes currently advertised by ComPDF.

Output

string
required
Data from the action execution
string
Error if any occurred during the execution of the action
boolean
required
Whether or not the action execution was successful or not
Slug: COMPDF_LIST_TASKSReturn one page of processing-task history for the connected ComPDF project.

Input Parameters

integer
Number of task records to request on this page.
string
Opaque continuation cursor from the previous response; omit for the first page.

Output

string
required
Data from the action execution
string
Error if any occurred during the execution of the action
boolean
required
Whether or not the action execution was successful or not
Slug: COMPDF_PARSE_DOCUMENTRun ComPDF intelligent parsing on one uploaded document, synchronously or asynchronously; the default async submission returns a task ID rather than the parsing result. Processing consumes AI quota; do not automatically retry an ambiguous submission.

Input Parameters

object
required
The single document to process.
object
Typed options for full intelligent document parsing.
integer ("1" | "2")
API error message language: 1 for English or 2 for Chinese.
string
Password for opening a protected source document.
boolean
Enable OCR while processing the document.
string
Pages to process, starting at 1, such as 1-3,6; omit for all pages.
string ("sync" | "async")
AI work defaults to async; choose sync only for a small document expected to complete quickly.
string ("AUTO" | "CHINESE" | "CHINESE_TRAD" | "ENGLISH" | "KOREAN" | "JAPANESE" | "LATIN" | "DEVANAGARI" | "CYRILLIC" | "ARABIC" | "TAMIL" | "TELUGU" | "KANNADA" | "THAI" | "GREEK" | "ESLAV")
Language used by OCR; AUTO lets ComPDF detect the language.

Output

string
required
Data from the action execution
string
Error if any occurred during the execution of the action
boolean
required
Whether or not the action execution was successful or not
Slug: COMPDF_REMOVE_PDF_WATERMARKRemove tagged or untagged watermarks from selected pages of one PDF. This consumes ComPDF quota; do not retry an ambiguous submission automatically.

Input Parameters

object
required
The single source PDF to process.
string
Pages from which to remove watermarks, such as 1-3,6.
string
required
Required tagged or untagged watermark removal settings.
integer ("1" | "2")
Response language: 1 for English or 2 for Chinese.
string
Password for opening the source PDF, when it is protected.
string
Webhook callback URL for asynchronous processing.
string ("sync" | "async")
Use sync for a small interactive PDF or async to return a task ID.
string
Requested file name for the generated PDF.

Output

string
required
Data from the action execution
string
Error if any occurred during the execution of the action
boolean
required
Whether or not the action execution was successful or not
Slug: COMPDF_ROTATE_PDF_PAGESRotate selected pages in one PDF by 90, 180, or 270 degrees. This consumes ComPDF quota; do not retry an ambiguous submission automatically.

Input Parameters

object
required
The single source PDF to process.
integer ("90" | "180" | "270")
required
Clockwise page rotation angle in degrees.
string
required
Pages to rotate, such as 1-3,6. Page numbers start at 1.
integer ("1" | "2")
Response language: 1 for English or 2 for Chinese.
string
Password for opening the source PDF, when it is protected.
string
Webhook callback URL for asynchronous processing.
string ("sync" | "async")
Use sync for a small interactive PDF or async to return a task ID.
string
Requested file name for the generated PDF.

Output

string
required
Data from the action execution
string
Error if any occurred during the execution of the action
boolean
required
Whether or not the action execution was successful or not
Slug: COMPDF_SPLIT_PDFSplit selected pages from one PDF into separate files in a ZIP archive. This consumes ComPDF quota; do not retry an ambiguous submission automatically.

Input Parameters

object
required
The single source PDF to process.
string
required
Page ranges to split, such as 1-3,6. Page numbers start at 1.
integer ("1" | "2")
Response language: 1 for English or 2 for Chinese.
string
Password for opening the source PDF, when it is protected.
string
Webhook callback URL for asynchronous processing.
string
Requested file name for the output ZIP.
string ("sync" | "async")
Use sync for a small interactive PDF or async to return a task ID.

Output

string
required
Data from the action execution
string
Error if any occurred during the execution of the action
boolean
required
Whether or not the action execution was successful or not
Slug: COMPDF_WAIT_FOR_TASKPoll a ComPDF processing task at a safe interval until it finishes, expires, fails, or reaches a timeout. A successful response requires all files to be confirmed successful; otherwise the tool reports a failure.

Input Parameters

string
required
Asynchronous processing task ID to wait for.
integer
Response language: 1 for English or 2 for Chinese.
number
Maximum wall-clock seconds to wait (1-600). A timeout does not mean the task itself failed.
number
Seconds between status checks (3-60). ComPDF requires at least 3 seconds.

Output

string
required
Data from the action execution
string
Error if any occurred during the execution of the action
boolean
required
Whether or not the action execution was successful or not