Class: Plaidio::Customer
- Inherits:
-
Object
- Object
- Plaidio::Customer
- Defined in:
- lib/plaidio/customer.rb
Overview
This is used when a customer needs to be defined by the plaid access token. Abstracting as a class makes it easier since we wont have to redefine the access_token over and over.
Constant Summary collapse
- BASE_URL =
'https://tartan.plaid.com'
Instance Method Summary collapse
- #delete_account(access_token) ⇒ Object
- #get_transactions(access_token) ⇒ Object
-
#initialize ⇒ Customer
constructor
This initializes our instance variables, and sets up a new Customer class.
- #mfa_step(access_token, code) ⇒ Object
Constructor Details
Instance Method Details
#delete_account(access_token) ⇒ Object
26 27 28 29 |
# File 'lib/plaidio/customer.rb', line 26 def delete_account(access_token) delete('/connect', access_token) return parse_response(@response,3) end |
#get_transactions(access_token) ⇒ Object
21 22 23 24 |
# File 'lib/plaidio/customer.rb', line 21 def get_transactions(access_token) get('/connect', access_token) return parse_response(@response,2) end |
#mfa_step(access_token, code) ⇒ Object
15 16 17 18 19 |
# File 'lib/plaidio/customer.rb', line 15 def mfa_step(access_token,code) @mfa = code post("/connect/step", access_token, mfa: @mfa) return parse_response(@response,1) end |