Events

Methods described in this section relate to the events API. These methods can be accessed at TenableOT.events.

class EventsAPI(api: restfly.session.APISession)[source]
list(query_filter: Optional[dict] = None, search: Optional[str] = None, sort: Optional[List[dict]] = None, start_at: Optional[str] = None, limit: Optional[int] = 200, **kwargs) tenable.ot.graphql.iterators.OTGraphIterator[source]

Retrieves a list of events via the GraphQL API.

Parameters
  • query_filter (dict, optional) – A document as defined by Tenable OT Security online documentation.

  • search (str, optional) – A search string to further limit the response.

  • sort (List[dict], optional) – A list of order documents, each of which must contain both the field and direction keys and may also contain the optional function key. Default sort is by descending id order. Please refer to Tenable OT Security online documentation for more information.

  • start_at (str, optional) – The cursor to start the scan from (the default is an empty cursor).

  • limit (int, optional) – Max number of objects that get retrieved per page (the default is 200).

Returns

An iterator object that will handle pagination of the data.

Return type

OTGraphIterator

Example

>>>     for event in tot.events.list(limit=500):
            print(event)
schema_class

alias of tenable.ot.graphql.schema.events.EventsSchema