Star us on GitHub
Star
Menu

Session Search

In highlight.io, you can search for a session by any of the data you send us (via the SDK) throughout a session. The data you send us can be in the form of:

  • click data

This is done using search query, and we cover how search/instrumentation for each type of these queries works below.

Searching for sessions

For general information on searching sessions, check out our Search docs.

By default, Highlight will show completed sessions that have been fully processed, completed=true. For newer projects with less sessions, Highlight will show all sessions, and provide an example of how to use the search query, completed=(true or false).

Default key

The default key for session search searches across multiple attributes. These columns include the user's identifier and location. This could be the user's email, device_id, or given identifier, as well as their city or country.

For example, if you enter an expression without a key (highlight) it will be used as the key for the following expression.

email=*highlight* OR city=*highlight*
Copy
Track Searching

For track calls, you can search for sessions based on the properties that you gave to the track method. For example, if you want to filter sessions out by the value of a tracked feature toggle, FeatureFlag-Analytics, then you can use the the following query:

FeatureFlag-Analytics=true
Copy
Identify Searching

For identify calls, you can search for sessions based on the properties that have a name of identifier, and the value corresponds to the value sent to the first argument of H.init (see here). This looks like the following query:

identifier=spencer@highlight.io
Copy
Searching by User Clicks

When using Highlight, you might be interested in querying for sessions where a user clicked a certain HTML element. Highlight records users' clicks on the page as two queryable properties: clickSelector and clickInnerText.

  • clickSelector is the HTML Element's target's selector, concatinating the element's tag, id and class values.

  • clickTextContent is the HTML Element's target's textContent property. Only the first 2000 characters are sent.

You can then use the session filters to search for text in the two fields. An example of these queries are:

clickSelector=svg clickTextContent="Last 30 days"
Copy
Searching by Visited URL

You can also search for sessions based on the URL that the user visited. This is useful if you want to search for sessions where a user visited a certain page on your site.

To perform this search, you can use the visit-url filter. An example of this query is:

visited-url="https://app.highlight.io/"
Copy

Since many urls contains the special characters, : and =, you can wrap the value in quotations to avoid any errors.

And like all of our filters, you can use contains, =**, and matches, =//, to help acheive the query you need. For example, to get all sessions that visited the sessions page, we can use the following queries:

visited-url=*sessions* visited-url=/.+\d/sessions.+/
Copy
Autoinjected attributes

By default, Highlight's SDKs will autoinject attributes to provide additional context to help with searching for sessions.

AttributeDescriptionExample
active_lengthTime the user was active in milliseconds60000 (1 minute)
browser_nameBrowser the user was onChrome
browser_versionBrowser version the user was on124.0.0.0
cityCity the user was inSan Francisco
completedIf the session is finished recordingtrue
countryCountry the user was inGreece
device_idFingerprint of the user's device1018613574
environmentThe environment specified in the SDKproduction
first_timeIf its the user's first sessionfalse
has_commentsIf someone has commented on the Highlight sessiontrue
has_errorsIf the session contained linked errorstrue
has_rage_clicksIf the user rage clicked in the sessiontrue
identifiedIf the session successfully identified the userfalse
identifierThe idenifier passed to H.init1
ipThe IP address of the user127.0.0.1
lengthThe total length of the session60000 (1 minute)
os_nameThe user's operating systemMac OS X
os_versionThe user's operating system version10.15.7
pages_visitedThe number of pages visited in the session10
sampleA unique order by to sample sessionsc1c9b1137183cbb1
service_versionVersion of the service specified in the SDKe1845285cb360410aee05c61dd0cc57f85afe6da
stateState the user was inVirginia
viewed_by_anyoneIf the session has been viewed by anyonetrue
viewed_by_meIf your account has viewed the sessionfalse
Helpful tips

Use the completed=false to view live sessions.

Create a new sample of sessions by clicking "New Random Seed" for the sample's values.

Currently, length and active length are not supported by time suffixes, but this functionality is coming soon.

Demo