Class: KeycloakOauth::PostAuthorizationCodeService
- Inherits:
-
AuthorizableService
- Object
- AuthorizableService
- KeycloakOauth::PostAuthorizationCodeService
- Defined in:
- app/services/keycloak_oauth/post_authorization_code_service.rb
Constant Summary collapse
- DEFAULT_GRANT_TYPE =
'authorization_code'.freeze
Constants inherited from AuthorizableService
AuthorizableService::AUTHORIZATION_HEADER, AuthorizableService::CONTENT_TYPE_JSON, AuthorizableService::CONTENT_TYPE_X_WWW_FORM_URLENCODED, AuthorizableService::HTTP_SUCCESS_CODES
Instance Attribute Summary collapse
-
#connection ⇒ Object
readonly
Returns the value of attribute connection.
-
#request_params ⇒ Object
readonly
Returns the value of attribute request_params.
Attributes inherited from AuthorizableService
#http_response, #parsed_response_body
Instance Method Summary collapse
-
#initialize(connection:, access_token: nil, refresh_token: nil, request_params:) ⇒ PostAuthorizationCodeService
constructor
A new instance of PostAuthorizationCodeService.
- #send_request ⇒ Object
Methods inherited from AuthorizableService
#perform, uri_with_supported_query_params
Constructor Details
#initialize(connection:, access_token: nil, refresh_token: nil, request_params:) ⇒ PostAuthorizationCodeService
Returns a new instance of PostAuthorizationCodeService.
9 10 11 12 13 14 |
# File 'app/services/keycloak_oauth/post_authorization_code_service.rb', line 9 def initialize(connection:, access_token: nil, refresh_token: nil, request_params:) @connection = connection @access_token = access_token @refresh_token = refresh_token @request_params = request_params end |
Instance Attribute Details
#connection ⇒ Object (readonly)
Returns the value of attribute connection.
7 8 9 |
# File 'app/services/keycloak_oauth/post_authorization_code_service.rb', line 7 def connection @connection end |
#request_params ⇒ Object (readonly)
Returns the value of attribute request_params.
7 8 9 |
# File 'app/services/keycloak_oauth/post_authorization_code_service.rb', line 7 def request_params @request_params end |
Instance Method Details
#send_request ⇒ Object
16 17 18 |
# File 'app/services/keycloak_oauth/post_authorization_code_service.rb', line 16 def send_request post_token end |