List of Log Operations

Last Updated on : 2021-08-14 08:25:49download

Get the list of log operations, and support fuzzy search by the start time, end time, and operation content.

API address

GET: /v1.0/iot-03/audit/operate-logs

Request parameter

Parameter name Type IN Required Description
req AuditLogPageReq false The list of auditing logs on pages.

Description of req

Parameter name Type IN Required Description
start_time Long false The start time.
end_time Long false The end time.
operate_type String false The operation type.
key_words String false The keywords of search.
last_id String false The number of the last value.
last_record_time Long false The logging time of the last value.
size Integer false The total number of entries.
merchant_code String false The code of a specified merchant.
ext String false The extension field.

Return parameter

Parameter name Type Description
result CursorPage The list of results.

Description of result

Parameter name Type Description
last_row_key String The row key of the last entry on the page.
list List The returned result.
has_more Boolean Specifies whether to return the next page.

Description of list

Parameter name Type Description
id String The log number.
record_time Long The logging time.
uid String The unique number of a specified user.
username String The name of a specified user.
operate_type String The operation type.
operate_content String The operation content.
user_id String The ID of a specified user.
role String The role.
account String The account.
operate_geo_info String The geographic location of a specified user.
operate_ip_info String The IP address.
client_id String The project number.
merchant_code String The code of a merchant.
ext String The extension field.
project_code String The project code.

Request example

GET: /v1.0/iot-03/audit/operate-logs?size=20&start_time=1627747200000&end_time=1628524800000

Return example

{ "result": { "list": [ { "ext": "kuozhan", "merchant_code": "tuya", "operate_type": "Logout 2", "role": "admin3", "project_code": "p1622691151775t7pu9v", "client_id": "eqtpvy5ramzuwgpcl***", "operate_content": "Log out of System 2", "uid": "bay1616159871313fFcE", "user_id": "user2", "id": "77f58bfd8df62890_9223370408028725***", "operate_ip_info": "192.168.1.9", "operate_geo_info": "Shenzhen City, Guangdong Province", "record_time": 1628826050134, "account": "18036142***", "username": "***" } ], "has_more": false }, "t": 1628826135152, "success": true }

Error code

For more information, see error code.