{"id":28367,"library":"tencentcloud-sdk-python-ticm","title":"Tencent Cloud SDK for Python - TICM","description":"Tencent Cloud Image Content Moderation (TICM) SDK for Python. Provides image moderation APIs. Latest version: 3.0.1416. Released weekly or on-demand.","status":"active","version":"3.0.1416","language":"python","source_language":"en","source_url":"https://github.com/TencentCloud/tencentcloud-sdk-python","tags":["tencentcloud","ticm","image moderation","sdk"],"install":[{"cmd":"pip install tencentcloud-sdk-python-ticm","lang":"bash","label":"Install SDK"}],"dependencies":[],"imports":[{"note":"Common mistake: import from parent package without versioned subpackage.","wrong":"from tencentcloud.ticm import TicmClient","symbol":"TicmClient","correct":"from tencentcloud.ticm.v20181127 import ticm_client"},{"note":"Wrong: models are under the versioned subpackage.","wrong":"import tencentcloud.ticm.models","symbol":"models","correct":"from tencentcloud.ticm.v20181127 import models"}],"quickstart":{"code":"from tencentcloud.ticm.v20181127 import ticm_client, models\nfrom tencentcloud.common import credential\nfrom tencentcloud.common.exception.tencent_cloud_sdk_exception import TencentCloudSDKException\n\ntry:\n    cred = credential.Credential(SecretId=os.environ.get('SECRET_ID', ''), SecretKey=os.environ.get('SECRET_KEY', ''))\n    client = ticm_client.TicmClient(cred, 'ap-guangzhou')\n    req = models.ImageModerationRequest()\n    req.FileUrl = 'https://example.com/image.jpg'\n    resp = client.ImageModeration(req)\n    print(resp.to_json_string())\nexcept TencentCloudSDKException as err:\n    print(err)","lang":"python","description":"Initializes client and calls ImageModeration. Set SECRET_ID and SECRET_KEY env vars."},"warnings":[{"fix":"Use from tencentcloud.ticm.v20181127 import ...","message":"All imports must use versioned subpackage. tencentcloud.ticm is not the correct import path.","severity":"gotcha","affected_versions":">=3.0"},{"fix":"Use Python 3.6 or later.","message":"Python 2 is not supported and imports may fail if using old Python 2 syntax.","severity":"breaking","affected_versions":">=3.0.0"},{"fix":"Always pass a region like 'ap-guangzhou' to client constructor.","message":"Region argument is required when initializing clients, no longer optional.","severity":"breaking","affected_versions":">=3.0.0"}],"env_vars":null,"last_verified":"2026-05-09T00:00:00.000Z","next_check":"2026-08-07T00:00:00.000Z","problems":[{"fix":"Run 'pip install tencentcloud-sdk-python-ticm'. Then import from tencentcloud.ticm.v20181127.","cause":"Trying to use tencentcloud-sdk-python-ticm without installing it, or incorrect import path.","error":"ModuleNotFoundError: No module named 'tencentcloud.ticm'"},{"fix":"Use 'from tencentcloud.ticm.v20181127 import ticm_client' then ticm_client.TicmClient.","cause":"Importing the module directly instead of the class from the module.","error":"AttributeError: module 'tencentcloud.ticm.v20181127' has no attribute 'TicmClient'"}],"ecosystem":"pypi","meta_description":null,"install_score":null,"install_tag":null,"quickstart_score":null,"quickstart_tag":null}