Rtu
Definition
Rtu Type
- JSON
- Typescript
- Kotlin
rtu.json
{
"id": 0,
"farmID": 0,
"zoneID": 0,
"groupID": 0,
"nodeID": 0,
"typeID": 0,
"rtuName": "",
"serialNumber": "",
"lat": 0,
"lng": 0,
"power": 0,
"rssi": 0,
"clientID": "",
"status": 0,
"createdAt": "",
"updatedAt": "",
}
Get Rtus
- Curl
- Typescript
- Kotlin
curl -X GET "https://${baseUrl}/rtu/?\$filter=&\$orderBy=&\$page=1&\$pageSize=10" \
-H "Authorization: Bearer ${accessToken}" \
-H "Content-Type: application/json" \
-H "Accept: application/json"
Get Rtu
- Curl
- Typescript
- Kotlin
curl -X GET "https://${baseUrl}/rtu/${id}" \
-H "Authorization: Bearer ${accessToken}" \
-H "Content-Type: application/json" \
-H "Accept: application/json"
Apply Rtu.ID
- Curl
- Typescript
- Kotlin
curl -X POST "https://${baseUrl}/apply/rtu/id/" \
-H "Authorization: Bearer ${accessToken}" \
-H "Content-Type: application/json" \
-H "Accept: application/json"
Create Rtu
- Curl
- Typescript
- Kotlin
curl -X POST "https://${baseUrl}/rtu/" \
-H "Authorization: Bearer ${accessToken}" \
-H "Content-Type: application/json" \
-H "Accept: application/json" \
-d @rtu.json
info
rtu.json
{
"farmID": 0,
"zoneID": 0,
"groupID": 0,
"nodeID": 0,
"typeID": 0,
"rtuName": "",
"serialNumber": "",
"lat": 0,
"lng": 0,
"power": 0,
"rssi": 0,
"clientID": "",
"status": 0,
}
tip
success status: 201
Update Rtu
- Curl
- Typescript
- Kotlin
curl -X PUT "https://${baseUrl}/rtu/${id}" \
-H "Authorization: Bearer ${accessToken}" \
-H "Content-Type: application/json" \
-H "Accept: application/json" \
-d @rtu.json
info
rtu.json
{
"farmID": 0,
"zoneID": 0,
"groupID": 0,
"nodeID": 0,
"typeID": 0,
"rtuName": "",
"serialNumber": "",
"lat": 0,
"lng": 0,
"power": 0,
"rssi": 0,
"clientID": "",
"status": 0,
}
Update Rtu Partial
- Curl
- Typescript
- Kotlin
curl -X PATCH "https://${baseUrl}/rtu/${id}" \
-H "Authorization: Bearer ${accessToken}" \
-H "Content-Type: application/json" \
-H "Accept: application/json" \
-H "Attrs: farmID,zoneID,groupID,nodeID,typeID,rtuName,serialNumber,lat,lng,power,rssi,clientID,status" \
-d @rtu.json
info
rtu.json
{
"farmID": 0,
"zoneID": 0,
"groupID": 0,
"nodeID": 0,
"typeID": 0,
"rtuName": "",
"serialNumber": "",
"lat": 0,
"lng": 0,
"power": 0,
"rssi": 0,
"clientID": "",
"status": 0,
}
Update Rtu Status
- Curl
- Typescript
- Kotlin
curl -X PATCH "https://${baseUrl}/rtu/${id}/status/" \
-H "Authorization: Bearer ${accessToken}" \
-H "Content-Type: application/json" \
-H "Accept: application/json" \
-d @rtu.json
info
rtu.json
{
"status": 0
}
Destroy Rtu
- Curl
- Typescript
- Kotlin
curl -X DELETE "https://${baseUrl}/rtu/${id}" \
-H "Authorization: Bearer ${accessToken}" \
-H "Content-Type: application/json" \
-H "Accept: application/json"