The project involves the development of a messaging service for sending messages to clients. Users can create, manage, and schedule message broadcasts with specified rules. The service automatically sends messages to clients based on defined filters and scheduled times. Comprehensive statistics are collected for each sent message to generate reports. Error handling is implemented to ensure that issues with external services do not affect the stability of message broadcasts. The API allows users to manage clients, broadcasts, and obtain statistics.
- Make sure you have Python and pip (Python package installer) installed.
- Activate or create a virtual environment (venv) to isolate the project. Install the required dependencies listed in the requirements.txt file using the command:
``` pip3 install -r requirements.txt ```
- Perform Django database migrations. Migrations are needed to create database tables related to your project's models. Execute the following commands:
``` python3 manage.py makemigrations
python3 manage.py migrate
```
- Run the Django development server:
``` python3 manage.py runserver ```
- Activate Celery Worker:
``` celery -A messaging_service worker -l INFO ```
- Activate Celery Beat:
``` celery -A messaging_service beat -l INFO ```
1. Get the List of Clients and Create a New Client::
◦ URL: /clients/
◦ HTTP Methods: GET, POST
Example of a Successful Response:
2. Get, Update, and Delete Client Information by ID:
• URL: /clients/<int:pk>/
• HTTP Methods: GET, PUT, DELETE
Example of a Successful Response:
1. Get the List of Campaigns and Create a New Campaign:
◦ URL: /campaigns/
◦ HTTP Methods: GET, POST
Example of a Successful Response:
2. Get, Update, and Delete Campaign Information by ID:
◦ URL: /campaigns/<int:pk>/
◦ HTTP Methods: GET, PUT, DELETE
1. Get the List of Messages and Create a New Message:
◦ URL: /messages/
◦ HTTP Methods: GET, POST
Example of a Successful Response:
3. Get, Update, and Delete Message Information by ID:
◦ URL: /messages/<int:pk>/
◦ HTTP Methods: GET, PUT, DELETE
Example of a Successful Response:





