Posted on December 13, 2008 at 2:29am EST. More.

A FatWatch API?

So, instead of doing the work I should be doing, I’ve been seeking out Hacker’s Diet aficionados on Twitter, and found my way to a Hacker’s Diet plug-in for WordPress. Then it occurred to me, it would be possible to write a web app that could pull data from FatWatch right now, without any updates to the app.

For example, a hypothetical “FatWatch plug-in for WordPress” could work like this:

  1. You enable Wi-Fi Import/Export on your iPhone.
  2. You enter the iPhone’s URL into the plug-in and press its “update” button.
  3. The plug-in’s JavaScript loads and parses your weight history from the base URL and the path “/export/weight.csv”.
  4. The plug-in saves the numbers to a database and displays a pretty chart on your blog.
It wouldn’t be terribly efficient — it would be downloading your entire weight history each time — but it’s cool to think that somebody could develop such a thing today, without waiting for an app update.

And, it wouldn’t be too hard to enhance FatWatch to limit export by time range or support additional formats like JSON or XML. Guess what’s going on my to-do list?