Activity Logs

Search activity logs

Search activity logs with flexible filtering and pagination. Logs are returned as LogEvent objects with metadata stored in attributes and tags. Full-text search is supported on the message field using PostgreSQL's text search capabilities. All list filters are optional - null or empty lists mean 'match all' for that field.

post/v1/activity-logs/search

Request

  • Base URL
    https://docs.grepr.ai (the document declares no server; this is the origin it was published from)
  • Auth
    • API key in header GREPR-API-KEY
    • or OpenID Connect (https://grepr-prod.us.auth0.com/.well-known/openid-configuration)

Request body

endTimestring date-time

End of time range filter. Must be a valid ISO timestamp in UTC.

limitinteger

Maximum number of results to return

logTypesstring[]

Optional filter by log types. If null or empty, matches all log types.

offsetinteger

Number of results to skip for pagination

searchQuerystring

Optional full-text search query for message content. Uses PostgreSQL's text search capabilities.

startTimestring date-time

Start of time range filter. Must be a valid ISO timestamp in UTC.

statusesstring[]

Optional filter by log statuses. If null or empty, matches all log statuses.

userIdsstring[]

Optional filter by user IDs who triggered the activity. If null or empty, matches all users.

Example request

{
  "endTime": "2024-01-01T23:59:59Z",
  "limit": 100,
  "logTypes": [
    "INTEGRATION_IMPORT",
    "JOB_EXECUTION"
  ],
  "resourceFilters": [
    {
      "resourceId": "int-123",
      "resourceType": "INTEGRATION"
    },
    {
      "resourceId": "job-456",
      "resourceType": "JOB"
    }
  ],
  "searchQuery": "failed import",
  "startTime": "2024-01-01T00:00:00Z",
  "statuses": [
    "INFO",
    "ERROR"
  ],
  "userIds": [
    "user123",
    "user456"
  ]
}

Response

activity logs retrieved successfully

Example response

{
  "items": [
    {
      "id": "034JA9FJ",
      "message": "This is a log message."
    }
  ]
}

Changes

No recorded changes to this operation across all 1 revision of this API.