Skip to content
Woopra SDK for iOS
Find file
Latest commit 1511526 Apr 7, 2016 @eliekhoury eliekhoury Create LICENSE
Failed to load latest commit information.
WTracker Tests Fix UT build Jun 15, 2015
WTracker.xcodeproj Add UT Target May 5, 2015
.gitignore Adds project files to .gitignore. Oct 7, 2015
LICENSE Create LICENSE Apr 7, 2016 Update Jan 24, 2013

Woopra iOS SDK Documentation

When the app loads, you should load the Woopra Tracker and configure it.

[WTracker sharedInstance].domain = @"";

You can update your idle timeout (default: 30 seconds) by updating the timeout property in your WTracker instance:

[WTracker sharedInstance].idleTimeout = 60;

If you want to keep the user online on Woopra even if they don't commit any event between the last event and the idleTimeout, you can enable auto pings.

// Ping is disabled by default
[WTracker sharedInstance].pingEnabled = true;

To add custom visitor properties, you should edit the visitor object.

[[WTracker sharedInstance].visitor addProperty:@"name" value:@"John Smith"]
[[WTracker sharedInstance].visitor addProperty:@"email" value:@""]

Your custom visitor data will not be pushed until you send your first custom event. On website, the default event is a pageview. In mobile apps, we recommend that developers use the event appview when switching between Windows and Views.

To add send an appview event:

// create event "appview"
WEvent* event = [WEvent eventWithName:@"appview"];
// add property "view" with value "login-view"
[event addProperty:@"view": value:@"login-view"];
// track event
[[WTracker sharedInstance] trackEvent:event];
Something went wrong with that request. Please try again.