Audit Log API
The Audit Log API provides endpoints for retrieving records of actions and changes within your Nected workspace. These logs are essential for tracking user activities, monitoring changes, and maintaining security within the workspace.
All Audit Log API endpoints require an authenticated request using the nected-api-key
header. This key is specific to your workspace and must be kept secure.
Note: By default, the nected-api-key is set to private for security purposes. To retrieve your nected-api-key, follow these steps:
Log in to Nected.
Go to Authorization page from the left sidebar
View or regenerate your
nected-api-key
to use in API requests.
For easier testing and exploration, the Audit Log API endpoints are available in a Postman Collection.
Endpoints
1. Get All Audit Logs
Retrieve a paginated list of audit logs for a specified module within your workspace. This endpoint is useful for monitoring actions performed by users in different modules.
Endpoint: GET /dev/audit/audit/search
Method: GET
Description: Retrieves a list of audit logs for a specified module in your workspace.
Request Parameters
Headers:
nected-api-key
(string, required) - Your API key to authenticate and link the request to your workspace. Learn how to get it here.
Query Parameters:
pageNo
(integer, optional) - Page number for paginated results. Default is 1.pageSize
(integer, optional) - Number of records per page. Default is 10, maximum is 10.search
- rule_name or any texttype
- Type can be anything among these: ruleSet | simpleRule | dataSet | connector | globalVar | decisionTable | systemAPIKey | authConfig | cron | workflow,nectedWorkflow | api | delay | webhookevent
In events you can set these: test | api | roleRevoke | roleUpdate | cronTest | cron | webhook | delayedTest | delaystatus
- Status can be success,Completed | error,Failed environment production | staging startDate date endDate date
Example Request
Response Parameters
logId (string) - Unique identifier of the audit log entry.
timestamp (integer) - Unix timestamp indicating when the action was performed.
user (string) - Identifier of the user who performed the action.
action (string) - Type of action recorded (e.g.,
create
,update
,delete
).module (string) - Module where the action occurred.
details (object) - Additional information about the action, such as affected entities or parameters.
Example Response
Errors
401 Unauthorized: Missing or invalid
nected-api-key
.Example:
{"error": "Unauthorized access. Invalid API key."}
404 Not Found: Specified module does not exist in the workspace.
Example:
{"error": "Module not found."}
2. Get Audit Log Detail
Retrieve detailed information for a specific audit log entry. This endpoint provides in-depth information about a particular action.
Endpoint: GET /dev/audit/audit/:log-id
Method: GET
Description: Retrieves details of a specific audit log entry by log-id
within the specified module.
Request Parameters
Headers:
nected-api-key
(string, required) - Your API key to authenticate and link the request to your workspace.
Path Parameters:
log-id
(string, required) - The unique identifier for the specific audit log entry.
Example Request
Response Parameters
logId (string) - Unique identifier of the audit log entry.
timestamp (integer) - Unix timestamp when the action occurred.
user (string) - Identifier of the user who performed the action.
action (string) - Type of action recorded.
module (string) - Module within which the action took place.
description (string) - A detailed description of the action taken.
details (object) - Additional data related to the action, such as the affected entity and fields.
Example Response
Errors
401 Unauthorized: Missing or invalid
nected-api-key
.Example:
{"error": "Unauthorized access. Invalid API key."}
404 Not Found: Specified
log-id
not found within the module.Example:
{"error": "Audit log entry not found."}
Error Responses
The Audit Log API may return specific errors if the request fails. Common error responses include:
401 Unauthorized: Indicates that the
nected-api-key
is missing or invalid. Ensure that you are using the correct API key for your workspace.Example Response:
404 Not Found: This error occurs if the specified module or log ID does not exist in the workspace.
Example Response:
Example Response for log ID:
Pagination
The Get All Audit Logs
endpoint supports pagination to help manage large sets of audit records. The following query parameters control pagination:
pageNo
(integer, optional) - Specifies the page number to retrieve, with a default of 1.pageSize
(integer, optional) - Specifies the number of records per page, with a default of 10 and a maximum of 10.
Example usage of pagination in the API:
This concludes the Audit Log API Documentation. These endpoints provide secure and comprehensive access to audit logs within your Nected workspace, empowering you to track and review actions for improved security and operational oversight.
Last updated