Skip to main content
The Archetype platform is built around the concept of Lenses. Developers can stream data in and out of a lens by attaching one or more data streams to each lens. The Archetype platform uses a unified events protocol to send data in and out of a Lens and to control and query various aspects of the platform. The events protocol is built on a JSON structure, with every event being identified by a type key, paired with a corresponding event_data key.

Event Types and Event Data

Every event consists of two fields:
  1. type: a string to identify the event type
  2. event_data: a dictonary containing dedicated data for the corresponding type
For example, a developer can query the status of an active lens session using the following event:
type: session.status
event_data: {}

Event Types

Common event types are as follows.