clients/hydra/ruby/lib/ory-hydra-client/api/admin_api.rb
# Revokes Consent Sessions of a Subject for a Specific OAuth 2.0 Client
# This endpoint revokes a subject&#39;s granted consent sessions for a specific OAuth 2.0 Client and invalidates all associated OAuth 2.0 Access Tokens.
# @param subject [String] The subject (Subject) who&#39;s consent sessions should be deleted.
# @param [Hash] opts the optional parameters
# @option opts [String] :client If set, deletes only those consent sessions by the Subject that have been granted to the specified OAuth 2.0 Client ID
# @option opts [Boolean] :all If set to &#x60;?all&#x3D;true&#x60;, deletes all consent sessions by the Subject that have been granted.
# @return [Array<(nil, Integer, Hash)>] nil, response status code and response headers
Revokes Consent Sessions of a Subject for a Specific OAuth 2.0 Client
This endpoint revokes a subject's granted consent sessions for a specific OAuth 2.0 Client and invalidates all associated OAuth 2.0 Access Tokens.
Revokes Consent Sessions of a Subject for a Specific OAuth 2 . 0 Client This endpoint revokes a subject ' s granted consent sessions for a specific OAuth 2 . 0 Client and invalidates all associated OAuth 2 . 0 Access Tokens .
def revoke_consent_sessions_with_http_info(subject, opts = {})
      if @api_client.config.debugging
        @api_client.config.logger.debug 'Calling API: AdminApi.revoke_consent_sessions ...'
      end
      if @api_client.config.client_side_validation && subject.nil?
        fail ArgumentError, "Missing the required parameter 'subject' when calling AdminApi.revoke_consent_sessions"
      end
      local_var_path = '/oauth2/auth/sessions/consent'
      query_params = opts[:query_params] || {}
      query_params[:'subject'] = subject
      query_params[:'client'] = opts[:'client'] if !opts[:'client'].nil?
      query_params[:'all'] = opts[:'all'] if !opts[:'all'].nil?
      header_params = opts[:header_params] || {}
      header_params['Accept'] = @api_client.select_header_accept(['application/json'])
      form_params = opts[:form_params] || {}
      post_body = opts[:debug_body]
      return_type = opts[:debug_return_type]
      auth_names = opts[:debug_auth_names] || []
      new_options = opts.merge(
        :operation => :"AdminApi.revoke_consent_sessions",
        :header_params => header_params,
        :query_params => query_params,
        :form_params => form_params,
        :body => post_body,
        :auth_names => auth_names,
        :return_type => return_type
      )
      data, status_code, headers = @api_client.call_api(:DELETE, local_var_path, new_options)
      if @api_client.config.debugging
        @api_client.config.logger.debug "API called: AdminApi#revoke_consent_sessions\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
      end
      return data, status_code, headers
    end
def revoke_consent_sessions_with_http_info ( subject , opts = { } ) if @api_client . config . debugging @api_client . config . logger . debug 'Calling API: AdminApi.revoke_consent_sessions ...' end if @api_client . config . client_side_validation && subject . nil? fail ArgumentError , "Missing the required parameter 'subject' when calling AdminApi.revoke_consent_sessions" end local_var_path = '/oauth2/auth/sessions/consent' query_params = opts [ :query_params ] || { } query_params [ :' subject ' ] = subject query_params [ :' client ' ] = opts [ :' client ' ] if ! opts [ :' client ' ] . nil? query_params [ :' all ' ] = opts [ :' all ' ] if ! opts [ :' all ' ] . nil? header_params = opts [ :header_params ] || { } header_params [ 'Accept' ] = @api_client . select_header_accept ( [ 'application/json' ] ) form_params = opts [ :form_params ] || { } post_body = opts [ :debug_body ] return_type = opts [ :debug_return_type ] auth_names = opts [ :debug_auth_names ] || [ ] new_options = opts . merge ( :operation => :" AdminApi.revoke_consent_sessions " , :header_params => header_params , :query_params => query_params , :form_params => form_params , :body => post_body , :auth_names => auth_names , :return_type => return_type ) data , status_code , headers = @api_client . call_api ( :DELETE , local_var_path , new_options ) if @api_client . config . debugging @api_client . config . logger . debug "API called: AdminApi#revoke_consent_sessions\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data , status_code , headers end
Revokes Consent Sessions of a Subject for a Specific OAuth 2.0 Client
This endpoint revokes a subject&#39;s granted consent sessions for a specific OAuth 2.0 Client and invalidates all associated OAuth 2.0 Access Tokens.
Revokes Consent Sessions of a Subject for a Specific OAuth 2 . 0 Client This endpoint revokes a subject&#39 ; s granted consent sessions for a specific OAuth 2 . 0 Client and invalidates all associated OAuth 2 . 0 Access Tokens .
# verify the required parameter 'subject' is set # resource path # query parameters # header parameters # HTTP header 'Accept' (if needed) # form parameters # http body (model) # return_type # auth_names
nil, response status code and response headers
nil response status code and response headers
Array<(nil, Integer, Hash)>
subject
The subject (Subject) who's consent sessions should be deleted.
The subject ( Subject ) who ' s consent sessions should be deleted .
opts
:all If set to `?all=true`, deletes all consent sessions by the Subject that have been granted.
: all If set to ` ?all = true ` deletes all consent sessions by the Subject that have been granted .
<not_specific>
opts the optional parameters
opts the optional parameters