Class: IPay::CC::Debit

Inherits:
ApiRequest show all
Defined in:
lib/ipay/cc.rb

Constant Summary

Constants inherited from ApiRequest

ApiRequest::DEFAULT_SERVICE_FORMAT

Class Method Summary collapse

Methods inherited from ApiRequest

send_request, service, service_format, service_format=, service_type

Class Method Details

.auth(data) ⇒ Object



30
31
32
33
# File 'lib/ipay/cc.rb', line 30

def self.auth(data)
  data[:goods_indicator] ||= GOODS_DIGITAL
  self.send_request(data)
end

.capture(data) ⇒ Object



35
36
37
# File 'lib/ipay/cc.rb', line 35

def self.capture(data)
  self.send_request(data)
end

.reversal(data) ⇒ Object



50
51
52
# File 'lib/ipay/cc.rb', line 50

def self.reversal(data)
  self.send_request(data)
end

.sale(data) ⇒ Object



39
40
41
42
43
# File 'lib/ipay/cc.rb', line 39

def self.sale(data)
  data[:goods_indicator] ||= GOODS_DIGITAL
  data[:entry_mode] ||= EM_MANUAL_NOT_PRESENT
  self.send_request(data)
end

.void(data) ⇒ Object



45
46
47
48
# File 'lib/ipay/cc.rb', line 45

def self.void(data)
  data = {:transaction_id => data} if data.is_a?(String) || data.is_a?(Fixnum)
  self.send_request(data)
end