Get all connected devices states while not looking at the Web UI #536
-
Greetings, I am looking for a way to get stuff like "battery charge", "temperature" and "voltage" from all devices known to a device farm. While we do have the "grand list", that one can access from the device farms web ui, I wonder if there is a way to get this kind of information as json, or csv, or whatever data structure seems fit. Like a HTTP GET or something like this. I had a look in the Groups Document, where all the API calls for managing devices and groups are listed, but it seems no entry there does cover any of the device-information I am after. Currently I do crotchet a python script that does docker-compose adb calls and regexes the parts I am after out of that output. But somehow this feels like doing work already done. EDiT: About the "why": we do have devices of a greater age in use, ans sometimes their battery decides to go... well... bloom. Yes, bLoom, not boom. In that case we would like to exchange that device's battery. Now, finding these is task of the administrator user, which has to watch the charge voltage, the state and other parameters manually using the Web UI, which is... not efficient. |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments
-
okay, found it.... I looked at the wrong document, as it seems. In the stf/api.md there is a call that .... provides way to much information, but at least its a pretty json which can be reused more easily. |
Beta Was this translation helpful? Give feedback.
-
@ConfusedMerlin, see the |
Beta Was this translation helpful? Give feedback.
okay, found it.... I looked at the wrong document, as it seems. In the stf/api.md there is a call that .... provides way to much information, but at least its a pretty json which can be reused more easily.
Found it here: https://github.com/DeviceFarmer/stf/blob/master/doc/API.md#get-devices