Through this API you can consult the list of readings inserted to a Fracttal meter.
In this web service you can filter to obtain all the meter readings associated to a particular asset or to obtain all the readings of a specific meter.
The parameter to query the meter readings associated to an asset is:
- Code: Code of the asset to which the meter is associated.
The parameters to query the readings of a particular meter are:
- Code: Code of the asset to which the meter is associated - Serial: Serial of the meter.
This API allows you to filter by the date of the reading to get the meter readings you need.
Input parameters
Parameter | Type | Required | Description | ||||||
---|---|---|---|---|---|---|---|---|---|
code
|
* Text | Optional | Code of the asset associated with the meter. | ||||||
type_date
|
* Text | Optional |
Type of date to make the query. It can be:
|
||||||
serial
|
* Text | Optional | Serial number of the meter to be consulted. | ||||||
since
|
*Text* | Optional | Initial date, applies to the reading date. Formato: ‘YYYY-MM-DDTHH:MM:SS-UTC’ Ejemplo:’2016-07-12T20:00:00-03′. | ||||||
until
|
*Text* | Optional | End date, applies to the reading date. Formato: ‘YYYY-MM-DDTHH:MM:SS-UTC’ Ejemplo:’2016-07-12T20:00:00-03′. | ||||||
code_location
|
*Text* | Optional | Location code. | ||||||
start
|
*Integer* | Optional | Field used to make the pagination of records. It is the number at which the pagination starts. By default it is 0 | ||||||
limit
|
*Integer* | Optional | Number of records (items) you want the API to return. Default is 100 (cannot be higher than this value). |
Output parameters
Parameter | Type | Description | ||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|
date_reading
|
*Text* | Date of reading | ||||||||||
date
|
*Text* | Date of insertion in Fracttal | ||||||||||
data
|
*json* |
Reading information:
|
||||||||||
units_description
|
*Text* | Description Meter unit | ||||||||||
units_code
|
*Text* | Unit code | ||||||||||
trigger_run
|
*Boolean* | True when a task is triggered, false otherwise | ||||||||||
source
|
*Text* | Source for reading: API, WORK_ORDER, MANUAL |
Example:
Request: (GET)https://app.fracttal.com/api/meters_reading_list/?code=EQM027&serial=12345656
{
"success": true,
"message": "200",
"data": [
{
"success": true,
"message": "200",
"data": [
{
"id_meter": 1157,
"date_reading": "2019-08-21T14:07:13+00:00",
"date": "2019-08-21T14:07:13.932837+00:00",
"data": {
"date": "2019-08-21T14:07:13+00:00",
"value": -8.701,
"accumulated_value": -8.701
},
"units_description": "TEMPERATURA",
"units_code": "C",
"trigger_run": false,
"source": "MANUAL"
},
{
"id_meter": 1157,
"date_reading": "2019-08-21T14:06:03+00:00"
"date": "2019-08-21T14:06:03.714035+00:00",
"data": {
"date": "2019-08-21T14:06:03+00:00",
"value": -8.737,
"accumulated_value": -8.737
},
"units_description": "TEMPERATURA",
"units_code": "C",
"trigger_run": false,
"source": "API",
},
{
"id_meter": 1157,
"date_reading": "2019-08-21T14:05:12+00:00"
"date": "2019-08-21T14:05:14.151536+00:00",
"data": {
"date": "2019-08-21T14:05:12+00:00",
"value": -8.769,
"accumulated_value": -8.769
},
"units_description": "TEMPERATURA",
"units_code": "C",
"trigger_run": false,
"source": "WORK_ORDER"
}
],
"total": 3
}
Test It