module OmniAuth module Strategies class Norseal < OmniAuth::Strategies::OAuth2 option :name, :norseal option :client_options, { site: "http://identity.norseal.co.uk", authorize_url: "/oauth/authorize" } uid do raw_info['id'] end info do {uid: raw_info['id'], email: raw_info['email'], name: raw_info['name']} end def raw_info @raw_info ||= access_token.get('/me.json').parsed || {} end end end end