Domain name for API request: csip.intl.tencentcloudapi.com.
This API is used to query the log list information.
A maximum of 20 requests can be initiated per second for this API.
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: DescribeDspmLogList. |
| Version | Yes | String | Common Params. The value used for this API: 2022-11-21. |
| Region | No | String | Common Params. This parameter is not required. |
| MemberId.N | No | Array of String | Group account member id |
| Limit | No | Integer | Number limit. |
| Offset | No | Integer | Offset. |
| Sort | No | String | Sorting method (desc=descending order, asc=ascending order) |
| Field | No | String | Sorting field (opTime=time, dangerLvl=risk level) |
| DangerLevel | No | String | Risk level (0-safe, 1-low risk, 2-medium-risk, 3-high-risk, all if not passed) |
| DbName | No | String | Database name |
| DbPort | No | Integer | Database port |
| DbIp | No | String | Database IP |
| AssetsId | No | Integer | Asset ID. |
| SessionId | No | String | Session ID |
| ClientSideIp | No | String | Client IP |
| EndTime | No | Integer | End time. |
| HitRule | No | Integer | Hit rule. |
| StartTime | No | Integer | Start time. |
| FuzzySearch | No | String | Fuzzy query |
| UserName | No | String | Username. |
| RestoreLogId | No | Integer | Restore log id |
| ClientName | No | String | Client |
| SourceTypes.N | No | Array of String | Traffic source. Parameter Value: Agent/Proxy/empty. If Agent is passed, Agent logs will be returned. If Proxy is passed, proxy logs will be returned. If both are passed or neither is passed, all will be returned. |
| TableName | No | String | Table name, length limited to 64. For queries on multiple tables, use space-separated names. |
| FieldName | No | String | Field name. Length limit: 64. For querying multiple field names, use space-separated values. |
| SqlMainTypes.N | No | Array of String | Main SQL types, DDL, DML, DCL, TCL |
| SqlType | No | String | Operation type. |
| RowNumMin | No | Integer | Minimum number of affected rows |
| RowNumMax | No | Integer | Maximum number of affected rows |
| DbTypes.N | No | Array of String | Database type. Supported values: cdb, mariadb |
| RetNo | No | Integer | Status code. |
| ClientDriverName | No | String | Client tool |
| ClientPort | No | Integer | Client port |
| LogId | No | String | Audit log ID |
| DangerLevels.N | No | Array of Integer | Risk level array (0-safe, 1-low risk, 2-medium-risk, 3-high-risk) |
| SensitiveCategoryRule | No | String | Field classification |
| SensitiveLevelRisk | No | String | Field classification |
| ClientMac | No | String | Client MAC |
| Parameter Name | Type | Description |
|---|---|---|
| TotalCount | Integer | Total number. |
| List | Array of AuditLogInfo | Log information list |
| 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. |
Querying the Log List in Ascending Order Based on Risk Level
POST / HTTP/1.1
Host: csip.intl.tencentcloudapi.com
Content-Type: application/json
X-TC-Action: DescribeDspmLogList
<Common request parameters>
{
"Sort": "desc",
"DbPort": 0,
"FuzzySearch": "select",
"HitRule": 0,
"DangerLevel": "high",
"RestoreLogId": 0,
"AssetsId": 0,
"UserName": "root",
"DbIp": "127.0.0.1",
"Field": "ip",
"SessionId": "1711987200000-140227893131008-2045",
"Limit": 1,
"StartTime": 0,
"Offset": 1,
"EndTime": 0,
"ClientSideIp": "127.0.0.1",
"DbName": "mysql",
"ClientName": "Proxy"
}
{
"Response": {
"TotalCount": 1,
"List": [
{
"AiScore": 1,
"AppUser": "testuser",
"BackPacket": "",
"ClientIp": "127.0.0.1",
"ClientMac": "52:54:00:c9:38:87",
"ClientName": "root",
"ClientUser": "39510",
"ClientPort": 3306,
"DangerLevel": 1,
"DbIp": "127.0.0.1",
"DbName": "monitor",
"DbPort": 3306,
"DbUser": "root",
"EffectRow": 0,
"ExecTime": 1,
"HitRule": "10000",
"Id": 104709,
"InstanceId": 1,
"InstanceName": "Audit test asset",
"OpSql": "login",
"OpTime": 1631760308,
"RetMsg": "login failed",
"RetNo": 0,
"SessionId": "1631721600000-140388847871744-5319",
"SqlType": "LOGIN",
"TableName": "information_schema",
"AssetName": "Audit test asset"
"HitRules": [],
"SourceType": "cdb",
"ReqId": "req-testidaseeada",
"SqlMainType": "DML",
"TableNames": [
"table1,table2,table3"
],
"FieldNames": [
"field1,field2,field3"
],
"FieldName": "phonenum,username,id",
"DbType": "MYSQL",
"ClientDriverName": "mongosh"
}
],
"RequestId": "a8aa8bbc-c255-42b1-88c4-04419f435a77"
}
}
TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call APIs.
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. |
| DryRunOperation | DryRun operation means the request will be successful, but the DryRun parameter is passed. |
| FailedOperation | Operation failed. |
| FailedOperation.DasbAmountNotEnough | FailedOperation.DasbAmountNotEnough |
| FailedOperation.DasbErrorCode | FailedOperation.DasbErrorCode |
| FailedOperation.DasbInvalidSecretId | FailedOperation.DasbInvalidSecretId |
| FailedOperation.DasbInvalidSecretKey | FailedOperation.DasbInvalidSecretKey |
| InternalError | Internal error. |
| InvalidParameter | Parameter error. |
| InvalidParameter.ResourceId | InvalidParameter.ResourceId |
| InvalidParameterValue | Parameter value error. |
| LimitExceeded | The quota limit is exceeded. |
| MissingParameter | Parameters are missing. |
| OperationDenied | Operation denied. |
| RequestLimitExceeded | Number of requests exceeds the frequency limit. |
| ResourceInUse | The resource is occupied. |
| ResourceInsufficient | Insufficient resources. |
| ResourceNotFound | The resource does not exist. |
| ResourceUnavailable | Resources are unavailable. |
| ResourcesSoldOut | Resources are sold out. |
| UnauthorizedOperation | Unauthorized operation. |
| UnauthorizedOperation.NoPermission | UnauthorizedOperation.NoPermission |
| UnknownParameter | Unknown parameter error. |
| UnsupportedOperation | The operation is not supported. |
Was this page helpful?
You can also Contact sales or Submit a Ticket for help.
Help us improve! Rate your documentation experience in 5 mins.
Feedback