Skip to content

Remote Access Analytics

Learn from this guide how to set up remote-access analytics by integrating specialized software with our system, using the connection history as an example.

Analytics is the process of collecting, processing, interpreting, and using data to identify patterns, gain insights, and make informed decisions.

The tools for this process usually include visual reports with charts and tables. The main goal of this guide is to show how to integrate our system with external analytics platforms to create reports like these.

Author’s note

At the moment, no built-in analytics tools are available in the technician’s dashboard. We believe analytics is a separate, independent workflow that requires specialized tools and interfaces. We cannot offer it as a native feature at the same high level of quality as the rest of our remote-access functionality. Therefore, the right solution for this task is to use external software.

Integration

We will use commonly recognized analytics tools following the principle below:

  1. Get the source data – request data using the HTTP API.
  2. Transfer the data to an intermediate storage – it is needed as the data source for the analytics system.
  3. Visualize the data – in the analytics system as clear and informative reports.

Choosing a System

We need an external analytics platform such as Looker Studio , Microsoft Power BI , and others. In this guide, we will use Looker Studio as an example. And for the intermediate storage, we will use Google Sheets. Therefore, you will need an account with Google .


Data Dreparation

All reports are built based on the source data — in our case, on the Connection History. We need to extract the data from the personal account and place it into the intermediate storage.

Retrieving Data

You can extract the raw connection history data by making a request to the HTTP API using the history/list method.

GET /v1/history/list
  ?agent_id=<number>
  &support_id=<number>
  &date_from=<unixtime>
  &date_to=<unixtime>
  &video=<boolean>
  &offset=<number>
  &limit=<number>
Host: https://api.getscreen.me
X-Api-Key: YOUR_API_KEY
curl -G "https://api.getscreen.me/v1/history/list" \
  --data-urlencode "agent_id=<number>" \
  --data-urlencode "support_id=<number>" \
  --data-urlencode "date_from=<unixtime>" \
  --data-urlencode "date_to=<unixtime>" \
  --data-urlencode "video=<boolean>" \
  --data-urlencode "offset=<number>" \
  --data-urlencode "limit=<number>" \
  -H "X-Api-Key: YOUR_API_KEY"
Parameter Type Value
agent_id string Filter by agent ID
support_id number Filter by invitation ID
date_from unixtime Filter by date and time: period start
date_to unixtime Filter by date and time: period end
video boolean Filter by video recording
offset number Offset for the first item in the list
limit number Number of items in the list. Default value: 20; maximum value: 100

The response will contain all the necessary data:

Example Response
Response Data
{
    "offset": 0,
    "limit": 10,
    "total": 15,
    "filter": {
        "date_from": 1608660281,
        "date_to": 1608660389,
        "agent_id": 1001,
        "support_id": 1002,
        "video": true
    },
    "data": [ {
        "id": 27233,
        "start": 1608660273,
        "stop": 1608660281,
        "support_id": 1002,
        "client": [ {
            "user_agent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/87.0.4280.88 Safari/537.36",
            "login": "[email protected]",
            "geo": {
                "ip": "2.21.31.68",
                "country": "USA",
                "region": "California",
                "city": "Los Angeles"
            }
        } ],
        "agent": {
            "id": 1001,
            "name": "DESKTOP-SJBU5PO",
            "group": "Accounting",
            "geo": {
                "ip": "2.21.31.68",
                "country": "USA",
                "region": "California",
                "city": "Los Angeles"
            },
            "os": "win",
            "version": "2.1.5",
            "owner": "[email protected]"
        },
        "video": {
            "url": "https://st.getscreen.me/video/2/27233.mp4",
            "size": 428652
        }
    }, ... ]
}
Name Type Description
id number Internal system connection ID
start unixtime Connection start date and time
stop unixtime Connection end date and time

ℹ Can be empty if the connection is not ended
support_id number Invitation connection ID

ℹ The field may be blank if there was a connection to a Permanent Access device
client array List of clients who joined the connection
client[].user_agent string User agent
client[].login string User login

ℹ Can be empty if the connection was anonymous
client[].geo object Location
client[].geo.ip string IP address
client[].geo.country string Country
client[].geo.region string Region
client[].geo.city string City
agent object Agent info
agent.id number Internal system agent ID
agent.name string Name
agent.group string Group
agent.geo object Location
agent.geo.ip string IP address
agent.geo.country string Country
agent.geo.region string Region
agent.geo.city string City
agent.os string Operating system. Possible values: win, mac, linux or android
agent.version string Software version
agent.owner string Account login of the permanent access owner
video object Video recording info

ℹ Can be missing if the connection was not recorded
video.url string Video recording file address

⚠ To download a file with a video recording of the connection, add the ?apikey= parameter with your API key.
video.size number Video recording file size in bytes

HTTP API Reference

Learn about all available methods, how to make requests, and where to get your API Key in the section HTTP API Reference.

Don’t rush

You don’t need to make this request manually. It is shown only to demonstrate the data you can obtain via the HTTP API, and it will be used in automated scripts when filling the intermediate storage — you will find that information below.


Intermediate Storage

The simplest data source for reports is a regular Google Sheet, so we will store the data there.

You need to create a spreadsheet in Google Drive named Data. To do this, follow this link and make a copy of the table prepared for you in advance:

Script Configuration

When the spreadsheet is ready, it needs to be filled with data obtained from the HTTP API request. We will do this using scripts.

Open the script editor via Extensions Apps Script.

In the opened window, select the file named config.gs and replace the <API_TOKEN> value with your API key:

const CONFIG = {
  API_URL: 'https://api.getscreen.me/v1/',
  API_TOKEN: '<API_TOKEN>',
};

Data Initialization

To fill the spreadsheet, in the left menu of the Apps Script editor, select the index.gs file, then in the script control panel choose the method fetchSessionsLast90Days and click Run.

The script will request the last 90 days of data via the HTTP API and fill the spreadsheet with it. During execution, you will see the activity log:

17:25:40 Note Execution started
17:25:42 Info Request [1762529140 .. 1770305140]: total=149, fetched=100
17:25:44 Info Request [1762529140 .. 1764771841]: total=50, fetched=50
17:25:44 Info Done. Interval [1762529140 .. 1770305140], total unique rows: 149
17:25:44 Note Execution finished

Data for a longer period

If you need data for a longer period (for example, a year), you can change the number of days in the fetchSessionsLast90Days method in the index.gs file or add a new function. But the larger the requested period, the more requests will be made to the HTTP API, because it returns a maximum of 100 records per call. If there are too many frequent requests, this will create load on our server and may trigger automatic blocking of your IP address, causing inconvenience for you. Be careful and choose a reasonable period for the initial table filling.


Data Update

To always have the latest data in your reports, you can configure automatic loading of entries for the previous day at the end of each day.

To do this, in the Apps Script editor, go to the Triggers section and click Add trigger. In the opened window, select the function fetchSessionsLastDay, set the event source to Time-driven, the type to Daily, the time to from 00:00 to 1:00, and save the trigger. Now the table will continue updating automatically.

Data Visualization

The most important part of configuring the report is data visualization. You can set up charts and a dashboard based on the intermediate data on your own and at your discretion. However, below we will look at an example using a template we prepared.

To use it, you need to follow this link and copy the template by clicking Make a copy in the top right corner:

When copying the report template, the system will ask which data source to use for your copy. In the New Data Source field, select Create data source:

Next, in the popup area, select the Google Sheets connector.

In the next step, in the Spreadsheet column, select the file named Data, in the Worksheet column select history, and click CONNECT in the top right corner.

Next, the system will display the fields it found in the selected file and other settings for the new data source. Review them and click the Add to Report button in the top right corner.

The final step is to confirm all the actions you have taken and complete the copying.

Now in your Looker Studio dashboard you will see a copy of the report built on your data:

Analytics

We would like to highlight the important and convenient features of our report template that are now available to you.

Charts

The report includes charts for basic analytics:

  • Sessions by day
  • Top 10 most popular devices
  • Top 10 most active technicians


Filtering

You can filter the report data and view it from different angles:

  • Within a selected period
  • For a specific technician
  • For a specific device


Metrics

You can also view the data across different metrics:

  • Number of sessions
  • Session duration

For this, the report contains two pages:


Raw Data

For deeper and more detailed analytics, a table with raw data is available, with the ability to sort by columns: