List communication sessions
GET
/api/v1/seances Returns a paged list of telemetry communication sessions, optionally filtered by telemetry unit and time interval.
Query parameters
telemetry_id integer Telemetry unit identifier. Optional — narrows the selection.
fp_start string Time interval (segment start) in yyyy-mm-dd format. Optional.
fp_end string Time interval (segment end) in yyyy-mm-dd format. Optional.
page integer Page number.
Response fields
| Attribute | Description |
|---|---|
id | Identifier (unique key) of the communication session in the system |
telemetry_id | Identifier (unique key) of the telemetry unit in the system |
event_time | Date and time of the communication session in UTC format |
Evtid | Communication session reason code |
Trycnt | Number of retries |
Tryfl | Retry code |
state | Communication session status |
Btm | Telemetry battery charge |
Rssi | Signal level (RSSI) |
Bsg | Metrological battery charge |
gettime | Server current-time request |
next_session_time | Scheduled time of the next communication session |
referenceparameter_seance_status_id | Identifier of the communication session status in the system |
duration_session | Communication session duration |
session_traffic | Traffic volume |
millisecond | Milliseconds |
data | Array of returned data |
total_pages | Total number of pages in the returned set |
current_page | Current page |
next_page | Next page available for downloading, null if the current page is the last one |
Request
bash
curl -i \
--header "access-token: *********************" \
--header "token-type: Bearer" \
--header "client: **********************" \
--header "uid: user@local.net" \
--header "Content-Type: application/json" \
--request GET \
"https://uztgs.uz/api/v1/seances?telemetry_id=1111&fp_start=2021-11-02&fp_end=2021-11-30&page=2"js
const res = await fetch(
'https://uztgs.uz/api/v1/seances?telemetry_id=1111&fp_start=2021-11-02&fp_end=2021-11-30&page=2',
{
headers: {
'access-token': '*********************',
'token-type': 'Bearer',
client: '**********************',
uid: 'user@local.net',
'Content-Type': 'application/json',
},
},
);
const data = await res.json();python
import requests
res = requests.get(
"https://uztgs.uz/api/v1/seances",
params={
"telemetry_id": 1111,
"fp_start": "2021-11-02",
"fp_end": "2021-11-30",
"page": 2,
},
headers={
"access-token": "*********************",
"token-type": "Bearer",
"client": "**********************",
"uid": "user@local.net",
"Content-Type": "application/json",
},
)
data = res.json()go
req, _ := http.NewRequest("GET", "https://uztgs.uz/api/v1/seances?telemetry_id=1111&fp_start=2021-11-02&fp_end=2021-11-30&page=2", nil)
req.Header.Set("access-token", "*********************")
req.Header.Set("token-type", "Bearer")
req.Header.Set("client", "**********************")
req.Header.Set("uid", "user@local.net")
req.Header.Set("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)php
$ch = curl_init("https://uztgs.uz/api/v1/seances?telemetry_id=1111&fp_start=2021-11-02&fp_end=2021-11-30&page=2");
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_HTTPHEADER, [
"access-token: *********************",
"token-type: Bearer",
"client: **********************",
"uid: user@local.net",
"Content-Type: application/json",
]);
$data = json_decode(curl_exec($ch), true);Response
json
{
"data": [
{
"id": 303481,
"telemetry_id": 1111,
"event_time": 1636202160,
"Evtid": null,
"Trycnt": null,
"Tryfl": null,
"state": 0,
"Btm": 3900,
"Rssi": 23,
"Bsg": null,
"gettime": true,
"next_session_time": 1636204200,
"referenceparameter_seance_status_id": 99,
"duration_session": null,
"session_traffic": null,
"millisecond": null
}
],
"total_pages": 2,
"current_page": 1,
"next_page": 2
} Last updated on
Was this page helpful?
Thanks for your feedback!
Communication sessions
Previous
Directories
Next