Tracking Fields Reference

Complete reference of all data fields collected by the Pipetrace tracking script.

The Pipetrace tracking script sends page, device, and identifier data with events. Visitor identifiers persist in localStorage, a first-party cookie, and IndexedDB; session identifiers use sessionStorage.

Identifiers

Identifiers for visitors and browser sessions

FieldTypeRequiredDescription
site_idstringYesYour unique tracking ID from the data-site attribute
visitor_idstringYesPersistent visitor identifier stored in browser storage and sent with events
session_idstringYesTab session ID; renewed after 30 minutes of inactivity, including SPA use

Event Metadata

Core event information

FieldTypeRequiredDescription
event_contract_versionnumberNoCurrent tracker sends 2; stored as event_data.contract_version
event_page_instance_idstringNoShared by one pageview, its interactions and its exit; stored in event_data.page_instance_id
event_typestringYesType of event (pageview, page_exit, custom, etc.)
timestampISO 8601YesWhen the event occurred

Page Context

Information about the current page

FieldTypeRequiredDescription
urlstringNoFull page URL including query string
pathstringNoURL path (e.g., /pricing, /blog/post-1)
titlestringNoDocument title from <title> tag

Referrer Attribution

Traffic source information

FieldTypeRequiredDescription
referrerstringNoFull referrer URL
referrer_sourcestringNoParsed source (google, facebook, chatgpt, etc.)
referrer_mediumstringNoTraffic medium (search, social, ai, referral, direct)

Device Information

Visitor's device and browser details

FieldTypeRequiredDescription
device_typeenumNodesktop, mobile, or tablet
browserstringNoBrowser name (Chrome, Firefox, Safari, Edge, Opera)
browser_versionstringNoMajor browser version number
osstringNoOperating system (Windows, macOS, iOS, Android, Linux)
os_versionstringNoOS version number

Screen & Viewport

Display dimensions and resolution

FieldTypeRequiredDescription
screen_widthnumberNoPhysical screen width in pixels
screen_heightnumberNoPhysical screen height in pixels
viewport_widthnumberNoBrowser viewport width in pixels
viewport_heightnumberNoBrowser viewport height in pixels

Connection Quality

Network information (when available)

FieldTypeRequiredDescription
connection_typeenumNo4g, 3g, 2g, or slow-2g

Locale

Language and timezone

FieldTypeRequiredDescription
languagestringNoBrowser language code (e.g., en-US, pt-BR)
timezonestringNoIANA timezone (e.g., America/New_York)

Session Context

Session and visitor flags

FieldTypeRequiredDescription
is_new_sessionbooleanNoTrue for the first pageview of a session
is_new_visitorbooleanNoTrue when the server recognizes a new persistent visitor identifier
entry_pagestringNoFirst page visited in this session
page_numnumberNoOne-based page number for contract v2; legacy unversioned trackers started at 2

UTM Parameters

Campaign tracking parameters

FieldTypeRequiredDescription
utm_sourcestringNoTraffic source (google, newsletter, etc.)
utm_mediumstringNoMarketing medium (cpc, email, social)
utm_campaignstringNoCampaign name or ID
utm_contentstringNoContent variation (for A/B testing)
utm_termstringNoPaid search keywords

Engagement Metrics

Sent with page_exit events

FieldTypeRequiredDescription
time_on_pagenumberNoSeconds spent on the page (active time only)
scroll_depthnumberNoMaximum scroll depth (0-100%)
engagement_scorenumberNoCalculated engagement score (0-100)
is_bouncebooleanNoTrue if visitor only viewed one page

Core Web Vitals

Observed document metrics sent once in a web_vitals event; missing samples are omitted

FieldTypeRequiredDescription
web_vitals_lcpnumberNoLargest Contentful Paint in ms
web_vitals_fidnumberNoFirst Input Delay in ms (legacy)
web_vitals_inpnumberNoInteraction to Next Paint in ms
web_vitals_clsnumberNoCumulative Layout Shift score (zero is valid when supported)
web_vitals_fcpnumberNoFirst Contentful Paint in ms
web_vitals_ttfbnumberNoTime to First Byte in ms

Engagement Score Calculation

The engagement score (0-100) is calculated from multiple factors:

FactorMax PointsFormula
Time on Page30min(30, seconds / 2)
Scroll Depth30depth × 0.3
Click Count20min(20, clicks × 4)
Interactions20min(20, interactions × 2)

Web Vitals Thresholds

Google's recommended thresholds for Core Web Vitals:

MetricGoodNeeds ImprovementPoor
LCP≤ 2.5s≤ 4.0s> 4.0s
INP≤ 200ms≤ 500ms> 500ms
CLS≤ 0.1≤ 0.25> 0.25
FCP≤ 1.8s≤ 3.0s> 3.0s
TTFB≤ 800ms≤ 1.8s> 1.8s