Skip to main content
Version: 1.17.1 (latest)

Websockets

OMNI Platform is able to send the events from OMNI Agent to a third-party service via websockets.

The instructions below show how to set a websocket connection using the Postman HTTP client:

  1. Download and install Postman.
  2. Select file -> new -> WebSocket in the client interface.
  3. Specify the request URL in the opened tab:
  • ws://$DOMAIN/event-service/<event_type>/ws?endpoint_id=<endpoint_id>&scope_id=<workspace_id|agent_id|camera_id|profile_group_id> - to transmit events via websocket.
ATTENTION!

To receive events, specify the type of events that will be sent via websocket. There are 5 types for selection: non_identification, identification, har, roi, crossing.

To connect via a websocket, use endpoint_id, which is listed in the dashboard on the Web Sockets page. You can also request endpoint_id via the API (See Websocket endpoints in the API Reference section).

To filter events, specify scope_id. You can filter events by workspace ID, agent ID, camera ID or watchlist ID.

  1. The connection is established, events are sent to the server.
note

Since the Platform and Agent data are synchronized on average once per minute, the following situation can occur:

If within an average of 1 minute after deleting a profile from the database, the person, who this profile belonged to, gets into the camera’s field of view, the Agent generates an identification event and sends it to the Platform. Since such a profile no longer exists on the Platform, the Platform cannot send such an event via websocket. Such "lost" events can only be displayed through the GraphQL API of the Platform.