tencent cloud

APIs

CreateCloudProductLogCollection

다운로드
포커스 모드
폰트 크기
마지막 업데이트 시간: 2026-06-10 15:02:48

1. API Description

Domain name for API request: cls.intl.tencentcloudapi.com.

Cloud product integration uses internal APIs

A maximum of 20 requests can be initiated per second for this API.

We recommend you to use API Explorer
Try it
API Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation, and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters

The following request parameter list only provides API request parameters and some common parameters. For the complete common parameter list, see Common Request Parameters.

Parameter Name Required Type Description
Action Yes String Common Params. The value used for this API: CreateCloudProductLogCollection.
Version Yes String Common Params. The value used for this API: 2020-10-16.
Region Yes String Common Params. For more information, please see the list of regions supported by the product.
InstanceId Yes String

Instance ID

  • Obtained through official documentation of connected cloud services
AssumerName Yes String

Cloud product identifier, support enumerate: CDS, CWP, CDB, TDSQL-C, MongoDB, TDStore, DCDB, MariaDB, PostgreSQL, BH, APIS

LogType Yes String

Log type, supports enumerate: CDS-AUDIT, CDS-RISK, CDB-AUDIT, TDSQL-C-AUDIT, MongoDB-AUDIT, MongoDB-SlowLog, MongoDB-ErrorLog, TDMYSQL-SLOW, DCDB-AUDIT, DCDB-SLOW, DCDB-ERROR, MariaDB-AUDIT, MariaDB-SLOW, MariaDB-ERROR, PostgreSQL-SLOW, PostgreSQL-ERROR, PostgreSQL-AUDIT, BH-FILELOG, BH-COMMANDLOG, APIS-ACCESS

CloudProductRegion Yes String

Product region. The input parameter format for regions varies by log type (LogType). Refer to the following example:

  • All CDS log types: ap-guangzhou
  • CDB-AUDIT: gz
  • TDSQL-C-AUDIT: gz
  • MongoDB-AUDIT: gz
  • MongoDB-SlowLog: ap-guangzhou
  • MongoDB-ErrorLog: ap-guangzhou
  • TDMYSQL-SLOW: gz
  • All DCDB log types: gz
  • All MariaDB log types: gz
  • All PostgreSQL log types: gz
  • All BH log types: overseas-polaris (Hong Kong (China) and other)/fsi-polaris (financial district)/general-polaris (general zone)/intl-sg-prod (international site)
  • All APIS log types: gz
ClsRegion Yes String

CLS target region

LogsetName No String

Logset name. Required when LogsetId is not specified. If the log set does not exist, it will automatically create one.

TopicName No String

Log topic name. This parameter is required when TopicId is empty. If the log topic does not exist, the system will automatically create one.

Extend No String

Log configuration extension info, generally used to store additional log delivery configuration

LogsetId No String

log set id

TopicId No String

log topic id

Tags.N No Array of Tag

Tag description list. By specifying this parameter, you can simultaneously bind tags to the appropriate theme. Supports up to 10 tag key-value pairs. The same resource can only be bound to the same tag key.

3. Output Parameters

Parameter Name Type Description
TopicId String

Log topic ID.

TopicName String

Log topic name

LogsetId String

Logset ID

LogsetName String

Logset name

Status Integer

-1 Creating, 1 Creation completed

RequestId String The unique request ID, generated by the server, will be returned for every request (if the request fails to reach the server for other reasons, the request will not obtain a RequestId). RequestId is required for locating a problem.

4. Example

Example1 Creating a Cloud Product Delivery Task

Input Example

POST / HTTP/1.1
Host: cls.intl.tencentcloudapi.com
Content-Type: application/json
X-TC-Action: CreateCloudProductLogCollection
<Common request parameters>

{
    "InstanceId": "cdb-9edkkbdc",
    "AssumerName": "CDB",
    "LogType": "CDB-AUDIT",
    "CloudProductRegion": "qy",
    "ClsRegion": "ap-qingyuan",
    "LogsetName": "test-logset",
    "TopicName": "test-topic"
}

Output Example

{
    "Response": {
        "LogsetId": "c227837e-29e6-4597-a22d-15265d8179c6",
        "LogsetName": "test-logset",
        "RequestId": "1acc4a4a-8231-4439-8a30-d082a95b9b43",
        "Status": 1,
        "TopicId": "9e041c76-869b-4eec-a54e-7f22f53e1afc",
        "TopicName": "test-topic"
    }
}

5. Developer Resources

SDK

TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call APIs.

Command Line Interface

6. Error Code

The following only lists the error codes related to the API business logic. For other error codes, see Common Error Codes.

Error Code Description
AuthFailure CAM signature/authentication error.
FailedOperation Operation failed.
FailedOperation.CloudProductInvocationError Cloud product interface call exception
FailedOperation.Timeout Operation timed out
InternalError Internal error.
InvalidParameter Incorrect parameter.
InvalidParameter.ParamError Parameter error.
InvalidParameterValue Incorrect parameter value.
MissingParameter Missing parameter.
OperationDenied Operation denied.
ResourceNotFound.LogsetNotExist The specified logset does not exist.
ResourceNotFound.TopicNotExist The log topic does not exist.
UnsupportedOperation Unsupported operation.

도움말 및 지원

문제 해결에 도움이 되었나요?

피드백