Solved

Export Netbrain System Audit Logs

  • 21 October 2021
  • 1 reply
  • 18 views

Userlevel 2

I need to export all audit logs of Netbrain into a file or database on monthly basis. How to export "audit logs" from "System Management" to a csv file ? 

icon

Best answer by pradeep.gaddameedi 21 October 2021, 12:30

View original

1 reply

Userlevel 1

Hi Rakesh, 

First of all you need Highest level privilege access to do that. From the NetBrain REST API (NetBrain-REST-API-R10), you can use the API Server URL : “http(s)://NetBrain-WebAPI-IP/ServicesAPI/API/V1/CMDB/AuditLogs”. Here you have an option to filter the audit logs based on the time frame, tenant id, domain id etc. The output will be in JSON format sorted from the latest to earliest. 

 

Sample output:

{
"auditLogs":[
{
"time":"2020-05-26T14:18:22.785Z",
"userName":"ui.user1",
"tenantName":"Initial Tenant",
"domainName":"Initial Domain",
"machineName":"pool-96-237-64-80",
"ipAddress":"96.237.64.81",
"userAgent":"Chrome",
"module":"System Advanced Settings",
"message":"Enable Audit Log",
"status":0
},
{
"time":"2020-05-26T14:18:42.536Z",
"userName":"api.user1",
"tenantName":"",
"domainName":"",
"machineName":"pat-149-96-5-12",
"ipAddress":"149.96.5.12",
"userAgent":"Unknown",
"module":"Login",
"message":"Log in to get an authentication token with username api.user.",
"status":0
}
],
"statusCode": 790200,
"statusDescription":"Success."
}

 

For more info in API documentation please follow below link:

Audit Logs REST API Design

 

Thanks

Reply


Community |  Ideas

Facebook |  Instagram |  Youtube |  Twitter |  LinkedIn
Privacy & Security Statement  |  Terms & Conditions |  Impressum  |  UK Modern Slavery Statement