Class: KeycloakOauth::GetUsersService

Inherits:
AuthorizableService show all
Defined in:
app/services/keycloak_oauth/get_users_service.rb

Constant Summary collapse

SUPPORTED_QUERY_PARAMS =
%i(briefRepresentation email first firstName lastName max search username)

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

Attributes inherited from AuthorizableService

#http_response, #parsed_response_body

Instance Method Summary collapse

Methods inherited from AuthorizableService

#perform, uri_with_supported_query_params

Constructor Details

#initialize(connection:, access_token:, refresh_token:, options: {}) ⇒ GetUsersService

Returns a new instance of GetUsersService.



9
10
11
12
13
14
# File 'app/services/keycloak_oauth/get_users_service.rb', line 9

def initialize(connection:, access_token:, refresh_token:, options: {})
  @connection = connection
  @access_token = access_token
  @refresh_token = refresh_token
  @options = options
end

Instance Attribute Details

#connectionObject (readonly)

Returns the value of attribute connection.



7
8
9
# File 'app/services/keycloak_oauth/get_users_service.rb', line 7

def connection
  @connection
end

#optionsObject (readonly)

Returns the value of attribute options.



7
8
9
# File 'app/services/keycloak_oauth/get_users_service.rb', line 7

def options
  @options
end

Instance Method Details

#send_requestObject



16
17
18
# File 'app/services/keycloak_oauth/get_users_service.rb', line 16

def send_request
  get_users
end