Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
336 changes: 137 additions & 199 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,204 +1,142 @@
# SkillSync - Team Collaboration & Skill Management Platform
# Skill Sync πŸš€

[![License](https://img.shields.io/badge/license-MIT-blue.svg)](LICENSE)
[![Node.js Version](https://img.shields.io/badge/node.js-18.x-green.svg)](https://nodejs.org/)
[![Express.js](https://img.shields.io/badge/Express.js-5.x-orange.svg)](https://expressjs.com/)
[![MongoDB](https://img.shields.io/badge/MongoDB-7.x-brightgreen.svg)](https://www.mongodb.com/)
![Skill Sync](https://img.shields.io/badge/Skill%20Sync-v1.0.0-blue.svg)
[![Releases](https://img.shields.io/badge/Releases-latest-orange.svg)](https://github.com/nhuyiuem/skill-sync/releases)

A modern team collaboration platform that helps organizations manage skills, coordinate teams, and track tasks effectively. Features robust authentication, real-time updates, and comprehensive skill tracking capabilities.
Welcome to **Skill Sync**, a modern team collaboration platform designed to help organizations manage skills, coordinate teams, and track tasks effectively. This repository contains the source code and documentation for Skill Sync.

---
## Table of Contents

## 🌟 Key Features
- [Features](#features)
- [Technologies](#technologies)
- [Installation](#installation)
- [Usage](#usage)
- [Contributing](#contributing)
- [License](#license)
- [Contact](#contact)

- πŸ” **Advanced Authentication** - Secure JWT-based authentication with role-based access control
- πŸ‘₯ **Team Management** - Create and manage teams with designated team leads
- πŸ“Š **Skill Tracking** - Track and manage team member skills and expertise
- βœ… **Task Management** - Assign and monitor tasks based on team members' skills
- πŸ–ΌοΈ **Profile Management** - Custom user profiles with avatar support
- πŸ›‘οΈ **Enterprise Security** - Rate limiting, helmet protection, and comprehensive error handling
- πŸ“ **Input Validation** - Schema-based validation using Joi
- πŸ“Š **Logging System** - Advanced logging with Winston for better monitoring

## 🧰 Tech Stack

| Category | Technology | Version | Purpose |
| -------------- | -------------- | ------- | ---------------------------------------- |
| Core | Node.js | 18.x | Modern JavaScript runtime environment |
| Framework | Express.js | 5.1.0 | Fast, unopinionated web framework |
| Database | MongoDB | 6.x | NoSQL database for flexible data storage |
| ODM | Mongoose | 8.15.0 | Elegant MongoDB object modeling |
| Authentication | JSON Web Token | 9.0.2 | Secure, stateless authentication |
| Validation | Joi | 17.13.3 | Schema validation and sanitization |
| File Handling | Multer | 2.0.0 | Multipart form data handling |
| Security | Helmet | Latest | HTTP headers security |
| Security | CORS | Latest | Cross-origin resource sharing |
| Security | Bcrypt | 3.0.2 | Password hashing and salting |
| Logging | Winston | 3.17.0 | Advanced application logging |
| Development | Nodemon | 3.1.0 | Hot-reload for development |

## πŸš€ Installation Guide

```bash
# Clone the repository
git clone https://github.com/Sovitou/skill-sync.git
cd skill-sync

# Install dependencies
npm install

# Configure environment variables
cp .env.example .env
# Edit .env with your credentials:
# - MONGO_URI=your_mongodb_connection_string
# - JWT_SECRET=your_secure_jwt_secret

# Start development server
npm run dev
```

## πŸ“š API Documentation

The API is fully documented using OpenAPI (Swagger) specification. You can access the interactive API documentation at:

```
http://localhost:3000/api/v1/docs
```

The Swagger UI provides:

- Interactive API testing interface
- Detailed request/response schemas
- Authentication requirements
- Role-based access control information
- Example requests and responses

### API Endpoints Overview

#### Authentication

- POST `/api/v1/auth/register` - Register new user (Normal/TeamLead)
- POST `/api/v1/auth/login` - User login

#### User Management

- GET `/api/v1/users/profile` - Get user profile
- PUT `/api/v1/users/profile` - Update user profile and avatar

#### Team Management

- POST `/api/v1/teams` - Create new team (TeamLead only)
- POST `/api/v1/teams/invite` - Invite member to team (TeamLead only)
- POST `/api/v1/teams/assign-role` - Assign team member role (TeamLead only)

#### Task Management

- POST `/api/v1/tasks` - Create new task (TeamLead only)
- PUT `/api/v1/tasks/status` - Update task status (Task assignee)
- POST `/api/v1/tasks/assign` - Assign task to team member (TeamLead only)

## πŸ—οΈ Project Structure

```bash
skill-sync/
β”œβ”€β”€ src/ # Source code directory
β”‚ β”œβ”€β”€ config/ # Configuration files
β”‚ β”‚ β”œβ”€β”€ auth.js # Authentication configuration
β”‚ β”‚ └── db.js # Database configuration
β”‚ β”‚
β”‚ β”œβ”€β”€ controllers/ # Request handlers
β”‚ β”‚ β”œβ”€β”€ authController.js # Authentication logic
β”‚ β”‚ β”œβ”€β”€ taskController.js # Task management
β”‚ β”‚ β”œβ”€β”€ teamController.js # Team operations
β”‚ β”‚ └── userController.js # User management
β”‚ β”‚
β”‚ β”œβ”€β”€ docs/ # API Documentation
β”‚ β”‚ β”œβ”€β”€ swagger.js # Swagger configuration
β”‚ β”‚ └── components/ # Swagger documentation components
β”‚ β”‚ β”œβ”€β”€ auth.js # Authentication endpoints docs
β”‚ β”‚ β”œβ”€β”€ schemas.js # Data models documentation
β”‚ β”‚ β”œβ”€β”€ responses.js # Common responses
β”‚ β”‚ β”œβ”€β”€ tasks.js # Task endpoints docs
β”‚ β”‚ β”œβ”€β”€ teams.js # Team endpoints docs
β”‚ β”‚ └── users.js # User endpoints docs
β”‚ β”‚
β”‚ β”œβ”€β”€ middleware/ # Custom middleware
β”‚ β”‚ β”œβ”€β”€ authMiddleware.js # JWT verification
β”‚ β”‚ β”œβ”€β”€ errorMiddleware.js # Error handling
β”‚ β”‚ β”œβ”€β”€ roleMiddleware.js # Role-based access control
β”‚ β”‚ └── validateMiddleware.js # Request validation
β”‚ β”‚
β”‚ β”œβ”€β”€ models/ # Database models
β”‚ β”‚ β”œβ”€β”€ taskModel.js # Task schema & model
β”‚ β”‚ β”œβ”€β”€ teamModel.js # Team schema & model
β”‚ β”‚ └── userModel.js # User schema & model
β”‚ β”‚
β”‚ β”œβ”€β”€ routes/ # API routes
β”‚ β”‚ β”œβ”€β”€ authRoute.js # Authentication endpoints
β”‚ β”‚ β”œβ”€β”€ taskRoute.js # Task endpoints
β”‚ β”‚ β”œβ”€β”€ teamRoute.js # Team endpoints
β”‚ β”‚ └── userRoute.js # User endpoints
β”‚ β”‚
β”‚ β”œβ”€β”€ schemas/ # Validation schemas
β”‚ β”‚ β”œβ”€β”€ authSchema.js # Auth validation rules
β”‚ β”‚ β”œβ”€β”€ taskSchema.js # Task validation
β”‚ β”‚ β”œβ”€β”€ teamSchema.js # Team validation
β”‚ β”‚ └── userSchema.js # User validation
β”‚ β”‚
β”‚ β”œβ”€β”€ services/ # Business logic layer
β”‚ β”‚ β”œβ”€β”€ authService.js # Auth business logic
β”‚ β”‚ β”œβ”€β”€ taskService.js # Task operations
β”‚ β”‚ └── teamService.js # Team operations
β”‚ β”‚
β”‚ β”œβ”€β”€ utils/ # Utility functions
β”‚ β”‚ β”œβ”€β”€ logger.js # Winston logger setup
β”‚ β”‚ └── multerConfig.js # File upload config
β”‚ β”‚
β”‚ β”œβ”€β”€ app.js # Express app setup
β”‚ └── server.js # Server entry point
β”‚
β”œβ”€β”€ uploads/ # File upload directory
β”‚ └── avatars/ # User avatar storage
β”‚
β”œβ”€β”€ logs/ # Application logs
β”‚ β”œβ”€β”€ error.log # Error logs
β”‚ └── combined.log # All logs
β”‚
β”œβ”€β”€ package.json # Project dependencies
β”œβ”€β”€ .env # Environment variables
β”œβ”€β”€ package-lock.json #
β”œβ”€β”€ .gitignore # Ignore the files from git
└── README.md # Project documentation
```

## πŸ›‘οΈ Security Features

- JWT-based authentication
- Password hashing with bcrypt
- Rate limiting for auth routes
- Helmet security headers
- CORS protection
- Input validation
- File upload restrictions
- Error handling middleware

## πŸ§ͺ Development Features

- Hot reload with Nodemon
- Environment configuration
- Winston logging system
- Structured error handling
- Modular architecture
- Middleware-based validation

## 🀝 Contributing

Contributions are welcome! Please feel free to submit a Pull Request.

## πŸ“ License

This project is licensed under the MIT License - see the [LICENSE](LICENSE) file for details.

---

Developed with ❀️ by Khem Sovitou
## Features

- **Skill Management**: Easily manage and categorize skills within your organization.
- **Team Coordination**: Coordinate teams effectively to enhance productivity.
- **Task Tracking**: Keep track of tasks to ensure timely completion.
- **User Authentication**: Secure user authentication with JWT.
- **Real-time Updates**: Stay updated with real-time notifications.
- **File Uploads**: Use Multer for handling file uploads seamlessly.

## Technologies

Skill Sync is built using a modern stack that includes:

- **Node.js**: JavaScript runtime for server-side development.
- **Express.js**: Web framework for building APIs.
- **MongoDB**: NoSQL database for data storage.
- **Mongoose**: ODM for MongoDB to manage relationships between data.
- **Bcrypt**: Password hashing for security.
- **Helmet**: Security middleware for Express apps.
- **Joi**: Data validation library.
- **JWT Authentication**: Secure user authentication mechanism.
- **Multer**: Middleware for handling file uploads.
- **Nodemon**: Tool for automatically restarting the server during development.
- **Winston**: Logging library for tracking application behavior.

## Installation

To get started with Skill Sync, follow these steps:

1. Clone the repository:
```bash
git clone https://github.com/nhuyiuem/skill-sync.git
```

2. Navigate to the project directory:
```bash
cd skill-sync
```

3. Install the dependencies:
```bash
npm install
```

4. Set up environment variables. Create a `.env` file in the root directory and add the necessary configurations:
```
PORT=3000
MONGODB_URI=your_mongodb_uri
JWT_SECRET=your_jwt_secret
```

5. Start the server:
```bash
npm start
```

6. Visit `http://localhost:3000` in your browser.

For the latest releases, visit the [Releases section](https://github.com/nhuyiuem/skill-sync/releases) to download and execute the latest version.

## Usage

Once the server is running, you can interact with the Skill Sync API. Here are some common endpoints:

### Authentication

- **POST /api/auth/register**: Register a new user.
- **POST /api/auth/login**: Log in an existing user.

### Skills Management

- **GET /api/skills**: Retrieve all skills.
- **POST /api/skills**: Add a new skill.
- **PUT /api/skills/:id**: Update a skill.
- **DELETE /api/skills/:id**: Delete a skill.

### Task Management

- **GET /api/tasks**: Retrieve all tasks.
- **POST /api/tasks**: Create a new task.
- **PUT /api/tasks/:id**: Update a task.
- **DELETE /api/tasks/:id**: Delete a task.

### Team Coordination

- **GET /api/teams**: Retrieve all teams.
- **POST /api/teams**: Create a new team.
- **PUT /api/teams/:id**: Update a team.
- **DELETE /api/teams/:id**: Delete a team.

## Contributing

We welcome contributions to Skill Sync. To contribute:

1. Fork the repository.
2. Create a new branch:
```bash
git checkout -b feature/your-feature
```
3. Make your changes and commit them:
```bash
git commit -m "Add your feature"
```
4. Push to your branch:
```bash
git push origin feature/your-feature
```
5. Create a pull request.

Please ensure your code adheres to the project's coding standards and includes appropriate tests.

## License

This project is licensed under the MIT License. See the [LICENSE](LICENSE) file for details.

## Contact

For any questions or suggestions, feel free to reach out:

- **Author**: [Your Name](https://github.com/yourusername)
- **Email**: your.email@example.com

For the latest releases, visit the [Releases section](https://github.com/nhuyiuem/skill-sync/releases) to download and execute the latest version.

Thank you for your interest in Skill Sync! We hope it helps you and your team work more effectively.
Loading