ComPDF Documents to PDF
Overview
ComPDF Documents to PDF helps AI agents and teams standardize office files and web content into PDF. It supports Word to PDF, Excel to PDF, Slide to PDF, HTML to PDF, TXT to PDF, CSV to PDF, PNG to PDF, and RTF to PDF, making it easy to create fixed-layout deliverables for reporting, approvals, compliance, and distribution.
Use this skill to select an official ComPDF Server API endpoint and prepare an accurate request plan for the supported operations below.
Supported Operations
| Operation |
Official page or index section |
| Word to PDF |
word-to-pdf |
| Excel to PDF |
excel-to-pdf |
| PPT to PDF |
ppt-to-pdf |
| HTML to PDF |
html-to-pdf |
| TXT to PDF |
txt-to-pdf |
| CSV to PDF |
csv-to-pdf |
| RTF to PDF |
rtf-to-pdf |
| PNG and JPG to PDF |
image-to-pdf |
Scope
Produce PDF only. Do not use this skill for PDF-to-document conversion or PDF page editing.
Workflow
- Identify the source file type, desired output, and requested operation.
- Read
references/endpoint-index.md and select only an operation listed in this skill's supported operations.
- Read the matching heading in
references/official-api-reference.md. Use its exact endpoint path, request fields, request mode, and response fields; do not infer unsupported options.
- Prefer synchronous mode for small interactive work. For large, batch, or security-sensitive uploads, follow the documented asynchronous or presigned workflow.
- Resolve the API key before preparing the request. Read the first non-empty line from
COMPDF_API_KEY_FILE when set. Otherwise read %USERPROFILE%\.compdf\api_key on Windows, or ~/.config/compdf/api_key on macOS and Linux. Pass the value only as the x-api-key header; never put it in code, logs, examples, or output.
- Before an operation that overwrites, deletes, decrypts, applies permanent protection, or sends a document externally, identify affected files and obtain confirmation unless the user has already authorized it.
- Return the endpoint, method, content type, complete request fields, expected task/result fields, and the next polling or download step. Preserve original files unless replacement is explicitly requested.
API Key
Use one local, private key file so later ComPDF tasks do not require pasting an API key into chat. The file must contain only the API key on its first non-empty line. Do not create, commit, upload, or display this file.
When the selected file is absent, unreadable, or empty, direct the user to obtain a key at https://www.compdf.com/compdf-portal/signin?utm_source=github&utm_medium=referral&utm_campaign=compdf_skills_repo_en&ref_platform_id=github_compdfkit_skills_en, save it in the selected file, and retry.
Maintainer
Refresh the local official snapshot before release, then inspect the diff for renamed endpoints, changed fields, and changed enum values:
python scripts/sync_official_api_reference.py
1---2name: compdf-documents-to-pdf3description: Convert Word, Excel, PPT, HTML, TXT, CSV, RTF, PNG, and JPG files into PDF with ComPDF. Use when a business document or image needs fixed-layout PDF output for sharing, approvals, printing, or archiving.4---5
6# ComPDF Documents to PDF
7
8## Overview
9
10ComPDF Documents to PDF helps AI agents and teams standardize office files and web content into PDF. It supports Word to PDF, Excel to PDF, Slide to PDF, HTML to PDF, TXT to PDF, CSV to PDF, PNG to PDF, and RTF to PDF, making it easy to create fixed-layout deliverables for reporting, approvals, compliance, and distribution.
11
12Use this skill to select an official ComPDF Server API endpoint and prepare an accurate request plan for the supported operations below.
13
14## Supported Operations
15
16| Operation | Official page or index section |
17| --- | --- |
18| Word to PDF | `word-to-pdf` |
19| Excel to PDF | `excel-to-pdf` |
20| PPT to PDF | `ppt-to-pdf` |
21| HTML to PDF | `html-to-pdf` |
22| TXT to PDF | `txt-to-pdf` |
23| CSV to PDF | `csv-to-pdf` |
24| RTF to PDF | `rtf-to-pdf` |
25| PNG and JPG to PDF | `image-to-pdf` |
26
27## Scope
28
29Produce PDF only. Do not use this skill for PDF-to-document conversion or PDF page editing.
30
31## Workflow
32
331. Identify the source file type, desired output, and requested operation.
342. Read `references/endpoint-index.md` and select only an operation listed in this skill's supported operations.
353. Read the matching heading in `references/official-api-reference.md`. Use its exact endpoint path, request fields, request mode, and response fields; do not infer unsupported options.
364. Prefer synchronous mode for small interactive work. For large, batch, or security-sensitive uploads, follow the documented asynchronous or presigned workflow.
375. Resolve the API key before preparing the request. Read the first non-empty line from `COMPDF_API_KEY_FILE` when set. Otherwise read `%USERPROFILE%\.compdf\api_key` on Windows, or `~/.config/compdf/api_key` on macOS and Linux. Pass the value only as the `x-api-key` header; never put it in code, logs, examples, or output.
386. Before an operation that overwrites, deletes, decrypts, applies permanent protection, or sends a document externally, identify affected files and obtain confirmation unless the user has already authorized it.
397. Return the endpoint, method, content type, complete request fields, expected task/result fields, and the next polling or download step. Preserve original files unless replacement is explicitly requested.
40
41## API Key
42
43Use one local, private key file so later ComPDF tasks do not require pasting an API key into chat. The file must contain only the API key on its first non-empty line. Do not create, commit, upload, or display this file.
44
45When the selected file is absent, unreadable, or empty, direct the user to obtain a key at `https://www.compdf.com/compdf-portal/signin?utm_source=github&utm_medium=referral&utm_campaign=compdf_skills_repo_en&ref_platform_id=github_compdfkit_skills_en`, save it in the selected file, and retry.
46
47## Maintainer
48
49Refresh the local official snapshot before release, then inspect the diff for renamed endpoints, changed fields, and changed enum values:
50
51```powershell
52python scripts/sync_official_api_reference.py
53```