Class: Fleakr::Api::AuthenticationRequest
- Inherits:
-
Object
- Object
- Fleakr::Api::AuthenticationRequest
- Includes:
- Support::Request
- Defined in:
- lib/fleakr/api/authentication_request.rb
Overview
AuthenticationRequest
Handles authentication requests for the web authentication method. Requires that Fleakr.api_key and Fleakr.shared_secret both be set.
Instance Attribute Summary
Attributes included from Support::Request
Instance Method Summary collapse
-
#authorization_url ⇒ Object
The authorization URL that the user should be redirected to.
-
#endpoint_url ⇒ Object
The endpoint for the authentication request.
-
#response ⇒ Object
:nodoc:.
Methods included from Support::Request
Instance Method Details
#authorization_url ⇒ Object
The authorization URL that the user should be redirected to.
25 26 27 |
# File 'lib/fleakr/api/authentication_request.rb', line 25 def @authorization_url ||= response.header['Location'] end |
#endpoint_url ⇒ Object
The endpoint for the authentication request
15 16 17 |
# File 'lib/fleakr/api/authentication_request.rb', line 15 def endpoint_url 'http://flickr.com/services/auth/' end |
#response ⇒ Object
:nodoc:
19 20 21 |
# File 'lib/fleakr/api/authentication_request.rb', line 19 def response # :nodoc: Net::HTTP.get_response(endpoint_uri) end |