Class: ModernTreasury::Resources::AccountCollectionFlows
- Inherits:
-
Object
- Object
- ModernTreasury::Resources::AccountCollectionFlows
- Defined in:
- lib/modern_treasury/resources/account_collection_flows.rb
Instance Method Summary collapse
-
#create(counterparty_id: , payment_types: , receiving_countries: nil, request_options: {}) ⇒ ModernTreasury::Models::AccountCollectionFlow
create account_collection_flow.
-
#initialize(client:) ⇒ AccountCollectionFlows
constructor
private
A new instance of AccountCollectionFlows.
-
#list(after_cursor: nil, client_token: nil, counterparty_id: nil, external_account_id: nil, per_page: nil, status: nil, request_options: {}) ⇒ ModernTreasury::Internal::Page<ModernTreasury::Models::AccountCollectionFlow>
list account_collection_flows.
-
#retrieve(id, request_options: {}) ⇒ ModernTreasury::Models::AccountCollectionFlow
get account_collection_flow.
-
#update(id, status: , request_options: {}) ⇒ ModernTreasury::Models::AccountCollectionFlow
Some parameter documentations has been truncated, see Models::AccountCollectionFlowUpdateParams for more details.
Constructor Details
#initialize(client:) ⇒ AccountCollectionFlows
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 AccountCollectionFlows.
109 110 111 |
# File 'lib/modern_treasury/resources/account_collection_flows.rb', line 109 def initialize(client:) @client = client end |
Instance Method Details
#create(counterparty_id: , payment_types: , receiving_countries: nil, request_options: {}) ⇒ ModernTreasury::Models::AccountCollectionFlow
create account_collection_flow
21 22 23 24 25 26 27 28 29 30 |
# File 'lib/modern_treasury/resources/account_collection_flows.rb', line 21 def create(params) parsed, = ModernTreasury::AccountCollectionFlowCreateParams.dump_request(params) @client.request( method: :post, path: "api/account_collection_flows", body: parsed, model: ModernTreasury::AccountCollectionFlow, options: ) end |
#list(after_cursor: nil, client_token: nil, counterparty_id: nil, external_account_id: nil, per_page: nil, status: nil, request_options: {}) ⇒ ModernTreasury::Internal::Page<ModernTreasury::Models::AccountCollectionFlow>
list account_collection_flows
94 95 96 97 98 99 100 101 102 103 104 |
# File 'lib/modern_treasury/resources/account_collection_flows.rb', line 94 def list(params = {}) parsed, = ModernTreasury::AccountCollectionFlowListParams.dump_request(params) @client.request( method: :get, path: "api/account_collection_flows", query: parsed, page: ModernTreasury::Internal::Page, model: ModernTreasury::AccountCollectionFlow, options: ) end |
#retrieve(id, request_options: {}) ⇒ ModernTreasury::Models::AccountCollectionFlow
get account_collection_flow
43 44 45 46 47 48 49 50 |
# File 'lib/modern_treasury/resources/account_collection_flows.rb', line 43 def retrieve(id, params = {}) @client.request( method: :get, path: ["api/account_collection_flows/%1$s", id], model: ModernTreasury::AccountCollectionFlow, options: params[:request_options] ) end |
#update(id, status: , request_options: {}) ⇒ ModernTreasury::Models::AccountCollectionFlow
Some parameter documentations has been truncated, see Models::AccountCollectionFlowUpdateParams for more details.
update account_collection_flow
68 69 70 71 72 73 74 75 76 77 |
# File 'lib/modern_treasury/resources/account_collection_flows.rb', line 68 def update(id, params) parsed, = ModernTreasury::AccountCollectionFlowUpdateParams.dump_request(params) @client.request( method: :patch, path: ["api/account_collection_flows/%1$s", id], body: parsed, model: ModernTreasury::AccountCollectionFlow, options: ) end |