Production-grade PDF SaaS built with Next.js, FastAPI, async workers, and Razorpay billing.
Live product:
- Website: https://www.pdforbit.app
- API: https://api.pdforbit.app
Maintainer:
- Deepak Rakshit
- LinkedIn: https://www.linkedin.com/in/deepakrakshit/
Career note:
- This project is being published publicly as part of an open-source portfolio.
- I am open to paid internship opportunities, engineering discussions, and serious product collaborations.
AI disclosure:
- This is an AI-assisted project.
- AI was used for implementation support, refactoring assistance, testing support, documentation drafting, and repository cleanup acceleration.
- Final review, deployment, payment credential setup, and publishing decisions remained human responsibility.
- See
AI_ASSISTANCE.mdfor the explicit disclosure.
- Quick Start
- Screenshots
- Project Stats
- Product Summary
- Why This Project Exists
- Production Highlights
- Core Features
- Tool Categories
- Billing and Subscription System
- Architecture Overview
- Repository Structure
- Technology Stack
- Environment Variables
- Local Development
- Docker Compose
- Testing
- Deployment
- Security and Privacy
- AI Assistance
- Open-Source Publishing Notes
- Documentation Map
- GitHub Presentation Notes
- API Contract
- Production Status
- Roadmap
- Maintainer Contact
git clone https://github.com/deepakrakshit/pdforbit
cd pdforbit
cp backend/.env.example backend/.env
docker compose up --buildThe app will be available at http://localhost:3000.
Clean landing page with product overview and quick access to tools.
Organized tool categories for fast PDF workflow discovery.
Subscription tiers with Razorpay integration.
- 30+ PDF tools across 6 categories
- Full-stack SaaS architecture (Next.js + FastAPI)
- Async job processing with Redis worker queue
- Razorpay billing integration with webhook verification
- HMAC-signed download URLs
- JWT authentication with token rotation
- Integration test coverage for uploads, jobs, billing, and cleanup
PdfORBIT is a full-stack PDF platform for modern document workflows.
It includes:
- PDF merge, split, extract, remove, and reorder tools
- compression, repair, and OCR workflows
- conversion to and from common office and image formats
- editing workflows such as rotate, watermark, crop, and page numbering
- security workflows such as unlock, protect, sign, redact, and compare
- document intelligence workflows such as translation and summarization
- pricing, subscription, and payment integration through Razorpay
The project combines product UX, backend orchestration, worker-based processing, and deployment-aware engineering.
PdfORBIT was built to solve real PDF workflows while also serving as a serious engineering portfolio project.
This repository demonstrates:
- product thinking
- full-stack engineering ability
- async processing design
- deployment and operations awareness
- subscription and billing integration
- documentation quality
- transparent AI-assisted development practices
This is why the repository is structured for GitHub consumption, not just local development.
- deployed frontend on Railway
- deployed backend on Railway
- async worker-based processing model
- backend-driven subscription state
- Razorpay integration through secure server routes
- explicit webhook and payment verification flow
- public-facing docs for architecture, deployment, operations, and security
- cleaned repository with generated artifacts and local secrets removed
- root
.gitignoreadded for publish safety
- polished marketing and tool pages
- responsive frontend
- category-based tool discovery
- pricing and enterprise conversion flow
- support for public product presentation and screenshots
- upload documents
- create async jobs
- poll for status
- deliver signed download links
- handle retention cleanup
- account-aware platform direction
- credits and usage logic
- subscription-aware billing foundation
- payment record persistence
- cancellation and expiry handling
- Merge PDF
- Split PDF
- Extract Pages
- Remove Pages
- Reorder Pages
- Compress PDF
- Repair PDF
- OCR PDF
- JPG to PDF
- Word to PDF
- Excel to PDF
- PowerPoint to PDF
- HTML to PDF
- PDF to JPG
- PDF to Word
- PDF to Excel
- PDF to PowerPoint
- PDF to PDF/A
- PDF Editor
- Rotate PDF
- Watermark PDF
- Add Page Numbers
- Crop PDF
- Unlock PDF
- Protect PDF
- Sign PDF
- Redact PDF
- Compare PDF
- Translate PDF
- Summarize PDF
PdfORBIT includes a production-oriented billing path using Razorpay.
The billing design intentionally separates responsibilities:
- Next.js API routes interact with Razorpay using server-side credentials
- FastAPI remains the source of truth for orders, payment records, and subscription state
- webhook events are verified server-side
- payment signatures are verified server-side
- internal backend billing routes are protected with a shared secret
Supported commercial paths:
- Pro monthly
- Pro yearly
- Enterprise via contact flow
Billing-related implementation lives across:
- frontend secure API routes
- backend billing service
- backend schemas and models
- backend migration layer
User
↓
Next.js Frontend (product pages, tool flows, secure billing routes)
↓
FastAPI Backend (upload, auth, jobs, downloads, billing state)
↓
Redis Queue (async job dispatch)
↓
Worker Processes (heavy PDF operations)
↓
PostgreSQL (durable state) + File Storage (runtime artifacts)
Processing model:
- user uploads a file
- backend stores file metadata
- job is created and queued
- worker processes the job
- backend exposes job status via polling
- signed download is returned when complete
This structure keeps heavy document processing off the request path.
pdforbit/
├── backend/
├── docs/
├── frontend/
├── docker-compose.yml
├── AI_ASSISTANCE.md
├── CONTRIBUTING.md
├── SECURITY.md
├── .gitignore
└── README.md
Contains:
- Next.js app
- pages and components
- styles and assets
- secure billing API routes
Contains:
- FastAPI app
- services and repositories
- workers
- migrations
- tests
Contains:
- architecture notes
- deployment notes
- operations notes
- GitHub showcase notes
- Next.js Pages Router
- React
- TypeScript
- Tailwind utility usage
- custom CSS system
- Razorpay Node integration inside server routes
- FastAPI
- SQLAlchemy
- Alembic
- PostgreSQL
- Redis
- RQ workers
- OCR tooling
- PDF rendering and transformation libraries
- office-to-PDF and PDF-to-office conversion support
- Railway
- public frontend and backend domains
- environment-driven configuration
Examples are documented in backend/.env.example.
Core:
APP_ENVAPI_V1_PREFIXHOSTPORTLOG_FORMATLOG_LEVEL
Persistence and queues:
DATABASE_URLREDIS_URLFILES_ROOTQUEUE_DEFAULT_TIMEOUT_SECONDSCLEANUP_INTERVAL_SECONDSSTALE_JOB_THRESHOLD_SECONDS
Security:
JWT_ACCESS_SECRETJWT_REFRESH_SECRETDOWNLOAD_SIGNING_SECRETCORS_ORIGINSALLOWED_HOSTS
Uploads and retention:
RETENTION_MINUTESGUEST_MAX_UPLOAD_MBUSER_MAX_UPLOAD_MBUPLOAD_CHUNK_SIZE_BYTESRATE_LIMIT_UPLOADS_PER_HOURRATE_LIMIT_JOBS_PER_HOURRATE_LIMIT_AUTHENTICATED_MULTIPLIER
Processing:
TESSERACT_BINOCR_TIMEOUT_SECONDSPDF_RENDER_DPITRANSLATION_PROVIDERTRANSLATION_API_KEYGROQ_API_KEYGROQ_API_BASEGROQ_TRANSLATE_MODELGROQ_SUMMARY_MODELGROQ_TIMEOUT_SECONDSINTELLIGENCE_CHUNK_CHARSINTELLIGENCE_SUMMARY_CHUNK_CHARSINTELLIGENCE_OCR_DPI
Internal testing admin:
INTERNAL_ADMIN_ENABLEDINTERNAL_ADMIN_EMAILINTERNAL_ADMIN_PASSWORD
Billing:
BILLING_INTERNAL_API_SECRET
Examples are documented in frontend/.env.example.
NEXT_PUBLIC_API_BASERAZORPAY_KEY_IDRAZORPAY_KEY_SECRETRAZORPAY_WEBHOOK_SECRETBILLING_INTERNAL_API_SECRET
Publishing rule:
- never commit
.env - never commit
.env.local - never hardcode secrets in source
- Python 3.10+
- Node.js 20+
- PostgreSQL
- Redis
- Tesseract available to the backend runtime
cd backend
cp .env.example .env
pip install -e .
alembic upgrade head
uvicorn app.main:app --reload --host 0.0.0.0 --port 8000Run supporting processes in separate terminals:
python -m app.workers.rq_app
python -m app.workers.cleanupcd frontend
cp .env.example .env.local
npm install
npm run devThe frontend will run at http://localhost:3000.
The root docker-compose.yml starts PostgreSQL, Redis, the API, the RQ worker, the cleanup scheduler, and the frontend.
docker compose up --buildBefore first use, create backend/.env from backend/.env.example.
Run the full backend suite:
cd backend
pytest -qRun billing-focused integration coverage:
cd backend
pytest tests/integration/test_billing_system.py -qRun static validation and production build check:
cd frontend
npm run type-check
npm run buildThis repository treats build and integration stability as more important than inflated test-count vanity.
Deploy the backend image as three Railway processes sharing the same codebase and a persistent volume.
api— start command:
uvicorn app.main:app --host 0.0.0.0 --port $PORTworker:
python -m app.workers.rq_appcleanup:
python -m app.workers.cleanup- Managed PostgreSQL
- Managed Redis
- Persistent volume mounted and mapped to
FILES_ROOT, for example/data/pdforbit
- Run
alembic upgrade headas a release command before promoting a new backend build. - Point all backend processes to the same
DATABASE_URL,REDIS_URL, andFILES_ROOT. - Set
CORS_ORIGINSto the deployed frontend origin. - Set
BILLING_INTERNAL_API_SECRETon both the backend and frontend services to the same long random value. - Set
RAZORPAY_KEY_ID,RAZORPAY_KEY_SECRET, andRAZORPAY_WEBHOOK_SECRETon the frontend service only. - Configure the Razorpay webhook dashboard to call
https://pdforbit.app/api/razorpay-webhookwith the matching webhook secret. - If you want an unlimited internal testing account in production, set
INTERNAL_ADMIN_ENABLED=trueplusINTERNAL_ADMIN_EMAILandINTERNAL_ADMIN_PASSWORDon the backend service before redeploying. - Deploy the frontend as a separate Railway service with
NEXT_PUBLIC_API_BASEpointed at the backend public URL.
More detail is available in docs/DEPLOYMENT.md.
Security-sensitive areas include:
- uploads
- auth tokens
- signed downloads
- background processing boundaries
- billing verification
- webhook verification
- secret handling
Privacy-sensitive areas include:
- temporary document storage
- retention windows
- controlled artifact access
- public-vs-internal route separation
See SECURITY.md for the repository security policy.
This repository explicitly states that it is AI-assisted.
That is a feature of the documentation, not something hidden.
Why this matters:
- it reflects how modern software is actually built
- it is more honest than pretending the workflow was fully manual
- it still preserves human ownership and review responsibility
If you are evaluating this project for internships, open source quality, or engineering maturity, the intended standard is not “no AI”.
The intended standard is:
- clear ownership
- real verification
- sound architecture
- working deployment
- transparent process
See docs/PUBLISHING.md for the full cleanup notes.
README.md: primary public project documentLICENSE: MIT licenseAI_ASSISTANCE.md: explicit AI-assisted workflow disclosureCONTRIBUTING.md: contribution expectationsSECURITY.md: vulnerability and secret-handling guidancedocs/ARCHITECTURE.md: architecture summarydocs/DEPLOYMENT.md: deployment guidedocs/OPERATIONS.md: operational checklistdocs/SHOWCASE.md: GitHub presentation notesdocs/API_CONTRACT.md: frontend route contract and polling response shapedocs/STATUS.md: current production posture and test coveragedocs/ROADMAP.md: planned features and long-term directiondocs/PUBLISHING.md: open-source publishing and cleanup notesfrontend/README.md: frontend package summarybackend/README.md: backend package summary
See docs/SHOWCASE.md for recommended GitHub About text, profile links, and screenshot guidance.
See docs/API_CONTRACT.md for the full route listing and polling response shape.
See docs/STATUS.md for the current production posture and test coverage summary.
See docs/ROADMAP.md for planned features and long-term direction.
Deepak Rakshit
If you are reaching out for:
- paid internships
- engineering opportunities
- collaboration
- product discussion
that LinkedIn profile is the intended public contact path in this repository.


