Cloudflare Docs
Zaraz
Visit Zaraz on GitHub
Set theme to dark (⇧+D)

Properties reference

Cloudflare Zaraz offers properties that you can use when configuring the product. They are helpful to send data to a third-party tool or to create triggers as they have context about a specific user’s browser session and the actions they take on the website. Below is a list of the properties you can access from the Cloudflare dashboard and their values.

​​ Web API

PropertyTypeDescription
Track NameStringReturns the name of the event sent using the Track method of the Web API. Refer to the Track method for more information.
Track Property: name:StringReturns the value of a zaraz.track() eventProperties key. The key can either be directly used in zaraz.track() or set using zaraz.set(). Set the name of your key here. Refer to the Set method for more information.

​​ Page Properties

PropertyTypeDescription
Page character encodingStringReturns the document character encoding from document.characterSet.
Page referrerStringReturns the page referrer from document.referrer.
Page titleStringReturns the page title.
Query param: name:StringReturns the value of a URL query parameter. When you choose this variable, you need to set the name of your parameter.
URLStringReturns a string containing the entire URL.
URL base domainStringReturns the base domain part of the URL, without any subdomains.
URL hostStringReturns the domain (that is, the hostname) followed by a : and the port of the URL (if a port was specified).
URL hostnameStringReturns the domain of the URL.
URL originStringReturns the origin of the URL — that is, its scheme, domain, and port.
URL passwordStringReturns the password specified before the domain name.
URL pathnameStringReturns the path of the URL, including the initial /. Does not include the query string or fragment.
URL portStringReturns the port number of the URL.
URL protocol schemeStringReturns the protocol scheme of the URL, including the final :.
URL query parametersStringReturns query parameters provided, beginning with the leading ? character.
URL usernameStringReturns the username specified before the domain name.

​​ Cookies

PropertyTypeDescription
Cookie: name:ObjectReturns cookies obtained from the browser document.

​​ Device properties

PropertyTypeDescription
Browser engineStringReturns the type of browser engine (for example, WebKit).
Browser engine versionStringReturns the version of the browser’s engine.
Browser nameStringReturns the browser’s name.
Browser versionStringReturns the browser’s version.
Device CPUStringReturns the device’s CPU.
Device IP addressStringReturns the incoming IP address.
Device languageStringReturns the language used.
Device screen resolutionStringReturns the screen resolution of the device.
Device typeStringReturns the type of device used (for example, iPhone).
Device viewportStringReturns the visible web page area in user’s device.
Operating system nameStringReturns the operating system.
Operating system versionStringReturns the version of the operating system.
User-agent stringStringReturns the browser’s user agent.

​​ Miscellaneous

PropertyTypeDescription
Random numberNumberReturns a random number unique to each request.
Timestamp (milliseconds)NumberReturns the Unix time in milliseconds.
Timestamp (seconds)NumberReturns the Unix time in seconds.