Instant insights from any website.

This documentation provides guidance on how to integrate the Bigdelta SDK into your web-based application directly in the browser. The Bigdelta SDK allows you to track user interactions and events, offering robust functionality for your analytics needs.

Getting started

Bigdelta SDK

Installation

If you’d like to add Bigdelta SDK to your web application and you’re not using package managers like npm or yarn, you can add the code snipped provided below directly to your page:

browser
<script type="application/javascript" src="https://cdn.jsdelivr.net/npm/@bigdelta/bigdelta-browser/dist/index.iife.min.js"></script>

Alternatively, for Node.js environments you can install Bigdelta SDK with a package manager:

Usage

Once the SDK is loaded, you can use the client to access the SDK’s methods.

API

Tracking Events

To track events, you can use the track method:

client.track(payload: EventPayload | EventPayload[]);
EventPayload
{
  event_name: string;
  properties?: null | NestedObject;
  relations?: null | Relations;
}

NestedObject
{
  [key: string]: string | boolean | number | null | (string | boolean | number | null)[] | NestedObject;
};

Relations
{ [key: string]: string };

Example:

await client.track({ 
  event_name: 'Signed up', 
  properties: { url: '<YOUR URL>' }, 
  relations: { users: '<YOUR USER_ID>' } 
  });