A smart MERN-powered web application that suggests perfect activities based on weather, mood, and categories. Built using React, Node.js, Express, and MongoDB, with real-time weather data and dynamic UI.
- React.js
- JavaScript (ES6+)
- CSS
- Vite
- Node.js
- Express.js
- MongoDB
- Mongoose
- Nodemon (Dev)
/client -> React Frontend
/server -> Node + Express Backend
git clone https://github.com/YOUR-USERNAME/YOUR-REPO-NAME.git
cd YOUR-REPO-NAMEcd client
npm install
npm run devCreate a .env file inside /server:
MONGO_URI=mongodb://127.0.0.1:27017/activity_suggestor
PORT=5000
CORS_ORIGIN=http://localhost:5173
WEATHER_API_KEY=YOUR_OPENWEATHER_API_KEY
Then run:
cd server
npm install
npm run dev| Variable | Description |
|---|---|
MONGO_URI |
MongoDB local/Atlas URL |
PORT |
Server port (default: 5000) |
CORS_ORIGIN |
Allowed frontend URL |
WEATHER_API_KEY |
OpenWeather API key for weather-based suggestions |
- 🌤 Get activity suggestions based on live weather
- 👍 Suggest random or category-wise activities
- 🎨 Clean and responsive UI built with React
- 🔄 Real-time API communication using Axios
- 🗄 MongoDB storage for activities
- ⚡ Fast backend with Express.js
- 🔐 Secure environment variable usage
| Method | Endpoint | Description |
|---|---|---|
| GET | /api/activities |
Get all activities |
| POST | /api/activities |
Add a new activity |
| GET | /api/activities/random |
Get a random activity |
| GET | /api/weather/:city |
Get weather data for the selected city |
You can deploy this project using:
- Frontend → Vercel / Netlify
- Backend → Render / Railway / Cyclic
- Database → MongoDB Atlas
Deployment guide will depend on the platform you choose.
Pull requests are welcome. For major changes, please open an issue first.
This project is open-source and available under the MIT License.
Bishal Bhandari Frontend Developer | React.js | JavaScript