Skip to main content

Replace your internal webhooks with a reliable, performant, and scalable MQ with a fantastic DX.

Project description

LeanMQ

GitHub Repo stars GitHub license PyPI - Downloads Python Version PyPI PyPI - Status Code style: Ruff Contributions welcome


🔥 Just getting started – show your support!

If you find LeanMQ interesting, consider giving it a ⭐ star on GitHub!
It helps others discover it and motivates ongoing improvements.


LeanMQ is a lightweight, message queue library with minimal dependencies for internal or async microservice communication. It provides a simple but powerful implementation using Redis Streams with support for —

  • Dead Letter Queues: Automatic handling of failed messages
  • Message TTL: Set expiration times for messages
  • Atomic Transactions: Send multiple messages in a single transaction
  • Consumer Groups: Support for multiple consumers
  • Message Tracking: Track delivery attempts and failures

Read the docs


Installation

pip install leanmq

Quick Start

# Set up a webhook server
from leanmq import LeanMQWebhook

webhook = LeanMQWebhook()

# Register a handler
@webhook.get("/order/status/")
def process_order_status(data):
    print(f"Order {data['order_id']} status: {data['status']}")

# Start processing webhooks in a background thread
service = webhook.run_service()

# In another service, send a webhook
webhook.send("/order/status/", {
    "order_id": "ORD-12345", 
    "status": "shipped"
})

Find rest of the docs here.

License

Apache 2.0 - see LICENSE.md for details.

Copyright

Copyright (c) 2025 Augustus D'Souza

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

leanmq-0.2.0.tar.gz (17.9 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

leanmq-0.2.0-py3-none-any.whl (20.5 kB view details)

Uploaded Python 3

File details

Details for the file leanmq-0.2.0.tar.gz.

File metadata

  • Download URL: leanmq-0.2.0.tar.gz
  • Upload date:
  • Size: 17.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.12.9

File hashes

Hashes for leanmq-0.2.0.tar.gz
Algorithm Hash digest
SHA256 22c5c7086b6c97de81d1c29fe1bc0a1497d01ecee7dd9fc00dadc1b0e1436613
MD5 3acf5184d4ff3e761c7bfaee5505acf6
BLAKE2b-256 ded2152d9e95dfaa21fd853d39831a31210ab150b16d1f3e6af08c1020841f9e

See more details on using hashes here.

Provenance

The following attestation bundles were made for leanmq-0.2.0.tar.gz:

Publisher: publish.yml on augiwan/LeanMQ

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file leanmq-0.2.0-py3-none-any.whl.

File metadata

  • Download URL: leanmq-0.2.0-py3-none-any.whl
  • Upload date:
  • Size: 20.5 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.12.9

File hashes

Hashes for leanmq-0.2.0-py3-none-any.whl
Algorithm Hash digest
SHA256 1a050c64faed1b87417138ac9ae3eb83b106e76185705a4e74aecc111446b14f
MD5 9c3cbd65dfb95ffa414a2e6b31a01945
BLAKE2b-256 be3bd073c471604bdd1cef9395c3c1dc90c365ef21429fe75b03c4a4eaa166e6

See more details on using hashes here.

Provenance

The following attestation bundles were made for leanmq-0.2.0-py3-none-any.whl:

Publisher: publish.yml on augiwan/LeanMQ

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page