module Yandex::Pdd::Client::Connection

Public Instance Methods

delete(path, options = {}) click to toggle source
# File lib/yandex/pdd/client/connection.rb, line 21
def delete(path, options = {})
  request :delete, path, options
end
get(path, options = {}) click to toggle source
# File lib/yandex/pdd/client/connection.rb, line 5
def get(path, options = {})
  request :get, path, options
end
patch(path, options = {}) click to toggle source
# File lib/yandex/pdd/client/connection.rb, line 17
def patch(path, options = {})
  request :patch, path, options
end
post(path, options = {}) click to toggle source
# File lib/yandex/pdd/client/connection.rb, line 9
def post(path, options = {})
  request :post, path, options
end
put(path, options = {}) click to toggle source
# File lib/yandex/pdd/client/connection.rb, line 13
def put(path, options = {})
  request :put, path, options
end

Private Instance Methods

request(http_method, path, options) click to toggle source
# File lib/yandex/pdd/client/connection.rb, line 27
def request(http_method, path, options)
  response = self.class.send(http_method, path, body: options)
  response.parsed_response
end