Low commit activity in last 3 years
A long-lived project that still receives updates
Integrate with Greenhouse with OmniAuth
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
2025
2026
 Dependencies

Development

>= 0

Runtime

>= 1.3.1, < 2
 Project Readme

Important Note

This will be Greenhouse's last supported version of this gem. Any updates moving forward should be forked and maintained by the users.

Greenhouse

Integrate with Greenhouse via OAuth 2.0

Installation

Add this line to your application's Gemfile:

gem 'omniauth-greenhouse'

And then execute:

$ bundle

Or install it yourself as:

$ gem install omniauth-greenhouse

Usage

It's easy to integrate with Greenhouse using the OmniAuth gem.

If you aren't currently a Greenhouse customer, the first step is to reach out to our Partnerships team at partners@greenhouse.io to request a CLIENT_KEY and CLIENT_SECRET.

Unfortunately, there is no self-service mechanism to register your application. When you send a request to register your application, you will need to provide:

Once you receive your CLIENT_KEY and CLIENT_SECRET, add this to your config/initializers/omniauth.rb file:

Rails.application.config.middleware.use OmniAuth::Builder do
  provider :greenhouse, '<CLIENT_KEY>', '<CLIENT_SECRET>',
           :scope => 'candidates.create candidates.view'
end

After this is configured, your users will be able to authorize your application to use their Greenhouse account via:

http://myapp.example.com/auth/greenhouse

The user will be presented with an authorization screen. When the user clicks on the 'Authorize' button, they will be redirected back to your site to the 'Callback URL' you provided during the application registration process. This callback URL will look something like:

http://myapp.example.com/auth/greenhouse/callback

If the user clicked on the 'Authorize' button, you can retrieve the OAuth 2.0 token via:

request.env['omniauth.auth']['credentials']['token']

If the user clicked on the 'Deny' button, a 'oauth_problem' query parameter will be set with a value of 'user_refused'.