Help yourself to some API files

Here are some API files that use the PHP library.

[ EDIT: The link above doesn’t work anymore. Use this one instead: ]

dashboard.php is a visual dashboard for all of your goals.
It allows you to specify different groups for different goals, and allows you to enter more than one goal at a time by specifying “umbrella” goals and the goals that fall under that umbrella.

autodial.php dials your goal rates (of the goals you list) to the average for the last 4 weeks.
Note that it currently only works properly for cumulative goals, but other types are coming soon.

successes.php shows you what you’ve done in the last 4 weeks.
It, too, is a work in progress and is, at the moment, very, very basic. On the plus side, it can behave differently for time goals and other goals (a feature that will be used to improve the other files soon). It can also tell the difference between cumulative goals (like “number of x done”) and non-cumulative goals (like “size of email inbox”)

PLEASE let me know if you have any trouble with any of them or find them confusing so that I can improve them. They are still in very early development, so the paint is still fresh.

Let me know, also, if you have any ideas, as these are all works in progress (as are a few others that aren’t yet ready for public consumption).


I would really like to use your autodial tool. I may be beyond help but here’s where I got to.

I have downloaded the .php file and can add my username and key.

Beyond that point it is mostly incomprehensible.

// Include the autoloader
require_once 'lib/Beeminder/Autoloader.php'; // This assumes the library is in
// require_once '/path/to/lib/Beeminder/Autoloader.php';  // replace "/path/to/" with the actual path the API is stored in.

I’m not sure what a server is. Pretty certain I don’t have one but can I change that? Would this WampServer program help? It includes Apache, MySQL and PHP. Does the server have to be hosted online? Could I use dropbox?

Is the library additional things that need obtaining? If so, how do I get them?

This API that is stored somewhere, is that the Beeminder API or something else? I’m unsure how to set up this stored API.

I’m a Windows Vista user for what it’s worth. I also have an Ubuntu based virtual machine. I’m trying to learn about APIs (so I can do cool things with Beeminder!) but haven’t found much practical information. I have managed to get the API to spit out some information and I’ve been able to pick up the JSON values into a Google Spreadsheet but that is the extent of my experience.

I’m not scared to dabble out of my depth but I need some direction. Good luck to anyone who thinks they can help me!


Yes. The PHP API is here:
You will want to download and extract the zip file. Direct download

Unzip it in the same directory as the dashboard.php file and your require once line becomes:

require_once 'beeminder-php-api/lib/Beeminder/Autoloader.php';

It doesn’t have to be hosted online, it should work from your computer.

Wampserver would help in your case, I suggest you download and install that and get a ‘hello world’ program running before trying more complicated api tasks.


Thanks, Insti! I’ve got it working :smile:


I’ve added and changed a number of the files from my original dashboard (etc.) scripts, and you can now find them at:

Note that they all require the PHP API library.

(I’ll say more about them elsewhere in the not-too-distant future)


Here’s an example of the dashboard’s look & feel:
Beeminder Dashboard


I’m so excited about this! Huge thanks to @chipmanaged for being a pioneer for new interfaces to Beeminder and new tools for better control over the yellow brick road.

Btw, I can vouch for functionality of Mary’s code here.

I was setting this up again last night and ran it successfully twice before hitting the error below. I get the error every time now. :frowning:

    Fatal error: Uncaught exception 'Exception' with message '{"errors":{"road_dial":"Must specify exactly two parameters"}}' in /storage/sdcard0/pws/www/beeminder/lib/Beeminder/HttpDriver/Curl.php:145 Stack trace: #0 /storage/sdcard0/pws/www/beeminder/lib/Beeminder/HttpDriver/Curl.php(138): Beeminder_HttpDriver_Curl->_checkForErrorsFromRequest(Array) #1 /storage/sdcard0/pws/www/beeminder/lib/Beeminder/HttpDriver/Curl.php(47): Beeminder_HttpDriver_Curl->_checkForErrors(Array) #2 /storage/sdcard0/pws/www/beeminder/lib/Beeminder/HttpDriver.php(158): Beeminder_HttpDriver_Curl->execute('https://www.bee...', Array, 'POST', Array) #3 /storage/sdcard0/pws/www/beeminder/lib/Beeminder/HttpDriver.php(103): Beeminder_HttpDriver->request('users/:username...', Array, 'POST', Array) #4 /storage/sdcard0/pws/www/beeminder/lib/Beeminder/Api.php(62): Beeminder_HttpDriver->post('users/:username...', Array, Array) #5 /storage/sdcard0/pws/www/beeminder/lib/Beeminder/Api/Goal.php(163): Beeminder_Api->post('users/:username...', Array) #6 /storage/s in /storage/sdcard0/pws/www/beeminder/lib/Beeminder/HttpDriver/Curl.php on line 145

EDIT: I've set it up again from scratch and I'm hitting the error right from the start now. @mary is it still working for you?

It’s still working for me. Maybe we could set up a time to gChat and we
could try to figure it out?

1 Like

As a non-techie this discussion is over my head but this snapshot look & feel example is exactly what my non-techie brain can handle and it’s very helpful in many ways so thank you very much.

1 Like

I’d love to be looped in on this. Very much in our interest to help people debug issues with the Beeminder API, whether or not it’s strictly our fault.

1 Like

@peppertoni Did you get it working for you, in the end?

1 Like

I would really love it if the autodialer could become a built-in beeminder feature. I could definitely figure out the code if I put some real time into it, but at the moment that’s something I don’t have to spare. I wouldn’t use it on every goal, as I do check in with most goal rates weekly or monthly anyways, but there are some goals that I’ve had going for awhile that I’d like to just not obsess over the right rate, and instead require myself to either stay at the same rate or improve, and then MAINTAIN IMPROVEMENTS.

Right now I have this problem of wanting to up the rate as soon as I see even a little improvement, and then I fail (or get close) and bump it back down, and I end up spending weeks going back and forth before I find a new rate that’s actually sustainable. I’d still have to be thoughtful about which goals to turn on autodialing for, but I feel like this would be really useful overall.


Most humans are bad at adjusting processes with variation in them. While there are a variety of ways to get better at it, (see Control Charts), I have found that limiting myself to making goals more difficult to once a week has kept things sane for me for the last six months or so. You may find it simpler than this autodialer approach.


Nope, never got it working :(. Would love to nut it out with you.

I’m trying to run it off my android, so I’m using a free server app called palapa web server ( ). All I’ve done is set up and put the settings files and beeminder api library into the www folder as per insti’s instructions. I haven’t tinkered with anything aside from putting in my beeminder and goal settings so it should be pretty easy to reproduce with an android device. I’m running 5.0.2.

The strangest thing is that it worked initially and then died and has remained dead since. The version I had working on my PC still works to update the goal rates but is followed by an error message about it needing two parameters. The android version just gives me the fatal error.

My PC is a rather sad machine these days, hence the desire to run this on an android instead.

1 Like

I’d be happy to give you a hand at trying to set it up again (as much as I’m capable, anyway). When are you able to chat on something like gChat? I’m usually not available until after sometime between 6 and 7 (EST) Sun to Fri, and pretty much any time on Saturdays.


I’ve direct messaged you through the forum. Did you get it?

:anguished: And now the final straw…

The computer that this was working on (despite spitting errors it was still able to modify the graphs) has now given up as well. I have changed nothing.

1 Like

The last several weeks have been really busy, but I’m free today through Sunday to discuss via Hangouts or Skype if you’d like. (I’ll PM you my email address, since I never see PMs or posts in time to actually make it happen.)

1 Like

@mary Looks like it’s a PHP webpage? Does it require regular visits to update the goal rates with auto-dialer then?

Wow, this still works and it looks huge and impressive and awesome!! :heart: