Sha256: 78037b73ee8f5b16e66c9e6767bdd219582a7da8783c00a12aa4b369177d5186
Contents?: true
Size: 478 Bytes
Versions: 3
Compression:
Stored size: 478 Bytes
Contents
module Base module HTTP def generate_uri(partial_path) URI.join( Apis::API_HOST.to_s, "/#{Apis::API_VERSION}/#{partial_path}") end def generate_request(uri, header_parameter = nil) Net::HTTP::Get.new(uri, header_parameter) end def start(request, uri) Net::HTTP.start( uri.hostname, uri.port, use_ssl: uri.scheme == 'https') do |http| http.request(request) end end end end
Version data entries
3 entries across 3 versions & 1 rubygems
Version | Path |
---|---|
base-api-client-0.3.1.beta | lib/base/http.rb |
base-api-client-0.3.beta | lib/base/http.rb |
base-api-client-0.2.5.beta | lib/base/http.rb |