Difference between revisions of "ConversionRuler Tracking API"
m |
|||
(11 intermediate revisions by the same user not shown) | |||
Line 5: | Line 5: | ||
https://www.conversionruler.com/bin/tracker.php | https://www.conversionruler.com/bin/tracker.php | ||
− | All parameters are passed as a query string to the above call. | + | All parameters are passed as a query string to the above call. The server will respond with a |
+ | |||
+ | 204 No content | ||
+ | |||
+ | return code upon successful recording. | ||
The following parameters are accepted to this call: | The following parameters are accepted to this call: | ||
Line 14: | Line 18: | ||
|- | |- | ||
| <span class="code">siteid</span> | | <span class="code">siteid</span> | ||
− | | | + | | string |
| '''Yes''' | | '''Yes''' | ||
| The Site ID assigned to your site. Should remain the same for your entire site. Usually a numeric value (integer) but may be extended in the future to support text values as well. | | The Site ID assigned to your site. Should remain the same for your entire site. Usually a numeric value (integer) but may be extended in the future to support text values as well. | ||
Line 27: | Line 31: | ||
| <span class="code">user_id</span> | | <span class="code">user_id</span> | ||
| 32-character hexadecimal string | | 32-character hexadecimal string | ||
− | | ''Yes'' | + | | '''Yes''' |
− | | The unique identifier for this user on your site. This identifier should persist for this visitor for as long as possible and be set as a cookie in the user's | + | | The unique identifier for this user on your site. This identifier should persist for this visitor for as long as possible and be set as a cookie in the user's browser and passed through for each call to the tracking script. |
| c4ca4238a0b923820dcc509a6f75849b<br />eccbc87e4b5ce2fe28308fd9f2a7baf3 | | c4ca4238a0b923820dcc509a6f75849b<br />eccbc87e4b5ce2fe28308fd9f2a7baf3 | ||
|- | |- | ||
| <span class="code">session_id</span> | | <span class="code">session_id</span> | ||
| 32-character hexadecimal string | | 32-character hexadecimal string | ||
− | | ''Yes'' | + | | '''Yes''' |
− | | The unique identifier for this user's session on your site. This identifier should persist for this visitor for 30 minutes after their most recent page view. A new session ID should be generated after 30 minutes | + | | The unique identifier for this user's session on your site. This identifier should persist for this visitor for 30 minutes after their most recent page view. A new session ID should be generated after 30 minutes of inactivity. This can be done by setting the session cookie to expire 30 minutes after the current time, and creating a new session ID for the user if it does not exist. |
| e4da3b7fbbce2345d7772b0674a318d5<br />8f14e45fceea167a5a36dedd4bea2543 | | e4da3b7fbbce2345d7772b0674a318d5<br />8f14e45fceea167a5a36dedd4bea2543 | ||
+ | |- | ||
+ | | <span class="code">useragent</span> | ||
+ | | string | ||
+ | | '''Yes''' | ||
+ | | The user agent string from the client's browser. | ||
+ | | Mozilla/5.0 (Macintosh; Intel Mac OS X 10_11_4) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/49.0.2623.112 Safari/537.36<hr />Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 10.0; WOW64; Trident/7.0; Touch; .NET4.0C; .NET4.0E; .NET CLR 2.0.50727; .NET CLR 3.0.30729; .NET CLR 3.5.30729; Tablet PC 2.0) | ||
+ | |- | ||
+ | | <span class="code">page_url</span> | ||
+ | | URL | ||
+ | | '''Yes''' | ||
+ | | The URL of the page where a landing or action occurred. | ||
+ | | http://www.example.com/store/buy-now<br />https://conversion.marketruler.com/signup.php | ||
+ | |- | ||
+ | | <span class="code">top_page_url</span> | ||
+ | | URL | ||
+ | | ''No'' | ||
+ | | For Frame-based sites, the URL of the topmost page where a landing or action occurred. | ||
+ | | http://www.example.com/store/buy-now<br />https://conversion.marketruler.com/signup.php | ||
+ | |- | ||
+ | | <span class="code">referrer_url</span> | ||
+ | | URL | ||
+ | | ''No'' | ||
+ | | The referring page for the current page. Equivalent to the '''Referer''' HTTP header for web pages. | ||
+ | | http://www.example.com/store/checkout<br />https://www.conversionruler.com/pricing/ | ||
+ | |- | ||
+ | | <span class="code">craction</span> | ||
+ | | string | ||
+ | | ''No'' | ||
+ | | The code name of the action which occurred on the page in question. These should be configured in ConversionRuler's actions management. If not supplied the page is treated as a landing page. | ||
+ | | order<br />thank-you<br />5<br />newsletter | ||
+ | |- | ||
+ | | <span class="code">cramount0<br/>cramount1<br />cramount2<br />cramount3</span> | ||
+ | | floating-point | ||
+ | | ''No'' | ||
+ | | Pass floating point values to ConversionRuler configured for the action code specified. Ignored if no <span class="code">craction</span> is specified. These values are cleaned of non-numerical information before being processed. | ||
+ | | $512.52<br />39.99<br />0.002<br />245 | ||
+ | |- | ||
+ | | <span class="code">crtext0<br/>crtext1<br />crtext2<br />crtext3</span> | ||
+ | | strings | ||
+ | | ''No'' | ||
+ | | Pass text values to ConversionRuler configured for the action code specified. Ignored if no <span class="code">craction</span> is specified. | ||
+ | | O6139086342<br />basic-plan<br />58120938105<br />Fuzzy Slippers | ||
+ | |- | ||
+ | | <span class="code">same</span> | ||
+ | | boolean | ||
+ | | ''No'' | ||
+ | | 0 or 1. Whether landings should be recorded on pages which originate from the same domain. | ||
+ | | 0<br />1 | ||
+ | |- | ||
+ | | <span class="code">title</span> | ||
+ | | string | ||
+ | | ''No'' | ||
+ | | Current page title. | ||
+ | | Welcome to our business!<br />Checkout<br />Enter payment information<br />Widgets Inc. thanks you! | ||
+ | |- | ||
+ | | <span class="code">v</span> | ||
+ | | integer | ||
+ | | '''Yes''' | ||
+ | | Snippet version. The current snippet version is <span class="code">4444</span>. | ||
+ | | 4444 | ||
|} | |} | ||
+ | |||
+ | In general, you should send all information which is known to your program for each request. | ||
+ | |||
+ | The date and time of each transaction is recorded upon submission, so your application should submit information in real-time to the ConversionRuler servers. | ||
+ | |||
+ | Each query string value should be url encoded correctly. Blank or empty values should not be sent when possible. | ||
+ | |||
+ | For any questions, please contact [[ConversionRuler Support]]. | ||
[[Category:ConversionRuler Features]] | [[Category:ConversionRuler Features]] | ||
+ | [[Category:ConversionRuler]] |
Latest revision as of 21:07, 27 April 2016
ConversionRuler supports back-end calls to our server from your server, provided that your web site is willing to manage aspects of the user session and cookie management. This functionality is intended for advanced developers who understand cookies, the HTTP protocol, URL escaping, and how to retrieve various aspects of browser state.
The main call to ConversionRuler is:
https://www.conversionruler.com/bin/tracker.php
All parameters are passed as a query string to the above call. The server will respond with a
204 No content
return code upon successful recording.
The following parameters are accepted to this call:
Parameter | Type | Required | Description | Examples |
---|---|---|---|---|
siteid | string | Yes | The Site ID assigned to your site. Should remain the same for your entire site. Usually a numeric value (integer) but may be extended in the future to support text values as well. | 19 935 |
ip | IPv4 | No | If supplied, the IP address of the browser accessing your site. If not supplied, the IP address of the client making the request (e.g. the browser). | 125.63.12.52 192.168.0.12 8.5.1.2 |
user_id | 32-character hexadecimal string | Yes | The unique identifier for this user on your site. This identifier should persist for this visitor for as long as possible and be set as a cookie in the user's browser and passed through for each call to the tracking script. | c4ca4238a0b923820dcc509a6f75849b eccbc87e4b5ce2fe28308fd9f2a7baf3 |
session_id | 32-character hexadecimal string | Yes | The unique identifier for this user's session on your site. This identifier should persist for this visitor for 30 minutes after their most recent page view. A new session ID should be generated after 30 minutes of inactivity. This can be done by setting the session cookie to expire 30 minutes after the current time, and creating a new session ID for the user if it does not exist. | e4da3b7fbbce2345d7772b0674a318d5 8f14e45fceea167a5a36dedd4bea2543 |
useragent | string | Yes | The user agent string from the client's browser. | Mozilla/5.0 (Macintosh; Intel Mac OS X 10_11_4) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/49.0.2623.112 Safari/537.36 Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 10.0; WOW64; Trident/7.0; Touch; .NET4.0C; .NET4.0E; .NET CLR 2.0.50727; .NET CLR 3.0.30729; .NET CLR 3.5.30729; Tablet PC 2.0) |
page_url | URL | Yes | The URL of the page where a landing or action occurred. | http://www.example.com/store/buy-now https://conversion.marketruler.com/signup.php |
top_page_url | URL | No | For Frame-based sites, the URL of the topmost page where a landing or action occurred. | http://www.example.com/store/buy-now https://conversion.marketruler.com/signup.php |
referrer_url | URL | No | The referring page for the current page. Equivalent to the Referer HTTP header for web pages. | http://www.example.com/store/checkout https://www.conversionruler.com/pricing/ |
craction | string | No | The code name of the action which occurred on the page in question. These should be configured in ConversionRuler's actions management. If not supplied the page is treated as a landing page. | order thank-you 5 newsletter |
cramount0 cramount1 cramount2 cramount3 |
floating-point | No | Pass floating point values to ConversionRuler configured for the action code specified. Ignored if no craction is specified. These values are cleaned of non-numerical information before being processed. | $512.52 39.99 0.002 245 |
crtext0 crtext1 crtext2 crtext3 |
strings | No | Pass text values to ConversionRuler configured for the action code specified. Ignored if no craction is specified. | O6139086342 basic-plan 58120938105 Fuzzy Slippers |
same | boolean | No | 0 or 1. Whether landings should be recorded on pages which originate from the same domain. | 0 1 |
title | string | No | Current page title. | Welcome to our business! Checkout Enter payment information Widgets Inc. thanks you! |
v | integer | Yes | Snippet version. The current snippet version is 4444. | 4444 |
In general, you should send all information which is known to your program for each request.
The date and time of each transaction is recorded upon submission, so your application should submit information in real-time to the ConversionRuler servers.
Each query string value should be url encoded correctly. Blank or empty values should not be sent when possible.
For any questions, please contact ConversionRuler Support.