{"id":22800778,"url":"https://github.com/aakashdixit22/talx-backend","last_synced_at":"2025-04-19T18:21:30.462Z","repository":{"id":257064521,"uuid":"857228274","full_name":"aakashdixit22/talx-backend","owner":"aakashdixit22","description":"The backend API for the Talx Job Portal, built with Node.js and Express.js. It provides robust features like job management 💼, secure authentication 🔐, email subscriptions 📧, news integration 📰, contact form handling 📑, and job application management 📄. Powered by MongoDB, it ensures a seamless experience for job seekers and employers alike.","archived":false,"fork":false,"pushed_at":"2024-12-06T18:18:07.000Z","size":88,"stargazers_count":2,"open_issues_count":0,"forks_count":2,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-03-29T11:34:37.889Z","etag":null,"topics":["expressjs","google-sheets-api","job-portal-backend","mongodb","mongoosejs","multer","newsapi","node-cron","nodejs","nodemailer","pdf-on-mongo"],"latest_commit_sha":null,"homepage":"https://job-portal-backend-nm6k.onrender.com","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/aakashdixit22.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-09-14T05:14:26.000Z","updated_at":"2025-03-29T08:22:36.000Z","dependencies_parsed_at":"2024-12-06T20:08:39.416Z","dependency_job_id":"3c0e6e1c-3a06-4861-900d-1b1d6638835c","html_url":"https://github.com/aakashdixit22/talx-backend","commit_stats":null,"previous_names":["aakashdixit22/job-portal-backend","aakashdixit22/talx-backend"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/aakashdixit22%2Ftalx-backend","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/aakashdixit22%2Ftalx-backend/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/aakashdixit22%2Ftalx-backend/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/aakashdixit22%2Ftalx-backend/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/aakashdixit22","download_url":"https://codeload.github.com/aakashdixit22/talx-backend/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":249761789,"owners_count":21321858,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["expressjs","google-sheets-api","job-portal-backend","mongodb","mongoosejs","multer","newsapi","node-cron","nodejs","nodemailer","pdf-on-mongo"],"created_at":"2024-12-12T08:07:55.025Z","updated_at":"2025-04-19T18:21:30.433Z","avatar_url":"https://github.com/aakashdixit22.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Talx-Backend 🚀\n\n**Visit Talx**: [https://talx.vercel.app/](https://talx.vercel.app/) \n\n**Talx-Backend** is the backend API for the **Job Portal** on the Talx Website. It provides job management, authentication, subscription, news integration, contact functionalities, and job application handling. The backend is built using **Node.js** and **Express.js** with a MongoDB database.\n\n---\n\n## Features ✨\n- **Job Management**: Post, update, delete, and fetch jobs. 💼\n- **Email Subscription**: Subscribe users to daily job updates 📧.\n- **Authentication**: JWT-based secure login and signup 🔐.\n- **News Integration**: Fetch news articles using the News API 📰.\n- **Contact Form**: Integrates Google Sheets for storing contact form submissions 📑.\n- **Job Applications**: Submit and manage job applications, including file uploads for resumes 📄.\n- **Keep-Alive Mechanism**: Ensures the server stays active using cron jobs 🕒.\n\n---\n\n## Prerequisites 🛠️\nEnsure you have the following installed:\n1. [Node.js](https://nodejs.org/) (v16+ recommended) 💻\n2. [npm](https://www.npmjs.com/) 🛒\n3. MongoDB (local or cloud setup, e.g., MongoDB Atlas) 🗃️\n\n---\n\n## Setup Instructions ⚙️\n\n### 1. Clone the Repository\n```bash\ngit clone https://github.com/aakashdixit22/talx-backend.git\ncd talx-backend\n```\n\n### 2. Install Dependencies\n```bash\nnpm install\n```\n\n### 3. Create a `.env` File\nCreate a `.env` file in the root directory with the following variables:\n\n```plaintext\nEMAIL_USER=\u003cyour_email_user\u003e\nEMAIL_PASS=\u003cyour_email_password\u003e\nBACKEND_URL=\u003cyour_backend_url\u003e\nJWT_SECRET=\u003cyour_jwt_secret\u003e\nNEWS_API_KEY=\u003cyour_news_api_key\u003e\nMONGODB_URI=\u003cyour_mongodb_uri\u003e\nSPREADSHEET_ID=\u003cyour_google_sheet_id\u003e\nTYPE=service_account\nPROJECT_ID=\u003cyour_google_project_id\u003e\nPRIVATE_KEY_ID=\u003cyour_private_key_id\u003e\nPRIVATE_KEY=\"-----BEGIN PRIVATE KEY-----\\n...\\n-----END PRIVATE KEY-----\"\nCLIENT_EMAIL=\u003cyour_google_client_email\u003e\nCLIENT_ID=\u003cyour_google_client_id\u003e\nAUTH_URI=https://accounts.google.com/o/oauth2/auth\nTOKEN_URI=https://oauth2.googleapis.com/token\nAUTH_PROVIDER_X509_CERT_URL=https://www.googleapis.com/oauth2/v1/certs\nCLIENT_X509_CERT_URL=\u003cyour_google_client_cert_url\u003e\n```\n\n**⚠️ Important**: Do not hard-code credentials or sensitive information in your code. Use `.env` files and keep them secure.\n\n### 4. Run the Server\nStart the server locally:\n```bash\nnode app.js\n```\n\n---\n\n## API Endpoints 🔌\n\n### General 🌐\n- **GET** `/`  \n  Default route. Responds with a welcome message. 👋\n- **GET** `/api/keepalive`  \n  Keep-alive route to prevent the server from sleeping. 💤\n\n---\n\n### Jobs (`/api/jobs`) 💼\n- **POST** `/post-job`  \n  Create a new job. This requires authentication. ✍️\n  \n- **GET** `/all-jobs`  \n  Fetch all jobs available in the portal. 🧐\n\n- **GET** `/myJobs/:email`  \n  Fetch all jobs posted by a specific user (requires authentication). 📬\n\n- **DELETE** `/delete-job/:jobId`  \n  Delete a job by its ID (requires authentication). 🗑️\n\n- **PUT** `/edit-job/:jobId`  \n  Edit a job by its ID (requires authentication). ✏️\n\n---\n\n### Email Subscriptions (`/api/subscribers`) 📧\n- **POST** `/subscribe`  \n  Subscribe an email for updates. 🔔\n\n---\n\n### Authentication (`/api/auth`) 🔐\n- **POST** `/signin`  \n  Login using email and password. 💼  \n- **POST** `/signupr`  \n  Register a new user. 📝\n\n---\n\n### Job Applications (`/api/jobApply`) 📄\n- **POST** `/apply/:jobId`  \n  Submit a job application for a specific job. This route accepts a file upload (`resume`) and form fields (`name`, `email`, `phone`, and `coverLetter`). 📝💼\n\n- **GET** `/my-applications/:email`  \n  Fetch all job applications submitted by a user, identified by their email address. The response includes job details for each application. 📂\n\n- **GET** `/applicants/:jobId`  \n  Retrieve all applications for a specific job. Requires authentication. 📑\n\n---\n\n### News (`/api/news`) 📰\n- **GET** `/news`  \n  Fetch news articles (supports query and category filters). 📜\n\n---\n\n### Contact Form (`/api/contact`) 📑\n- **POST** `/submit`  \n  Submit a contact form entry. The data is stored in a Google Sheet. 🖋️\n\n---\n\n## Technologies Used 🧰\n- **Node.js**: Backend runtime. 💻\n- **Express.js**: Web framework. ⚙️\n- **MongoDB**: Database. 🗃️\n- **Mongoose**: ODM for MongoDB. 🐱\n- **Cron**: Keep-alive job scheduling. ⏰\n- **Axios**: HTTP requests. 🌐\n- **Multer**: File uploads handling. 📤\n- **Nodemailer**: Email handling. 📧\n- **Google Sheets API**: For contact form storage. 📝\n\n---\n\n\n## 🔗 Related Repositories  \n\n1. **Talx Frontend (Main Platform)**  \n   - [talx-frontend](https://github.com/aakashdixit22/talx-frontend)  \n\n2. **Talx AI Backend**  \n   - [talx-backend](https://github.com/aakashdixit22/talx-api)  \n\n---\n\n## License 📝\nThis project is licensed under the [MIT License](https://github.com/aakashdixit22/talx-backend/blob/main/LICENSE).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Faakashdixit22%2Ftalx-backend","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Faakashdixit22%2Ftalx-backend","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Faakashdixit22%2Ftalx-backend/lists"}