Class: CloudPayments::Namespaces::Tokens

Inherits:
Base
  • Object
show all
Defined in:
lib/cloud_payments/namespaces/tokens.rb

Instance Attribute Summary

Attributes inherited from Base

#client, #parent_path

Instance Method Summary collapse

Methods inherited from Base

#initialize, #request, resource_name

Constructor Details

This class inherits a constructor from CloudPayments::Namespaces::Base

Instance Method Details

#auth(attributes) ⇒ Object



10
11
12
13
# File 'lib/cloud_payments/namespaces/tokens.rb', line 10

def auth(attributes)
  response = request(:auth, attributes)
  Transaction.new(response[:model])
end

#charge(attributes) ⇒ Object



5
6
7
8
# File 'lib/cloud_payments/namespaces/tokens.rb', line 5

def charge(attributes)
  response = request(:charge, attributes)
  Transaction.new(response[:model])
end