Class: Doorkeeper::OAuth::AssertionAccessTokenRequest
- Inherits:
-
Object
- Object
- Doorkeeper::OAuth::AssertionAccessTokenRequest
- Includes:
- OAuth::Helpers, OAuth::RequestConcern, Validations
- Defined in:
- lib/doorkeeper/oauth/assertion_access_token_request.rb
Instance Attribute Summary collapse
-
#access_token ⇒ Object
readonly
Returns the value of attribute access_token.
-
#client ⇒ Object
readonly
Returns the value of attribute client.
-
#configuration ⇒ Object
readonly
Returns the value of attribute configuration.
-
#error_description ⇒ Object
readonly
Returns the value of attribute error_description.
-
#original_scopes ⇒ Object
Returns the value of attribute original_scopes.
-
#resource_owner ⇒ Object
readonly
Returns the value of attribute resource_owner.
-
#response ⇒ Object
readonly
Returns the value of attribute response.
-
#server ⇒ Object
Returns the value of attribute server.
Instance Method Summary collapse
- #authorize ⇒ Object
-
#initialize(server, configuration) ⇒ AssertionAccessTokenRequest
constructor
A new instance of AssertionAccessTokenRequest.
Constructor Details
#initialize(server, configuration) ⇒ AssertionAccessTokenRequest
Returns a new instance of AssertionAccessTokenRequest.
22 23 24 25 26 27 |
# File 'lib/doorkeeper/oauth/assertion_access_token_request.rb', line 22 def initialize(server, configuration) @server = server @configuration = configuration @response = nil @original_scopes = server.parameters[:scope] end |
Instance Attribute Details
#access_token ⇒ Object (readonly)
Returns the value of attribute access_token.
11 12 13 |
# File 'lib/doorkeeper/oauth/assertion_access_token_request.rb', line 11 def access_token @access_token end |
#client ⇒ Object (readonly)
Returns the value of attribute client.
11 12 13 |
# File 'lib/doorkeeper/oauth/assertion_access_token_request.rb', line 11 def client @client end |
#configuration ⇒ Object (readonly)
Returns the value of attribute configuration.
11 12 13 |
# File 'lib/doorkeeper/oauth/assertion_access_token_request.rb', line 11 def configuration @configuration end |
#error_description ⇒ Object (readonly)
Returns the value of attribute error_description.
11 12 13 |
# File 'lib/doorkeeper/oauth/assertion_access_token_request.rb', line 11 def error_description @error_description end |
#original_scopes ⇒ Object
Returns the value of attribute original_scopes.
10 11 12 |
# File 'lib/doorkeeper/oauth/assertion_access_token_request.rb', line 10 def original_scopes @original_scopes end |
#resource_owner ⇒ Object (readonly)
Returns the value of attribute resource_owner.
11 12 13 |
# File 'lib/doorkeeper/oauth/assertion_access_token_request.rb', line 11 def resource_owner @resource_owner end |
#response ⇒ Object (readonly)
Returns the value of attribute response.
11 12 13 |
# File 'lib/doorkeeper/oauth/assertion_access_token_request.rb', line 11 def response @response end |
#server ⇒ Object
Returns the value of attribute server.
10 11 12 |
# File 'lib/doorkeeper/oauth/assertion_access_token_request.rb', line 10 def server @server end |
Instance Method Details
#authorize ⇒ Object
29 30 31 32 33 34 35 36 37 38 |
# File 'lib/doorkeeper/oauth/assertion_access_token_request.rb', line 29 def validate if valid? @response = TokenResponse.new(access_token) else @response = DescribableErrorResponse.from_request(self) @response.description = error_description @response end end |