Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

In addition to event objects, the request body may include the following properties:

  • browserType - The user-agent information
  • sessionid - Any string format accepted.
  • un - User ID. Any string format accepted.

The JSON

...

Request Format

The full JSON request format is as follows:

{
    "events": {
      "event": [
        {
          "u": "http://www.intlock.com/",
          "X": "|referral|blog.intlock.com|/about/||",
          "et": 0,
          "RI": 564940
        },
        {
          "X": "1",
          "Y": "7",
          "et": 23,
          "RI": 0
        }
      ]
    },
    "browserType": "Apple-iPhone5C2/1001.525",
    "sessionid": "861529144.325047542",
    "un": "INTLOCK\\tomj"
}

The API URL

The default API URL for a SharePoint site is:

https://[SharePoint WFE]/_layouts/CardioLogAgent/tunnel.aspx?random=895.3324414324015

  • Replace [SharePoint WFE] with your SharePoint URL address
  • The random param is used as a cache buster

...

With the Data Export API you can develop client applications to retreive data from the CardioLog reporting engine, and refine the results of the request using query parameters. It allows This allows for even more flexibility and customization than the CardioLog UI, giving you a great deal of freedom over how to display your reports, in terms of their design, filters and data content, and where the reports are displayed. It's also possible to brand filter and display your reports. You can also brand your data with your organization's colors logos and logos to really take ownership of themes to fully own and identify it.

The CardioLog reporting engine generates the report in XML format and as a chart image.

...

  1. Browse: http://<cardiolog_server>:<port>/CardioLog/CLReport/ReportsAPIHelper.aspxYour browser may not support display of this image.
  2. Select a Report.
  3. Select the report parameters - Date RangeTime IntervalWebsite Item, Users and Groups
  4. Check Generate Chart Image to create an image and set its Width and Height (pixels).
  5. Click Get URL to generate the report URL
  6. Click Generate Report to generate the report.
  7. Click Show Advanced Options  and Get Report Preferences to modify report preferences.

...

The CardioLog report XML contains a preferences section (prefs node), and a data section (data node).

Chart

The chart's x-axis values are displayed in the categories node, while y-axis values are displayed in the dataset node (. Futher, each chart series is represented by a dataset node).

 

<xml id="root">
   <report>
      <call controlId="410" action="get" cached="False">
         <controlTitle>Chart</controlTitle>
         <title>Page Views</title>
         <prefs>
            <prefs>
               <enable3D>true</enable3D>
               <perspective>true</perspective>
               <legend>true</legend>
               <l_INSIDECHART>false</l_INSIDECHART>
               <l_STYLE>row</l_STYLE>
               <l_DOCKING>top</l_DOCKING>
               <labels>false</labels>
               <showtitle>false</showtitle>
               <showhelp>false</showhelp>
               <showpreferences>false</showpreferences>
               <timeframe>864000000000</timeframe>
               <timeInterval>864000000000</timeInterval>
               <rules>
                  <rule id="2022" status="on" title="Aggregated" type="Column" />
                  <rule id="2021" status="on" title="Specific" type="Column" />
                  <rule id="2046" status="off" title="Aggregated" type="Column"
                   period="1" />
                  <rule id="2129" status="off" title="Specific" type="Column" period="1" />
               </rules>
               <ctitle>Page Views</ctitle>
               <type>Column</type>
               <palette>BrightPastel</palette>
               <adgroup>2</adgroup>
               <adgroupname>Domain Users</adgroupname>
               <categories />
               <entityId>0:01264d16-4641-465a-bdfe-459f1cb10d35</entityId>
               <entityName>Collaboration Portal</entityName>
               <entityTree>0</entityTree>
            </prefs>
         </prefs>
         <data>
            <categories>
               <category name="Sun." />
               <category name="Mon." />
               <category name="Tue." />
               <category name="Wed." />
               <category name="Thu." />
               <category name="Fri." />
               <category name="Sat." />
            </categories>
            <dataset ruleId="2021" seriesname="Specific" type="Column">
               <set value="100" />
               <set value="212" />
               <set value="343" />
               <set value="256" />
               <set value="347" />
               <set value="103" />
               <set value="120" />
            </dataset>
            <dataset ruleId="2022" seriesname="Aggregated" type="Column">
               <set value="1390" />
               <set value="1456" />
               <set value="1437" />
               <set value="1367" />
               <set value="1278" />
               <set value="800" />
               <set value="678" />
            </dataset>
         </data>
      </call>
   </report>
</xml>

...

The data section for Table reports is automatically ready for HTML deploymentimplementation.

 

<xml id="root">
   <report>
      <call controlId="411" action="get" cached="True">
         <controlTitle>Table</controlTitle>
         <title>Page Views</title>
         <prefs>
            <prefs>
               <showhelp>false</showhelp>
               <showpreferences>false</showpreferences>
               <timeframe>36000000000</timeframe>
               <timeInterval>36000000000</timeInterval>
               <maxrows>10</maxrows>
               <mincount>1</mincount>
               <reporttype>120</reporttype>
               <columns>
                  <column id="title" title="Title" width="35%" type="SPPage" />
                  <column id="url" title="Url" width="0" type="hidden" />
                  <column id="views" title="Views" sorted="true" width="15%" type="number" />
                  <column id="users" title="Unique Users" sorted="false" width="20%" type="number" />
                  <column id="avgDuration" title="Duration" sorted="false" width="15%" type="string" />
                  <column id="exitRate" title="Exit Rate" sorted="false" width="15%" type="number" />
               </columns>
               <ctitle>Page Views</ctitle>
               <chartType>static</chartType>
               <adgroup />
               <adgroupname />
               <categories />
               <entityId>0:b0426e68-8f34-4eb2-8702-012d5de1c143</entityId>
               <entityName>All</entityName>
               <entityTree>0</entityTree>
            </prefs>
         </prefs>
         <data><![CDATA[<table cache='True'>

<prefs>

<showhelp>false</showhelp>

<showpreferences>false</showpreferences>

<timeframe>36000000000</timeframe>

<timeInterval>36000000000</timeInterval>

<maxrows>10</maxrows>

<mincount>1</mincount>

<reporttype>120</reporttype>

<columns>

<column id="title" title="Title" width="35%" type="SPPage" />

<column id="url" title="Url" width="0" type="hidden" />

<column id="views" title="Views" sorted="true" width="15%" type="number" />

<column id="users" title="Unique Users" sorted="false" width="20%" type="number" />

<column id="avgDuration" title="Duration" sorted="false" width="15%" type="string" />

<column id="exitRate" title="Exit Rate" sorted="false" width="15%" type="number" />

</columns><ctitle>Page Views</ctitle><chartType>static</chartType><adgroup></adgroup><adgroupname></adgroupname><categories></categories><entityId>0:b0426e68-8f34-4eb2-8702-012d5de1c143</entityId><entityName>All</entityName><entityTree>0</entityTree>

</prefs>

<thead>

<td type='SPPage' width='35%' id='title'>Title</td>

<td type='hidden' width='0' id='url'>Url</td>

<td type='number' width='15%' sorted='true' direction='-1' id='views'>Views</td>

<td type='number' width='20%' id='users'>Unique Users</td>

<td type='string' width='15%' id='avgDuration'>Duration</td>

<td type='number' width='15%' id='exitRate'>Exit Rate</td>

</thead>

<tbody from='0' to='10' total='10'>

<tr>

<td>bl_SecondaryNav_Divider.jpg</td>

<td>http://scotland:81/Style Library/Images/bl_SecondaryNav_Divider.jpg</td>

<td>3</td>

<td>3</td>

<td>00:00:04</td>

<td>0%</td>

</tr>

<tr>

<td>Links</td>

<td>http://scotland:81/Lists/Links/AllItems.aspx</td>

<td>3</td>

<td>3</td>

<td>00:00:02</td>

<td>0%</td>

</tr>

<tr>

<td>Workflow Tasks</td>

<td>http://scotland:81/News/WorkflowTasks/AllItems.aspx</td>

<td>3</td>

<td>3</td>

<td>00:00:07</td>

<td>0%</td>

</tr>

<tr>

<td>Total Problems</td>

<td>http://scotland:81/Reports/Lists/Sample Dashboard KPI Definitions/DispForm.aspx?ID=1</td>

<td>3</td>

<td>3</td>

<td>00:00:05</td>

<td>0%</td>

</tr>

</tbody>

<startTime>1/1/0001 12:00:00 AM</startTime><endTime>1/1/0001 12:00:00 AM</endTime><rules>1</rules></table>]]>

         </data>

      </call>

   </report>

</xml>

...

1. How to add values to the chart image:

In order to add values to

...

a chart click on "Show Advanced Settings"

...

in the Data Export API, and then "Get Report Preferences".

...

 In the preferences XML, edit the <labels>true</labels> key and set the value to true.

...

Values should now appear in the chart.

2. How to display the page views meter value:

<script>
function getPageViews() {

...