Statistics API

GET

  • The GET method displays the mains statistics of an office, or from the whole domain. 

GET developer.viadesk.com/api/statistics?start=2022…

  • Parameter office represents the office id, and is optional. If no office-parameter is given, data of the whole domain is displayed, and ‘popular offices’ is added. 
  • Parameters start and end are relevant for which new items, responses or likes are placed. 
  • Parameter maxitems can be used to change the number of popular items or offices displayed, default is 10.
  • Validation: either office or start/end are required to limit load on the server. Please consider that the statistics are not cached, and many repetitive calls can influence the performance of your Viadesk domain. 

 
Example response body when office specified:

{
  "visits":56,
  "joins":2,
  "popularItems":[
     {
        "id":"developer.viadesk.com/id/560",
        "name":"User API",
        "hits":22,
        "responses":0,
        "diggsPositive":0,
        "diggsNegative":0
     },
     {
        "id":"developer.viadesk.com/id/643",
        "name":"Roles API",
        "hits":5,
        "responses":0,
        "diggsPositive":0,
        "diggsNegative":0
     }
  ],
  "memberCount":57,
  "totalItems":1,
  "newItems":0,
  "newResponses":0,
  "newDiggsPositive":0,
  "newDiggsNegative":0
}

 
Response body without office-parameter:

{
  "loginTotal":60,
  "loginWeb":60,
  "loginApp":0,
  "popularOffices":[
    {
       "id":"developer.viadesk.com/id/1",
       "name":"Viadesk Developer Portal",
       "joins":2,
       "visits":56,
       "newItems":1
    }
 ],
  "popularItems":[
     {
        "id":"developer.viadesk.com/id/560",
        "name":"User API",
        "hits":22,
        "responses":0,
        "diggsPositive":0,
        "diggsNegative":0
     },
     {
        "id":"developer.viadesk.com/id/643",
        "name":"Roles API",
        "hits":5,
        "responses":0,
        "diggsPositive":0,
        "diggsNegative":0
     }
  ],
  "userCount":57,
  "deactivatedUserCount":10,
  "totalItems":1,
  "newItems":0,
  "newResponses":0,
  "newDiggsPositive":0,
  "newDiggsNegative":0
}