Skip to content

Privacy and security ​

This page tells which data the SDK sends and stores, how it uses consent, and how to protect your pages.

Data that the SDK sends ​

DataExample
Event name and propertiespricing.viewed with { "plan": "pro" }
PageThe address, the referrer and the title
UTM valuesutm_source=newsletter
Ad click IDs, only after consent for analytics and adsgclid=Cj0KCQjw
IdentifiersThe visitor ID after consent, an email address from a form or from identify
DeviceThe user agent and the language of the browser

QuickPipe receives the IP address of the request. It uses the IP address to find the country and the city, and to stop automated traffic.

Data that the SDK never sends ​

  • The text of a textarea field
  • Password, one-time code, payment, hidden and card fields
  • Personal identity numbers
  • Form fields that the SDK cannot identify, unless you add them with data-lg-capture

Use beforeSend in the npm client to change or drop an event before it leaves the browser.

The default consent mode is auto. In this mode, the SDK reads the consent from these sources:

  • Google Consent Mode v2: the values analytics_storage, ad_storage and ad_user_data in the dataLayer
  • The Cookiebot, CookieYes and OneTrust adapters

In manual mode, the SDK waits for a call to consent:

ts
lg.consent({ analytics: 'granted', ads: 'denied' });

The table gives the analytics state. The SDK sends ad data only when the ads state is also granted.

StateWhat the SDK does
unknownIt stores no visitor ID. It keeps the UTM values and the click IDs of the session in memory only. It sends the UTM values with each event. The events have context.consent: "unknown", no ID and no click ID. QuickPipe counts them and keeps them only in traffic statistics without an identifier of a person.
grantedIt stores the visitor ID and sends it with each event. It stores the UTM values of the session. It stores and sends the click IDs only when the purpose ads is granted too. The events have context.consent: "granted".
deniedIt deletes the visitor ID, the UTM values and the click IDs of the session. It also removes them from each event that it did not send yet. Then it asks QuickPipe to erase the data of that ID. It sends events with context.consent: "denied" and without an ID, a UTM value or a click ID. QuickPipe only counts them.

Browser storage ​

NameStoreContentTime
lg_aidFirst party cookie and localStorageThe visitor ID, after consent for analytics13 months after the last visit
lg-session-<key>localStorageThe UTM values and the ad click IDs of the session. The SDK stores the UTM values after consent for analytics, and the click IDs after consent for analytics and ads.Until the session ends, 30 minutes after the last event by default
Offline queuelocalStorageEvents, and requests to erase a visitor ID, that the SDK did not send yetUntil the SDK sends them

The SDK writes no UTM value and no click ID before the visitor gives consent. Before consent, both stay in memory only. A denial deletes them from memory, from localStorage and from each event that the SDK did not send yet. The option utm: false also stops the send of each UTM value and each click ID and deletes the values of a stored session. A request to erase a visitor ID that fails stays in the queue, and the SDK sends it again.

Safari keeps cookies that a script sets for a maximum of 7 days. To keep the visitor ID longer in Safari, send the events through a path of your website, for example /_lg. Refer to Use a first party endpoint.

Integrity ​

Use a URL with a fixed version and the integrity attribute. The browser then does not run a file that someone changed.

html
<script async src="https://cdn.jsdelivr.net/npm/@quickpipeaiab/[email protected]/dist/lg.js"
        integrity="sha384-…" crossorigin="anonymous"
        data-key="lg-pub-live-…"></script>

QuickPipe gives you the exact line. Each package version has the file integrity.json with the sha384 hash of each browser file. The GitHub release of each version also has this file.

The browser checks the hash of each adapter file before it runs the file.

GTM cannot check an integrity hash. The QuickPipe GTM template loads only a fixed version.

Content Security Policy ​

The SDK operates with a strict Content Security Policy. It uses no eval and no inline styles, and it is compatible with Trusted Types. Add these values to your policy:

DirectiveValue
script-srchttps://cdn.jsdelivr.net
connect-srchttps://in.quickpipe.ai, or your first party endpoint

Keys ​

KeyWhere to use it
Publishable key, lg-pub-live-…In the browser and in mobile apps. It can send events, and it can erase the visitor ID that it sends.
Secret key, lg-sec-live-…Only on your servers. Keep it in a secret store.

The SDK refuses a secret key in a browser. Each key belongs to one source, and the key gives the source of each event.

Erasure of a visitor ID ​

When the visitor denies consent, the SDK asks QuickPipe to erase the visitor ID:

  • When the person has other identifiers, for example an email address, QuickPipe removes only the visitor ID and the events that it sent.
  • When the visitor ID is the only identifier, QuickPipe erases the anonymous person.