• This documentation is for an old version of this tracker!
  • Contents
  • 1. Overview
  • 2. Initialization
  • 2.1 Requiring the module
  • 2.2 Creating a tracker
  • 2.3 Creating multiple trackers
  • 3. Adding extra data
  • 3.1 Set the tracker's platform with set_platform
  • 3.2 Set the user ID with set_user_id
  • 3.3 Set the screen resolution with set_screen_resolution
  • 3.4 Set the viewport dimensions with set_viewport
  • 3.5 Set the color depth with set_color_depth
  • 3.6 Setting the timezone with set_timezone
  • 3.7 Setting the language with set_lang
  • 3.8 Setting the IP address with set_ip_address
  • 3.9 Setting the useragent with set_useragent
  • 3.10 Setting the domain user ID with set_domain_user_id
  • 3.11 Setting the network user ID with set_network_user_id
  • 4. Tracking specific events
  • 4.1 Common
  • 4.1.1 Argument validation
  • 4.1.2 Optional context argument
  • 4.1.3 Optional timestamp argument
  • 4.1.4 Example
  • Track screen views with track_screen_view
  • Track page views with track_page_view
  • 4.4 Track ecommerce transactions with track-ecommerce-transaction()
  • 4.5 Track structured events with track_struct_event
  • 4.6 Track unstructured events with track_unstruct_event
  • 5. Emitters
  • 5.1. Overview
  • 5.2. The AsyncEmitter class
  • 5.3. Multiple emitters
  • 5.4. Flushing manually
  • 6. Contracts
  • 7. Logging
  • 8. Advanced usage
  • 8.1. snowplow_ruby_duid