# Kenya Tender Connect - Backend Server
Backend API for the **Kenya Tender Connect** platform built with **Flask, MySQL, and JWT authentication**.
---
## Features
* π JWT Authentication & Authorization
* π Tender Management (CRUD operations)
* π Application Management
* π₯ User Management
* π Document Upload Support
* π RESTful API
---
## Tech Stack
* **Backend:** Flask, Python
* **Database:** MySQL with SQLAlchemy ORM
* **Authentication:** JWT with Flask-JWT-Extended
* **File Upload:** Secure document handling
* **CORS:** Cross-Origin Resource Sharing enabled
---
## Quick Start
### Prerequisites
* Python 3.8+
* MySQL 5.7+
* `pip` (Python package manager)
### Installation
1. **Clone the repository**
```bash
git clone
github.com
cd kenya-tender-connect-server
```
2. **Create virtual environment**
```bash
python -m venv venv
source venv/bin/activate # On Windows: venv\Scripts\activate
```
3. **Install dependencies**
```bash
pip install -r requirements.txt
```
4. **Set up environment variables**
```bash
cp .env.example .env
# Edit .env with your database credentials and secret keys
```
5. **Set up database**
```bash
python scripts/setup_db.py
```
6. **Seed sample data (optional)**
```bash
python scripts/seed_data.py
```
7. **Run the application**
```bash
python run.py
```
The API will be available at: `
localhost`
---
## API Endpoints
### Authentication
| Method | Endpoint | Description |
| ------ | -------------------- | ----------------- |
| POST | `/api/auth/register` | User registration |
| POST | `/api/auth/login` | User login |
| GET | `/api/auth/me` | Get current user |
### Tenders
| Method | Endpoint | Description |
| ------ | ------------------- | ------------------------------- |
| GET | `/api/tenders` | List all tenders (with filters) |
| GET | `/api/tenders/ ` | Get tender β¦