List

Description

Returns a list of audit logs gathered from the Tines tenant.

Request

HTTP Method: GET

Query Parameter Description
before Optional Only include logs created before this timestamp
after Optional Only include logs created after this timestamp
user_id Optional Only include logs from a specific user
operation_name Optional Only include logs with a specific operation name
curl -X GET \
  https://<tenant-domain>/api/v1/audit_logs \
  -H 'content-type: application/json' \
  -H 'x-user-email: <email-address>' \
  -H 'x-user-token: <api-token>'

Response

A successful response will return a list of logs for every user operation executed on the database along with the associated inputs and the id of the user who triggered the operation.

Field description

Parameter Description
inputs JSON Inputs passed to the operation.
operation_name The name of the operation.
request_ip The IP Address the operation was triggered from
request_user_agent The user agent that the operation was triggered with
tenant_id The ID of the tenant the operation was triggered on.
user_email The email of the user who triggered the operation.
user_id The ID of the user who triggered the operation.
user_name The name of the user who triggered the operation.

Sample response

{
 "audit_logs": [
   {
     "created_at": "2022-06-24T08:35:21Z",
     "inputs": {
       "storyId": 3480,
       "inputs": {
         "actionIds": [21246],
         "diagramNoteIds": [],
         "delta": {
           "x": 61,
           "y": 0
         }
       }
     },
     "request_ip": "127.0.0.1",
     "request_user_agent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/103.0.0.0 Safari/537.36",
     "operation_name": "StoryItemsMovement",
     "tenant_id": 1,
     "updated_at": "2022-06-24T08:35:21Z",
     "user_email": "name@example.com",
     "user_id": 622,
     "user_name": "Name Person"
   }
 ],
 "meta": {
   "current_page": "https://hq.tines.io/api/v1/audit_logs?per_page=20&page=1",
   "previous_page": null,
   "next_page": null,
   "per_page": 20,
   "pages": 1,
   "count": 1
 }
},
Was this helpful?