{"metadata":{"image":[],"title":"","description":""},"api":{"url":"","auth":"required","results":{"codes":[]},"settings":"","params":[]},"next":{"description":"","pages":[]},"title":"Getting Started","type":"basic","slug":"getting-started-2","excerpt":"","body":"[block:callout]\n{\n  \"type\": \"danger\",\n  \"title\": \"Deprecated API Warning\",\n  \"body\": \"This page documents a no-longer supported version of the Boomtrain JavaScript Library (versions 4.x and below). The new `p13n.js` library, documented [here](https://boomtrain.readme.io/v1/docs/p13njs-getting-started) is the currently supported library for integrating with ZetaHub.\"\n}\n[/block]\n\n[block:api-header]\n{\n  \"title\": \"Analyticstrain\"\n}\n[/block]\n`analyticstrain.js` is the simplest way to integrate your website with Boomtrain. This JavaScript library bundles functions to manage user identification and attribute management, behavioral tracking, on-site personalized recommendation campaigns, and more.\n[block:api-header]\n{\n  \"title\": \"Adding Analyticstrain to your site\"\n}\n[/block]\nThe first step of integration is putting the Boomtrain JavaScript library on each page of your site's code (we recommend the `<head>` section).\n\nOur CDN supports the HTTPS protocol.\n[block:code]\n{\n  \"codes\": [\n    {\n      \"code\": \"<script async src=\\\"https://cdn.boomtrain.com/analyticstrain/<site_id>/analyticstrain.min.js\\\"></script>\",\n      \"language\": \"html\"\n    }\n  ]\n}\n[/block]\n\n[block:api-header]\n{\n  \"title\": \"Auto-tracked Events\"\n}\n[/block]\nBy default, `analyticstrain.js` uses `autoTrack`, which automatically tracks each page load with a `viewed` event without the need to call [Track](doc:track) manually. Please reach out to the Boomtrain team if you need `autoTrack` to be disabled.","updates":[],"order":0,"isReference":false,"hidden":false,"sync_unique":"","link_url":"","link_external":false,"_id":"5928a4fbe2653627003e14c0","project":"56aff08c3a5b810d00745d99","user":"566887ff8639090d00759415","parentDoc":null,"createdAt":"2017-05-26T21:58:19.553Z","version":{"version":"1","version_clean":"1.0.0","codename":"","is_stable":true,"is_beta":false,"is_hidden":false,"is_deprecated":false,"categories":["56aff08d3a5b810d00745d9d","56aff24f3a5b810d00745da0","56aff25dbc304a0d00ace207","56aff287e0b1e40d00c53798","56aff2b260a37a0d00ed8883","56aff2b8e0b1e40d00c53799","56aff2bd5b1f01170014dc7b","56aff2c9d21e9c0d00b62993","56aff493aef9a21700da0e67","56aff4ce1486990d009c0f64","56aff4da5b1f01170014dc7d","56aff4dfe0b1e40d00c537a2","56aff4e59d32e30d0006d3e9","56aff4e91486990d009c0f65","56aff4f93a5b810d00745da2","56aff4fe9d32e30d0006d3ea","56b91c7ab1e03e0d001057c5","56c4f51aba4a540d0091b9a2","56cd09488c4a331d002c1e44","56d4ec4773dcd20b00fb8769","56e79bc515f96b2200878e54","56ec25c538ff1d2200d56cc2","56ec3a6f36bc8e0e00f190c8","56ec3e308ea7ce0e00a3d8b0","5724d8fe4255580e005938b2","5724dc842ad0bc1700122803","5776ef2a04f7500e0095dc37","57ab9f70b5e8742000e17eb9","57d7117646dcc30e007dd21f","58e6abd5b1eece19008b7d31","59288c65e2653627003e1221","5a8f4797a44f8600128e75ee","5bbf8833eb416300039a2c14","5ea811617bf4b5007328a0af"],"_id":"56aff08c3a5b810d00745d9c","project":"56aff08c3a5b810d00745d99","releaseDate":"2016-02-01T23:55:56.544Z","__v":34,"createdAt":"2016-02-01T23:55:56.544Z"},"category":{"sync":{"isSync":false,"url":""},"pages":[],"title":"Zeta JavaScript Library (versions 4.x and lower)","slug":"boomtrain-javascript-sdk","order":4,"from_sync":false,"reference":false,"_id":"59288c65e2653627003e1221","createdAt":"2017-05-26T20:13:25.882Z","project":"56aff08c3a5b810d00745d99","version":"56aff08c3a5b810d00745d9c","__v":0},"githubsync":"","__v":0}
[block:callout] { "type": "danger", "title": "Deprecated API Warning", "body": "This page documents a no-longer supported version of the Boomtrain JavaScript Library (versions 4.x and below). The new `p13n.js` library, documented [here](https://boomtrain.readme.io/v1/docs/p13njs-getting-started) is the currently supported library for integrating with ZetaHub." } [/block] [block:api-header] { "title": "Analyticstrain" } [/block] `analyticstrain.js` is the simplest way to integrate your website with Boomtrain. This JavaScript library bundles functions to manage user identification and attribute management, behavioral tracking, on-site personalized recommendation campaigns, and more. [block:api-header] { "title": "Adding Analyticstrain to your site" } [/block] The first step of integration is putting the Boomtrain JavaScript library on each page of your site's code (we recommend the `<head>` section). Our CDN supports the HTTPS protocol. [block:code] { "codes": [ { "code": "<script async src=\"https://cdn.boomtrain.com/analyticstrain/<site_id>/analyticstrain.min.js\"></script>", "language": "html" } ] } [/block] [block:api-header] { "title": "Auto-tracked Events" } [/block] By default, `analyticstrain.js` uses `autoTrack`, which automatically tracks each page load with a `viewed` event without the need to call [Track](doc:track) manually. Please reach out to the Boomtrain team if you need `autoTrack` to be disabled.