Skip to content

Sundaraj0828/leadandtraining

Repository files navigation

LeadAndTraining Management System πŸš€

LeadAndTraining is a high-performance RESTful application designed to streamline the lifecycle of student leads and vocational training programs. It provides a centralized backend to manage prospective client data, track training progress, and automate the conversion of leads into active participants.

πŸ› οΈ Tech Stack

  • Backend: Python 3.10+ with Flask Framework
  • API Architecture: RESTful Design
  • Database: MongoDB (NoSQL for flexible data modeling)
  • Authentication: JWT (JSON Web Tokens) via Flask-JWT-Extended
  • Configuration: python-dotenv for secure environment variables
  • Validation: Marshmallow (suggested for request/response schema)

✨ Key Features

  • Lead Lifecycle Tracking: Manage leads from "New" to "Enrolled" or "Closed."
  • Training Module Management: Create, update, and assign training sessions to specific leads.
  • Secure API Access: Protected endpoints ensuring only authorized admins can modify data.
  • Scalable Architecture: Built with a decoupled frontend-ready approach.
  • Dynamic Queries: Leverages MongoDB’s flexibility for complex lead filtering.

πŸš€ Getting Started

1. Prerequisites

  • Python 3.10 or higher
  • MongoDB installed and running (locally or Atlas)

2. Installation

Clone the repository and navigate to the project directory:

git clone https://github.com/Sundaraj0828/leadandtraining.git
cd leadandtraining

3. Environment Setup

Create a .env file in the root directory to protect your credentials:

FLASK_APP=app.py
FLASK_ENV=development
MONGO_URI=mongodb://localhost:27017/lead_training_db
JWT_SECRET_KEY=your_random_secure_string_here

4. Install Dependencies

pip install -r requirements.txt

5. Run the Application

flask run

The server will start at http://127.0.0.1:5000/.

πŸ”— API Documentation

Method Endpoint Description Auth Required
GET /api/leads Retrieve all leads Yes
POST /api/leads Create a new lead Yes
GET /api/leads/<id> Get specific lead details Yes
PUT /api/training/<id> Update training status Yes
POST /api/auth/login Obtain JWT access token No

πŸ“ Project Structure

β”œβ”€β”€ app/
β”‚   β”œβ”€β”€ models/          # MongoDB Schemas
β”‚   β”œβ”€β”€ routes/          # REST API Endpoints
β”‚   β”œβ”€β”€ utils/           # Helpers & Auth decorators
β”‚   └── __init__.py      # Flask app factory
β”œβ”€β”€ .env                 # Environment variables (Hidden)
β”œβ”€β”€ requirements.txt     # Python dependencies
└── README.md            # Project documentation

πŸ“„ License

Distributed under the MIT License. See LICENSE for more information.

Developed with ❀️ by [L.C. Sundaraj/Sundaraj0828]

About

LeadAndTraining Management System πŸš€ LeadAndTraining is a high-performance RESTful application designed to streamline the lifecycle of student leads and vocational training programs. It provides a centralized backend to manage prospective client data, track training progress, and automate the conversion of leads into active participants.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors