meteorhacks/meteor-customer-io

Name: meteor-customer-io

Owner: meteorhacks

Description: Customer.io Integration for Meteor

Created: 2014-08-30 00:36:06.0

Updated: 2017-06-09 12:03:15.0

Pushed: 2014-10-08 08:04:45.0

Homepage: null

Size: 165

Language: JavaScript

GitHub Committers

UserMost Recent Commit# Commits

Other Committers

UserEmailMost Recent Commit# Commits

README

Customer.Io integration for Meteor

This is an isopack!
(Which means, both client and server has the same API)

Installation
// for meteor 0.9
meteor add meteorhacks:customer.io

// for < meteor 0.9
mrt add customer.io
Usage
// initialization

var siteId = 'site_id';
var token = 'the_token'; // only on the server
var cio = CustomerIo.init(siteId, token);

// identifing

var userId = 'user_id';
var email = 'user@email.com';
var properties = {name: "My Name"};
cio.identify(userId, email, properties, function(err, res, body) {
  // callback is only available on the server
});

// track

var userId = 'user_id';
var event = 'the_event';
var properties = {name: "My Name"};
cio.track(userId, event, properties, function(err, res, body) {
  // callback is only available on the server
});

This work is supported by the National Institutes of Health's National Center for Advancing Translational Sciences, Grant Number U24TR002306. This work is solely the responsibility of the creators and does not necessarily represent the official views of the National Institutes of Health.