FreshBooks WordPress Widget

As avid users of Freshbooks web-based accounting software, we are always looking for ways to integrate our project tracking and accounting in fun and useful ways. This plugin creates a simple sidebar widget that outputs the total hours billed for a FreshBooks account. Our website reflects the real-time productivity of our contractors and staffers. This is just one more way to offer transparency to our clients. Read more about the plug-in and download it below.

Note: You will need the API URL and API token for your FreshBooks account, see http://developers.freshbooks.com/

Your FreshBooks API URL has a single point of entry, derived from your account URL:

https://sample.freshbooks.com/api/2.1/xml-in

After enabling API access for your account, you’ll be given a unique authentication token. The admin user, and each staff member, has an API token. The admin user’s authentication token can be found on the “enable FreshBooks API” page. The staff token can be found on each staff member’s Profile page, or on the Edit Staff page (for admin only). At this time, staff members have limited access to the API (see the individual method pages for details).

Please note your authentication token is based on your account password. If your password changes, so will your authentication token.

To use this widget, install the plugin and then in the widgets setup admin area drag the “Freshbooks Widget” to a sidebar. Input your Title, API URL, and API token. Note, using the Freshbooks Admin API token will return the number hours billed by the Admin user and all the Staff accounts associated with the Admin account (the entire team), whereas inputing a Staff token will output the hours billed by that staff user only.

Screenshots



Note: PHP will produce a warning if it is operating in “safe_mode” which will look something like this:

 

Warning: curl_setopt() [function.curl-setopt]: CURLOPT_FOLLOWLOCATION cannot be activated when in safe_mode or an open_basedir is set in /home/public_html/wp-content/plugins/freshbooks-widget/library/FreshBooks/HttpClient.php on line 79

Check with your host provider to turn-off “safe_mode” if this warning appears.

Thanks to developer: Milan Rukavina for providing a PHP5 library for the FreshBooks API. Saves the time of dealing with XML calls directly. Available at: http://code.google.com/p/freshbooks-php-library/

WordPress 2.8 and up.


LICENSE:

 

This program is free software; you can redistribute it and/or modify it.

THE SOFTWARE IS PROVIDED “AS IS”, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

Tags: ,

Categories : Labs

About the author

Richard is a Software Developer and Star Trek Enthusiast. He is well trained in ECE, Physics, and Math. He really enjoys soccer, college football, and cheap Chinese Buffet food. Projects>>

One Response to “FreshBooks WordPress Widget”

  1. Trent Nov-25, 2010

    Reply

    Thanks for developing this plugin. Just what I was looking for !

Leave a Reply