The Splitbee Node.js library provides Splitbee tracking functionality in server-side applications built using Node.js

Installation

Use npm or yarn to install the package @splitbee/node

yarn add @splitbee/node

Usage

You need to replace the PROJECT_ID with your id shown within the Splitbee Dashboard

import { SplitbeeAnalytics } from '@splitbee/node';

const analytics = new SplitbeeAnalytics('PROJECT_ID');

analytics.track({
  userId: '[email protected]',
  event: 'Payment confirmed',
  data: {
    paymentId: '1234567890',
  },
});