Search Audit Records

POST https://{{axpAPIDomain}}/api/business-hours/v1/accounts/:accountId/audit-records:search?pageNumber=1&pageSize=5&orderBy=date desc

This API requires the Account Administrator role.

Searches the audit records based on the supplied filter.

The value of searchKeyword can be used to perform a text search across all fields within an audit record (excluding date).

Request Params

KeyDatatypeRequiredDescription
pageNumbernumberThe target page of results.
pageSizenumberThe maximum number of results per page.
orderBystringField name on which sorting needs to be performed.
The possible fields you ordered on are date (date of audit record) and author.
Field Names are case-sensitive (should be written as it is in description).
The default sorting order is descending. To specify ascending order, a suffix "asc" should be added.
For example, "date asc" for ascending or "date desc" for descending".

Request Body

{"startDate"=>"2021-11-13T20:25:39.534Z", "endDate"=>"2021-11-15T16:07:12.723Z", "event"=>"CREATED", "author"=>"jsmith@example.com", "type"=>"TIMETABLE", "ipAddress"=>"165.225.72.60", "searchKeyword"=>"timetable"}

HEADERS

KeyDatatypeRequiredDescription
appkeystring
Content-Typestring
Acceptstring

RESPONSES

status: OK

{"pagination":{"pageNumber":2,"pageSize":5,"total":20},"auditRecords":[{"date":"2021-11-14T09:24:05.234Z","event":"CREATED","author":"jsmith@example.com","ipAddress":"165.225.72.60","type":"TIMETABLE","auditData":{"autoDaylightSavingTime":false,"description":"Test Timetable","name":"TestTimetable","timeZone":"Pacific/Midway","timetableId":"5702a5be-51f9-4493-a83e-c09e768059e5"}}],"links":{"next":"/api/business-hours/v1/accounts/ASDJGE/audit-records:search?pageNumber=3\u0026pageSize=5","prev":"/api/business-hours/v1/accounts/ASDJGE/audit-records:search?pageNumber=1\u0026pageSize=5"}}