| Module | OmniAuth::Strategy |
| In: |
lib/omniauth/strategy.rb
|
| CURRENT_PATH_REGEX | = | %r{/$} |
| EMPTY_STRING | = | ''.freeze |
| app | [R] | |
| env | [R] | |
| options | [R] | |
| response | [R] |
Initializes the strategy by passing in the Rack endpoint, the unique URL segment name for this strategy, and any additional arguments. An `options` hash is automatically created from the last argument if it is a hash.
@param app [Rack application] The application on which this middleware is applied.
@overload new(app, options = {})
If nothing but a hash is supplied, initialized with the supplied options overriding the strategy's default options via a deep merge.
@overload new(app, *args, options = {})
If the strategy has supplied custom arguments that it accepts, they may will be passed through and set to the appropriate values.
@yield [Options] Yields options to block for further configuration.
@abstract This method is called when the user is on the request path. You should perform any information gathering you need to be able to authenticate the user in this phase.
Determines whether or not user info should be retrieved. This allows some strategies to save a call to an external API service for existing users. You can use it either by setting the `:skip_info` to true or by setting `:skip_info` to a Proc that takes a uid and evaluates to true when you would like to skip info.
@example
use MyStrategy, :skip_info => lambda{|uid| User.find_by_uid(uid)}