Registry / http-networking / tencentcloud-sdk-python-ecdn

tencentcloud-sdk-python-ecdn

JSON →
library3.0.1459pypypi✓ verified 84d ago

Official Tencent Cloud SDK for Enterprise Content Delivery Network (ECDN) services. Current version 3.0.1459, released weekly alongside the main tencentcloud-sdk-python suite. Provides Pythonic access to ECDN APIs including domain management, log reporting, and DSA configuration.

pip install tencentcloud-sdk-python-ecdn
INSTALL
IMPORT
SIG · TENCENTCLOUD-SDK-P
T
tencentcloud-sdk-python-ecdn
http-networkingpythonv3.0.1459
harness data pending
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.

EcdnClient
from tencentcloud.ecdn.v20191012 import ecdn_client
from tencentcloud.ecdn.v20191012.ecdn_client import EcdnClient
Direct class import sometimes fails due to __init__ reloads; use module-level import

Authenticate with environment variables and list ECDN domain configurations.

from tencentcloud.common import credential from tencentcloud.ecdn.v20191012 import ecdn_client from tencentcloud.ecdn.v20191012 import models cred = credential.Credential( secret_id=os.environ.get('TENCENTCLOUD_SECRET_ID', ''), secret_key=os.environ.get('TENCENTCLOUD_SECRET_KEY', '') ) client = ecdn_client.EcdnClient(cred, 'ap-guangzhou') req = models.DescribeDomainsConfigRequest() resp = client.DescribeDomainsConfig(req) print(resp.to_json_string())
Debug
Known issues
breakingIn v3.0.1000+, the 'from tencentcloud.ecdn.v20191012 import ecdn_client' pattern is required; older direct import of EcdnClient class from the ecdn_client module may cause ImportError.
fix
Use 'from tencentcloud.ecdn.v20191012 import ecdn_client' then reference ecdn_client.EcdnClient.
affects: >=3.0.1000
deprecatedThe v20191012 API version is the only available version for ECDN; do not attempt to import other versions (e.g., v2018...).
fix
Always use v20191012 in the import path.
affects: all
gotchaRegion parameter is required even for global services; incorrectly setting region to empty string leads to an AuthenticationError.
fix
Specify an actual region like 'ap-guangzhou' or use client.set_region() after initialization.
affects: all
gotchaWhen using async client (EcdnClient from async version), you must import from the same module but the async variant is not available in this package; must install tencentcloud-sdk-python-common with async extras.
fix
Install 'pip install tencentcloud-sdk-python-common[async]' for async support, then import from tencentcloud.ecdn.v20191012.async_ecdn_client.
affects: >=3.0.0
Errors
Common errors & fixes
ImportError: cannot import name 'EcdnClient' from 'tencentcloud.ecdn.v20191012.ecdn_client'
Python may sometimes resolve the module as a script and the class is not at top-level; the correct import is the module itself.
fix
Use: from tencentcloud.ecdn.v20191012 import ecdn_client; then ecdn_client.EcdnClient
tencentcloud.common.exception.TencentCloudSDKException: [TencentCloudSDKException] code: AuthFailure.SecretIdNotFound
Missing or invalid secret ID/Key environment variables.
fix
Set TENCENTCLOUD_SECRET_ID and TENCENTCLOUD_SECRET_KEY environment variables correctly.
AttributeError: 'EcdnClient' object has no attribute 'DescribeDomainsConfig'
Using an older or mismatched API version where the method does not exist.
fix
Ensure you are using the correct API version (v20191012) and upgrading to the latest SDK version.
TypeError: __init__() got an unexpected keyword argument 'secret_id'
Credential class expects positional arguments in older versions; or using old credential pattern.
fix
Use credential.Credential(secret_id, secret_key) without keyword arguments or upgrade to latest SDK.
Upgrade
Version history
3.0.1459latest on PyPI · released Sep 15, 2025
Audit
Dependencies
tencentcloud-sdk-python-commonrequiredRequired for credential and HTTP handling
Agent activity
32 hits · last 30 days
node
28
OpenAI (training)
1
Resources
tencentcloud-sdk-python-ecdn — pip install tencentcloud-sdk-python-ecdn · libregistry