Skip to content

Latest commit

 

History

History
110 lines (69 loc) · 2.37 KB

File metadata and controls

110 lines (69 loc) · 2.37 KB

📄 PDF Merger API + Web Interface


A powerful, production-ready API and drag & drop frontend to merge PDF files in seconds. Fully local, secure, and extendable.

Includes: Dockerfile, HTML5/CSS frontend, modular Flask code, file validation, MIME checks, and full project structure.

👉 💳 Buy it on Gumroad


Designed for agencies, SaaS developers, freelancers, and document-heavy teams who want to automate PDF operations without relying on cloud services.


✅ Key Features

  • 📥 Upload and merge multiple PDF files (via API or UI)
  • 🖥 Drag & Drop Web Interface (mobile ready)
  • 🔑 API Key protection (X-API-KEY)
  • 📄 Count total pages in PDF
  • 🚫 MIME, file size, and extension validation
  • 📁 Secure temporary storage using timestamp + hashing
  • 🔐 Works 100% locally — no 3rd-party file access
  • 🧱 Clean modular structure (routes, utils, validators)
  • 🐳 Docker-ready for instant deployment
  • 📦 Includes ready-to-use static frontend (HTML/JS/CSS)

👥 Use Cases

  • Legal, financial, or HR teams automating doc prep
  • Web apps with PDF upload & merge needs
  • Freelancers integrating PDF workflows for clients
  • SaaS builders needing reliable PDF processing

🚀 API Endpoints

Merge PDFs

POST /merge
Headers: X-API-KEY: your-api-key
Body: multipart/form-data with 2+ PDF files

Returns a downloadable merged PDF and sets X-Total-Pages.


Count Pages

POST /count-pages
Headers: X-API-KEY: your-api-key
Body: multipart/form-data with single PDF

Returns: { "pages": <number> }


⚙️ Setup

pip install -r requirements.txt

Then:

python app.py

Or use Docker:

docker build -t pdf-api .
docker run -p 5000:5000 pdf-api

🌐 Web Interface

Open http://localhost:5000 to use the drag & drop PDF merger.
Supports multiple files, mobile layout, and direct download.


🧪 Screenshots & Demo

  • ✅ Merging PDFs via API & UI
  • ✅ Counting PDF pages
  • ⚠️ Error handling and validation messages

See /screens/ for real usage previews.


📬 Contacts


Need PDF splitting, password protection, or watermarking?
Custom features available — just ask.