Skip to main content

Browser agent collection data

The WhaTap browser agent collects events that occur from each user's browser, reprocesses the collected data, and uses the data for monitoring. All collected data is user session dependent.

Types

The following lists the types of data that the WhaTap browser agent collects.

  • Long: A unique ID data type in the long to string32 format.
  • TimeStamp: Time stamp upon measurement, in milliseconds (ms).
  • HighResolutionTime: Elapsed time in milliseconds (ms)
  • TimeSet: The start time stamp and the elapsed time are displayed for display of a timeline.
  • It is any of ResourceType : document, xhr, fetch, beacon, css, script, image, font, media, and other.
  • ErrorType : It is any of console, onError, promiseRejection, fetchError, xhrError, and messageError.

Common collection data

When any event occurs, the collected basic data is as follows:

Data nameTypeDescriptionExample
sessionIDLongA unique ID issued when a web application user starts navigating to a web page. The maximum duration of a session is 4 hours, and the ID expires after 15 minutes of inactivity. IDs are stored in browser cookies.x7dbvq64ga80sd
userIDLongIt is a unique ID issued when a web application user first connects and has no expiration time. IDs are stored in browser cookies.z7eqnnitlc19j9
sendEventIDLongThis is a unique request ID issued when data is transmitted to the collection server after an event occurs.x4rp4tnuq25i0h
page.urlStringThe URL of the page where an event occurred.https://site.whatap.io/8/dashboard?dataKey=abcd
page.hostStringThe URL domain name of the page where an event occurred.site.whatap.io
page.pathStringThe URL path of the page where an event occurred./8/dashboard
page.queryStringThe URL parameter of the page where an event occurred.dataKey=abcd
page.protocolStringThe URL protocol of the page where an event occurred.https
page.titleStringThe document title of the page where an event occurred.SaaS Monitoring No.1 WhaTap Monitoring | WhaTap
userAgentStringThe useragent of the browser where an event occurred.Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7)
AppleWebKit/537.36 (KHTML, like Gecko)
Chrome/103.0.0.0
Safari/537.36

Page Load Event

This event occurs when you access the web application and the page content is fully loaded. The basic collection data is as follows:

Data nameTypeDescriptionExample
navigationTiming.startTimeStampTimeStampIt is the time stamp of navigationStart. Time stamp of the page that starts loading1658057382311
navigationTiming.eventIDLongThis is a unique ID issued when a page loading event occurs.x7mkg24tags307
navigationTiming.redirectTimeSetTime taken for HTTP redirection.{duration: 10, start: 315}
navigationTiming.cacheTimeSetTime taken to load the app cache resources.{duration: 5, start: 325}
navigationTiming.dnsTimeSetTime taken for browsing the website domain.{duration: 5, start: 330}
navigationTiming.connectTimeSetTime taken for TCP connection setting.{duration: 6, start: 335}
navigationTiming.sslTimeSetTime taken for the ssl handshake process.{duration: 5, start: 336}
navigationTiming.downloadTimeSetTime taken for document downloading.{duration: 100, start: 341}
navigationTiming.firstByteTimeSetIt is the time taken for the browser to request a document from the server and receive the first byte.{duration: 10, start: 341}
navigationTiming.domInteractiveHighResolutionTimeIt is the time when the browser finished parsing the document from navigationStart. DOM is ready.441
navigationTiming.domContnentLoadedTimeSetTime taken to build the DOM tree.{duration: 50, start: 441}
navigationTiming.domCompleteHighResolutionTimeThis is the time between navigationStart and completion of loading documents and resources.491
navigationTiming.domLoadTimeSetTime taken for the onload event.{duration: 1, start: 491}
navigationTiming.backendTimeHighResolutionTimeTime from navigationStart to resource downloading.126
navigationTiming.frontendTimeTimeSetTime from browser parsing completion to load event completion.{duration: 51, start: 441}
navigationTiming.loadTimeHighResolutionTimeTime from navigationStart to loadEventEnd.492
totalDurationHighResolutionTimeThis is the time between navigationStart and completion of importing the final page.550

Page load time

Pageload time is the total time from the moment the web browser requests the URL of a page until all of the page's resources (HTML, CSS, JavaScript, images, etc.) are downloaded and processed, and the browser completely renders the page so that it is available.

To collect page load times, browser agents collect them through the Navigation Timing API, one of the web APIs provided by the browser. This API provides measurements of the times for each step (e.g. request start, response, rendering start and completion).

There are measurement events accessible through the PerformanceTiming interface that are measured in milliseconds. The following is a list of those events in the order in which they occur.

Navigation timing

EventDescriptionRemarks
navigationStartStarting point of page navigation.-
redirectStartFirst HTTP redirection time point.If there is no redirection, the value is 0.
redirectEndTime point when the response to the last redirection has been received.If there is no redirection, the value is 0.
fetchStartTime point when the browser begins the process of fetching resources.Time point when cache lookup has begun.
domainLookupStartStarting point for DNS lookups for domain names.The browser begins converting the host name in the URL into an IP address. It can have the same value as fetchStart if there is cached DNS information or information in the local hosts file.
domainLookupEndTime point when the DNS lookup has been completed.The browser successfully obtains the IP address for the domain. Even if the DNS lookup fails, it is logged with this time point.
connectStartTime point when the connection to the server has begun.TCP connection begins. If you are reusing the persistent connection, you can have the same value as domainLookupEnd.
connectEndTime point when the connection to the server has been established completely.The TCP handshake is completed. For HTTPS, the SSL/TLS handshake is also completed by this time point. Even if the connection fails, it is logged with this time point.
secureConnectionStartTime point when the HTTPS connection has begun.It is recorded only when applicable.
requestStartTime point when requesting resources to the server has begun.-
responseStartTime point when receiving the first byte of the response from the server has begun.It is used to calculate the server's initial response time (Time to First Byte, TTFB) starting from the time the first byte of the HTTP response header was received.
responseEndTime point at which the last byte has been received from the server.Time point when the entire response (header and body) has been received. If you have a redirection response, it is the time point when the last byte of the final response has been received.
domInteractiveIt is the time point when DOM parsing has been finished and the script is ready.-
domContentLoadedEventStartTime point when the DOMCONTENTLOADED event has occurred.At this time, the loading and parsing of the HTML document have been completed and the DOM tree has been completely built.
domContentLoadedEventEndTime point at which all DOMContentLoaded event handlers have completed execution.-
domCompleteTime point at which both DOM loading and subresource loading have been completed.-
loadEventStartTime point just before the load event.Time point immediately after the DOM is fully configured and all resources have been loaded. Moment just before the window.onload event handler has been executed.
loadEventEndTime point at which all load event handlers have completed execution.The page and all subresources are fully loaded.

Router change event

This event occurs when you move to a page in a single page application (SPA) type web application. The basic collection data is as follows:

Data nameTypeDescriptionExample
loadTimeHighResolutionTimeTime taken to change the router.500
startTimeStampTimeStampTimestamp of the router change start time.1658057382311
endTimeStampTimeStampTimestamp of the router change completion time.1658057382811
pageLocationStringThe URL of the page where a router change event occurred.https://site.whatap.io/8/dashboard?dataKey=abcd
hostStringURL domain name of the page URL where a router change event occurred.site.whatap.io
pathStringThe URL path of the page where a router change event occurred./8/dashboard
queryStringThe URL parameter of the page where a router change event occurred.dataKey=abcd
protocolStringThe URL protocol of the page where a router change event occurred.https
isCompleteBooleanThis value is used to distinguish when a router is changed to another page while the router change is not completed.true

Resource Load Event

This event occurs when you call a resource while using the web application. The basic collection data is as follows:

Data nameTypeDescriptionExample
startTimeHighResolutionTimeTime from navigationStart to the resource request start.1000
startTimeStampTimeStampTimestamp of the resource request start.1658057382321
eventIDLongA unique ID issued each time a resource is fetched.x280or4ok0kqo0
typeResourceTypeResource type.image
urlStringResource URL.https://unpkg.com/purecss@2.0.3/build/pure-min.css?dataKey=abcd
urlHostStringDomain name of the resource URL.unpkg.com
urlPathStringPath of the resource URL./purecss@2.0.3/build/pure-min.css
urlQueryStringParameter of the resource URL.dataKey=abcd
urlProtocolStringProtocol of the resource URL.https
is3rdPartyBooleanThis value is used to identify resources requested by the 3rd party.false
timing.durationHighResolutionTimeTime taken to complete the resource download.61
timing.sizeNumberResource encoding size.20
timing.redirectTimeSetTime taken for HTTP redirection.{duration: 10, start: 315}
timing.cacheTimeSetTime taken to load the app cache resources.{duration: 5, start: 325}
timing.dnsTimeSetTime taken to search the resource domain.{duration: 5, start: 330}
timing.connectTimeSetTime taken for TCP connection setting.{duration: 6, start: 335}
timing.sslTimeSetTime taken for the ssl handshake process.{duration: 5, start: 336}
timing.firstByteTimeSetIt is the time taken for the browser to request resources from the server and receive the first byte.{duration: 10, start: 341}
timing.downloadTimeSetTime taken to complete the resource download.{duration: 100, start: 341}
resourceInfo.methodStringResource request method.POST
resourceInfo.statusNumberResource request state.200

Error event

It is an error that occurred from the browser while you are using the web application. The basic collection data is as follows:

Data nameTypeDescriptionExample
messageStringMessage displayed when an error occurs.SyntaxError: Unexpected end of JSON input
stackStringStack information displayed when an error occurs.at printWarning (webpack-internal:///../node_modules/react-dom/cjs/react-dom.development.js:86:30)

at error (webpack-internal:///../node_modules/react-dom/cjs/react-dom.development.js:60:7)
timestampTimeStampTimestamp of an error occurred.1658057382321
typeErrorTypeError type.onError
statusNumberThis is the error status value to be collected when the error type is xhr or fetch.501
urlStringThis is the AJAX request URL when the error type is xhr or fetch.https://site.whatap.io/yard/api?pcode=8&type=summary

Core Web Vitals Event

Core Web Vitals are three metrics that Google considers important, among various measurement values that affect the user experience of web content. The basic collection data is as follows:

Data nameTypeDescriptionExample
lcpHighResolutionTimeLargest Contentful Paint (LCP), which reports the rendering time of the largest image or text block within the viewport based on the first page loaded time.12334
fidHighResolutionTimeFirst Input Delay (FID), from the first time you interact with the page (e.g. clicking a link, tapping a button, or using a custom JavaScript-based control) to the time to start the event handler in response to that interaction.7
clsNumberCumulative Layout Shift (CLS) is a score that quantifies the unexpected layout shifts caused by the dynamically loaded content.2