A comprehensive biological data tracking application built with Next.js, deployed on Vercel, and using PostgreSQL database.
- Frontend & Backend: Next.js 15
- Database: PostgreSQL (compatible with any provider)
- Styling: Tailwind CSS with shadcn/ui components
- Authentication: Custom auth solution
- ORM: Drizzle ORM
- AI Integration: OpenAI and Mistral AI
- User Engagement: Loops
- Deployment: Vercel
- Node.js 20+ or Bun
- PostgreSQL database (Neon, Supabase, or any other PostgreSQL provider)
- OpenAI API key
- Mistral AI API key
- Loops API key
- Vercel account (for deployment)
Create a .env.local
file in the root directory with the following variables:
DATABASE_URL=your_postgresql_connection_string
OPENAI_API_KEY=your_openai_api_key
APP_SECRET=your_app_secret_for_general_encryption
APP_AUTH_SECRET=your_app_auth_secret_for_authentication
MISTRAL_API_KEY=your_mistral_api_key
LOOPS_API_KEY=your_loops_api_key
For APP_SECRET
and APP_AUTH_SECRET
, you can generate secure random strings using:
openssl rand -hex 32
- Clone the repository
git clone https://github.com/NoQuarterTeam/my-bio-tracker
cd my-bio-tracker
- Install dependencies
bun install
- Set up the database
Create a PostgreSQL database using any provider of your choice:
- Neon
- Supabase
- Railway
- Or any other PostgreSQL provider
- Get your connection string and add it to your
.env.local
file asDATABASE_URL
- Run database migrations
bun db:push
- Start the development server
bun dev
The application will be available at http://localhost:3000.
- Push schema changes:
bun db:push
- Generate migrations:
bun db:migrate
- Open Drizzle Studio:
bun db:studio
- Push your code to a GitHub repository
- Connect your repository to Vercel
- Add all environment variables in the Vercel project settings
- Deploy
- Create an account at OpenAI
- Generate an API key
- Add the key to your
.env.local
file asOPENAI_API_KEY
- Create an account at Mistral AI
- Generate an API key
- Add the key to your
.env.local
file asMISTRAL_API_KEY
- Create an account at Loops
- Generate an API key
- Add the key to your
.env.local
file asLOOPS_API_KEY
/src/app
- Next.js app router pages and API routes/src/components
- UI components using shadcn/ui/src/lib
- Utility functions and shared code/src/lib/server
- Server-side code including database schema and operations/public
- Static assets