Firstly, congrats on the device stats card. Looks like the beginning of something very useful for the cloud interface.
However, one thing that I find myself constantly wishing Balena offered is an uptime statistic as an extension of the Last Seen (VPN) data.
It seems like balena cloud is already gathering all the necessary data to calculate long term uptime (ie. 98.55% over a certain period) via the VPN data, maybe even with a mini chart showing red bars in downtime.
I think it would be useful enough to include in the paid version of Balena, especially if the uptime over a selectable time range is included.
In the meantime, is there a way to pipe the last seen and device statsu (online/offline) data to a third party like Datadog?
I know this information on the radar of the product team already, so I’ll tack on that another user is asking about it. Thank you for your feedback
If you wanted to create an agent to pull the info from the device model on our API then you could do that. Obviously you can only see the current state, so the granularity would be only as fine as the period you chose to run the query. Our API docs can be found here for reference: https://www.balena.io/docs/reference/api/overview/
I know this was discussed before but a outbound web hook from Balena would be very useful in this scenario rather than doing constant polling against the is_online endpoint for example. Are there usage limits on the APIs? I’m imagining I’d do something like a 15-30 second recurring call and then just chart that over time.
There are rate limits, yes, but I am not sure what they are exactly. My suggestion would be to make a single call to pull back the info for all your devices, in one shot, and to do that every 60 secs at the most.
You can construct a call to $select these fields for every device in your application, using a $filter to specify the app ID etc. If you get stuck then we can help out with that query
Hi Juan, that does work (kind of). No formatting error, but it doesn’t actually perform the filter. It just gives me a list of every device I’ve got. Strange behavior.
Hi there, it shows you all the devices across all applications, or all devices inside one application that are both online and offline. The behavior I am seeing is the second one
Ha, I appreciate you trying to help. Here’s my query, that still seems to be returning every device. Send back about 730 lines at 15kb - which is about 10 devices across just as many apps.
Interesting… this whole time I’ve been testing with Insomia app (https://insomnia.rest) and it kept failing the filter portion of the query. However, I just tested in Postman and it works like a charm.
Sorry for the hassle! Guess I’ll be sticking with postman.