Audit Log
You need View Audit Log permission to view audit logs.
Audit Logs
- Audit Logs Manage
GET global/auditLogs
GET global/auditLogs/{id}
POST global/auditLogs
Model
Audit Log JSON Format
Audit Log is represented as simple flat JSON objects with the following keys:
Name | Type | Description |
---|---|---|
id |
guid | Id of the audit log. |
moduleId |
string | Module which the action belongs to. |
actionSummary |
string | Summary of the action. |
actionDetails |
string | Details of the action. |
agentId |
guid | Id of the agent who did the action. |
createTime |
datetime | Audit log create time. |
actionTypeId |
integer | Id of the action type. |
agent |
agent | Reference to Agent. |
actionType |
actionType | Reference to Action Type. |
module |
module | Reference to Module. |
Endpoint
Get the list of Audit Logs
GET global/auditLogs
Parameters:
Name | Type | In | Required | Description |
---|---|---|---|---|
anyAgent |
guid | query | no | Id of the agent. |
keywords |
string | query | no | The keywords associated with the action. |
actionTime |
DateTime | query | no | The created time of the action. |
actionType |
int | query | no | Action types for different applications. Call this interface 'Get the list of ActionTypes' to get action types. |
module |
string | query | no | The module of the action. Call this interface 'Get the list of Modules' to get modules. |
include |
string | query | no | Allowed values are "agent", "actionType", "module". |
Response:
An array of Audit Log
Example
Sample Request:
curl https://api11.comm100.io/v4/global/auditLogs \
-X
'GET'
\
-H
'Authorization: Bearer {access_token}'
\
Response:
HTTP/1.1 200 OK
Get a single Audit Log
GET global/auditLogs/{id}
Parameters:
Name | Type | In | Required | Description |
---|---|---|---|---|
include |
string | query | no | Allowed values are "agent", "actionType", "module". |
Response:
Example
Sample Request:
curl https://api11.comm100.io/v4/global/auditLogs/aa11589d-b3cd-4f46-874b-e07f799e593c \
-X
'GET'
\
-H
'Authorization: Bearer {access_token}'
\
Response:
HTTP/1.1 200 OK
Create a new Audit Log
POST global/auditLogs
Parameters:
Name | Type | In | Required | Description |
---|---|---|---|---|
moduleId |
string | body | no | Module which the action belongs to. |
actionSummary |
string | body | no | Summary of the action. |
actionDetails |
string | body | no | Details of the action. |
agentId |
guid | body | no | Id of the agent who did the action. |
createTime |
datetime | body | no | Audit log create time. |
actionTypeId |
integer | body | no | Id of the action type. |
Response:
Example
Sample Request:
curl https://api11.comm100.io/v4/global/auditLogs \
-X
'POST'
\
-H
'Authorization: Bearer {access_token}'
\
-H
'Content-Type: application/json'
\
-D
'{"moduleId":"Global","actionSummary":"Update Restricted Words : 10000 (ID: 10000) ","actionDetails":"[{\"fieldName\":\"avatar\",\"newValue\":\"https://dash11.comm100dev.io/Global/agents/c1ad60f8-e2e1-47d2-ad50-8b5de24d2b06/avatar?SiteId=10000&version=0a81b7ef4afeecb251b27c3e45b4ba5a\",\"oldValue\":\"https://dash11.comm100dev.io/Global/agents/c1ad60f8-e2e1-47d2-ad50-8b5de24d2b06/avatar?SiteId=10000&version=920b345dfe5d42cf0441305e5a1191dc\"},{\"fieldName\":\"systemAvatarId\",\"newValue\":\"1768a098-f138-eb11-ac9f-18c04d023ea9\",\"oldValue\":\"2d83d4fd-3114-eb11-80fc-00155d081d0b\"}]","agentId":"07975907-ee24-4722-b7df-711a2a4f5dba","createTime":"2021-04-16T10:05:38.7593288Z","actionTypeId":"1"}'
Response:
HTTP/1.1 201 Created