key *
(data-key) | Required. API key
How to get API key |
tracking_host
(data-tracking-host) | If not set, Jitsu will do the best attempt to detect it automatically.
For HTML snippet - script location host will be used. For npm package,
t.jitsu.com is a default host |
cookie_name
(data-cookie-name) | Name of tracking cookie (__eventn_id by
default) |
cookie_domain
(data-cookie-domain) | Domain of the tracking cookie (by default this is
location.hostname with any
www. subdomain removed) |
segment_hook
(data-tracking-host) | If set to true, Jitsu will automatically listen to Segment's
analytics.js events and collect them. |
randomize_url
(data-randomize-url) | If set to true, Jitsu will send events on a dynamic endpoint. It allows
avoiding ad blockers. |
compat_mode
(data-compat-mode) | If event JSON should have a structure compatible with an old version.
Read more about compat mode in
Migration Guide |
ip_policy
(data-ip-policy) | ['keep', 'comply', 'strict'] values are
supported. keep value is default.
keep - Jitsu extracts client IP address and stores
it in every analytics event in 'source_ip' field.
strict - Jitsu replaces last octet in client
IP address with '1' on the backend side. like
10.10.10.10 -> 10.10.10.1
comply - Jitsu detects client country with
MaxMind
(if MaxMind isn't provided the behavior will be like in strict mode) if client is from EU or UK then the behavior will be like in
strict mode. Otherwise like in keep mode. Read more about Privacy Policy
|
cookie_policy
(data-cookie-policy) | ['keep', 'comply', 'strict'] values are
supported. keep value is default.
keep - Jitsu writes identification cookies and
recognizes users with it.
strict - Jitsu doesn't write any cookies
(including identification cookies and persistent properties). Instead of
cookies, Jitsu will use fingerprinting (
hash(client ip + user agent) function).
comply - Jitsu detects client country with
MaxMind
(if MaxMind isn't provided the behavior will be like in strict mode) if client is from EU or UK then the behavior will be like in
strict mode. Otherwise like in keep mode. Read more about Privacy Policy
|
privacy_policy
(data-privacy-policy) | This parameter is just shortcut for strict
configuration of cookie_policy and
ip_policy . If set to
strict value,
cookie_policy and
ip_policy will be set
strict . Read more about
Privacy Mode |
force_use_fetch
(data-force-use-fetch) | This parameter forces SDK to use the fetch implementation (custom or default) even in browser |
custom_headers | (Not available as data- parameter in embedded environment; available only in npm lib) This parameter adds custom headers to each request. Can be either a static object (Record<string, string> ) or
a function that returns an object |