Tracking without JavaScript

JavaScript implementation is the recommended way of tracking, but it is also possible to send the pixel data to the analytics server from your site's serverside. This page describes and demonstrates how to format HTTP requests to send visitor data in such case.

The request

To send visitor data, make a HTTP GET request to http://srv.pixel.parsely.com/plogger/. The request headers should contain User-Agent string that would be set to of the user device information (browser, version, etc.) initiating the action.

GET /plogger/

Path Arguments

idsite your Parse.ly API key
date ISO 8601 encoded event datetime string
ip_address IP address of the visitor
url URL of the page being viewed
urlref referring URL
screen Client device resolution: x
action Event type (pageview, heartbeat, videostart, or vheartbeat)
data user identifier, see below

Optional Parameters

title Page title, optional.

User Identifier

In order to tie multiple requests to a single user or device, provide a parsely_site_uuid field in the data JSON object.

&data={"parsely_site_uuid": "2706838D-A52F-40D8-BCD2-B343045AC2EE"}

Although the user ID specified above is a UUID-4, any unique identifier is fine as long as it is unique across all users of your site and does not contain any personally identifiable information. For example - if you wish to track logged in users, you should not provide a user's e-mail address for the UUID, instead providing a salted hash of it.

Example

An example of a complete page view request to the insertion API might be::

GET /plogger/?rand=48919820492&idsite=yoursite.com&date=2013-11-05T00%3A23%3A12.142-0500&ip_address=243.123.22.1&data=%7B%22parsely_site_uuid%22%3A%20%222706838D-A52F-40D8-BCD2-B343045AC2EE%22%7D&url=http%3A%2F%2Fyoursite.com%2Fsome-article-1234&urlref=http%3A%2F%2Fyoursite.com%2F&screen=1440x900%7C1436x878%7C24&title=Article+title+1234&action=pageview
Host: srv.pixel.parsely.com
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_9_0) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/30.0.1599.101 Safari/537.36

Or with the query string elements broken out (and not URL encoded)::

?rand=48919820492
&idsite=yoursite.com
&date=2013-11-05T00:23:12.142-0500
&ip_address=243.123.22.1
&data={"parsely_site_uuid": "2706838D-A52F-40D8-BCD2-B343045AC2EE"}
&url=http://yoursite.com/some-article-1234
&urlref=http://yoursite.com/
&screen=1440x900|1436x878|24
&title=Article title 1234
&action=pageview
Do you have an urgent support question?