Skip to main content

Microsoft Azure IoT Device Library

Project description

Azure IoT Device SDK

The Azure IoT Device SDK for Python provides functionality for communicating with the Azure IoT Hub for both Devices and Modules.

Azure IoT Device Features

The SDK provides the following clients:

  • Provisioning Device Client

    • Creates a device identity on the Azure IoT Hub
  • IoT Hub Device Client

    • Send telemetry messages to Azure IoT Hub
    • Receive Cloud-to-Device (C2D) messages from the Azure IoT Hub
    • Receive and respond to direct method invocations from the Azure IoT Hub
  • IoT Hub Module Client

    • Supports Azure IoT Edge Hub and Azure IoT Hub
    • Send telemetry messages to a Hub or to another Module
    • Receive Input messages from a Hub or other Modules
    • Receive and respond to direct method invocations from a Hub or other Modules

These clients are available with an asynchronous API, as well as a blocking synchronous API for compatibility scenarios. We recommend you use Python 3.7+ and the asynchronous API.

Python Version Asynchronous API Synchronous API
Python 3.5.3+ YES YES
Python 2.7 NO YES

DEPRECATION NOTICE: SUPPORT FOR PYTHON 2.7 WILL BE DROPPED AT THE BEGINNING OF 2022

Installation

pip install azure-iot-device

Device Samples

Check out the samples repository for example code showing how the SDK can be used in a variety of scenarios, including:

  • Sending multiple telemetry messages at once.
  • Receiving Cloud-to-Device messages.
  • Using Edge Modules with the Azure IoT Edge Hub.
  • Send and receive updates to device twin
  • Receive invocations to direct methods
  • Register a device with the Device Provisioning Service

Getting help and finding API docs

API documentation for this package is available via Microsoft Docs

Additionally, the SDK makes use of docstrings which means you can find API documentation directly through Python with use of the help command:

e.g.

>>> from azure.iot.device import IoTHubDeviceClient
>>> help(IoTHubDeviceClient)

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

azure-iot-device-2.9.0.tar.gz (126.8 kB view details)

Uploaded Source

Built Distribution

azure_iot_device-2.9.0-py2.py3-none-any.whl (166.0 kB view details)

Uploaded Python 2 Python 3

File details

Details for the file azure-iot-device-2.9.0.tar.gz.

File metadata

  • Download URL: azure-iot-device-2.9.0.tar.gz
  • Upload date:
  • Size: 126.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.2 importlib_metadata/4.8.1 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.7.9

File hashes

Hashes for azure-iot-device-2.9.0.tar.gz
Algorithm Hash digest
SHA256 29cac73645b82afbb3d1c8689dcc737cea346f2f6199a19d5fcab45af25bc9a2
MD5 7adb661f88e79a2635ec882f1012b700
BLAKE2b-256 f63e027a4526e14229a37498b84535d414a2d24907bbd417400ff8a535fd7412

See more details on using hashes here.

File details

Details for the file azure_iot_device-2.9.0-py2.py3-none-any.whl.

File metadata

  • Download URL: azure_iot_device-2.9.0-py2.py3-none-any.whl
  • Upload date:
  • Size: 166.0 kB
  • Tags: Python 2, Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.2 importlib_metadata/4.8.1 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.7.9

File hashes

Hashes for azure_iot_device-2.9.0-py2.py3-none-any.whl
Algorithm Hash digest
SHA256 acd0843ea4e98ffccb8625b25f918d6c67159adebe80bbce6528401c742e57c8
MD5 5fbbc1f0c432f3660c225d11cc9c9258
BLAKE2b-256 3096025a8b6ef760a6da0153457c33ce6f294ce237c728d41e6969716fd9d34a

See more details on using hashes here.

Supported by

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