Class: FinchAPI::Resources::Sandbox::Connections
- Inherits:
-
Object
- Object
- FinchAPI::Resources::Sandbox::Connections
- Defined in:
- lib/finch-api/resources/sandbox/connections.rb,
lib/finch-api/resources/sandbox/connections/accounts.rb
Defined Under Namespace
Classes: Accounts
Instance Attribute Summary collapse
Instance Method Summary collapse
-
#create(params) ⇒ FinchAPI::Models::Sandbox::ConnectionCreateResponse
Create a new connection (new company/provider pair) with a new account.
-
#initialize(client:) ⇒ Connections
constructor
A new instance of Connections.
Constructor Details
#initialize(client:) ⇒ Connections
Returns a new instance of Connections.
39 40 41 42 |
# File 'lib/finch-api/resources/sandbox/connections.rb', line 39 def initialize(client:) @client = client @accounts = FinchAPI::Resources::Sandbox::Connections::Accounts.new(client: client) end |
Instance Attribute Details
#accounts ⇒ FinchAPI::Resources::Sandbox::Connections::Accounts (readonly)
8 9 10 |
# File 'lib/finch-api/resources/sandbox/connections.rb', line 8 def accounts @accounts end |
Instance Method Details
#create(params) ⇒ FinchAPI::Models::Sandbox::ConnectionCreateResponse
Create a new connection (new company/provider pair) with a new account
27 28 29 30 31 32 33 34 35 36 |
# File 'lib/finch-api/resources/sandbox/connections.rb', line 27 def create(params) parsed, = FinchAPI::Models::Sandbox::ConnectionCreateParams.dump_request(params) @client.request( method: :post, path: "sandbox/connections", body: parsed, model: FinchAPI::Models::Sandbox::ConnectionCreateResponse, options: ) end |