home

Mobile Endpoint Security

Lookout Product Documentation

Find answers about using and optimizing Lookout products.

Retrieving events using streamPosition

streamPosition is an integer value. A request with no streamPosition, or streamPosition=0 tells the API to return the earliest events. Any other streamPosition tells the API to return the events that follow that streamPosition.

To retrieve events:

  1. Send an initial request without specifying a streamPosition, or with streamPosition=0.
    The API responds with your earliest events, a new streamPosition, and a Boolean moreEvents.
  2. While moreEvents returns true, retrieve the next events by sending a new request where streamPosition is set equal to the streamPosition returned by the previous request.
  3. Once moreEvents is false, poll the API periodically to retrieve events as they occur.

    You can connect to the Mobile Risk API as many times as desired. The API returns up to 100 events per request. In rare cases, you may observe events where an event timestamp is older than the events delivered earlier in the stream. If so, the time skew should be small (less than a second).