Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
56 changes: 56 additions & 0 deletions QUICK_START.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,59 @@
# TaskFlow - Quick Start Guide

## What You Have

A fully functional, production-ready project management SaaS with:
- Database schema for projects, tasks, comments, attachments, and team management
- Complete REST API with 8+ endpoints
- Beautiful React UI with kanban board, analytics, and team collaboration
- Real-time activity tracking
- File upload capability with Vercel Blob
- Dark theme with responsive mobile design

## Essential Setup Steps

### 1. Verify Environment Variables
Check your Vercel project settings and ensure these are set:
- `DATABASE_URL` - Your Neon PostgreSQL connection string
- `BLOB_READ_WRITE_TOKEN` - Your Vercel Blob token
- `NEXT_PUBLIC_STACK_PROJECT_ID` - Your Stack project ID
- `NEXT_PUBLIC_STACK_PUBLISHABLE_CLIENT_KEY` - Your Stack publishable client key
- `STACK_SECRET_SERVER_KEY` - Your Stack server key

Optional helper command:
```bash
pnpm env:setup
# or to auto-bootstrap Vercel auth/link:
pnpm env:setup:auto
```
This scans the codebase, attempts autofetch from authenticated provider sessions (Vercel/Neon), then prompts for any remaining values before writing `.env.local`.
Helper keys used only for autofetch are excluded by default unless you pass `--include-agent-keys`.

For best automation:
```bash
pnpm dlx vercel login
pnpm dlx vercel link
# optional Neon API autofetch
export NEON_API_KEY=...
export NEON_PROJECT_ID=...
```

### 2. Database Ready
The database schema is already created in Neon with:
- All 6 tables set up
- Indexes for performance
- Foreign key relationships
- Ready for data

### 3. Start Development Server
```bash
pnpm dev
```

Then navigate to:
- **http://localhost:3000/dashboard** - Main app
- **http://localhost:3000/dashboard/projects** - Projects list
- **http://localhost:3000/dashboard/projects/[id]/tasks** - Kanban board
# CodeVault Backend - Quick Start Guide

## Prerequisites
Expand Down
74 changes: 74 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -116,6 +116,21 @@ Copy `.env.example` to `.env.local` and fill in your values:
cp .env.example .env.local
```

# Stack Auth
NEXT_PUBLIC_STACK_PROJECT_ID=...
NEXT_PUBLIC_STACK_PUBLISHABLE_CLIENT_KEY=...
# Optional compatibility alias used by some Stack integrations:
NEXT_PUBLIC_STACK_PUBLISHED_CLIENT_KEY=...
STACK_SECRET_SERVER_KEY=...
```

Or run the env setup agent:
```bash
pnpm env:setup
```
It scans your project, attempts provider autofetch from authenticated sessions, then prompts only for remaining values before writing `.env.local`.

4. **Run the development server**
4. **Set up the database**
Run the schema migration in your Neon console or with psql:
```bash
Expand All @@ -130,6 +145,65 @@ pnpm dev
6. **Access the application**
Open http://localhost:3000 in your browser

## Environment Setup Agent

This project includes a secure env setup agent at `scripts/env-agent.mjs`.

What it does:
- Detects env vars used in code and docs
- Suggests likely provider docs (Neon, Vercel Blob, Stack Auth, etc.)
- Attempts autofetch from authenticated sources:
- Current shell environment (`process.env`)
- Vercel project vars via `vercel env pull`
- Neon `DATABASE_URL` via Neon API or Neon CLI
- Auto-derives equivalent aliases for common key variants (for example Stack `PUBLISHABLE` / `PUBLISHED` key names)
- Prompts you for any missing values and writes `.env.local`

By default it excludes helper keys used only for autofetch (`NEON_API_KEY`, `NEON_PROJECT_ID`, etc.) so your project env file only contains app/runtime values.

What it does **not** do:
- It does not create API keys for you
- It does not bypass authentication or scrape secrets from websites
- For account-based retrieval, you must sign in through official provider auth flows

Autofetch prerequisites:
```bash
# For Vercel variables
pnpm dlx vercel login
pnpm dlx vercel link

# Optional for Neon API autofetch
export NEON_API_KEY=...
export NEON_PROJECT_ID=...
```

Commands:
```bash
# scan only (no file writes)
pnpm env:scan

# setup with autofetch + prompts (writes .env.local)
pnpm env:setup

# setup with autofetch + auto-bootstrap vercel auth/link when needed
pnpm env:setup:auto

# setup with prompts only (disable autofetch)
pnpm env:setup:manual

# pull from preview or a specific branch on Vercel
node scripts/env-agent.mjs --vercel-environment preview --vercel-git-branch main

# include helper keys used by autofetch logic
node scripts/env-agent.mjs --include-agent-keys

# enable automatic Vercel login/link bootstrap in CLI mode
node scripts/env-agent.mjs --bootstrap-vercel

# generate template file without prompts
node scripts/env-agent.mjs --template-only --non-interactive --output .env.example.generated
```

## API Endpoints

### Authentication
Expand Down
6 changes: 5 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,11 @@
"dev": "next dev",
"build": "next build",
"start": "next start",
"lint": "eslint ."
"lint": "eslint .",
"env:scan": "node scripts/env-agent.mjs --scan-only",
"env:setup": "node scripts/env-agent.mjs",
"env:setup:manual": "node scripts/env-agent.mjs --no-autofetch",
"env:setup:auto": "node scripts/env-agent.mjs --bootstrap-vercel"
},
"dependencies": {
"@anthropic-ai/sdk": "^0.82.0",
Expand Down
Loading
Loading