{"id":28337,"library":"tencentcloud-sdk-python-gpm","title":"Tencent Cloud GPM SDK for Python","description":"Official Tencent Cloud SDK for Game Player Matchmaking (GPM) service. Version 3.0.1416, released regularly alongside other Tencent Cloud services. Enables integration with matchmaking rules, tickets, and matches.","status":"active","version":"3.0.1416","language":"python","source_language":"en","source_url":"https://github.com/TencentCloud/tencentcloud-sdk-python","tags":["tencent-cloud","gpm","matchmaking","sdk"],"install":[{"cmd":"pip install tencentcloud-sdk-python-gpm","lang":"bash","label":"Install via pip"}],"dependencies":[{"reason":"Required for credentials and HTTP transport","package":"tencentcloud-sdk-python-common","optional":false}],"imports":[{"note":"Direct import without versioned module path fails. Must include v20200820.","wrong":"from tencentcloud.gpm import GpmClient","symbol":"GpmClient","correct":"from tencentcloud.gpm.v20200820 import gpm_client"},{"note":"Import models module, then use models.CreateMatchRequest() to avoid circular imports.","wrong":"from tencentcloud.gpm.v20200820.models import CreateMatchRequest","symbol":"models (e.g., CreateMatchRequest)","correct":"from tencentcloud.gpm.v20200820 import models"}],"quickstart":{"code":"import os\nfrom tencentcloud.common import credential\nfrom tencentcloud.gpm.v20200820 import gpm_client, models\n\ncred = credential.Credential(\n    os.environ.get('TENCENTCLOUD_SECRET_ID'),\n    os.environ.get('TENCENTCLOUD_SECRET_KEY')\n)\nclient = gpm_client.GpmClient(cred, \"ap-guangzhou\")\nreq = models.DescribeMatchRequest()\nreq.MatchCode = \"your-match-code\"\nresp = client.DescribeMatch(req)\nprint(resp.to_json_string())","lang":"python","description":"Initialize client and call DescribeMatch with credentials from environment variables."},"warnings":[{"fix":"Use from tencentcloud.gpm.v20200820 import gpm_client","message":"The SDK uses versioned API paths (e.g., v20200820). Incorrect import leads to AttributeError.","severity":"breaking","affected_versions":"all"},{"fix":"from tencentcloud.gpm.v20200820 import models; then use models.CreateMatchRequest()","message":"Models must be imported via `models` module; directly importing individual model classes may cause circular import errors.","severity":"gotcha","affected_versions":"all"},{"fix":"Install service-specific package: pip install tencentcloud-sdk-python-gpm","message":"Older documentation may reference `tencentcloud-sdk-python` directly. The package is now split per service.","severity":"deprecated","affected_versions":"<=3.0.1416"}],"env_vars":null,"last_verified":"2026-05-09T00:00:00.000Z","next_check":"2026-08-07T00:00:00.000Z","problems":[{"fix":"Install package: pip install tencentcloud-sdk-python-gpm; then use from tencentcloud.gpm.v20200820 import gpm_client","cause":"Missing the service-specific package or incorrect import path.","error":"ModuleNotFoundError: No module named 'tencentcloud.gpm'"},{"fix":"import gpm_client from tencentcloud.gpm.v20200820 import gpm_client","cause":"Typo in module name (e.g., 'gpmclient' instead of 'gpm_client') or import of wrong symbol.","error":"AttributeError: module 'tencentcloud.gpm.v20200820' has no attribute 'gpm_client'"}],"ecosystem":"pypi","meta_description":null,"install_score":null,"install_tag":null,"quickstart_score":null,"quickstart_tag":null}