Class: PushPay::Settlement

Inherits:
Base
  • Object
show all
Defined in:
lib/pushpay/settlement.rb

Instance Attribute Summary

Attributes inherited from Base

#client

Instance Method Summary collapse

Methods inherited from Base

#initialize

Constructor Details

This class inherits a constructor from PushPay::Base

Instance Method Details

#find(settlement_key) ⇒ Object

Get a specific settlement



6
7
8
# File 'lib/pushpay/settlement.rb', line 6

def find(settlement_key)
  client.get("/v1/settlement/#{settlement_key}")
end

#list(merchant_key: nil, **params) ⇒ Object

List settlements for a merchant



11
12
13
# File 'lib/pushpay/settlement.rb', line 11

def list(merchant_key: nil, **params)
  client.get("#{merchant_path(merchant_key)}/settlements", params)
end

#list_for_organization(organization_key: nil, **params) ⇒ Object

List settlements for an organization



16
17
18
# File 'lib/pushpay/settlement.rb', line 16

def list_for_organization(organization_key: nil, **params)
  client.get("#{organization_path(organization_key)}/settlements", params)
end

#payments(settlement_key, **params) ⇒ Object

Get payments within a settlement



21
22
23
# File 'lib/pushpay/settlement.rb', line 21

def payments(settlement_key, **params)
  client.get("/v1/settlement/#{settlement_key}/payments", params)
end