Configuring REST API

Creating a REST API Network

The REST API network allows you to connect external REST API services and retrieve data for monitoring within the platform.

  1. Navigate to the Devices module from the sidebar.

  2. Click the + (Add) icon and select REST API from the Choose a Network dropdown.

    The Create Network dialog box appears.

    Create REST API Network

  3. Configure the REST API connection by providing the required details.

    FieldDescription
    API NameEnter a unique name to identify the REST API network.
    Base URLEnter the base URL or endpoint of the REST API.
    Auth TypeSelect the required authentication method. Available options are No Auth, Basic Auth, and Bearer Token.
    Include Custom HeadersEnable this option to add additional HTTP headers required by the REST API.

Authentication Types

No Auth

Select No Auth if the REST API does not require authentication.

Basic Auth

Select Basic Auth if the API requires a username and password.

FieldDescription
UsernameEnter the username used for API authentication.
PasswordEnter the password associated with the username.

Bearer Token

Select Bearer Token if the API uses token-based authentication.

FieldDescription
TokenEnter the bearer token provided by the REST API service.

Custom Headers

If the API requires additional HTTP headers, enable Include Custom Headers and provide the required headers in JSON format.

  1. Click Test Connection to verify that the REST API endpoint is reachable and the authentication details are valid.

  2. Click Create Network.

    The REST API network is successfully created and displayed in the Devices module.


Understanding the REST API Response

The configured Base URL returns data in JSON format. The platform reads the JSON response and extracts the available fields, which can then be used to create monitoring points.

For example, the REST API may return the following response:

{
  "location": {
    "name": "Coimbatore",
    "region": "Tamil Nadu",
    "country": "India"
  },
  "current": {
    "temp_c": 28.9,
    "humidity": 58,
    "wind_kph": 19.8,
    "pressure_mb": 1010,
    "condition": {
      "text": "Partly Cloudy"
    }
  }
}

The platform converts the JSON response into field paths using dot notation.

JSON ValueField Path
Citylocation.name
Regionlocation.region
Countrylocation.country
Temperaturecurrent.temp_c
Humiditycurrent.humidity
Wind Speedcurrent.wind_kph
Pressurecurrent.pressure_mb
Weather Conditioncurrent.condition.text

These field paths are used while adding monitoring points.


Configuring and Adding a Device

After creating the REST API network, add a device to retrieve data from the configured REST API.

  1. Select the created REST API network.

  2. Click Add Device.

    The Add Device dialog box appears.

    Add REST API Device

  3. Enter the required device details.

    FieldDescription
    Device NameEnter a unique name for the device.
    Device DescriptionEnter a brief description of the device.
    Poll FrequencySpecify how frequently the platform polls the REST API to retrieve the latest data.

    The platform provides two methods for configuring attributes:

    • Fetch from API
    • Add Manually

Fetch from API

  1. Select Fetch from API.

  2. Click Fetch Fields.

    The platform retrieves all available fields from the configured REST API response.

  3. Select the required fields from the list.

    Each field contains:

    FieldDescription
    Field NameThe attribute name retrieved from the API response.
    Field PathThe JSON path of the selected attribute.
  4. Click Add.

    The selected fields are added to the device configuration.

  5. Click Add Device.

    The device is created successfully.

    Fetch API Fields


Add Manually

Select Add Manually if you want to configure the attributes yourself.

Enter the required attribute details manually and click Add.

Repeat the process for additional attributes if required.

Click Add Device to create the device.

Add Attributes Manually


Adding Points

After creating the device, you can create monitoring points for the required attributes.

  1. Select the newly created REST API device.

  2. Click Add Points.

    The Add Points dialog box appears.

    Add Points

  3. Enter the Attribute Count.

    The Attribute Count specifies the number of attributes (points) that you want to create.

  4. Click Add Attribute.

    A new attribute row is added for each point.

    Configure the following details for each attribute.

    FieldDescription
    Attribute NameEnter a unique name for the point.
    Field PathEnter the JSON path corresponding to the attribute in the API response.

    Repeat the process until all required attributes have been added.

  5. Click Add.

    The selected attributes are created as monitoring points.


Starting the Points

After the points have been created successfully, you can start retrieving live values.

  1. Locate the required point under the REST API device.

  2. Turn the On toggle for the point.

    The platform starts polling the configured REST API based on the specified Poll Frequency and updates the point with the latest values.

    Starting Points


Viewing Live Values

Once the point is turned On, click the required point to view its details.

The Point Details page displays:

  • Point Properties
  • Live Values
  • Communication Status
  • Real-time Updates

Live Point Values

Point Properties

After enabling a point, click the required point to view and configure its properties.

The point details page contains the following tabs:

  • Properties
  • Config

Point Properties

After the point is created and enabled, click the required point to open its Properties page.

The Properties tab allows you to view and modify the basic information of the selected point.

Point Properties

The following fields are available:

FieldDescription
Point NameDisplays the name of the point. You can modify the point name if required.
Point DescriptionEnter or update a description for the point.
Point PathDisplays the JSON field path associated with the point.
Point UnitSpecify the unit of measurement for the point, such as °C, %, kPa, or km/h.

After updating the required fields, click Save Changes to save the point configuration.


Point Configuration

After opening a point, click the Config tab to configure the point settings.

The Config tab contains the following sections:

  • General
  • Alarms
  • Trends
  • Tags

General

The General section allows you to configure linear mapping, scaling, and offset values for the selected point.

Point Characteristics

Enable Linear Mapping to map the raw input value to the required output range.

FieldDescription
Min VoltageSpecifies the minimum input value.
Max VoltageSpecifies the maximum input value.
Min OutputSpecifies the minimum mapped output value.
Max OutputSpecifies the maximum mapped output value.

Scaling

Enable Scaling to multiply the incoming point value by a scaling factor.

FieldDescription
Scaling ValueSpecifies the scaling factor applied to the point value.

Offset

Enable Offset to adjust the point value by adding or subtracting a fixed value.

FieldDescription
Offset ValueSpecifies the offset value applied to the point.

Live Readings

The Live Readings section displays:

  • Raw Value
  • Calculated Value

After configuring the required settings, click Apply Changes to save the configuration.

General Configuration


Alarms

The Alarms section allows you to configure alarm thresholds for the selected point.

The following alarm types are available:

  • High Critical
  • Low Critical

For each alarm, you can configure:

FieldDescription
PrioritySelect the alarm priority.
Critical LimitSpecify the threshold value that triggers the alarm.
Alarm MessageEnter the message displayed when the alarm is triggered.

Enable the required alarm and click Save Alarm Configuration to apply the changes.

Alarm Configuration


The Trends section allows you to configure data logging for the selected point.

Data Logging

Enable Data Logging and configure the following settings:

FieldDescription
Trend IntervalSpecifies how frequently the point value is logged.
Max History RecordsSpecifies the maximum number of records to store.

Active Calendar

The Active Calendar allows you to define when trend logging should be active.

Configure:

  • Days of the week
  • Start Time
  • End Time

After completing the configuration, click Save Trend Configuration.

Trend Configuration


Tags

The Tags section allows you to organize points using custom tags.

To add a tag:

  1. Enter the tag name in the Search & Add Tags field.
  2. Select an existing tag or create a new one.
  3. The selected tag is displayed under Added Tags.

Tags help group and filter points throughout the platform.

Tags Configuration


Alarm Status

After configuring the required alarm thresholds, click Save Alarm Configuration.

The platform continuously monitors the point value against the configured alarm limits. When the point value exceeds the configured threshold, the corresponding alarm is generated.

You can verify the alarm status for the selected point by checking whether the alarm has been triggered based on the configured limits. If the point value remains within the configured threshold, no alarm is generated.

Alarm Status


To view the historical data of a point, select the required point and click the Trends tab.

The Trends page displays the historical data in both Table and Chart views.


Table View

The Table view displays the recorded values of the selected point in a tabular format.

The following options are available:

OptionDescription
Start DateSelect the starting date for retrieving trend data.
End DateSelect the ending date for retrieving trend data.
ExportExports the displayed trend data to a CSV file.
RefreshRetrieves the latest trend data for the selected date range.
ClearClears the selected date range and displayed data.
DeltaEnables or disables delta value display.
EditEnables or disables edit mode using the toggle button.

Alarm Status

Chart View

The Chart view displays the historical data of the selected point as a graphical trend.

The following options are available:

OptionDescription
Start DateSelect the starting date for displaying trend data.
End DateSelect the ending date for displaying trend data.
ExportExports the displayed chart data.
RefreshReloads the trend data based on the selected date range.
ClearClears the selected filters and chart data.
DeltaEnables or disables delta value display on the chart.
EditEnables or disables edit mode using the toggle button.

Alarm Status

The table and chart views help users analyze historical point data over a selected period and export the data for further analysis.

Complete Workflow

Follow the steps below to configure a REST API network and monitor live data.

  1. Open the Devices module.
  2. Click the + (Add) icon and select REST API.
  3. Enter the required network details:
    • API Name
    • Base URL
    • Authentication Type
    • Custom Headers (if required)
  4. Click Test Connection to verify the REST API connection.
  5. Click Create Network.
  6. Select the newly created REST API network.
  7. Click Add Device.
  8. Enter the device details:
    • Device Name
    • Device Description
    • Poll Frequency
  9. Configure the device attributes using one of the following methods:
    • Fetch from API – Retrieve and select fields from the JSON response.
    • Add Manually – Manually specify the required attributes and field paths.
  10. Click Add Device to create the device.
  11. Select the newly created device and click Add Points.
  12. Enter the Attribute Count.
  13. Click Add Attribute and configure the required Attribute Name and Field Path for each point.
  14. Click Add to create the monitoring points.
  15. Turn the required point On to start polling the REST API.
  16. Open the point to:
    • View and edit Point Properties.
    • Configure General, Alarms, Trends, and Tags from the Config tab.
  17. Configure alarm thresholds and click Save Alarm Configuration to monitor alarm status.
  18. Configure trend logging and click Save Trend Configuration.
  19. View the live values of the selected point.
  20. Open the Trends tab to analyze historical data using:
    • Table View
    • Chart View
  21. Export trend data, refresh the display, clear filters, or enable Delta and Edit options as required.