ContextSuite

Basic Context Objects

Every Semantic Event is enriched with a set of standardized context objects. These objects provide a wealth of information about the environment in which the event occurred, such as the user's device, operating system, and application details. Understanding these objects is key to unlocking the full analytical power of your event stream.

Much of this context is captured automatically by the Jitsu client library, reducing the amount of manual instrumentation required. For the core event properties that work alongside these context objects, see Core Properties. Below is a breakdown of the most common context objects and their properties.


The App Object

Contains details about the application that generated the event, typically a mobile app.

PropertyDescriptionProvided By
nameThe name of the app (e.g., "MyShop App").Auto-Populated
versionThe version of the app (e.g., "1.2.0").Auto-Populated
buildThe build number of the app (e.g., "1024").Auto-Populated
namespaceThe namespace of the app (e.g., "com.myshop.app").Auto-Populated

The Device Object

Captures information about the user's device.

PropertyDescriptionProvided By
idA unique identifier for the device instance.Auto-Populated
manufacturerThe manufacturer of the device (e.g., "Apple").Auto-Populated
modelThe model of the device (e.g., "iPhone 14 Pro").Auto-Populated
nameThe user-assigned name of the device.Auto-Populated
typeThe type of device (e.g., "mobile", "tablet").Auto-Populated
ad_tracking_enabledA boolean indicating if ad tracking is on.Auto-Populated
advertising_idThe device's advertising identifier (IDFA/GAID).Auto-Populated

The OS Object

Details about the operating system of the device.

PropertyDescriptionProvided By
nameThe name of the OS (e.g., "iOS").Auto-Populated
versionThe version of the OS (e.g., "16.5.1").Auto-Populated

The Page Object

For web events, this object contains information about the page being viewed.

PropertyDescriptionProvided By
urlThe full URL of the page.Auto-Populated
pathThe path portion of the URL (e.g., "/pricing").Auto-Populated
referrerThe URL of the page that referred the user.Auto-Populated
titleThe <title> of the page.Auto-Populated
searchThe query string portion of the URL.Auto-Populated

The Screen Object

For mobile events, this object details the screen being viewed.

PropertyDescriptionProvided By
nameThe name you provide for the screen.User-Provided
heightThe height of the screen in pixels.Auto-Populated
widthThe width of the screen in pixels.Auto-Populated
densityThe pixel density of the screen.Auto-Populated

The Campaign Object

Captures marketing campaign information, typically from URL parameters.

PropertyDescriptionProvided By
nameThe name of the campaign (from utm_campaign).Auto-Populated
sourceThe source of the traffic (from utm_source).Auto-Populated
mediumThe medium of the campaign (from utm_medium).Auto-Populated
termThe keyword for the campaign (from utm_term).Auto-Populated
contentThe specific ad content (from utm_content).Auto-Populated

Event Enrichment Example

The true power of the context objects comes from automatic enrichment. A simple track event sent from the client becomes a rich, detailed record on the server.

Event as Sent by the User (Client-Side)

Here is a track event for a user adding a product to their cart. Notice how little information the developer needs to provide manually.

JSON
json
1{
2"type": "track",
3"event": "Product Added",
4"userId": "user-9b8d7c",
5"properties": {
6"cart_id": "cart-a1b2c3",
7"product_id": "prod-f4g5h6",
8"sku": "SKU-BLK-LG",
9"price": 49.99,
10"quantity": 1
11}
12}

Event After Auto-Population (Server-Side)

After the event is received, it is enriched with the context objects. The final event stored is much more detailed, providing a complete picture of the interaction without extra work from the developer.

JSON
json
1{
2"type": "track",
3"event": "Product Added",
4"userId": "user-9b8d7c",
5"timestamp": "2025-07-18T20:45:30.123Z",
6"messageId": "msg_a1b2c3d4e5f6",
7"event_gid": "...",
8"properties": {
9"cart_id": "cart-a1b2c3",
10"product_id": "prod-f4g5h6",
11"sku": "SKU-BLK-LG",
12"price": 49.99,
13"quantity": 1
14},
15"context": {
16"ip": "203.0.113.1",
17"locale": "en-US",
18"timezone": "America/Los_Angeles"
19},
20"page": {
21"path": "/products/some-product-page",
22"referrer": "https://example.com/category/shirts",
23"search": "",
24"title": "Cool Black Shirt - MyShop",
25"url": "https://example.com/products/some-product-page"
26},
27"device": {
28"id": "...",
29"manufacturer": "Apple",
30"model": "iPhone",
31"type": "mobile"
32},
33"os": {
34"name": "iOS",
35"version": "16.5"
36},
37"user_agent": {
38"signature": "Mozilla/5.0 (iPhone; CPU iPhone OS 16_5 like Mac OS X) ..."
39}
40}