Amar M

Sep 20, 20232 min

Using API to Link Ellenex IoT Platform with Other Visualisation Platforms.

A simple visualisation created using PowerBI with Ellenex API as a source
We believe integratability is the key success point for IoT solutions. That is why we developed the most integratable LPWAN IoT framework to address current and future demands of our industrial clients.

The Ellenex IoT Platform is designed to excel in data collection and near real-time analytics, featuring a highly capable visualisation engine tailored for device-specific data. While we've equipped the platform with a rich set of functionalities, we understand that enterprises often require more customised solutions for amalgamating IoT device metrics with other operational KPIs, such as service costs or broader reporting needs.

EllenexQL: Your Gateway to Custom Data Integration

To address this, we've introduced a specialised EllenexQL endpoint within our API. This endpoint allows industrial clients to query device-specific data within specified date ranges and perform arithmetic operations and aggregations.

The flexibility afforded by this API endpoint makes it easy to integrate Ellenex's data into any third-party platforms your organisation may already be using.

Sample Query for Data Retrieval from Ellenex IoT Platform via API

Below is a sample query structure designed to fetch data through our REST Data Store APIs:

{
 
"@context": "https://schema.ellenex.com/v1/context.jsonld",
 
"@type": "QueryObject",
 
"kind": "Raw",
 
"granularity": "all",
 
"dimensions": [ "resultTime", "device", "pressure", "unit"],
 
"filter": {
 
"@type": "Filter",
 
"kind": "and",
 
"fields": [{
 
"@type": "Field",
 
"kind": "eq",
 
"dimension": "device",
 
"value": "/v1/edi/devices/0ccd677a-d01e-49d9-98a6-5f3d4bcccc46"
 
}]
 
},
 
"intervals": "2023-05-14T00:00:00.000/2023-05-17T00:00:00.000"
 
}

This robust query format not only allows for data retrieval but also supports advanced features like aggregations.

Analytics with PowerBI

EllenexQL can be directly connected to reporting tools such as PowerBI, facilitating instant juxtaposition of your device metrics with other data sources within your organisational framework.

Sample PowerBI Query for Ellenex Data Import

Here's a sample code snippet for importing data from the Ellenex Platform into PowerBI, utilising the same request body schema as above but adapted for variable extraction:

let
 
Payload = Json.FromValue([
 
#"@context" = "https://schema.ellenex.com/v1/context.jsonld",
 
#"@type" = "QueryObject",
 
#"kind" = "Raw",
 
#"granularity" = "all",
 
#"dimensions" = {"resultTime", "device", "pressure", "unit"},
 
#"filter" = [#"@type" = "Filter", #"kind" = "and", #"fields" = {[#"@type" = "Field", #"kind" = "eq", #"dimension" = "device", #"value" = DeviceId]}],
 
#"intervals" = DateTime.ToText(StartTime, "yyyy-MM-ddThh:mm:ss.000") &"/"&DateTime.ToText(EndTime, "yyyy-MM-ddThh:mm:ss.000")
 
]),
 

 
source = Json.Document(Web.Contents("https://api.ellenex.net/v1/edsa/observations/eql",
 
[Headers=[#"Content-Type"="application/json",#"x-api-key"=ApiKey,#"x-lnx-token"=ApiToken],
 
Content=Payload
 
])),
 
deviceDatapoints = Table.FromRows(source[values],source[columns]),
 
#"Changed Type" = Table.TransformColumnTypes(deviceDatapoints,{{"time", type datetimezone}, {"pressure", type number}})
 
in
 
#"Changed Type"

This is just a basic version of the query; a seasoned expert can do much more.

Visualisation Capabilities

Once the API data is ingested into PowerBI, you can visualise it directly within the query editor.

By leveraging PowerBI's extensive features, you can build comprehensive dashboards to track maximum pressure, among other metrics, through gauges and bar graphs.

A simple visualisation created using PowerBI with Ellenex API as a source

Extending Your Analytics

The flexibility of our API means you can achieve complex multi-device and multi-datapoint visualisations by employing a variety of filters and aggregations.

Get Started with Ellenex

For more comprehensive documentation or specialised assistance in integrating Ellenex's API with other reporting tools, please don't hesitate to contact our support team.

By utilising EllenexQL and our API, you can fully exploit the Ellenex IoT Platform’s data retrieval and analysis capabilities, ensuring that your organisation can adapt to the ever-evolving landscape of industrial analytics.

    450
    0