List user audit events¶
View the operation records of the specified user in the current workspace in chronological order.
GET $CLOUDSIGMA_API_BASE/workspaces/{workspace_id}/iam/users/{user_id}/audit-events
Before you call¶
Configure the CloudSigma regional endpoint and authentication before calling. The endpoint, credentials, workspace, and resource IDs must belong to the same region. First select user. If you need to continue reading, keep the cursor returned from the previous page.
Prepare personal access token and target workspace ID that can access the target workspace.
Request parameters¶
curl -G "$CLOUDSIGMA_API_BASE/workspaces/$WORKSPACE_ID/iam/users/$USER_ID/audit-events" \
-H "X-API-Key: $CLOUDSIGMA_API_KEY" \
-H "X-Workspace-ID: $WORKSPACE_ID" \
--data-urlencode "limit=20"
Path parameters
Parameter |
Type |
Required |
Description |
|---|---|---|---|
workspace_id |
string |
Yes |
Target workspace ID. |
user_id |
string |
Yes |
The IAM user ID of the accepted member, taken from the iam_user_id of the same record in the user list. |
Query parameters
Parameter |
Type |
Required |
Description |
|---|---|---|---|
cursor |
string |
No |
The cursor returned from the previous page. |
limit |
integer |
No |
The quantity per page, default is 20, range is 1~100. |
When data.next_cursor is not empty, use it as cursor for the next request. Stop turning pages when empty.
user_id in the path fills in the iam_user_id returned by the user list, and the member must have accepted the invitation. id in the list is the product account UID and cannot replace iam_user_id. Pending invitations cannot be used with this interface.
Successful response¶
{
"code": "OK",
"msg": "OK",
"data": {
"events": [],
"next_cursor": "",
"request_id": "req-001",
"trace_id": "trace-001"
}
}
Field |
Type |
Description |
|---|---|---|
|
string |
success code. |
|
string |
Response information. |
|
object |
The data returned by this operation. |
|
array of object |
User operation record of the current page. |
|
string |
Association ID. |
|
string |
Audit event type. |
|
string |
Association ID. |
|
string |
Operator type. The values are |
|
string |
Association ID. |
|
string |
Display information. |
|
string |
Association ID. |
|
string |
status. |
|
array of object |
Summary. |
|
string |
Match key. |
|
string |
Value. |
|
string |
Lifecycle version. |
|
integer |
Creation time. |
|
string |
Next page cursor. When empty there is no next page. |
|
string |
Request association ID. |
|
string |
Link tracking ID. |
Error response¶
The only common errors are code and msg, and data:null is not returned. data is only possible if there is a core authorization error code, which contains the request ID, tracking ID, and core error code.
{
"code": "ErrParamInvalid",
"msg": "请求参数无效"
}
Field |
Type |
Description |
|---|---|---|
code |
string |
error code. |
msg |
string |
error message. |
Common HTTP errors¶
HTTP status |
Error code |
Common cause |
Recommended action |
|---|---|---|---|
400 |
|
Invalid request field, workspace, or operation precondition. |
Fix the request parameters and submit again. |
401 |
|
Missing or invalid authentication credentials. |
Check the credential type, expiration, and authentication header. |
403 |
|
The current identity or active role does not have permission for this operation. |
Use an authorized identity or contact an administrator to grant access. |
404 |
|
The target object or required reference was not found. |
Verify the object identifier, workspace, and current status. |
409 |
|
Conflict in resource state, request payload, or concurrent modification. |
Re-read the current state and version, then handle according to the latest result. |
500 |
|
Internal processing failed; write operations may have been partially applied. |
Retain request and trace details, and verify the current state before retrying. |
503 |
|
A business, runtime, or authorization dependency is temporarily unavailable. |
After the dependency recovers, check existing results first instead of blindly repeating writes. |