# /logs

# Route Details

# GET /logs

Retrieves all logs stored in the database, filtered according to the query parameters provided and ordered by latest first.

# Request

  • Method: HTTP GET

  • Query parameters, allows filtering by parameters provided (at least one or more):

    • path: Get logs of a file/directory (prioritized over inpath)
    • inpath: Get logs within a directory
    • type: Get logs of a certain event type, see list.
    • user: Get logs of events made by a user

# Response

Status Code Description
200 Array of variable length, with JSON object for each log entry.
401 Unauthorized. Applies if /list route authorization enabled in config.yaml.
429 Too Many Requests
500 Internal Server Error

Example 200 response body:

[
  {
    "log_id": 1,
    "username": null,
    "display_name": "deafnv",
    "ip_address": "111.111.11.111",
    "file_id": "1688849860271907",
    "event_type": "RETRIEVE",
    "event_path": "/testdir/test.jpg",
    "event_old": null,
    "event_new": null,
    "event_data": null,
    "created_at": "2023-07-09T11:36:11.948Z"
  }
]

# List of event types

# File events
Route Name Event Type
/retrieve RETRIEVE
/upload UPLOAD
/delete DELETE
/copy COPY
/move MOVE
/rename RENAME
/makedir MAKEDIR
# Authorization events
Route Name Event Type
/authorize/register REGISTER
/authorize/login LOGIN
/authorize/delete DELETEUSER
/authorize/get APILOGIN
/authorize/logout LOGOUT
/authorize/verify VERIFY