Class: Increase::Resources::ExternalAccounts
- Inherits:
-
Object
- Object
- Increase::Resources::ExternalAccounts
- Defined in:
- lib/increase/resources/external_accounts.rb
Instance Method Summary collapse
-
#create(account_number: , description: , routing_number: , account_holder: nil, funding: nil, request_options: {}) ⇒ Increase::Models::ExternalAccount
Some parameter documentations has been truncated, see Models::ExternalAccountCreateParams for more details.
-
#initialize(client:) ⇒ ExternalAccounts
constructor
private
A new instance of ExternalAccounts.
-
#list(cursor: nil, idempotency_key: nil, limit: nil, routing_number: nil, status: nil, request_options: {}) ⇒ Increase::Internal::Page<Increase::Models::ExternalAccount>
Some parameter documentations has been truncated, see Models::ExternalAccountListParams for more details.
-
#retrieve(external_account_id, request_options: {}) ⇒ Increase::Models::ExternalAccount
Retrieve an External Account.
-
#update(external_account_id, account_holder: nil, description: nil, funding: nil, status: nil, request_options: {}) ⇒ Increase::Models::ExternalAccount
Update an External Account.
Constructor Details
#initialize(client:) ⇒ ExternalAccounts
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
Returns a new instance of ExternalAccounts.
126 127 128 |
# File 'lib/increase/resources/external_accounts.rb', line 126 def initialize(client:) @client = client end |
Instance Method Details
#create(account_number: , description: , routing_number: , account_holder: nil, funding: nil, request_options: {}) ⇒ Increase::Models::ExternalAccount
Some parameter documentations has been truncated, see Models::ExternalAccountCreateParams for more details.
Create an External Account
28 29 30 31 32 33 34 35 36 37 |
# File 'lib/increase/resources/external_accounts.rb', line 28 def create(params) parsed, = Increase::ExternalAccountCreateParams.dump_request(params) @client.request( method: :post, path: "external_accounts", body: parsed, model: Increase::ExternalAccount, options: ) end |
#list(cursor: nil, idempotency_key: nil, limit: nil, routing_number: nil, status: nil, request_options: {}) ⇒ Increase::Internal::Page<Increase::Models::ExternalAccount>
Some parameter documentations has been truncated, see Models::ExternalAccountListParams for more details.
List External Accounts
111 112 113 114 115 116 117 118 119 120 121 |
# File 'lib/increase/resources/external_accounts.rb', line 111 def list(params = {}) parsed, = Increase::ExternalAccountListParams.dump_request(params) @client.request( method: :get, path: "external_accounts", query: parsed, page: Increase::Internal::Page, model: Increase::ExternalAccount, options: ) end |
#retrieve(external_account_id, request_options: {}) ⇒ Increase::Models::ExternalAccount
Retrieve an External Account
50 51 52 53 54 55 56 57 |
# File 'lib/increase/resources/external_accounts.rb', line 50 def retrieve(external_account_id, params = {}) @client.request( method: :get, path: ["external_accounts/%1$s", external_account_id], model: Increase::ExternalAccount, options: params[:request_options] ) end |
#update(external_account_id, account_holder: nil, description: nil, funding: nil, status: nil, request_options: {}) ⇒ Increase::Models::ExternalAccount
Update an External Account
78 79 80 81 82 83 84 85 86 87 |
# File 'lib/increase/resources/external_accounts.rb', line 78 def update(external_account_id, params = {}) parsed, = Increase::ExternalAccountUpdateParams.dump_request(params) @client.request( method: :patch, path: ["external_accounts/%1$s", external_account_id], body: parsed, model: Increase::ExternalAccount, options: ) end |