Ensora
Ensora
DocumentationInstallationBasic Usage
Custom EventsNavigation TrackingPrivacy & MaskingHeatmapsSession Replay

Advanced

Error TrackingPrivacy & Utilities

API Reference

API Reference
Customization

Custom Events

Track any user action with properties

Custom Events

Use track() to send custom events with properties from anywhere in your app.

Basic Usage

import { track } from '@ensora/react-native';

track('button_pressed', { label: 'Sign Up', screen: 'home' });

Event Properties

Properties are key-value pairs. Supported value types:

track('purchase_completed', {
  amount: 29.99,         // number
  currency: 'USD',       // string
  plan: 'pro',           // string
  trial: false,          // boolean
  coupon: null,          // null (property omitted)
});

Naming Conventions

Use snake_case for event names and properties:

// Good
track('checkout_started', { cart_total: 49.99 });

// Avoid
track('CheckoutStarted', { cartTotal: 49.99 });

Group related events with a shared prefix:

track('onboarding_step_1_completed');
track('onboarding_step_2_completed');
track('onboarding_completed', { steps_skipped: 0 });

Common Patterns

User Actions

track('button_pressed', { label: 'Subscribe', screen: 'pricing' });
track('form_submitted', { form: 'contact', fields: 3 });
track('item_selected', { item_id: '42', category: 'shoes' });

Business Events

track('subscription_started', { plan: 'pro', price: 29 });
track('subscription_cancelled', { plan: 'pro', reason: 'too_expensive' });
track('feature_used', { feature: 'heatmaps', session_count: 12 });

Error Context

try {
  await submitOrder(cart);
} catch (error) {
  track('order_failed', {
    error: error.message,
    cart_total: cart.total,
    item_count: cart.items.length,
  });
}

Viewing Events

From the dashboard Analytics tab:

  • Event breakdown — see event counts over time
  • Event explorer — filter and inspect individual event payloads
  • Funnels — combine events into conversion funnels
  • Session filter — find sessions that contain a specific event

Event Limits

PlanEvents per second
Free10 events/sec
Pro50 events/sec

Events over the rate limit are dropped at the ingest API. The SDK does not queue rejected events.

Next Steps

  • Navigation Tracking — auto-captured nav events
  • Error Tracking — track errors with session context
  • API Reference — complete track() API

Last updated on

Basic Usage

Configure the Ensora SDK and track events

Navigation Tracking

Auto-capture screen transitions with Expo Router

On this page

Custom Events
Basic Usage
Event Properties
Naming Conventions
Common Patterns
User Actions
Business Events
Error Context
Viewing Events
Event Limits
Next Steps