Skip to content

RajviDhameliya/Fitness-App

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 

Repository files navigation

Chat-Based Personal Fitness Trainer

A MERN stack fitness coach with a chat assistant (Gemini), workout logging, and progress tracking.

Features

  • Landing, authentication, and onboarding flows
  • Dashboard with workout logs and progress charts (Recharts)
  • Floating chat widget connected to Gemini
  • Profile settings and onboarding reset
  • MongoDB persistence for users, logs, and chat history

Tech Stack

  • Frontend: React + Vite + Tailwind CSS
  • Backend: Node.js + Express + Mongoose
  • Database: MongoDB
  • AI: Google Gemini API

Project Structure

client/   # React frontend
server/   # Express backend

Setup

1) Backend

cd server
npm install

Create a .env in server/ (see .env.example):

PORT=5000
MONGO_URI=your_mongodb_uri
JWT_SECRET=your_jwt_secret
GEMINI_API_KEY=your_gemini_api_key
GEMINI_MODEL=models/gemini-2.5-flash
CLIENT_ORIGIN=http://localhost:5173

Run the API:

npm run dev

2) Frontend

cd client
npm install

Create client/.env:

VITE_API_URL=http://localhost:5000

Run the UI:

npm run dev

API Endpoints (Backend)

  • POST /api/auth/register - create account
  • POST /api/auth/login - login
  • GET /api/profile - get user profile
  • PUT /api/profile - update profile/goals/onboarding
  • POST /api/profile/reset - reset onboarding
  • POST /api/logs - create workout log
  • GET /api/logs - list workout logs
  • GET /api/progress - progress chart data
  • POST /api/gemini/chat - chat with Gemini
  • GET /api/gemini/history - chat history

Scripts

Backend:

  • npm run dev - start server with nodemon
  • npm start - start server

Frontend:

  • npm run dev - start Vite dev server
  • npm run build - production build

About

A MERN stack fitness coach with a chat assistant (Gemini), workout logging, and progress tracking.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages