py-pingpong


Namepy-pingpong JSON
Version 0.1.3 PyPI version JSON
download
home_pagehttps://github.com/karan-kap00r/PingPong
SummaryA dynamic notification delivery system with Redis and Kafka integration.
upload_time2024-12-02 09:33:35
maintainerNone
docs_urlNone
authorKaran Kapoor
requires_python>=3.8
licenseNone
keywords
VCS
bugtrack_url
requirements fastapi uvicorn redis kafka-python google-cloud-firestore twilio Jinja2 bcrypt passlib PyJWT
Travis-CI No Travis.
coveralls test coverage No coveralls.
            # **PingPong: A Dynamic and Scalable Notification Delivery System**

PingPong is a robust, scalable, and highly customizable **Dynamic Notification Delivery System** designed to efficiently manage and deliver notifications across various channels, including **Email**, **SMS**, and **Push Notifications**. Built with modern technologies and adhering to high-performance standards, PingPong serves as a comprehensive solution for handling diverse notification workflows, ensuring reliability, speed, and scalability.

---

## **Features**
### 🔔 **Multi-Channel Notification Delivery**
- **Email**: Seamlessly integrates with **Mailgun** and other email providers for reliable email delivery {Future Scope}.
- **SMS**: Supports integration with **Twilio** for fast and secure text message delivery.
- **Push Notifications**: Will be implementing for real-time, personalized push notifications to mobile and web devices. {Future Scope}

### 💾 **Data Management**
- Centralized storage in **Google Firestore**, optimized for managing user preferences and notification history.
- Flexible and scalable queues powered by **Redis** and **Kafka**, ensuring efficient message processing and delivery.

### ⚡ **User-Centric Design**
- Supports **user preferences** to respect channel priorities and avoid unnecessary notifications.
- Allocates **unique notification IDs** for precise tracking and audit trails.

### 🛡️ **Secure and Robust Architecture**
- **Authentication and Authorization**:
  - Implements a secure login and signup feature with **JWT-based authentication**.
  - Dynamically handles notification publishing based on logged-in user context.
- **Message Integrity**: Ensures notifications are correctly routed to their intended users, leveraging Redis and Kafka filtering logic.

### 🚀 **Scalability and Performance**
- Dockerized microservice architecture for seamless deployment and portability.
- Scalable infrastructure to handle millions of notifications, ensuring minimal latency and high throughput.
- Auto-scaling and cost-efficient hosting on **GCP Cloud Run** with pay-as-you-use billing.

### 🛠️ **Developer-Friendly**
- Designed for extensibility with clear and modular code.
- Supports new channel integrations with minimal effort.
- Just import the package for publishing, consuming, and managing notifications.


### 🛠️ **User-Friendly**
- Easy-to-use interface with a class-based design for sending notifications.
- Support for configurable parameters, including sender, receiver, and notification channels.
- Integration with popular services like Mailgun (for email) and Twilio (for SMS).
- Future-ready: Additional notification services will be supported in upcoming updates.
- Fully customizable by passing API Keys and Auth Tokens.
---

## **Tech Stack**
- **Backend**: Python, FastAPI
- **Messaging Queues**: Kafka, Redis
- **Database**: Google Firestore
- **Notifications**: Mailgun, Twilio, OneSignal
- **Deployment**: Docker, GCP Cloud Run
- **Authentication**: JWT-based authentication and role management

---

## **How It Works**
1. **Notification Publishing**:
   - Users or services send notification requests via a REST API endpoint for demo purpose or by importing python package with their personal API keys.
   - Notifications are queued in **Redis** and **Kafka** for asynchronous processing.

2. **User Preferences**:
   - Every user can configure their preferred notification channels (e.g., Email, SMS).
   - Notifications respect user preferences during both publishing and consumption.

3. **Message Consumption**:
   - Consumers retrieve notifications from queues and deliver them through the appropriate channels.
   - Redis ensures only recent and relevant messages are processed.

4. **Integration with External Services**:
   - Email and SMS are sent using external providers (Mailgun, Omnisend, Twilio, etc).

5. **Analytics and Tracking**:
   - All notifications are logged with unique IDs in **Firestore**, enabling detailed tracking and reporting.

---

## **GitHub Setup and Usage**
1. Clone the repository:
   ```bash
   git clone https://github.com/karan-kap00r/PingPong.git
   cd pingpong
   ```

2. Build and run the Docker containers:
   ```bash
   docker-compose up --build
   ```

3. Access the API on `http://localhost:8000` and explore the interactive Swagger documentation at `http://localhost:8000/docs`.

4. Configure your environment variables:
   - Redis and Kafka configurations.
   - API keys for Mailgun, Twilio, Omnisend, and OneSignal.

5. Enjoy the PingPong.

---

## **PyPI Setup and Usage**
![Image description](https://raw.githubusercontent.com/karan-kap00r/PingPong/refs/heads/master/pypi_import_code.png)

---

## **Why PingPong?**
PingPong is the ultimate notification management solution for projects demanding:
- **High performance**: Deliver notifications at lightning speed to millions of users.
- **Scalability**: Handle growing notification workloads with ease.
- **Flexibility**: Support for multiple notification channels and user preferences.
- **Security**: Robust authentication and secure data management.

---

## **Contributions**
We welcome contributions to enhance PingPong! Feel free to submit pull requests, open issues, or share feature ideas.

---

## **License**
This project is licensed under the [MIT License](https://opensource.org/licenses/MIT).  

---

            

Raw data

            {
    "_id": null,
    "home_page": "https://github.com/karan-kap00r/PingPong",
    "name": "py-pingpong",
    "maintainer": null,
    "docs_url": null,
    "requires_python": ">=3.8",
    "maintainer_email": null,
    "keywords": null,
    "author": "Karan Kapoor",
    "author_email": "kaykay9464769@gmail.com",
    "download_url": "https://files.pythonhosted.org/packages/ff/5f/98eb7ce0c15b002314a6a525d67146414af8aed7aa9d5fff2bf727724a07/py_pingpong-0.1.3.tar.gz",
    "platform": null,
    "description": "# **PingPong: A Dynamic and Scalable Notification Delivery System**\n\nPingPong is a robust, scalable, and highly customizable **Dynamic Notification Delivery System** designed to efficiently manage and deliver notifications across various channels, including **Email**, **SMS**, and **Push Notifications**. Built with modern technologies and adhering to high-performance standards, PingPong serves as a comprehensive solution for handling diverse notification workflows, ensuring reliability, speed, and scalability.\n\n---\n\n## **Features**\n### \ud83d\udd14 **Multi-Channel Notification Delivery**\n- **Email**: Seamlessly integrates with **Mailgun** and other email providers for reliable email delivery {Future Scope}.\n- **SMS**: Supports integration with **Twilio** for fast and secure text message delivery.\n- **Push Notifications**: Will be implementing for real-time, personalized push notifications to mobile and web devices. {Future Scope}\n\n### \ud83d\udcbe **Data Management**\n- Centralized storage in **Google Firestore**, optimized for managing user preferences and notification history.\n- Flexible and scalable queues powered by **Redis** and **Kafka**, ensuring efficient message processing and delivery.\n\n### \u26a1 **User-Centric Design**\n- Supports **user preferences** to respect channel priorities and avoid unnecessary notifications.\n- Allocates **unique notification IDs** for precise tracking and audit trails.\n\n### \ud83d\udee1\ufe0f **Secure and Robust Architecture**\n- **Authentication and Authorization**:\n  - Implements a secure login and signup feature with **JWT-based authentication**.\n  - Dynamically handles notification publishing based on logged-in user context.\n- **Message Integrity**: Ensures notifications are correctly routed to their intended users, leveraging Redis and Kafka filtering logic.\n\n### \ud83d\ude80 **Scalability and Performance**\n- Dockerized microservice architecture for seamless deployment and portability.\n- Scalable infrastructure to handle millions of notifications, ensuring minimal latency and high throughput.\n- Auto-scaling and cost-efficient hosting on **GCP Cloud Run** with pay-as-you-use billing.\n\n### \ud83d\udee0\ufe0f **Developer-Friendly**\n- Designed for extensibility with clear and modular code.\n- Supports new channel integrations with minimal effort.\n- Just import the package for publishing, consuming, and managing notifications.\n\n\n### \ud83d\udee0\ufe0f **User-Friendly**\n- Easy-to-use interface with a class-based design for sending notifications.\n- Support for configurable parameters, including sender, receiver, and notification channels.\n- Integration with popular services like Mailgun (for email) and Twilio (for SMS).\n- Future-ready: Additional notification services will be supported in upcoming updates.\n- Fully customizable by passing API Keys and Auth Tokens.\n---\n\n## **Tech Stack**\n- **Backend**: Python, FastAPI\n- **Messaging Queues**: Kafka, Redis\n- **Database**: Google Firestore\n- **Notifications**: Mailgun, Twilio, OneSignal\n- **Deployment**: Docker, GCP Cloud Run\n- **Authentication**: JWT-based authentication and role management\n\n---\n\n## **How It Works**\n1. **Notification Publishing**:\n   - Users or services send notification requests via a REST API endpoint for demo purpose or by importing python package with their personal API keys.\n   - Notifications are queued in **Redis** and **Kafka** for asynchronous processing.\n\n2. **User Preferences**:\n   - Every user can configure their preferred notification channels (e.g., Email, SMS).\n   - Notifications respect user preferences during both publishing and consumption.\n\n3. **Message Consumption**:\n   - Consumers retrieve notifications from queues and deliver them through the appropriate channels.\n   - Redis ensures only recent and relevant messages are processed.\n\n4. **Integration with External Services**:\n   - Email and SMS are sent using external providers (Mailgun, Omnisend, Twilio, etc).\n\n5. **Analytics and Tracking**:\n   - All notifications are logged with unique IDs in **Firestore**, enabling detailed tracking and reporting.\n\n---\n\n## **GitHub Setup and Usage**\n1. Clone the repository:\n   ```bash\n   git clone https://github.com/karan-kap00r/PingPong.git\n   cd pingpong\n   ```\n\n2. Build and run the Docker containers:\n   ```bash\n   docker-compose up --build\n   ```\n\n3. Access the API on `http://localhost:8000` and explore the interactive Swagger documentation at `http://localhost:8000/docs`.\n\n4. Configure your environment variables:\n   - Redis and Kafka configurations.\n   - API keys for Mailgun, Twilio, Omnisend, and OneSignal.\n\n5. Enjoy the PingPong.\n\n---\n\n## **PyPI Setup and Usage**\n![Image description](https://raw.githubusercontent.com/karan-kap00r/PingPong/refs/heads/master/pypi_import_code.png)\n\n---\n\n## **Why PingPong?**\nPingPong is the ultimate notification management solution for projects demanding:\n- **High performance**: Deliver notifications at lightning speed to millions of users.\n- **Scalability**: Handle growing notification workloads with ease.\n- **Flexibility**: Support for multiple notification channels and user preferences.\n- **Security**: Robust authentication and secure data management.\n\n---\n\n## **Contributions**\nWe welcome contributions to enhance PingPong! Feel free to submit pull requests, open issues, or share feature ideas.\n\n---\n\n## **License**\nThis project is licensed under the [MIT License](https://opensource.org/licenses/MIT).  \n\n---\n",
    "bugtrack_url": null,
    "license": null,
    "summary": "A dynamic notification delivery system with Redis and Kafka integration.",
    "version": "0.1.3",
    "project_urls": {
        "Homepage": "https://github.com/karan-kap00r/PingPong"
    },
    "split_keywords": [],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "f2717c75aa6d2dc5c1c8e79a334e7b22794f51aa7c8ad46e503cbcf9ad9ff325",
                "md5": "b61d8409874e340560fd55b597e8b2f8",
                "sha256": "7ea25905103ca3cd9b7a72170f608e364c106eee6d3c386458d55e77bd3dea05"
            },
            "downloads": -1,
            "filename": "py_pingpong-0.1.3-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "b61d8409874e340560fd55b597e8b2f8",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": ">=3.8",
            "size": 18122,
            "upload_time": "2024-12-02T09:33:33",
            "upload_time_iso_8601": "2024-12-02T09:33:33.394232Z",
            "url": "https://files.pythonhosted.org/packages/f2/71/7c75aa6d2dc5c1c8e79a334e7b22794f51aa7c8ad46e503cbcf9ad9ff325/py_pingpong-0.1.3-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "ff5f98eb7ce0c15b002314a6a525d67146414af8aed7aa9d5fff2bf727724a07",
                "md5": "0d74969aa244f12300ef8553e5abebac",
                "sha256": "b421d7d5fd2c4839763fa9505edff4d359a2f051ab698a2d4427b425138cb941"
            },
            "downloads": -1,
            "filename": "py_pingpong-0.1.3.tar.gz",
            "has_sig": false,
            "md5_digest": "0d74969aa244f12300ef8553e5abebac",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=3.8",
            "size": 15557,
            "upload_time": "2024-12-02T09:33:35",
            "upload_time_iso_8601": "2024-12-02T09:33:35.902106Z",
            "url": "https://files.pythonhosted.org/packages/ff/5f/98eb7ce0c15b002314a6a525d67146414af8aed7aa9d5fff2bf727724a07/py_pingpong-0.1.3.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2024-12-02 09:33:35",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "karan-kap00r",
    "github_project": "PingPong",
    "travis_ci": false,
    "coveralls": false,
    "github_actions": false,
    "requirements": [
        {
            "name": "fastapi",
            "specs": [
                [
                    "==",
                    "0.95.2"
                ]
            ]
        },
        {
            "name": "uvicorn",
            "specs": [
                [
                    "==",
                    "0.23.1"
                ]
            ]
        },
        {
            "name": "redis",
            "specs": [
                [
                    "==",
                    "5.0.0"
                ]
            ]
        },
        {
            "name": "kafka-python",
            "specs": [
                [
                    "==",
                    "2.0.2"
                ]
            ]
        },
        {
            "name": "google-cloud-firestore",
            "specs": [
                [
                    "==",
                    "2.10.1"
                ]
            ]
        },
        {
            "name": "twilio",
            "specs": [
                [
                    "==",
                    "8.0.0"
                ]
            ]
        },
        {
            "name": "Jinja2",
            "specs": [
                [
                    "==",
                    "3.1.4"
                ]
            ]
        },
        {
            "name": "bcrypt",
            "specs": [
                [
                    "==",
                    "3.2.2"
                ]
            ]
        },
        {
            "name": "passlib",
            "specs": [
                [
                    "==",
                    "1.7.4"
                ]
            ]
        },
        {
            "name": "PyJWT",
            "specs": [
                [
                    "==",
                    "2.10.0"
                ]
            ]
        }
    ],
    "lcname": "py-pingpong"
}
        
Elapsed time: 3.41257s