No commit activity in last 3 years
No release in over 3 years
OmniAuth strategy for squidd.io
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
 Dependencies

Runtime

 Project Readme

OmniAuth sQuiddio

Work in Progress

This gem is an OmniAuth Strategy for the Squiddio API which uses OAuth 2.0

Usage

Obtain app key and secret (SQUIDDIO_KEY, SQUIDDIO_SECRET):

  • Create a sQuidd.io account at http://squidd.io/signup if you don't already have one.
  • Create a Boat (app credentials are associated to a user's vessel, not the user, in case you own/manage multiple vessels).
  • Update your boat's current position (some of the sample API requests require a known vessel position).
  • Finally, go to your boat's page and click "Edit Boat Profile". You can find the ID and Secret in the APIs Tab. More info in the Getting Started Guide and FAQ

Add the strategy to your Gemfile alongside OmniAuth:

gem 'omniauth'
gem 'omniauth-squiddio'

Then, to integrate the strategy into your middleware, add this to your omniauth.rb settings file:

use OmniAuth::Builder do
  provider :squiddio, ENV['SQUIDDIO_KEY'], ENV['SQUIDDIO_SECRET']
end

In Rails, you'll want to add to the middleware stack:

Rails.application.config.middleware.use OmniAuth::Builder do
  provider :squiddio, ENV['SQUIDDIO_KEY'], ENV['SQUIDDIO_SECRET']
end

If you use Devise:

Devise.setup do |config|
  config.omniauth :squiddio, ENV['SQUIDDIO_KEY'], ENV['SQUIDDIO__SECRET']
end

For additional information, refer to the OmniAuth wiki.