Stirling PDF
by @angusthefuzz
Self-hosted REST API for comprehensive PDF manipulation including merge, split, convert, OCR, compress, sign, redact, and secure PDFs.
clawhub install stirling-pdfπ About This Skill
name: stirling-pdf description: PDF manipulation via Stirling-PDF API. Merge, split, convert, OCR, compress, sign, redact, and more. Self-hosted. metadata: openclaw: emoji: π requires: bins: [node, curl] env: { STIRLING_PDF_URL: "http://localhost:8080", STIRLING_API_KEY: "", }
Stirling-PDF Skill
Self-hosted PDF manipulation platform with 60+ tools via REST API.
Configuration
Set these environment variables:
STIRLING_PDF_URL β Your Stirling-PDF instance URL (default: http://localhost:8080)STIRLING_API_KEY β API key if authentication is enabledDocs
/swagger-ui/index.html on your deploymentQuick Commands
# Use the wrapper script
node ~/.openclaw/skills/stirling-pdf/scripts/pdf.js [options]Examples:
node pdf.js merge file1.pdf file2.pdf -o merged.pdf
node pdf.js split input.pdf -o ./output-dir
node pdf.js compress input.pdf -o compressed.pdf
node pdf.js ocr input.pdf -o searchable.pdf
node pdf.js convert-to-pdf document.docx -o output.pdf
node pdf.js pdf-to-word input.pdf -o output.docx
node pdf.js add-watermark input.pdf "DRAFT" -o watermarked.pdf
Available Operations
Page Operations
merge - Combine multiple PDFssplit - Split PDF into partsrotate - Rotate pagesextract-pages - Extract specific pagesreorder - Reorganize pagesConversion
convert-to-pdf - Word, Excel, Images, HTML β PDFpdf-to-word - PDF β Wordpdf-to-image - PDF β Imagespdf-to-text - Extract textContent
compress - Reduce file sizeocr - Make scanned PDFs searchableadd-watermark - Add text/image watermarkadd-stamp - Add stampredact - Remove sensitive contentsign - Add signatureSecurity
add-password - Password protectremove-password - Remove passwordsanitize - Remove metadata/scriptsDirect API Usage
For operations not covered by the script, call the API directly:
curl -X POST "$STIRLING_PDF_URL/api/v1/general/merge-pdfs" \
-H "X-API-KEY: $STIRLING_API_KEY" \
-H "Content-Type: multipart/form-data" \
-F "fileInput=@file1.pdf" \
-F "fileInput=@file2.pdf" \
-o merged.pdf
Check Swagger UI at for all endpoints.
Common Endpoints
| Operation | Endpoint |
|-----------|----------|
| Merge | /api/v1/general/merge-pdfs |
| Split | /api/v1/general/split-pages |
| Compress | /api/v1/misc/compress-pdf |
| OCR | /api/v1/misc/ocr-pdf |
| PDF to Image | /api/v1/convert/pdf/img |
| Image to PDF | /api/v1/convert/img/pdf |
| Add Watermark | /api/v1/security/add-watermark |
| Add Password | /api/v1/security/add-password |
Notes
fileInputβοΈ Configuration
Set these environment variables:
STIRLING_PDF_URL β Your Stirling-PDF instance URL (default: http://localhost:8080)STIRLING_API_KEY β API key if authentication is enabledπ Tips & Best Practices
fileInput