Turning Grafana into a health tracking app
from rcmd@lemmy.world to selfhosted@lemmy.world on 24 Oct 11:19
https://lemmy.world/post/37808390

Hello, lemmy.world! First time posting here, hope you’ll find it somewhat useful.

In an attempt to protect my personal info from data-hungry cloud-infested madness that comes from app stores of various kinds, I decided to establish a routine of scraping health metrics from… myself. This particular example requires manual input, however it proved to be working reliably and much more precise than any other mood journaling app.

More details you may find here, in my personal blog.

Feel free to ask other details, I can share my termux scripts, Tasker workflows, Grafana dashboard JSONs, and other infrastructure around it.

#selfhosted

threaded - newest

rcmd@lemmy.world on 24 Oct 11:21 next collapse

FTR: currently experimenting with scraping Gadgetbridge data into Grafana.

Impromptu2599@lemmy.world on 24 Oct 12:12 collapse

I would be curious how you are doing on scraping the gadgetbridge data. I have been thinking about doing this and feeding it into Zabbix.

rcmd@lemmy.world on 24 Oct 12:19 collapse

Gadgetbridge allows automatic SQLite database export to the location you specify.

Navigate to Settings -> Automations -> Auto export database, and from there you can configure the details.

You can put it into a shared Syncthing folder, or something alike, or process it with Termux + Tasker. Personally, I hesitate to send megabytes of data over the wire every couple of minutes, so I rigged up a script that extracts the required metrics (for now its my steps only, the rest does not seem to be accurate) and sends a payload to my queue, where a consumer script later adds it to the DB.

Tangent5280@lemmy.world on 24 Oct 13:13 collapse

Does gadgetbridge have something like an API? It seems like it should already have something along these lines, since health wearables not having one is what gave birth to gadgetbridge in the first place…

rcmd@lemmy.world on 25 Oct 07:54 collapse

To my knowledge not really much is available. You may use an intent to trigger database export and then use SQLite to scrape data.

Also keep in mind that data is kept in device specific tables.

codeberg.org/Freeyourgadget/…/Intent-API

handsoffmydata@lemmy.zip on 24 Oct 11:42 next collapse

I’ve been experimenting with something similar the last two months. My workflow involves self reported health data via NextCloud forms. The api feeds a sql db that’s modeled using grafana. I also have a python tool in open webui to chat over the data with gpt-oss:20b. Fun project. Happy to hear others are tinkering too.

ryokimball@infosec.pub on 24 Oct 11:48 collapse

Love this. Thanks for sharing.