Skip to content

PrafulK99/clent

Repository files navigation

Clent

Stop writing proposals from scratch.

Clent is a SaaS tool that streamlines client intake for freelancers and agencies. Collect project requirements via structured, shareable forms, instantly generate polished proposals using AI, and export them as client-ready PDFs — all from one dashboard.


✨ Features

  • Custom Intake Forms — Build structured questionnaires tailored to your services. Share a unique public link with clients; no account required on their end.
  • AI-Powered Proposal Generation — Turn client responses into a polished, professional proposal draft in seconds, powered by Google Gemini.
  • PDF Export — Export finalized proposals as clean, client-ready PDFs instantly.
  • Submissions Dashboard — All client responses stay organized in one place, linked to the form that created them.
  • Proposals Tracker — Manage proposals across DRAFT and FINAL statuses.
  • Authentication — Secure sign-up/sign-in via Supabase Auth (email/password).
  • Free-tier & Plan Support — Built-in user plan tracking to support freemium or paid tiers.

🛠 Tech Stack

Layer Technology
Framework Next.js 16 (App Router)
Language TypeScript
Styling Tailwind CSS v4 + tw-animate-css
UI Components Radix UI + shadcn/ui conventions
Animations Framer Motion
Auth Supabase Auth + @supabase/ssr
Database PostgreSQL (via Supabase)
ORM Prisma 7
AI Google Gemini (@google/genai)
PDF Generation pdf-lib, pdfkit, pdfmake
Icons Lucide React

🗄 Database Schema

User → Form → Question
            ↓
         Submission → Answer
                    ↓
                 Proposal
  • User — Linked to a Supabase auth account; tracks plan (free / paid).
  • Form — A set of intake questions; has a unique public URL (publicId).
  • Question — Supports TEXT, TEXTAREA, EMAIL, and SELECT types.
  • Submission — A client's response to a form, including optional name/email.
  • Answer — Snapshot of each question label + value at submission time.
  • Proposal — AI-generated content tied to a submission; status: DRAFT or FINAL.

🚀 Getting Started

Prerequisites

  • Node.js ≥ 18
  • A Supabase project (for auth + database)
  • A Google Gemini API key

1. Clone the repository

git clone <your-repo-url>
cd clent

2. Install dependencies

npm install

3. Configure environment variables

Create a .env.local file in the project root:

# Supabase
NEXT_PUBLIC_SUPABASE_URL=your_supabase_project_url
NEXT_PUBLIC_SUPABASE_ANON_KEY=your_supabase_anon_key
SUPABASE_SERVICE_ROLE_KEY=your_supabase_service_role_key

# Database (PostgreSQL connection string from Supabase)
DATABASE_URL=your_postgresql_connection_string

# Google Gemini
GEMINI_API_KEY=your_gemini_api_key

4. Run Prisma migrations

npx prisma migrate dev

5. Start the development server

npm run dev

Open http://localhost:3000 in your browser.


📁 Project Structure

clent/
├── app/
│   ├── (auth)/          # Sign-in / Sign-up pages
│   ├── dashboard/       # Protected dashboard (forms, submissions, proposals, settings)
│   ├── f/               # Public form submission pages (/f/[publicId])
│   └── api/             # API route handlers
├── components/
│   ├── landing/         # Landing page sections (Hero, HowItWorks, Benefits, etc.)
│   ├── dashboard/       # Dashboard UI components
│   ├── forms/           # Form builder & public form components
│   ├── proposals/       # Proposal viewer & generator components
│   └── ui/              # Base UI primitives (Button, Dropdown, Tooltip…)
├── lib/
│   ├── auth/            # Auth server actions & session helpers
│   ├── submissions/     # Submission server actions & queries
│   ├── supabase/        # Supabase client factories (browser, server, admin)
│   └── db.ts            # Prisma client singleton
└── prisma/
    └── schema.prisma    # Database schema

🔁 How It Works

  1. Create an intake form — Build a structured form with custom questions from the dashboard.
  2. Share the link — Send your client a unique public URL. They fill it out once; no signup needed.
  3. Generate & export the proposal — Clent feeds the responses to Gemini AI, generates a clean proposal, and lets you export it as a PDF.

📜 Available Scripts

Command Description
npm run dev Start the development server
npm run build Build for production
npm run start Start the production server
npm run lint Run ESLint
npm run format Format code with Prettier

🙌 Who It's For

Clent is built for freelancers, consultants, and small agencies who:

  • Write proposals regularly for clients
  • Want client inputs organized before drafting
  • Need professional, polished proposals without the manual grind
  • Want a repeatable workflow that gets better over time

📄 License

Private — all rights reserved.

About

AI powered client onboarding and proposal builder

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors