An open API service indexing awesome lists of open source software.

https://github.com/giomjds/printify

Upload your PDF or DOCX, select print settings, pay securely, and track your order in real timeβ€”professional prints made effortless.
https://github.com/giomjds/printify

cloudinary nextjs postgresql uploadthing websockets

Last synced: 2 months ago
JSON representation

Upload your PDF or DOCX, select print settings, pay securely, and track your order in real timeβ€”professional prints made effortless.

Awesome Lists containing this project

README

          

# Printify
# ![Printify Logo](public/printify_logo.png)

> **Seamless document-to-print platform**
>
> Upload your `.pdf` or `.docx`, pay securely, and track your order in real time.

---

## πŸ“¦ Table of Contents

* [πŸš€ About](#-about)
* [✨ Features](#-features)
* [πŸ› οΈ Tech Stack](#tech-stack)
* [βš™οΈ Installation & Setup](#️-installation--setup)
* [▢️ Usage](#-usage)
* [πŸ“ Repository Structure](#-repository-structure)
* [🀝 Contributing](#-contributing)

---

## πŸš€ About

Printify is a professional web portal that transforms your PDF and DOCX documents into high-quality printsβ€”fast, reliable, and user-friendly. Designed for local print shops, it offers a streamlined, end-to-end experience:

* **Upload** documents in seconds
* **Pay** physically
* **Track** order status in real time

---

## ✨ Features

* πŸ”’ **Secure Uploads & Payments**: SSL encryption and Stripe integration for peace of mind
* πŸ•’ **Real-Time Tracking**: WebSockets notifications for status changes
* πŸ“„ **Document Preview**: In-browser preview before you submit
* πŸ“§ **Order Confirmation & Receipts**: Email receipts with unique Order ID

---

## πŸ› οΈ Tech Stack

| Layer | Technology |
| ------------- | ---------------------------------------- |
| Front End | Next.js 15 (App Router), Tailwind CSS v4 |
| Back End | Next.js API Routes, TypeScript |
| Database | PostgreSQL, Prisma ORM |
| File Storage | Cloudinary |
| Real-Time | WebSockets |
| Email Service | Nodemailer |

---

## βš™οΈ Installation & Setup

1. **Clone the repo**

```bash
git clone https://github.com/GioMjds/Printify.git
cd printify
```

2. **Install dependencies**

```bash
npm install
```

3. **Environment Variables** Create a `.env.local` file in the root and add:

```bash
# PostgreSQL for the database
DATABASE_URL="postgresql://:@:5432/printify?schema=public"

# Setup your own Cloudinary and fill the credentials needed
NEXT_PUBLIC_CLOUDINARY_CLOUD_NAME=
NEXT_PUBLIC_CLOUDINARY_API_KEY=
NEXT_PUBLIC_CLOUDINARY_API_SECRET=
CLOUDINARY_URL=

# Create your own Gmail Address for your own setup
EMAIL_USER=your_own_gmail_address
EMAIL_PASS=app_password
```

4. **Run Prisma migrations & generate client**

```bash
Just copy the `schema.prisma` file in my repo

npx prisma migrate dev --name init
npx prisma generate
```

5. **Start the development server**

```bash
npm run dev
```

---

## ▢️ Usage

1. Open `http://localhost:3000` in your browser
2. **Upload** your PDF or DOCX file
3. **Select** print settings (paper size, color, duplex, quantity)
4. **Review** price estimate and **proceed** to payment
5. **Track** your order status on the dashboard
6. **Receive** email notification when ready

---

## πŸ“ Repository Structure

```plaintext
/printify
β”œβ”€β”€ components/
β”‚ β”œβ”€β”€ ProtectedRoutes.tsx
β”‚ β”œβ”€β”€ constants/
β”‚ β”‚ β”œβ”€β”€ admin-sidebar.ts
β”‚ β”‚ β”œβ”€β”€ customer-sidebar.ts
β”‚ β”‚ β”œβ”€β”€ hero.ts
β”‚ β”‚ └── navbar.ts
β”‚ β”œβ”€β”€ hooks/
β”‚ β”‚ └── useWebSockets.tsx
β”‚ β”œβ”€β”€ layout/
β”‚ β”‚ β”œβ”€β”€ Footer.tsx
β”‚ β”‚ └── Navbar.tsx
β”œβ”€β”€ lib/
β”‚ β”œβ”€β”€ auth.ts
β”‚ └── prisma.ts
β”œβ”€β”€ public/
β”‚ β”œβ”€β”€ file.svg
β”‚ β”œβ”€β”€ globe.svg
β”‚ β”œβ”€β”€ next.svg
β”‚ β”œβ”€β”€ printify_logo.png
β”‚ β”œβ”€β”€ vercel.svg
β”‚ └── window.svg
β”œβ”€β”€ prisma/
β”‚ β”œβ”€β”€ schema.prisma
β”‚ └── migrations/
β”‚ β”œβ”€β”€ migration_lock.toml
β”‚ β”œβ”€β”€ 20250605034628_init/
β”‚ β”‚ └── migration.sql
β”‚ β”œβ”€β”€ 20250605100725_init/
β”‚ β”‚ └── migration.sql
β”‚ β”œβ”€β”€ 20250605101251_init/
β”‚ β”‚ └── migration.sql
β”‚ └── 20250607093243_init/
β”‚ └── migration.sql
β”œβ”€β”€ src/
β”‚ β”œβ”€β”€ middleware.ts
β”‚ β”œβ”€β”€ app/
β”‚ β”‚ β”œβ”€β”€ favicon.ico
β”‚ β”‚ β”œβ”€β”€ globals.css
β”‚ β”‚ β”œβ”€β”€ providers.tsx
β”‚ β”‚ β”œβ”€β”€ (auth)/
β”‚ β”‚ β”‚ β”œβ”€β”€ layout.tsx
β”‚ β”‚ β”‚ β”œβ”€β”€ login/
β”‚ β”‚ β”‚ β”‚ β”œβ”€β”€ login.tsx
β”‚ β”‚ β”‚ β”‚ └── page.tsx
β”‚ β”‚ β”‚ β”œβ”€β”€ register/
β”‚ β”‚ β”‚ β”‚ β”œβ”€β”€ page.tsx
β”‚ β”‚ β”‚ β”‚ └── register.tsx
β”‚ β”‚ β”‚ └── verify/
β”‚ β”‚ β”‚ β”œβ”€β”€ page.tsx
β”‚ β”‚ β”‚ └── verify-otp.tsx
β”‚ β”‚ β”œβ”€β”€ (landing)/
β”‚ β”‚ β”‚ β”œβ”€β”€ landing-page.tsx
β”‚ β”‚ β”‚ β”œβ”€β”€ layout.tsx
β”‚ β”‚ β”‚ └── page.tsx
β”‚ β”‚ β”œβ”€β”€ (protected)/
β”‚ β”‚ β”‚ β”œβ”€β”€ layout.tsx
β”‚ β”‚ β”‚ β”œβ”€β”€ sidebar.tsx
β”‚ β”‚ β”‚ β”œβ”€β”€ admin/
β”‚ β”‚ β”‚ β”‚ β”œβ”€β”€ page.tsx
β”‚ β”‚ β”‚ β”‚ β”œβ”€β”€ analytics/
β”‚ β”‚ β”‚ β”‚ β”‚ └── page.tsx
β”‚ β”‚ β”‚ β”‚ β”œβ”€β”€ orders/
β”‚ β”‚ β”‚ β”‚ β”‚ └── page.tsx
β”‚ β”‚ β”‚ β”‚ β”œβ”€β”€ settings/
β”‚ β”‚ β”‚ β”‚ β”‚ └── page.tsx
β”‚ β”‚ β”‚ β”‚ └── users/
β”‚ β”‚ β”‚ β”‚ └── page.tsx
β”‚ β”‚ β”‚ └── customer/
β”‚ β”‚ β”‚ β”œβ”€β”€ page.tsx
β”‚ β”‚ β”‚ β”œβ”€β”€ new/
β”‚ β”‚ β”‚ β”‚ └── page.tsx
β”‚ β”‚ β”‚ β”œβ”€β”€ orders/
β”‚ β”‚ β”‚ β”‚ └── page.tsx
β”‚ β”‚ β”‚ └── profile/
β”‚ β”‚ β”‚ └── page.tsx
β”‚ β”‚ └── api/
β”‚ β”‚ β”œβ”€β”€ auth/
β”‚ β”‚ β”‚ β”œβ”€β”€ [...nextauth]/
β”‚ β”‚ β”‚ β”‚ └── route.ts
β”‚ β”‚ β”‚ └── action/
β”‚ β”‚ β”‚ └── [action]/
β”‚ β”‚ β”‚ └── route.ts
β”œβ”€β”€ services/
β”‚ β”œβ”€β”€ _axios.ts
β”‚ └── Auth.ts
β”œβ”€β”€ skeletons/
β”œβ”€β”€ types/
β”‚ └── useWebSocketsTypes.ts
β”œβ”€β”€ utils/
β”‚ β”œβ”€β”€ otpCache.ts
β”‚ └── send-email.ts
β”œβ”€β”€ .env.local
β”œβ”€β”€ README.md
β”œβ”€β”€ eslint.config.mjs
β”œβ”€β”€ next-auth.d.ts
β”œβ”€β”€ next-env.d.ts
β”œβ”€β”€ next.config.ts
β”œβ”€β”€ package.json
β”œβ”€β”€ pnpm-lock.yaml
β”œβ”€β”€ pnpm-workspace.yaml
β”œβ”€β”€ postcss.config.mjs
β”œβ”€β”€ tsconfig.json
```

---

## 🀝 Contributing

1. Fork the repository
2. Create a new branch: `git checkout -b feature/YourFeature`
3. Commit your changes: `git commit -m 'Add YourFeature'`
4. Push to the branch: `git push origin feature/YourFeature`
5. Open a Pull Request

Please ensure your code follows the existing style and includes tests where applicable.

---

## πŸ“„ License

This project is licensed under the [MIT License](./LICENSE).