
Mock Orbit is an end-to-end peer interviewing platform designed to simulate real-world interview scenarios through an interactive and scalable interface. It combines a modern Next.js frontend with Tailwind CSS (using CDN integration) with a robust Golang backend, leveraging MongoDB for data storage and authentication. With support for real-time interviews, scheduling, and collaboration, Mock Orbit is built for performance and real-world usability.
- Mock Orbit - A Peer Interviewing Application
Mock Orbit is built to facilitate immersive and realistic peer interviews. Featuring dual dashboards to cater to both interviewers and interviewees, the platform streamlines interview scheduling, real-time communication, and performance tracking, all while maintaining a secure and scalable architecture.
Key functionalities include:
- Real-time Interview Rooms: Integrated video/audio communication, a collaborative whiteboard, chat, and code editor.
- User Management: Seamless profile creation and management.
- Scheduling: Intuitive calendar-based scheduling with notifications.
- Robust Authentication: Secure user registration, login, and authorization using JWT.
- Dual Dashboards:
- Interviewer Dashboard: View scheduled interviews, performance stats, and provide feedback.
- Interviewee Dashboard: Access upcoming interviews, preparation materials, and interview history.
- Real-time Interview Environment:
- Video & Audio Communication: Powered by WebRTC.
- Collaborative Whiteboard: Real-time drawing and annotations using the Canvas API.
- Chat System: Instant messaging with WebSocket integration.
- Code Editor: Integrated environment for collaborative coding.
- Profile Management: Update personal details, manage roles, and view interview logs.
- Scheduling Interface: Calendar-based interview scheduling with real-time notifications.
- Secure API Integration: Comprehensive RESTful endpoints powered by JWT for protected access.
- Framework: Next.js (Latest version) with TypeScript
- Styling: Tailwind CSS (integrated via CDN)
- Routing: Next.js App Router with server components
- State Management: React Context (or Redux as needed)
- Data Fetching: React Query
- Form Handling: react-hook-form with Zod validation
- Language & Framework: Golang with Gin for RESTful API
- Real-Time Communication: WebSockets
- Video Signaling: pion/webrtc for WebRTC-based interactions
- Authentication: JWT with middleware for secure sessions
- Database: MongoDB for storage, pub/sub notifications, and presence tracking
The project is organized with feature-based modules that promote maintainability and scalability. The frontend follows atomic design principles, ensuring that UI components, hooks, and utilities are neatly modularized. The Golang backend embraces clean architecture by separating configuration, database logic, models, handlers, middleware, and routing.
MockOrbit/
├── README.md
├── components.json
├── next.config.ts
├── package.json
├── postcss.config.mjs
├── tailwind.config.ts
├── tsconfig.json
├── .env.example
├── .modified
├── backend/
│ ├── go.mod
│ ├── go.sum
│ ├── cmd/
│ │ └── server/
│ │ ├── main.go
│ │ └── .env.example
│ └── internal/
│ ├── config/
│ │ └── config.go
│ ├── database/
│ │ └── mongo.go
│ ├── handlers/
│ │ ├── auth_handlers.go
│ │ ├── interview_handlers.go
│ │ ├── user_handlers.go
│ │ └── websocket_handler.go
│ ├── middleware/
│ │ └── auth.go
│ ├── models/
│ │ └── models.go
│ └── routes/
│ └── routes.go
├── docs/
│ └── blueprint.md
└── src/
├── ai/
│ ├── ai-instance.ts
│ └── dev.ts
├── app/
│ ├── globals.css
│ ├── layout.tsx
│ ├── page.tsx
│ ├── auth/
│ │ ├── login/
│ │ │ └── page.tsx
│ │ └── register/
│ │ └── page.tsx
│ ├── dashboard/
│ │ ├── interviewee/
│ │ │ └── page.tsx
│ │ └── interviewer/
│ │ └── page.tsx
│ ├── interview-room/
│ │ └── [id]/
│ │ └── page.tsx
│ ├── profile/
│ │ └── page.tsx
│ ├── question-generator/
│ │ └── page.tsx
│ └── schedule/
│ └── page.tsx
├── components/
│ ├── shared/
│ │ └── AppLayout.tsx
│ └── ui/
│ ├── accordion.tsx
│ ├── alert-dialog.tsx
│ ├── alert.tsx
│ ├── avatar.tsx
│ ├── badge.tsx
│ ├── button.tsx
│ ├── calendar.tsx
│ ├── card.tsx
│ ├── chart.tsx
│ ├── checkbox.tsx
│ ├── dialog.tsx
│ ├── dropdown-menu.tsx
│ ├── form.tsx
│ ├── input.tsx
│ ├── label.tsx
│ ├── menubar.tsx
│ ├── popover.tsx
│ ├── progress.tsx
│ ├── radio-group.tsx
│ ├── scroll-area.tsx
│ ├── select.tsx
│ ├── separator.tsx
│ ├── sheet.tsx
│ ├── sidebar.tsx
│ ├── skeleton.tsx
│ ├── slider.tsx
│ ├── switch.tsx
│ ├── table.tsx
│ ├── tabs.tsx
│ ├── textarea.tsx
│ ├── toast.tsx
│ ├── toaster.tsx
│ └── tooltip.tsx
├── hooks/
│ ├── use-mobile.tsx
│ └── use-toast.ts
├── lib/
│ └── utils.ts
└── providers/
├── AuthProvider.tsx
└── ReactQueryProvider.tsx
- Node.js & npm/yarn: For the Next.js frontend.
- Go: Version 1.18+ for running the backend.
- MongoDB: A running MongoDB instance (local or via Docker).
- Git: For source control.
-
Clone the Repository:
git clone https://github.com/adityaxanand/MockOrbit.git cd MockOrbit
-
Install Dependencies:
npm install # or yarn install
-
Configure Environment Variables:
cp .env.example .env
-
Run the Development Server:
npm run dev # or yarn dev
Access the app at http://localhost:3000.
-
Navigate to the Backend Directory:
cd backend
-
Install Go Modules:
go mod tidy
-
Configure Environment Variables:
cp cmd/server/.env.example cmd/server/.env
Adjust the MongoDB connection string, port, JWT secrets, and other parameters as needed.
-
Run the Server:
go run cmd/server/main.go
The server will start (typically on port 8080). Test with:
curl http://localhost:8080/ping
-
Local MongoDB: Ensure your MongoDB server is running.
-
Docker Option:
docker run --name mockorbit-mongo -p 27017:27017 -d mongo:latest
The backend exposes several endpoints:
-
Ping:
GET /ping
– Returns a simple status message.
-
Authentication:
POST /api/v1/auth/register
– Register a new user.POST /api/v1/auth/login
– Login and receive a JWT.
-
User Management (Protected):
GET /api/v1/users/profile
– Retrieve current user’s profile.PATCH /api/v1/users/profile
– Update profile details.GET /api/v1/users/peers
– List peer users.GET /api/v1/users/:userId/interviews
– Get interviews for a specific user.GET /api/v1/users/:userId/stats
– (Interviewer only) Retrieve performance stats.
-
Interview Management (Protected):
POST /api/v1/interviews
– Schedule a new interview.GET /api/v1/interviews/:interviewId
– Get interview details.
-
Utility Endpoints (Protected):
GET /api/v1/topics
– Retrieve available topics.GET /api/v1/availability
– Get available interview slots.
-
Real-Time Communication:
GET /ws
– WebSocket endpoint for chat and collaboration.
Remember to include your JWT in the request headers when accessing protected routes.
Use these credentials for testing:
-
Interviewer:
- Email:
[email protected]
- Password:
interview123
- Email:
-
Interviewee:
- Email:
[email protected]
- Password:
interview123
- Email:
These are demo credentials; please update them in a production environment.
-
Frontend: Deployed on Vercel.
-
Backend: Containerized using Docker and deployed on your chosen cloud provider. Use CI/CD pipelines (GitHub Actions, GitLab CI, etc.) for automated testing, building, and deployment.
- Frontend Testing: Use Jest and React Testing Library for unit and integration tests.
- Backend Testing: Write unit tests for API endpoints and middleware.
- Monitoring: Implement logging, error tracking, and health checks to monitor application status.
This project is licensed under the MIT License.
Happy Interviewing!