Repository is archived
Low commit activity in last 3 years
No release in over a year
OmniAuth strategy for Fishbrain
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
 Dependencies

Runtime

~> 2.0
~> 0.3.0
 Project Readme

OmniAuth Fishbrain

This gem provides two OmniAuth strategies for Fishbrain.

  1. The fishbrain strategy is a standard OmniAuth OAuth2 strategy.
  2. The fishbrain_id strategy is intended for sharing identities between services.

Installation

gem 'omniauth-fishbrain'

Usage

In production environments:

use OmniAuth::Builder do
  provider :fishbrain, ENV['FISHBRAIN_CLIENT_ID'], ENV['FISHBRAIN_CLIENT_SECRET']
  provider :fishbrain_id
end

In development/test/staging environments:

use OmniAuth::Builder do
  provider :fishbrain, ENV['FISHBRAIN_CLIENT_ID'], ENV['FISHBRAIN_CLIENT_SECRET'],
                       user_pool_id: 'eu-west-1_9AdkO5S3c',
                       client_options: {
                         site: 'https://accounts.staging.fishbrain.com',
                       }
  provider :fishbrain_id, user_pool_id: 'eu-west-1_9AdkO5S3c'
end

path_prefix is supported too:

use OmniAuth::Builder do
  ...

  configure { |c| c.path_prefix = '/client/auth' }
end

See /examples for full example using Sinatra.

License

MIT