Retrieve an Audit Log API

On this page

Request#

Retrieve a single Audit Log by its Id on the URI.

API Key Authentication
Retrieve an Audit Log by Id
GET/api/system/audit-log/{logId}
OpenAPI Spec

Path Parameters#

logId
  • Type: Long
  • Required

The unique Id of the Audit Log to retrieve.

Response#

Response Codes
CodeDescription
200The request succeeded. The response contains a JSON body.
400The request was invalid or malformed. The response contains an Errors JSON object with the specific errors. FusionAuth also returns a 400 when the request needs a paid FusionAuth license and no license is present.
401FusionAuth didn't authorize the request. The Authorization header is missing, the API key isn't valid, or the API key doesn't have permission for this endpoint and method. The response is empty. For more information, see Unauthorized Responses.
404The object you requested doesn't exist. The response is empty.
500FusionAuth had an internal error and logged a stack trace in the FusionAuth log files. The response is empty.
503The search index is unavailable or returned an error, so FusionAuth can't complete the request. The response contains a JSON body.

Response Body#

auditLog.data
  • Type: Object

Additional details of an audit log.

auditLog.newValue
  • Type: String

The new value of a changed object.

auditLog.oldValue
  • Type: String

The previous value of a changed object.

auditLog.reason
  • Type: String

The reason why the audit log was created.

auditLog.tenantId
  • Type: UUID
  • Available since 1.65.0

The Id of the Tenant associated with this Audit Log. This field will be null for instance-scoped audit logs. The associated audit-log.create event will be delivered as a tenant-scoped event.

auditLog.id
  • Type: Long

The Audit Log unique Id.

auditLog.insertInstant
  • Type: Long

The instant when the Audit Log was created.

auditLog.insertUser
  • Type: String

The user that created the Audit Log.

auditLog.message
  • Type: String

The message of the Audit Log.

Example JSON Response
{
  "auditLog": {
    "data": {
      "externalId": "_applicationA"
    },
    "newValue:": "{\"name\": \"bar\"}",
    "oldValue": "{\"name\": \"foo\"}",
    "reason": "Because I like to change things.",
    "id": 3,
    "insertInstant": 1471796483322,
    "insertUser": "user@fusionauth.io",
    "message": "Changed Application"
  }
}