Class: PriorityPayoutGateway::CustomerVault
- Defined in:
- lib/priority_payout_gateway/customer_vault.rb
Constant Summary
Constants inherited from Api
Api::QUERY_URL, Api::TRANSACTION_URL
Instance Attribute Summary
Attributes inherited from Api
Instance Method Summary collapse
-
#create(options = {}) ⇒ Object
PriorityPayoutGateway::CustomerVault.new.create ccnumber: ‘4111111111111111’, ccexp: “0219”, first_name: “John”, last_name: “Doe”.
-
#destroy(options = {}) ⇒ Object
PriorityPayoutGateway::CustomerVault.new.destroy customer_vault_id: 481397475.
-
#find(options = {}) ⇒ Object
PriorityPayoutGateway::CustomerVault.new.find customer_vault_id: 481397475.
-
#update(options = {}) ⇒ Object
PriorityPayoutGateway::CustomerVault.new.update customer_vault_id: 481397475, ccnumber: ‘4111111111111111’, ccexp: “0220”, first_name: “Jane”, last_name: “Doe”.
Methods inherited from Api
Constructor Details
This class inherits a constructor from PriorityPayoutGateway::Api
Instance Method Details
#create(options = {}) ⇒ Object
PriorityPayoutGateway::CustomerVault.new.create ccnumber: ‘4111111111111111’, ccexp: “0219”, first_name: “John”, last_name: “Doe”
5 6 7 8 9 10 11 |
# File 'lib/priority_payout_gateway/customer_vault.rb', line 5 def create( = {}) query = set_query() query[:customer_vault] = 'add_customer' require_fields(:ccnumber, :ccexp) response = post query end |
#destroy(options = {}) ⇒ Object
PriorityPayoutGateway::CustomerVault.new.destroy customer_vault_id: 481397475
22 23 24 25 26 27 |
# File 'lib/priority_payout_gateway/customer_vault.rb', line 22 def destroy( = {}) query = set_query() query[:customer_vault] = 'delete_customer' require_fields(:customer_vault_id) response = post query end |
#find(options = {}) ⇒ Object
PriorityPayoutGateway::CustomerVault.new.find customer_vault_id: 481397475
30 31 32 33 34 35 |
# File 'lib/priority_payout_gateway/customer_vault.rb', line 30 def find( = {}) query = set_query() query[:report_type] = 'customer_vault' require_fields(:customer_vault_id) response = get query end |
#update(options = {}) ⇒ Object
PriorityPayoutGateway::CustomerVault.new.update customer_vault_id: 481397475, ccnumber: ‘4111111111111111’, ccexp: “0220”, first_name: “Jane”, last_name: “Doe”
14 15 16 17 18 19 |
# File 'lib/priority_payout_gateway/customer_vault.rb', line 14 def update( = {}) query = set_query() query[:customer_vault] = 'update_customer' require_fields(:customer_vault_id) response = post query end |