Table of contents

Node.js SDK

Track customers using Woopra’s Node.js SDK


You can install the library using npm. You may also view the source on Github.

$ npm install woopra


var Woopra = require('woopra');

// Replace projectKey with your project key (generally your website name)
// `options` is an object, currently the only option supported is ssl: <true|false> (default: true)
var woopra = new Woopra('projectKey', options);

Alternatively, you can configure the tracker after initialization by calling config(options)

	ssl: true

You must identify your users before tracking. Use the identify(uid, properties) method to attach a unique ID (we highly recommend using e-mails to get the most out of AppConnect), as well as other visitor properties.

Your custom visitor data will not be pushed until you send your first custom event. In order to push your identify without sending a custom event, use the push method.

woopra.identify('', {
    visitor_property: 'property'

To send a custom event, use track(eventName, properties)

woopra.track('eventName', {
    event_property: 'property'
Note: All event and property names should be lowercase

A day of setup. A lifetime of insights.

Try Woopra for free. No credit cards. No obligations.