Dashboard Analytics

Dashboard Analytics Service

APIs for DSS analytics dashboard primarily consists of 2 APIs. The one which is used to get configuration based on which the dashboard is painted. The other one is the API which gets the data needed for the visualization to paint different graphs.

API to get the Dashboard Configuration which gives the Visualizations and Layout to paint

This endpoint will pass the Dashboard ID from the URL to this API and will get the Dashboard Configuration from the backend which will have the details of the Visualization Layouts which are to be designed in this Dashboard.

GEThttps://dev.digit.org/dashboard/[APIEndPoint]/getDashboardConfig/{dashboardId}
Path parameters
dashboardId*string

ID of the Dashboard

Response

Response for Success State of the API

Body
statusInfoStatusInfo (object)

Status Information object will hold the run time status and the live response obtained from the server for the respective API Call.

responseDataarray of Dashboard (object)
Request
const response = await fetch('https://dev.digit.org/dashboard/[APIEndPoint]/getDashboardConfig/{dashboardId}', {
    method: 'GET',
    headers: {},
});
const data = await response.json();
Response
{
  "statusInfo": {
    "statusCode": "text",
    "statusMessage": "text",
    "errorCode": 0,
    "errorMessage": "text"
  },
  "responseData": [
    {
      "name": "text",
      "id": "text",
      "isActive": false,
      "style": "text",
      "visualizations": [
        {
          "row": 0,
          "name": "text",
          "vizArray": [
            {
              "id": 0,
              "name": "text",
              "dimensions": {
                "height": 0,
                "width": 0
              },
              "vizType": "text",
              "charts": [
                {
                  "id": 0,
                  "name": "text",
                  "code": "text",
                  "chartType": "text"
                }
              ]
            }
          ]
        }
      ]
    }
  ]
}

Get Chart API will be responding with the Data for each visualization based on the Chart ID which has been sent

Based on the Chart ID and the Visualization Type and the Request Dates and Filters, the API will aggregate the data and give the data which needs to be painted on Visualization Charts

POSThttps://dev.digit.org/dashboard/[APIEndPoint]/getChartV2
Query parameters
Header parameters
Body

This request object contains the Visualization for which the data has to be served.

headerobject

A map of String and and String to hold the Header Filters which are applied on this dashboard

aggregationRequestAggregationRequest (object)
Response

Response for Success State of the API

Body
statusInfoStatusInfo (object)

Status Information object will hold the run time status and the live response obtained from the server for the respective API Call.

responseDataarray of ChartApiResponse (object)
Request
const response = await fetch('https://dev.digit.org/dashboard/[APIEndPoint]/getChartV2', {
    method: 'POST',
    headers: {
      "Content-Type": "*/*"
    },
    body: JSON.stringify({}),
});
const data = await response.json();
Response
{
  "statusInfo": {
    "statusCode": "text",
    "statusMessage": "text",
    "errorCode": 0,
    "errorMessage": "text"
  },
  "responseData": [
    {
      "chartType": "text",
      "chartFormat": "text",
      "drillDownChartId": "text",
      "data": [
        {
          "headerName": "text",
          "headerValue": 0,
          "headerSymbol": "text",
          "plots": [
            {
              "label": "text",
              "name": "text",
              "value": 0,
              "symbol": "text"
            }
          ]
        }
      ]
    }
  ]
}

Last updated

​All content on this page by eGov Foundation is licensed under a Creative Commons Attribution 4.0 International License.