Pixel tracker implementation
14 min
v2 0 1 our empty (zero size) pixel captures data elements without the need to drop cookies or load javascript this makes it extremely light and ensures that it can be called both as an image or script there are a number of placeholders that allow the site or app to pass in some information that allows us to capture elements, which are to be used for reporting the pixel data after onboarding can be used to build custom segments including the option to overlay third party segments the simple integration process for the pixel tracker allows you to start sending information with minimal setup the api request can be made from a mobile app, mobile web browser, desktop web, or even from the server side request url details you can send a request in the following formats to the request url image tag \<img>) javascript tag (\<script>) http get you can implement the pixel as a part of any creative tags including vast video tags parameters must be uri encoded and included in the request request url https //pix cadent tv/pixel png ssl required http method get request parameters the following table defines the request parameters \<font color="#ffffff">parameter name\</font> \<font color="#ffffff">description\</font> \<font color="#ffffff">example\</font> \<font color="#ffffff">required\</font> dsid identifies the dataset in audience studio generated by cadent during onboarding process dsid=123 yes random any large random integer to be appended for cache busting purposes unix timestamp can also be used here other examples could be milliseconds since epoch random=1503556996234 random=\[cachebuster macro] yes erid this is external request id can be used to identify each pixel uniquely for example, impressionid this field is alphanumeric only erid=23afn5bkfktiasd4428 5nfi5jsf erid=a545 utf4 tiiadsf 434r5a no uid a user id or username to identify a unique user on partner platform it is preferable to pass a unique value here to track the same user across multiple devices could be a cookie id for users that are not logged in uid=7652632 uid=baseballfan18 uid=\[user idname mac ro] no email email address of the logged in user clear text preferred if hashed ids are sent, use md5/sha1/ sha256 as hashing without any salt email=d65be7dcb2c383cc fb565bc de3753270 email=john doe\@gmail co m email=\[email macro] no \<font color="#ffffff">parameter name\</font> \<font color="#ffffff">description\</font> \<font color="#ffffff">example\</font> \<font color="#ffffff">required\</font> maid used to uniquely identify a mobile device should be a mobile advertising id for mobile devices (idfa for apple, gaid for android, waid for microsoft and similar ids from other vendors) for other types of devices, feel free to add any relevant id that can uniquely identify the device use clear text maid=e68af3d1 4ed7 4bc 0 abcb af84e565572f no ip ip address of the user if the request is sent from a server ip=10 20 30 40 require d only for server side call ua url encoded user agent if the request is sent from a server ua=mozilla%2f5 0%20%28 macintosh%3b%20i ntel%20mac%20os%20x %2010 11 6%29%20 applewebkit%2f601 7 7% 20%28khtml%2c%2 0like%20gecko%29%20ve rsion%2f9 1 2%20saf ari%2f601 7 7 require d only for server side call \<font color="#ffffff">parameter name\</font> \<font color="#ffffff">description\</font> \<font color="#ffffff">example\</font> \<font color="#ffffff">required\</font> segids a list of segment ids to send any additional data to cadent for recording or segmentation purposes segids=123,sports,male information should be structured as follows value1,value2,value3 no when you generate the pixel url in identity ui it will include some placeholder macros you should replace them with your platform macros (e g freewheel macros) or actual values the segment ids can only contain alphabets, numbers and underscores these segment ids are must be unique across different dimensions in order to use it for audience building the max number of unique segment id values supported is 2000 (e g sports and male mean 2 segment ids) \<font color="#ffffff">parameter name\</font> \<font color="#ffffff">description\</font> \<font color="#ffffff">example\</font> \<font color="#ffffff">required\</font> segkv\<key>= \<value> segments as key value pairs (suitable for segments at two or more levels) usage segkv key1=value1,value2 \&segkv key2=value3 no for example segkv user=logged in\&se gkv page =landing,product detail the total length of key and value cannot be more than 125 characters you can use actual value or a macro to provide info in the value your ad ops team can append additional key value pairs directly in the url using the above format without logging into the ui best practices for ip/ua , if the value is explicitly passed in the url we will use it (a case of server side request), if the value is not passed we will use it from http header when client makes the request the pixel template is used during dataset creation and should be just used a guide if you want to pass a supported optional field or segment information later, your ad ops can append those details in the url without logging into the application the macros shown above are placeholders only if a macro is unavailable in the target platform, please remove the parameterand corresponding placeholder macro from the url example tags image tag \<img src="https //pix cadent tv/pixel png? dsid=123\&ip=10 1 1 10& uid=7652632\&email=name\@example com\&maid=e68af3d1 4ed7 4bc 0 abcb af84e565572f\&random=1503556996234\&erid=1232asf4i5rn a94724\&segids= sports,123,az" height="0" width="0"> javascript tag tag example for custom javascript (replace 111 with your dataset id) \<script type="text/javascript"> var rt=parseint((new date()) gettime() math random()); var rurl="https //pix cadent tv/pixel png?dsid=111\&random="+rt; document write("&\<scr" + "ipt type='text/javascript' "src='" + rurl + "'/ scr" + "ipt\>");/script> you can add segment information to capture various page sections of your website using the segids param home page \<script type="text/javascript"> var rt=parseint((new date()) gettime() math random()); var rurl="https //pix cadent tv/pixel png? dsid=111\&segids=home\&random="+rt; document write("\<scr" + "ipt type='text/javascript' src='" + rurl + "'/scr" + "ipt"\</script> subscription page \<script type="text/javascript> var rt=parseint((new date()) gettime() math random()); var rurl="https //pix cadent tv/pixel png? dsid=111\&segids=subscription\&random="+rt; document write(\<scr" + "ipt type='text/javascript' src='" + rurl + "'><;/scr" + "ip>"); \</script> http get \<img src=" https //pix cadent tv/pixel png? dsid=123\&ip=10 1 1 10\&uid=\[user idnam e macro]\&email=\[email macro]\&maid=\[device id macro]\&ran dom=\[cachebust er macro]&;segids=\[category macro], \[campaign id macro],\[state macro]" height="0" width="0" /> response after receiving the recording request, cadent servers will respond with an empty pixel (zero content) and a http status code of 200 this makes it suitable to work both as an empty image pixel and as a valid response to http get request
