Class: Callapi::Call::Request::Http

Inherits:
Base
  • Object
show all
Includes:
LogHelper
Defined in:
lib/callapi/call/request/http.rb

Direct Known Subclasses

Api

Defined Under Namespace

Modules: LogHelper

Constant Summary collapse

HTTP_METHOD_TO_REQUEST_CLASS =
{
  get:     Net::HTTP::Get,
  post:    Net::HTTP::Post,
  put:     Net::HTTP::Put,
  delete:  Net::HTTP::Delete,
  patch:   Net::HTTP::Patch
}

Instance Method Summary collapse

Methods included from LogHelper

#add_api_host_log, #add_request_headers_log, #add_request_params_log, #add_request_path_log, #add_response_log, #add_response_summary_log, #with_logging

Methods inherited from Base

#initialize

Constructor Details

This class inherits a constructor from Callapi::Call::Request::Base

Instance Method Details

#responseObject



18
19
20
21
22
# File 'lib/callapi/call/request/http.rb', line 18

def response
  with_logging do
    http.request(request)
  end
end