RideFlow is a production-style peer-to-peer mobility platform that enables users to list, discover, and book vehicles in real time.
The platform is engineered using modern full-stack technologies and cloud-native deployment patterns, featuring secure JWT authentication, Google OAuth, live booking workflows, scalable media uploads, role-based user management, and AWS-based production deployment architecture.
Built to simulate real-world distributed systems challenges such as booking concurrency, async workflows, authentication security, cloud storage, and scalable API communication.
- JWT-based authentication and protected API routes
- Google OAuth integration
- Real-time booking lifecycle management
- Booking overlap prevention and concurrency handling
- Cloud-based image upload pipeline using Cloudinary
- AWS deployment architecture (S3 + CloudFront + Elastic Beanstalk)
- Role-based access control
- RESTful API architecture
- Responsive React frontend
- Secure environment-based configuration
- Scalable MERN stack architecture
- Transaction and simulated wallet infrastructure (demo ledger, not production payments)
ββββββββββββββββββββββββ
β React Frontend β
β Rider / Owner UI β
βββββββββββ¬βββββββββββββ
β
β HTTPS / REST APIs
βΌ
ββββββββββββββββββββββββ
β Node.js Backend β
β Express REST API β
βββββββββ¬ββββββββ¬ββββββ
β β
β β
βββββββββββββββΌβββ β
β MongoDB β β
β Users/Bookings β β
ββββββββββββββββββ β
β
βββββββββββββββββΌβββββββββββββ
β Cloudinary Media Storage β
β Vehicle/Profile Uploads β
ββββββββββββββββββββββββββββββ
AWS Deployment Layer
βββββββββββββββββββββββββββββββββββββββββββββ
Frontend β S3 + CloudFront
Backend β Elastic Beanstalk / ECS
Secrets β AWS Secrets Manager
DNS β Route53Implemented booking overlap validation so conflicting pickup/drop-off windows cannot be confirmed for the same vehicle, reducing double-booking risk in a request-based workflow.
Integrated JWT for authenticated API access together with Google OAuth on the client; sensitive routes use middleware-backed authorization.
Delegated vehicle and profile images to Cloudinary instead of storing binary assets on the application server, keeping the API stateless and upload throughput scalable.
Documented and aligned the codebase with an AWS-shaped deployment path: static frontend on S3 behind CloudFront, Node API on Elastic Beanstalk (or ECS), secrets externalized, DNS via Route 53.
Separate flows for renters, vehicle owners (listing and rental requests), and admin-side verification review for optional identity checks.
- React
- JavaScript
- Tailwind CSS
- Axios
- React Router
- Node.js
- Express.js
- JWT authentication
- Google OAuth (token exchange via backend)
- REST APIs
- Mongoose
- MongoDB (Atlas recommended for production)
- AWS S3
- AWS CloudFront
- AWS Elastic Beanstalk
- Route 53
- Docker (planned)
- GitHub Actions (planned)
- Cloudinary
- Google OAuth APIs
- Node.js (LTS)
- MongoDB (Atlas or local URI)
- Google Cloud OAuth Web Client ID
- Cloudinary cloud name and unsigned upload preset
From the repository root:
npm run install:allBackend β backend/.env:
MONGODB_URI=mongodb://localhost:27017/rideflow
JWT_SECRET=your_long_random_secret
PORT=5000
GOOGLE_CLIENT_ID=your_id.apps.googleusercontent.com
FRONTEND_URL=http://localhost:3000Frontend β frontend/.env:
REACT_APP_API_URL=http://localhost:5000
REACT_APP_GOOGLE_CLIENT_ID=your_id.apps.googleusercontent.com
REACT_APP_CLOUDINARY_CLOUD_NAME=your_cloud_name
REACT_APP_CLOUDINARY_UPLOAD_PRESET=your_unsigned_presetRun:
npm run dev| URL | Role |
|---|---|
| http://localhost:3000 | React UI |
| http://localhost:5000 | Express API |
| Command | Description |
|---|---|
npm run dev |
Backend + frontend development servers |
npm run dev:backend |
Backend only |
npm run start:frontend |
Frontend only |
npm run install:all |
Install dependencies at root, backend, and frontend |
Representative REST surface (all prefixed by your deployed API origin, e.g. https://api.example.com).
| Method | Path | Notes |
|---|---|---|
POST |
/api/auth/google-login |
Google OAuth sign-in / signup |
POST |
/api/auth/complete-profile |
Finish profile after OAuth (protected) |
GET |
/api/auth/me |
Current user (protected) |
PATCH |
/api/auth/profile |
Update profile (protected) |
POST |
/api/auth/upload-profile-picture |
Profile image (protected) |
POST |
/api/auth/upload-citizenship |
Optional ID upload (protected) |
GET |
/api/auth/pending-verifications |
Admin: pending reviews (protected) |
POST |
/api/auth/verify-user/:userId |
Admin: approve/reject (protected) |
| Method | Path | Notes |
|---|---|---|
GET |
/api/vehicles |
Public marketplace list |
POST |
/api/vehicles/add |
Create listing (protected) |
GET |
/api/vehicles/my-vehicles |
Owner inventory (protected) |
PATCH |
/api/vehicles/:vehicleId/status |
Active / inactive (protected) |
DELETE |
/api/vehicles/:vehicleId |
Delete listing (protected) |
| Method | Path | Notes |
|---|---|---|
POST |
/api/bookings |
Create booking request (protected) |
GET |
/api/bookings/user |
Renter bookings (protected) |
GET |
/api/bookings/owner |
Owner rental requests (protected) |
GET |
/api/bookings/:bookingId |
Booking detail (protected) |
PATCH |
/api/bookings/:bookingId/status |
Owner confirm/reject (protected) |
PATCH |
/api/bookings/:bookingId/cancel |
Cancel flow (protected) |
| Method | Path | Notes |
|---|---|---|
POST |
/api/payment/demo |
Process simulated wallet payment (protected) |
GET |
/api/payment/booking/:bookingId |
Payment by booking (protected) |
GET |
/api/payment/user/history |
Transaction history (protected) |
POST |
/api/payment/refund/:paymentId |
Refund marker for demos (protected) |
DELETE |
/api/payment/user/clear-history |
Clear visible history (protected) |
| Method | Path | Notes |
|---|---|---|
GET |
/api/recommendations/:userId |
Personalized vehicle suggestions |
| Method | Path | Notes |
|---|---|---|
GET |
/api/health |
Liveness check |
RideFlow maps cleanly onto AWS: MongoDB Atlas for data (recommended), S3 + CloudFront for the React production build, and Elastic Beanstalk or ECS Fargate for the Express API. Use Route 53 for DNS and Secrets Manager or SSM Parameter Store for JWT_SECRET, MONGODB_URI, and OAuth configuration.
Typical steps
- Provision Atlas; allow outbound from your compute tier; inject
MONGODB_URIvia secrets. - Deploy the backend with environment variables (
PORT,JWT_SECRET,GOOGLE_CLIENT_ID,FRONTEND_URLpointing at your CloudFront URL). - Build the frontend with
REACT_APP_API_URLset to the API URL; uploadfrontend/buildto S3; front it with CloudFront (SPA fallback toindex.html). - Register OAuth origins for CloudFront and API URLs in Google Cloud Console.
- Replace simulated wallet infrastructure with a regulated payment provider before accepting real funds.
Planned production-scale enhancements:
- Redis caching for hot reads and session-adjacent data
- WebSocket-based real-time notifications
- Queue-backed async jobs (e.g. BullMQ)
- Dockerized services and repeatable environments
- Kubernetes orchestration for multi-service scale-out
- CI/CD with GitHub Actions
- Distributed booking and payment event processing
- Payment gateway integration (e.g. Stripe)
- Observability with Prometheus / Grafana
Landing is captured from the running app (Google sign-in entry). Vehicles, booking, and wallet images are high-fidelity UI previews aligned with the shipped screens; those routes are behind authentication, so they were rendered for documentation consistencyβswap in your own captures anytime from /vehicles, /book-now, and /transactions (or dashboard wallet tab) after signing in.
rideflow/
βββ backend/ Express API, Mongoose models, middleware
βββ frontend/ React SPA
βββ Documentation/ Extended references (optional)
Deep dives: Documentation/.
Coursework / portfolio demonstration β adapt the license for your distribution needs.
Remote: github.com/samarth1412/RideFlow



