Skip to content


Subversion checkout URL

You can clone with
Download ZIP
A base library for Hoptoad error reporting
Pull request Compare This branch is 24 commits behind toolmantim:master.

Fetching latest commit…

Cannot retrieve the latest commit at this time

Failed to load latest commit information.

Build Status

A base library for Airbrake error reporting.

Toadhopper can be used to report plain old Ruby exceptions, or to build a framework-specific gem such as toadhopper-sinatra.

  raise "Kaboom!"
rescue  => e
  require 'toadhopper'

You can install it via rubygems:

gem install toadhopper

Posting Notices Over SSL

Toadhopper can transport your messages over SSL.

In order to enable SSL, just add the :secure option."YOURAPIKEY", :secure => true).post!(e)

Alternatively, you can specify a :notify_host with a https:// protocol."YOURAPIKEY", :notify_host => '').post!(e)

Note: You must have a paid plan for Airbrake to accept your messages over SSL.

Deploy tracking

You can use Toadhopper to notify Airbrake of deployments:


The method accepts options to set the environment, SCM revision, etc.

There is Capistrano support for deploy tracking. Simply require toadhopper/capistrano in your deploy config and set the variable airbrake_api_key:

require 'toadhopper/capistrano'

set :airbrake_api_key, 'YOURAPIKEY'

Set the variable airbrake_secure as well if you want deploy tracking over ssl:

set :airbrake_secure, true


Toadhopper is tested against and compatible with the following ruby platforms:

  • 1.8.7
  • 1.9.2
  • 1.9.3
  • ree 1.8.7-2011.03
  • jruby 1.6.3

    For jruby support, you need to gem install jruby-openssl if you do not already have that gem. More info on why this is.

  • rubinius 2.0.testing branch in ruby 1.8 mode (1.9 mode is not supported)


Install Bundler 0.9.x, then:

% git clone git://
% cd toadhopper
% bundle install
% bundle exec rake test

If you set a AIRBRAKE_API_KEY environment variable it'll test actually posting to the Airbrake API. For example:

% bundle exec rake test AIRBRAKE_API_KEY=abc123

Set AIRBRAKE_FULL_TEST to test integration operations that require a paid Airbrake plan such as posting over SSL, deploy tracking, and github integration. For example:

% bundle exec rake test AIRBRAKE_API_KEY=abc123 AIRBRAKE_FULL_TEST=1

Beware: Setting AIRBRAKE_FULL_TEST will record a bogus deployment in your Airbrake project and auto-resolve any pre-existing development errors.

To generate the docs:

% bundle exec yardoc

To build the gem:

% bundle exec rake build


Something went wrong with that request. Please try again.