Type annotations for aiobotocore IoT
raw JSON → 3.5.0 verified Fri May 01 auth: no python
Provides type annotations for the IoT service in aiobotocore. Version 3.5.0 corresponds to aiobotocore 3.5.0 service. Generated by mypy-boto3-builder. Supports Python >=3.9. Released on demand when new aiobotocore versions are published.
pip install types-aiobotocore-iot Common errors
error Cannot find reference 'IoTClient' in 'types_aiobotocore_iot' ↓
cause IDE not picking up installed stub package; often due to missing `__init__.pyi` or cache issues.
fix
Restart IDE or run
pip install types-aiobotocore-iot --upgrade --no-cache-dir. error Module 'types_aiobotocore_iot' has no attribute 'IoTClient' ↓
cause Version mismatch: installed package is for a different service (e.g., types-aiobotocore-s3 instead of types-aiobotocore-iot).
fix
Install the correct package:
pip install types-aiobotocore-iot. Warnings
breaking Version mismatch: types-aiobotocore-iot version must match your aiobotocore IoT service version (e.g., 3.5.0 for aiobotocore 3.5.0). Breaking changes can occur if versions differ. ↓
fix Ensure `pip install types-aiobotocore-iot==your.aiobotocore.version`.
gotcha Mypy may report missing imports if `boto3-stubs` is not installed. These types are defined in a stub-only package without runtime code. ↓
fix Install `boto3-stubs` as a dev dependency: `pip install boto3-stubs` or use a mypy plugin.
Imports
- IoTClient
from types_aiobotocore_iot import IoTClient
Quickstart
import asyncio
from types_aiobotocore_iot import IoTClient
async def main():
# Example usage: type checking with aiobotocore
from aiobotocore.session import get_session
session = get_session()
async with session.create_client('iot', region_name='us-east-1') as client:
# client is inferred as IoTClient
resp = await client.list_things()
print(resp)
asyncio.run(main())