Skip to main content

Documentation Index

Fetch the complete documentation index at: https://docs.pureclarity.com/llms.txt

Use this file to discover all available pages before exploring further.

PCJS Master Function

The PureClarity JavaScript Snippets (PCJS) master function assists with tracking events, session management and debugging PureClarity within your website. The PCJS master function JavaScript snippet needs to be added to the top of every page on the website, ideally after the closing <head> tag. Each PureClarity installation has a unique access key. You will need to replace <access_key> within the code snippet. Your API Access Key can be found in the Admin console under My Account > Integrations.
<script type="text/javascript">
 (function(w, d, s, u, f) {
   w['PureClarityObject'] = f;
   w[f] = w[f] || function() {(w[f].q = w[f].q || []).push(arguments)};
   var p = d.createElement(s), h = d.getElementsByTagName(s)[0];
   p.src = u;p.async=1;h.parentNode.insertBefore(p, h);
 })(window, document, 'script', '//pcs.pureclarity.net/<access_key>/cs.js', '_pc');
</script>
You will have different access keys for each store view.