To track events in Woopra, send Http GET
requests to this endpoint
Endpoint: http(s)://www.woopra.com/track/ce
http(s)://www.woopra.com/track/ce
Track Requests
Track requests track an event performed by a visitor. This is the main endpoint to use, and may very well end up being the only endpoint you need to use.
GET Request Parameters
Parameter | Required | Type | Example | Description |
---|---|---|---|---|
project | Required | my-project.com | The name of your project in Woopra. | |
cookie | Optional (Recommended. See Description) | kDei34gy3h25F | The Cookie should be thought of as a device id. It can also be used for anonymous ids. Required if no cv_{Visitor Identifier} . See The Cookie | |
event | Required | lowercase | form_submit | The name of the custom event that you are tracking. See Custom Events. |
timestamp | Optional | unix ms timestamp | 1489704275615 | Event timestamp – time in milliseconds since the UNIX epoch that the event occurred. (this can be back-dated, but not in the future.) |
cv_{Visitor Identifier} | Optional (Required to identify a user) | [email protected] | An identifier or multiple identifiers to associate with this visitor. Required if no cookie . See Visitor Properties | |
cv_{Visitor Property} | Optional | Various (See Description) | cv_first_name=Tigi | Properties to set on the visitor's profile. These can be strings, numbers, dates, etc. See Visitor Properties |
ce_{Event Property} | Optional | Various (See Description) | ce_total_value=54 | Properties to set on the custom event. These can be strings, numbers, dates, etc. See Custom Events. |
cs_{Visit Property} | Optional | Various (See Description) | cs_is_work_computer=false | Properties to set on the visit/session. These can be strings, numbers, dates, etc. See Visit/Session Properties |
referer | Optional | valid url | https://www.google.com | Visit’s referring URL, Woopra servers will match the URL against a database of referrers and will generate a referrer type and search terms when applicable. The referrers data will be automatically accessible from the Woopra interface |
ip | Optional | Valid IP Address | 127.0.0.1 | IP address of the visitor. If defined, it overrides the physical IP address of the connection. |
timeout | Optional | milliseconds | Default: 30000 //30 seconds | In milliseconds, defaults to 30000 (equivalent to 30 seconds) after which the event will expire and the visit will be marked as over, and the visitor as offline. |
browser | Optional | chrome | User’s browser. If defined, it overrides the auto-detected browser from the request's user-agent. You can also build your custom user-agent. | |
os | Optional | Windows 10 | User’s operating system. If defined, it overrides the auto-detected operating system from user-agent. | |
device | Optional | eg: mobile or iPhone | User’s device type. If defined, it overrides the auto-detected device type from user-agent. Common values are mobile, tablet and desktop. | |
app | Optional | eg: server event or internal |
Pageviews
Woopra has a default pageview event that the Javascript Client Tracker send when there are no arguments sent to the track function. It automatically adds certain visit and event properties such as page title, url, device resolution, etc. Here is an example of request parameters sent from the SDK for a built-in pageview event:
{
project: "dev.woopra.com"
instance: "woopra"
screen: "2560x1440"
language: "en-US"
app: "js-client"
referer:"www.google.com"
cookie: "5e0saOzmYfgh4q"
event: "pv"
ce_title: "Real-time Customer Analytics - Woopra"
ce_domain: "www.woopra.com"
ce_url: "/welcome-page"
ce_uri: "https://www.woopra.com/welcome-page"
}
To track similar pageview events via this API, it is recommended that at least ce_url
is used for the page path, and ce_title
is used for the page title. This will integrate seamlessly with the Woopra interface and built-in pageview event reporting.
Example
To track a payment
by John Smith
of $149.95
for a Titanium
package, you should issue a tracking request similar to the following:
http://www.woopra.com/track/ce/
?project=mywebsite.com
&response=json
&cookie=AH47DHS5SF182DIQZJD
&timeout=300000
&cv_username=John+Smith
&[email protected]
&event=payment
&ce_amount=149.95
&ce_type=blog
&ce_package=Titanium