Trackveil Custom Events Test Page

This page demonstrates the custom events tracking API. Click the buttons below to track various events.

Note: Make sure to replace YOUR_SITE_ID_HERE in the script tag above with your actual site ID.

Simple Event Tracking

Track events without additional properties

Trackveil.track('Button Clicked');

Event with Properties

Track events with additional data

Trackveil.track('Purchase', {
  value: 29.99,
  currency: 'EUR',
  product: 'Test Product'
});

Newsletter Signup

Track form submissions

Trackveil.track('Newsletter Signup', {
  source: 'test-page'
});

Video Play

Track media interactions

Trackveil.track('Video Played', {
  video_id: 'intro-video',
  duration: 120
});

File Download

Track file downloads

Trackveil.track('File Downloaded', {
  filename: 'whitepaper.pdf',
  size: '2.4MB'
});

Add to Cart

Track e-commerce actions

Trackveil.track('Add to Cart', {
  product_id: '12345',
  name: 'Premium Plan',
  price: 15.00
});

Event Log

Open your browser's developer console (F12) and check the Network tab to see events being tracked.

Events are sent to: https://api.trackveil.net/event

View your events in the dashboard: Events Dashboard

API Documentation

Trackveil.track(eventName, properties)

Parameters:

  • eventName (string, required) - Name of the event to track
  • properties (object, optional) - Additional data to track with the event

Example:

// Simple event
Trackveil.track('Feature Used');

// Event with properties
Trackveil.track('Purchase', {
  value: 49.99,
  currency: 'EUR',
  product_id: '12345',
  category: 'Premium',
  payment_method: 'stripe'
});

Common Use Cases:

  • Track button clicks and CTA interactions
  • Monitor form submissions and conversions
  • Track e-commerce purchases and cart actions
  • Measure video plays and engagement
  • Track file downloads and resource access
  • Monitor feature usage and user behavior