You need to enable JavaScript to run this app.
导航
LookupEvents - 查询审计事件列表
最近更新时间:2024.12.31 16:04:13首次发布时间:2023.01.04 19:09:31
我的收藏
有用
有用
无用
无用

查询审计事件列表。

调试

请求参数

下表仅列出该接口特有的请求参数和部分公共参数。更多信息请见公共参数

参数
类型
是否必填
示例值
描述
Action
String

LookupEvents

要执行的操作,取值:LookupEvents。

Version
String

2021-09-01

API的版本,取值:2021-09-01。

NextToken
String

""

用于请求下一页结果。

MaxResults
Integer

10

允许返回的最大结果数。

StartTime
Long

1735574400

查询起始时间戳。

EndTime
Long

1735578000

查询截止时间戳。

LookupConditions
Array of Object

[]

查询条件。

返回参数

下表仅列出本接口特有的返回参数。更多信息请参见返回结构

参数
类型
示例值
描述
NextToken
String

""

用于请求下一页结果。

Trails
Array of Object

[]

事件的列表。

请求示例

{
    "NextToken": "",
    "MaxResults": "",
    "StartTime": "",
    "EndTime": "",
    "LookupConditions": [
        {
            "LookupConditionKey": "",
            "LookupConditionValue": ""
        }
    ]
}

返回示例

{
  "ResponseMetadata": {
    "RequestId": "202109131754500102252431**********"
  },
  "Result": {
    "NextToken": "613f1ed7-2-5ed3-1-1",
    "Trails": [
      {
        "EventID": "2967779b-1dc8-4404-8858-a6**********",
        "EventTime": "2021-09-13T09:54:08Z",
        "EventName": "GetUser",
        "RequestID": "202109131754070102252431***********",
        "SourceIPAddress": "10.255.29.190",
        "EventSource": "iam",
        "UserName": "",
        "AccessKeyID": "AKLTODZlNWI1ODEtNTRlNC00MmEyLWIwYjYtZTI2Nz**********",
        "Region": "cn-north-1",
        "ErrorCode": "",
        "EventDetail": "{\"EventVersion\":\"v1.0\",\"EventID\":\"2967779b-1dc8-4404-8858-a6**********\",\"RequestID\":\"202109131754070102252431***********\",\"EventTime\":\"2021-09-13T09:54:08Z\",\"EventType\":\"ApiCall\",\"UserIdentity\":{\"AccountID\":\"21000*****\",\"Type\":\"Root\",\"PrincipalID\":\"21000*****\",\"TRN\":\"trn:iam::21000*****:root\",\"AccessKeyID\":\"AKLTODZlNWI1ODEtNTRlNC00MmEyLWIwYjYtZTI2Nz**********\"},\"EventSource\":\"iam\",\"EventName\":\"GetUser\",\"Region\":\"cn-north-1\",\"SourceIPAddress\":\"10.255.**.***\",\"UserAgent\":\"node-fetch/1.0 (+https://github.com/bitinn/node-fetch)\",\"RequestParameters\":\"\",\"ResponseElements\":\"\",\"ApiVersion\":\"2018-01-01\"}"
      }
    ]
  }
}

错误码

下表为您列举了该接口与业务逻辑相关的错误码。公共错误码请参见公共错误码文档。

状态码
错误码
错误信息
说明
400
InvalidParameter
The parameter '%s' is invalid.
400
SiteDoesNotMatch
The site does not match the identity.
400
BadRequest
Bad Request
400
ParameterMissing
The request parameter %s is missing.
400
InvalidTimeRange
The end time must be later than the start time.
400
InvalidParameterStartTime
The specified StartTime is invalid.
400
InvalidParameterEndTime
The specified EndTime is invalid.
403
AccessDenied
You have no permission for this action.
500
InternalError
The request has failed due to an unknown error.