APIs for Sharing Dashboards & Cards

APIs for Sharing Dashboards & Cards

API Authentication & Implementation

APIs can be used to present Analytics 365 statistical data from published dashboard cards of paid subscribers in another application, such as Power BI.

Step 1: Create a bearer token from within the app

To use Analytics 365 APIs, a super administrators must first create a bearer token for the user accessing the data. This is done from the settings section of the app. To create a bearer token: 
  1. Go to Settings  
  2. Click Create New 
  3. Enter a token name 
  4. Select a user from the drop-down list  
  5. enter an expiry date and save 
  The bearer token will replicate the permissions of the user thereby authenticating access to the appropriate data. Once created, the token can be copied or deleted. 

Step 2: In the API interface, use the bearer token with the relevant API command. See the full API framework below. 

  1. Select the relevant API (see below). 
  2. Add the bearer token in the authorization section of the API client/interface. 
  3. Choose the appropriate API request method (GET, POST, DELETE, etc.)  
  4. Enter the API URL (all URLs begin with this prefix:  https://app.uk.analytics-365.com/api/).  
  5. Enter the request code for the API. 

API Framework 

Present a Dashboard: GetDashboards

Use the GetDashboards API to present a dashboard for a particular paid subscriber. This API returns the list of Dashboard IDs of all published dashboards for that user and their individual URLs.

Key Name
Value
URL
Description
Get list of dashboards
Method
GET
Request

Response
[
{
"userDashboardsID": 621,
"userId": " abc@xyz.com ",
"name": "Sample Dashboard",
"isDemo": false,
"isDefault": true,
"dashboardUrl": "Y-8EGNaCd9e6o_Cu_kJoXcQKGVyz31cNBp_ThRwV"
}
]

Input Parameters
None

Output Parameters
Parameter Name
Parameter Description
userDashboardsID
User Dashboards ID
userId
User email
name
Dashboard name
isDemo
Is dashboard a demo dashboard
isDefault
Is dashboard a default dashboard
dashboardUrl
Dashboard URL

Present Dashboard Cards: GetDashboardById  

Use the ‘GetDashboardById’ API to present dashboard cards of paid subscribers. This API returns the IDs of a user’s dashboard cards published on a specific dashboard and their individual URLs.

Substitute {dashboardId} in the URL below with the ID of the relevant dashboard. To obtain the dashboard ID, use the 'GetDashboards' API above.

Key Name
Value
URL
Description
Get Card list by dashboard Id
Method
GET
Request

Response
[
{
"cardID": 24,
"widgetID": 11,
"viewTypeID": 17,
"name": "Sample Card",
"dashboardName": "Sample Dashboard",
"x": 2,
"y": 4,
"cardURL": "ndY2-NaCd9e6o_Cu_kJoXcQKGVyz31cNBp_ThRwV"
}
]

Input Parameters
Parameter Name 
Data Type
Is Mandatory or Optional
Allowed Values
Parameter Description
dashboardId
Int
Mandatory
Dashboard Ids
Dashboard Ids

Output Parameters
Parameter Name
Parameter Description
cardID
Card ID
widgetID
Card Widget Id
viewTypeID
Card View Type Id
name
Card Name
dashboardName
Dashboard Name
x
Card’s X position
y
Card’s Y Position
cardURL
Card URL

Retrieve Card Data in JSON Format: GetCardData

Use the ‘GetCardData’ API to return the statistical data of a published card of a paid subscriber (in JSON) by following these steps. 
  1. Get a list of dashboard IDs using the 'GetDashboards' API.
  2. Identify the ID of the relevant dashboard/s.
  3. Get the list of Card IDs using the 'GetDashboardById' API.
  4. Identify the ID of the relevant card/s.
  5. Get the statistical data of dashboard cards in JSON format using the 'GetCardData' API below. Substitute {cardId} in the URL below with the ID of the relevant card. (To obtain the Card ID, use the 'GetDashboardById' API above.)
Key Name
Value
URL
Description
Get card data by card Id
Method
GET
Request

Response
{
"filters": {
"cardId": 37145,
"widgetId": 15,
"runPeriod": 5,
"timePeriod": 2,
"selectedStartDate": "2022-07-05 00: 00:00.000",
"selectedEndDate": "2022-07-05 00: 00:00.000",
"selectedStartTime": "00:00:00",
"selectedEndTime": "15:00:00",
"teamFilter": "",
"groupFilter": "",
"callQueueFilter": "",
"agentFilter": "",
"userFilter": "-1",
"callQualityFilter": "0,1,2",
"sentimentFilter": "0,1,2",
"reactionFilter": "0,1,2,3,4,5,6",
"modalitiesFilter": "0,1,2",
"messagesFilter": true,
"teamIsGroup": false,
},
"inValidLicenses": [
{
"userId": 4407,
"userName": "xyz",
"userPhoto": null,
"isPhotoAvailable": false
}
],
"data": []
}

Input Parameters

Parameter Name

Data Type

Is Mandatory or Optional

Allowed Values

Parameter Description

cardId

Int

Mandatory

Card ids

Card id


Output Parameters

Parameter Name

Parameter Description

filters

Applied filters on card

cardId

Card Id

widgetId

Card widget id

runPeriod

Card run period type

timePeriod

Card time period

selectedStartDate

Selected start date

selectedEndDate

Selected end date

selectedStartTime

Selected start time

selectedEndTime

Selected end time

teamFilter

Team filter ids

groupFilter

Group filter ids

callQueueFilter

Call queue filter ids

agentFilter

Agent filter ids

userFilter

User filter ids

callQualityFilter

Call quality filter ids

sentimentFilter

Sentiment filter ids

reactionFilter

Reaction filter ids

modalitiesFilter

Modalities filter ids

messagesFilter

Messages filter value

teamIsGroup

Is data outside selected team included

inValidLicenses

List of users with invalid licenses

userId

User Id

userName

User display name

userPhoto

User photo

isPhotoAvailable

Is user photo available

data

Card Data

Retrieve Card Data in CSV Format: GetCardDataAsCSV

Users with the appropriate permissions can use the ‘GetCardDataAsCSV’ API to return the statistical data of a published card of a paid subscriber (in CSV) by following these steps:
  1. Get a list of dashboard IDs using the 'GetDashboards' API above.
  2. Identify the ID of the relevant dashboard/s.
  3. Get the list of Card IDs using the 'GetDashboardById' API above.
  4. Identify the ID of the relevant card/s.
  5. Get the statistical data of dashboard cards in CSV format using the 'GetCardDataByCSV'. Substitute {cardId} in the URL below with the ID of the relevant card. (To obtain the Card ID, use the 'GetDashboardById' API above.)

Key Name

Value

URL

Description

Get card data in data table format with card url

Method

GET

Request

Params

{

   "cID": "sfgsdu2-ns4dsjcvwetfe3-2fue"

}

Response

data


Input Parameters
Parameter Name
Data Type
Is Mandatory or Optional
Allowed Values
Parameter Description
cID
String
Mandatory
Card URL
Card URL

Output Parameters
None

    • Related Articles

    • Dashboards Explained

      To view a list of your dashboards, select the Dashboards tab in the top left corner of the app. To get you started, a set of default dashboards have been prepared for you. From the View My Dashboards page you can: Open dashboards to view and to add ...
    • FAQs: Dashboards & Cards

      Why are some cards no longer available? Some cards have been replaced by other improved cards as is indicated below: Call Summary / Communication by People: data is now within Call Summary by People. Call Trends: data is now within Collaboration ...
    • Dashboard Cards Overview

      Dashboard cards are categorised by communication type (calls, messages, meetings, overall collaboration, platform and teams calling), view type (summary, activity, trends, comparison, insights), people engagement, manager engagement, wellbeing and ...
    • Editing Dashboard Cards & Using Filters

      Card Name Every card name is editable and displayed in the top banner of each card. Filters The filters for individual cards, can be edited to tailor dashboards, by clicking on the edit icon in the top right corner of every card. On editing filters ...
    • Teams Calling Cards Defined

      Agent Activity by Queue View a summary of agent activity in each call queue, including number of calls offered, answered and missed, as well as the average talk and answer times. Use this card to understand call activity within call queues. (Data: ...