Gem to use the API to track and embed metrics
Latest commit 2cd7148 Jan 8, 2013 @bittersweet Release version 0.1.2


Metric Build Status

Track simple metrics via


Add the following anywhere in your Gemfile and run bundle install.

gem 'metric'

And create the following initializer:

Metric.configure do |config|
  config.api_key = "YOUR_API_KEY"
  config.secret_key = "YOUR_SECRET_KEY"

Now you are all set to start tracking some metrics!

Note: If you are using Rails it will only track events in Production mode.


You can track whatever metric you want, it will automatically show up in your dashboard.


You can also add a custom amount to log multiple metrics in one go:

Metric.track("email_notifications", {:amount => 301})

If you want to push old statistics into you can use the date parameter:

Metric.track("signup", {:date => "20120101"})

To give the live event view in your dashboard some more context you can pass in meta information:

Metric.track("email", {:meta => "user 1021"})


Although the code is pretty lightweight and self-explanatory, documentation is available via


jeffkreeftmeijer for providing me with the awesome domainname!