CareerFit is a platform designed to assist fresh graduates in finding jobs by analyzing their CVs and providing insightful reviews. This backend API powers the CareerFit platform by handling user authentication, CV analysis, job recommendations, and more.
- Access the Platform: CareerFit Platform
- Job Search: Search for job CV.
- Matching with Jobs: Matches user CVs with relevant job listings based on skills, experience, and qualifications.
- CV Scoring & Weaknesses: Provides a score for each CV based on its match with job descriptions, along with feedback on areas for improvement.
- Latest Job Listings: Offers real-time job updates, categorized by industry and role, to help users stay up-to-date with the job market.
- Scrollable Job Feed: Users can scroll through available jobs with filtering options to narrow down their search.
- Personalized Recommendations: Sends tailored job alerts and notifications based on the user's profile and preferences.
- Setup and Installation Frontend
- Project Structure
- Technologies Used Frontend
- API Integration with Backend
Installation Steps:
-
Clone the repository:
git clone https://github.com/Safi222/CareerFit cd CareerFit/client
-
Install dependencies:
npm install
-
Start the server:
npm run dev
Components:
Slogan
: Displays the website slogan.Login
: Handles user authentication.Register
: For new user registration.Search
: Enables job searches.Value
: Highlights the application's core values.AboutUs
: Provides information about the team and project.Footer
: Includes links, copyright details, and contact information.Jobs
: Displays job listings.Profile
: Provides an overview of user activity and stats.CVPilot
: Helps users build and upload their CVs.
- React.js: For building user interfaces.
- Vite: A fast build tool and development server.
- Tailwind CSS: For efficient and modern styling.
The frontend is integrated with the backend API to support:
- User authentication and authorization
- Job searching and listing
- CV upload and analysis
- User dashboard with analytics
- Ensure the backend server is running at the specified port for API requests.
- Node.js (>= 14.x)
- MongoDB
- Redis
-
Clone the repository:
git clone https://github.com/Safi222/CareerFit cd CareerFit/server
-
Install dependencies:
npm install
-
Start the server:
npm start
POST /auth/register
Request Body:
{
"firstName": "John",
"lastName": "Doe",
"email": "[email protected]",
"password": "password123"
}
Response:
- Success (201):
{ "status": "success", "data": { "token": "<jwt-token>" } }
- Error (400): Email already in use.
POST /auth/login
Request Body:
{
"email": "[email protected]",
"password": "password123"
}
Response:
- Success (200):
{ "status": "success", "data": { "token": "<jwt-token>" } }
- Error (404): User not found.
- Error (400): Incorrect password.
GET /auth/google
Description: Redirects to Google for authentication.
GET /auth/google/callback
Description: Handles Google OAuth callback and returns a token.
GET /cv/analyze
Headers:
{
"Authorization": "Bearer <jwt-token>"
}
Response:
- Success (200):
{ "status": "success", "data": { "recommendation": ["Software Engineer", "Data Analyst"] } }
- Error (404): CV not found.
GET /jobs/home
Query Parameters:
query
(string, optional): Search query.page
(number, optional): Page number.num_pages
(number, optional): Number of pages to fetch.
Response:
- Success (200):
{ "status": "success", "data": { "jobs": [ { "title": "Software Engineer", "location": "Cairo" } ] } }
- Error (500): Failed to fetch jobs.
GET /jobs/search
Query Parameters:
title
,location
,type
,level
(all optional): Filters for job search.page
,num_pages
(optional): Pagination.
Response: Similar to /jobs/home
.
POST /user/profile-picture
Headers:
{
"Authorization": "Bearer <jwt-token>"
}
Form Data:
profilePic
: File upload (image).
Response:
- Success (200):
{ "status": "success", "data": { "profilePic": "<image-url>" } }
POST /user/cv
Headers: Same as /user/profile-picture
.
Form Data:
cvFile
: File upload (PDF).
Response:
- Success (200): CV uploaded successfully.
GET /user/profile
Headers: Same as /user/profile-picture
.
Response:
- Success (200):
{ "status": "success", "data": { "user": { "firstName": "John", "lastName": "Doe", "email": "[email protected]" } } }
Errors are returned in the following format:
{
"status": "fail",
"data": {
"title": "Error message"
}
}
- Node.js
- Express.js
- MongoDB
- Redis
- Cloudinary
- Passport.js for authentication
- Bull for background processing