Class: Stripe::FinancialConnections::AccountService
- Inherits:
-
StripeService
- Object
- StripeService
- Stripe::FinancialConnections::AccountService
- Defined in:
- lib/stripe/services/financial_connections/account_service.rb
Defined Under Namespace
Classes: DisconnectParams, ListParams, RefreshParams, RetrieveParams, SubscribeParams, UnsubscribeParams
Instance Attribute Summary collapse
-
#owners ⇒ Object
readonly
Returns the value of attribute owners.
Instance Method Summary collapse
-
#disconnect(account, params = {}, opts = {}) ⇒ Object
Disables your access to a Financial Connections Account.
-
#initialize(requestor) ⇒ AccountService
constructor
A new instance of AccountService.
-
#list(params = {}, opts = {}) ⇒ Object
Returns a list of Financial Connections Account objects.
-
#refresh(account, params = {}, opts = {}) ⇒ Object
Refreshes the data associated with a Financial Connections Account.
-
#retrieve(account, params = {}, opts = {}) ⇒ Object
Retrieves the details of an Financial Connections Account.
-
#subscribe(account, params = {}, opts = {}) ⇒ Object
Subscribes to periodic refreshes of data associated with a Financial Connections Account.
-
#unsubscribe(account, params = {}, opts = {}) ⇒ Object
Unsubscribes from periodic refreshes of data associated with a Financial Connections Account.
Methods inherited from StripeService
Constructor Details
#initialize(requestor) ⇒ AccountService
Returns a new instance of AccountService.
9 10 11 12 |
# File 'lib/stripe/services/financial_connections/account_service.rb', line 9 def initialize(requestor) super(requestor) @owners = Stripe::FinancialConnections::AccountOwnerService.new(@requestor) end |
Instance Attribute Details
#owners ⇒ Object (readonly)
Returns the value of attribute owners.
7 8 9 |
# File 'lib/stripe/services/financial_connections/account_service.rb', line 7 def owners @owners end |
Instance Method Details
#disconnect(account, params = {}, opts = {}) ⇒ Object
Disables your access to a Financial Connections Account. You will no longer be able to access data associated with the account (e.g. balances, transactions).
111 112 113 114 115 116 117 118 119 |
# File 'lib/stripe/services/financial_connections/account_service.rb', line 111 def disconnect(account, params = {}, opts = {}) request( method: :post, path: format("/v1/financial_connections/accounts/%<account>s/disconnect", { account: CGI.escape(account) }), params: params, opts: opts, base_address: :api ) end |
#list(params = {}, opts = {}) ⇒ Object
Returns a list of Financial Connections Account objects.
122 123 124 125 126 127 128 129 130 |
# File 'lib/stripe/services/financial_connections/account_service.rb', line 122 def list(params = {}, opts = {}) request( method: :get, path: "/v1/financial_connections/accounts", params: params, opts: opts, base_address: :api ) end |
#refresh(account, params = {}, opts = {}) ⇒ Object
Refreshes the data associated with a Financial Connections Account.
133 134 135 136 137 138 139 140 141 |
# File 'lib/stripe/services/financial_connections/account_service.rb', line 133 def refresh(account, params = {}, opts = {}) request( method: :post, path: format("/v1/financial_connections/accounts/%<account>s/refresh", { account: CGI.escape(account) }), params: params, opts: opts, base_address: :api ) end |
#retrieve(account, params = {}, opts = {}) ⇒ Object
Retrieves the details of an Financial Connections Account.
144 145 146 147 148 149 150 151 152 |
# File 'lib/stripe/services/financial_connections/account_service.rb', line 144 def retrieve(account, params = {}, opts = {}) request( method: :get, path: format("/v1/financial_connections/accounts/%<account>s", { account: CGI.escape(account) }), params: params, opts: opts, base_address: :api ) end |
#subscribe(account, params = {}, opts = {}) ⇒ Object
Subscribes to periodic refreshes of data associated with a Financial Connections Account.
155 156 157 158 159 160 161 162 163 |
# File 'lib/stripe/services/financial_connections/account_service.rb', line 155 def subscribe(account, params = {}, opts = {}) request( method: :post, path: format("/v1/financial_connections/accounts/%<account>s/subscribe", { account: CGI.escape(account) }), params: params, opts: opts, base_address: :api ) end |
#unsubscribe(account, params = {}, opts = {}) ⇒ Object
Unsubscribes from periodic refreshes of data associated with a Financial Connections Account.
166 167 168 169 170 171 172 173 174 |
# File 'lib/stripe/services/financial_connections/account_service.rb', line 166 def unsubscribe(account, params = {}, opts = {}) request( method: :post, path: format("/v1/financial_connections/accounts/%<account>s/unsubscribe", { account: CGI.escape(account) }), params: params, opts: opts, base_address: :api ) end |