Log and History

Pre-requisite

  • The user has to be signed in to perform the following operations.
  • The user should have an active pro-monitoring plan activated on the space.

Getting the Logs

To get the past logs of the system, The following method can be used:

  • spaceId (required): The space id for which the logs are to be fetched.
  • queryItems (required): e.g. [.init(key: .from, value: .equal(value: from)), .init(key: .to, value: .equal(value: to)), .init(key: .skip, value: .equal(value: "0")), .init(key: .limit, value: .equal(value: "50"))].
  • sortItem (optional): Ordering, typically SortItem(descending: [.loggedAt]).
Factory.proMonitoringService.securityLogs(spaceId: String, queryItems: [QueryItem], sortItem: SortItem?) -> IVPublisher<ListDataModel<SecurityLogsModel>>