Class: Iyzipay::HttpClient

Inherits:
Object
  • Object
show all
Defined in:
lib/iyzipay/http_client.rb

Class Method Summary collapse

Class Method Details

.delete(url, headers = {}, content, &block) ⇒ Object



15
16
17
# File 'lib/iyzipay/http_client.rb', line 15

def self.delete(url, headers={}, content, &block)
  RestClient::Request.execute(:method => :delete, :url => url, :payload => content, :headers => headers, &block)
end

.get(url, header = {}) ⇒ Object



3
4
5
# File 'lib/iyzipay/http_client.rb', line 3

def self.get(url, header={})
  RestClient.get(url, header)
end

.post(url, header, content) ⇒ Object



7
8
9
# File 'lib/iyzipay/http_client.rb', line 7

def self.post(url, header, content)
  RestClient.post(url, content, header)
end

.put(url, header, content) ⇒ Object



11
12
13
# File 'lib/iyzipay/http_client.rb', line 11

def self.put(url, header, content)
  RestClient.put(url, content, header)
end