PXL Events

Integration

Import

import * as pxl from "@mod-consilio/js/pxl";

Send events

Send a pxl event:

pxl.sendPxlEvent("mymodule:myevent");

Send a pxl event with custom data (see Custom data fields below):

pxl.sendPxlEvent("mymodule:myevent", { ds_mystring: "some string", dn_mynumber: 1234 });

Options

Set the global options for all subsequent pxl calls:

let options = {};
pxl.setOptions(options);

The following options can be set in the options object:

To set specific options when sending pxl event, supply an options object to the sendPxlEvent call:

let options = {};
pxl.sendPxlEvent("mymodule:myevent", { ds_mystring: "some string", dn_mynumber: 1234 }, options);

PXL QUERY VARIABLES

Pxl event fields

Base pxl event fields, identifying the event, user and/or session.

Browser context fields

The actual referrer and browser identification for the page sending the event, along with some extra information about the browser environment. These might differ from the referrer and user agent in the access log if using a CDN.

The last three fields (bu, bs and bp) can be omitted if not wanted or if the url might become too large by setting the nobrowserenvironment option.

Custom data fields

Fields containing custom data which can be used for analyzation of the events. XXX denotes a custom string consiting of a-z, 0-9 or underscores, eg 'ds_clientid'

PXL INDEXED FIELDS

Pxl event fields

Browser context fields

Custom data fields

General access log fields