skillfed

azure-eventhub

Microsoft Azure Event Hubs Client Library for Python

azure-eventhub v5.15.1 13.9M downloads/30d#1,257 on PyPI5,588
License unclear Active released

What it is and what it does

Azure Event Hubs is a client library for interacting with Azure's managed pub-sub event streaming service. It provides EventHubProducerClient and EventHubConsumerClient classes to emit telemetry, publish application state changes, and consume event streams from Azure Event Hubs. The library handles authentication via connection strings or Azure Active Directory credentials, manages partitioned event delivery, and supports both synchronous and asynchronous APIs.

The package is designed for scenarios where you need to ingest high-volume event data from connected devices or applications, transform it, and stream it to multiple independent consumers or analytics platforms. It abstracts the AMQP protocol and Azure service details, allowing you to focus on event publishing and consumption logic. Thread safety and coroutine safety are not guaranteed, so applications must manage concurrency explicitly.

Use it for:

  • Emit application telemetry and diagnostic logs to a centralized Event Hub for business intelligence and monitoring.
  • Publish state-change events that loosely coupled systems can observe and react to without direct coupling.
  • Consume events from an Event Hub, transform them, and republish to a new stream for downstream consumers.
  • Build real-time analytics pipelines by consuming Event Hub streams with analytics providers.
  • Collect sensor data from connected devices and route it to storage or processing systems.

Worth the install?

AI-flagged interpretation of the facts on this page — verify before relying

Publishes and consumes events from Azure Event Hubs, a scalable pub-sub service for ingesting and streaming millions of events per second to multiple consumers.

Yes. The package is production-stable, actively maintained, has low install friction, and is the official Azure SDK for Event Hubs. It carries no known vulnerabilities and supports Python 3.9 or later. Install it if you need to publish or consume events from Azure Event Hubs; the only caveat is that thread and coroutine safety are not guaranteed, so your application must manage concurrency carefully.

Install

azure-eventhub on PyPI

pip

pip install azure-eventhub

uv

uv add azure-eventhub

poetry

poetry add azure-eventhub

Installing azure-eventhub

Before you install

Low install friction with only two runtime dependencies (azure-core and typing-extensions). Active maintenance with recent commits; production-stable status as part of the official Azure SDK.

Quickstart

pip install azure-eventhub

from azure.eventhub import EventHubProducerClient

client = EventHubProducerClient.from_connection_string(connection_str, eventhub_name=hub_name)
with client:
    event_data_batch = client.create_batch()
    event_data_batch.add(EventData(body=b"test"))
    client.send_batch(event_data_batch)

Requires Python 3.9 or later; requires an Azure subscription and Event Hubs namespace with an Event Hub already created; async API requires aiohttp; AAD authentication requires azure-identity.

Verify before relying

  • Whether aiohttp and azure-identity are truly optional or required for specific use patterns.
  • Specific throughput or latency characteristics under typical workloads.
  • Thread-safety guarantees or recommended patterns for concurrent access.

Package facts

License not declared (unclear)
Python support supports the current Python release (>=3.9)
Install friction low — pure-Python wheel
Runtime dependencies 2 — azure-core, typing-extensions
Maintenance actively maintained — 288 days since the last release
Last repo commit
First released
Downloads 13,938,646/month — #1,257 on PyPI (30-day window, as of 2026-08-14)
Known vulnerabilities none known (OSV.dev, checked 2026-08-14)

Evidence: azure_eventhub-5.15.1-py3-none-any.whl

Keywords: azure, azure sdk

Development Status :: 5 - Production/StableProgramming Language :: PythonProgramming Language :: Python :: 3Programming Language :: Python :: 3 :: OnlyProgramming Language :: Python :: 3.10Programming Language :: Python :: 3.11Programming Language :: Python :: 3.12Programming Language :: Python :: 3.13Programming Language :: Python :: 3.9

Tags

azure event hubs clientpublish subscribe messaging azureevent streaming azureazure telemetry ingestiondistributed event processingazure event consumer producerreal-time event streaming
azure-sdkevent-streamingpub-sub

More Distributed Computing packages

grpcio

gRPC Python is an HTTP/2-based RPC framework…

permissive · top 100 on PyPI

execnet

execnet lets you spawn and communicate with…

permissive · top 1,000 on PyPI

cloudpickle

Cloudpickle extends Python's standard pickle…

permissive · top 1,000 on PyPI

smart-open

Provides a unified, open()-compatible Python…

permissive · top 1,000 on PyPI

portalocker

Portalocker provides cross-platform file…

permissive · top 1,000 on PyPI

ray

Ray is a distributed computing framework that…

permissive · top 1,000 on PyPI

azure-eventhub-checkpointstoreblob

Provides a checkpoint store implementation for…

permissive · top 15,000 on PyPI

azure-messaging-webpubsubservice

Manages WebSocket connections and real-time…

permissive · top 15,000 on PyPI

azure-eventhub-checkpointstoreblob-aio

Stores checkpoints and partition ownership for…

permissive · top 15,000 on PyPI

azure-eventgrid

Publishes and consumes events through Azure…

permissive · top 5,000 on PyPI

azure-mgmt-eventhub

Manages Azure Event Hub resources—namespaces,…

permissive · top 5,000 on PyPI

azure-servicebus

Azure Service Bus client library for Python…

unclear · top 1,000 on PyPI

azure-mgmt-notificationhubs

Manages Azure Notification Hubs…

permissive · top 5,000 on PyPI

azure-storage-queue

Client library for interacting with Azure Queue…

permissive · top 1,000 on PyPI

azure-schemaregistry

Registers, retrieves, and manages schemas in…

permissive · top 5,000 on PyPI

acryl-datahub-actions

Acryl-datahub-actions is an event-driven…

permissive · top 15,000 on PyPI