Registry /
aws / tencentcloud-sdk-python-iot
Install & Compatibility
Where this runs
No compatibility data collected yet for this library.
Code
Verified usage
Verified import paths — ran on the pinned version, not inferred.
IotClient
✓ from tencentcloud.iot.v20180123 import iot_client
✗ from tencentcloud_sdk_python_iot import ...
The package uses dashed names, but imports use dotted paths with versioned modules.
models
✓ from tencentcloud.iot.v20180123 import models
✗ from tencentcloud.iot import models
Models are version-specific; v20180123 is the current stable API version.
List IoT products using credentials from environment variables.
import os
from tencentcloud.common import credential
from tencentcloud.iot.v20180123 import iot_client, models
secret_id = os.environ.get('TENCENTCLOUD_SECRET_ID', '')
secret_key = os.environ.get('TENCENTCLOUD_SECRET_KEY', '')
cred = credential.Credential(secret_id, secret_key)
client = iot_client.IotClient(cred, 'ap-guangzhou')
req = models.DescribeProductsRequest()
resp = client.DescribeProducts(req)
print(resp.to_json_string())
Errors
Common errors & fixes
ModuleNotFoundError: No module named 'tencentcloud'
Missing common SDK package.
fixInstall both: pip install tencentcloud-sdk-python-common tencentcloud-sdk-python-iot
AttributeError: module 'tencentcloud.iot' has no attribute 'v20180123'
Using an incorrect API version string or the package is not installed.
fixVerify API version from docs and install the correct package.
tencentcloud.common.exception.TencentCloudSDKException: [TencentCloudSDKException] code: UnsupportedOperation
Using an endpoint that does not exist for the IoT service in the current region.
fixCheck region availability for IoT service.
Upgrade
Version history
3.0.1459latest on PyPI · released Sep 15, 2025
Audit
Dependencies
tencentcloud-sdk-python-commonrequiredRequired: provides base client and credential handling