Class: Increase::Resources::Simulations::Programs
- Inherits:
-
Object
- Object
- Increase::Resources::Simulations::Programs
- Defined in:
- lib/increase/resources/simulations/programs.rb
Instance Method Summary collapse
-
#create(name: , bank: nil, reserve_account_id: nil, request_options: {}) ⇒ Increase::Models::Program
Simulates a [Program](#programs) being created in your group.
-
#initialize(client:) ⇒ Programs
constructor
private
A new instance of Programs.
Constructor Details
#initialize(client:) ⇒ Programs
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 Programs.
39 40 41 |
# File 'lib/increase/resources/simulations/programs.rb', line 39 def initialize(client:) @client = client end |
Instance Method Details
#create(name: , bank: nil, reserve_account_id: nil, request_options: {}) ⇒ Increase::Models::Program
Simulates a [Program](#programs) being created in your group. By default, your group has one program called Commercial Banking. Note that when your group operates more than one program, ‘program_id` is a required field when creating accounts.
25 26 27 28 29 30 31 32 33 34 |
# File 'lib/increase/resources/simulations/programs.rb', line 25 def create(params) parsed, = Increase::Simulations::ProgramCreateParams.dump_request(params) @client.request( method: :post, path: "simulations/programs", body: parsed, model: Increase::Program, options: ) end |