fuse_client 1.0.7 → 1.0.31

Sign up to get free protection for your applications and to get access to all the features.
Files changed (277) hide show
  1. checksums.yaml +4 -4
  2. data/Gemfile.lock +6 -5
  3. data/docs/AccountSubType.md +15 -0
  4. data/docs/AccountType.md +15 -0
  5. data/docs/CountryCode.md +15 -0
  6. data/docs/CreateLinkTokenRequest.md +0 -2
  7. data/docs/CreateLinkTokenResponse.md +2 -2
  8. data/docs/CreateSessionRequest.md +9 -1
  9. data/docs/CreateSessionResponse.md +3 -3
  10. data/docs/Currency.md +20 -0
  11. data/docs/DeleteFinancialConnectionResponse.md +22 -0
  12. data/docs/ExchangeFinancialConnectionsPublicTokenResponse.md +3 -3
  13. data/docs/FinancialConnectionData.md +2 -2
  14. data/docs/FinancialConnectionDetails.md +32 -0
  15. data/docs/FinancialConnectionDetailsMx.md +20 -0
  16. data/docs/FinancialConnectionDetailsPlaid.md +20 -0
  17. data/docs/FinancialConnectionDetailsTeller.md +20 -0
  18. data/docs/FinancialConnectionsAccount.md +8 -8
  19. data/docs/FinancialConnectionsAccountBalance.md +5 -3
  20. data/docs/FinancialConnectionsAccountCachedBalance.md +24 -0
  21. data/docs/FinancialConnectionsAccountDetails.md +2 -2
  22. data/docs/FinancialConnectionsAccountLiability.md +8 -8
  23. data/docs/FinancialConnectionsHolding.md +8 -8
  24. data/docs/FinancialConnectionsInvestmentSecurity.md +17 -7
  25. data/docs/FinancialConnectionsInvestmentSecurityExchange.md +18 -0
  26. data/docs/FinancialConnectionsInvestmentTransaction.md +22 -2
  27. data/docs/FinancialConnectionsOwner.md +4 -4
  28. data/docs/FinancialConnectionsOwnerEmailsInner.md +1 -1
  29. data/docs/FinancialConnectionsOwnerNamesInner.md +1 -1
  30. data/docs/FinancialConnectionsOwnerPhoneNumbersInner.md +1 -1
  31. data/docs/FinancialInstitution.md +3 -1
  32. data/docs/FuseApi.md +189 -185
  33. data/docs/FuseApiErrorData.md +1 -1
  34. data/docs/FuseApiWarningData.md +1 -1
  35. data/docs/GetEntityResponse.md +4 -2
  36. data/docs/GetFinancialConnectionResponse.md +20 -0
  37. data/docs/GetFinancialConnectionsAccountDetailsResponse.md +3 -3
  38. data/docs/GetFinancialConnectionsAccountsResponse.md +3 -3
  39. data/docs/GetFinancialConnectionsBalanceRequest.md +3 -1
  40. data/docs/GetFinancialConnectionsBalanceRequestOptions.md +18 -0
  41. data/docs/{GetFinancialConnectionsAccountBalanceResponse.md → GetFinancialConnectionsBalanceResponse.md} +4 -4
  42. data/docs/GetFinancialConnectionsOwnersResponse.md +1 -1
  43. data/docs/GetFinancialConnectionsOwnersResponseAccountsInner.md +3 -3
  44. data/docs/GetFinancialConnectionsTransactionsRequest.md +26 -0
  45. data/docs/GetFinancialConnectionsTransactionsResponse.md +22 -0
  46. data/docs/GetFinancialInstitutionResponse.md +2 -2
  47. data/docs/GetInvestmentHoldingsRequest.md +3 -3
  48. data/docs/GetInvestmentHoldingsRequestOptions.md +18 -0
  49. data/docs/GetInvestmentHoldingsResponse.md +3 -5
  50. data/docs/GetInvestmentTransactionsRequest.md +11 -1
  51. data/docs/GetInvestmentTransactionsRequestOptions.md +18 -0
  52. data/docs/GetInvestmentTransactionsResponse.md +3 -5
  53. data/docs/MigrateFinancialConnectionsAggregatorConnectionData.md +20 -0
  54. data/docs/MigrateFinancialConnectionsAggregatorConnectionDataMx.md +20 -0
  55. data/docs/MigrateFinancialConnectionsAggregatorConnectionDataPlaid.md +18 -0
  56. data/docs/MigrateFinancialConnectionsTokenRequest.md +24 -0
  57. data/docs/MigrateFinancialConnectionsTokenRequestEntity.md +18 -0
  58. data/docs/MigrateFinancialConnectionsTokenResponse.md +24 -0
  59. data/docs/SyncTransactionsResponse.md +2 -2
  60. data/docs/{GetTransactionsResponseDataInner.md → Transaction.md} +16 -14
  61. data/docs/{GetTransactionsResponseDataInnerMerchant.md → TransactionMerchant.md} +2 -2
  62. data/docs/WebhookEvent.md +28 -0
  63. data/docs/WebhookSource.md +15 -0
  64. data/docs/WebhookType.md +15 -0
  65. data/fuse_client.gemspec +1 -1
  66. data/lib/fuse_client/api/fuse_api.rb +181 -197
  67. data/lib/fuse_client/api_client.rb +1 -1
  68. data/lib/fuse_client/api_error.rb +1 -1
  69. data/lib/fuse_client/configuration.rb +39 -18
  70. data/lib/fuse_client/models/account_subtype.rb +178 -0
  71. data/lib/fuse_client/models/account_type.rb +45 -0
  72. data/lib/fuse_client/models/aggregator.rb +3 -3
  73. data/lib/fuse_client/models/country_code.rb +40 -0
  74. data/lib/fuse_client/models/create_asset_report_request.rb +1 -1
  75. data/lib/fuse_client/models/create_asset_report_response.rb +1 -1
  76. data/lib/fuse_client/models/create_entity_request.rb +1 -1
  77. data/lib/fuse_client/models/create_entity_response.rb +1 -1
  78. data/lib/fuse_client/models/create_link_token_request.rb +2 -12
  79. data/lib/fuse_client/models/create_link_token_request_mx.rb +1 -1
  80. data/lib/fuse_client/models/create_link_token_request_plaid.rb +1 -1
  81. data/lib/fuse_client/models/create_link_token_response.rb +11 -1
  82. data/lib/fuse_client/models/create_session_request.rb +46 -5
  83. data/lib/fuse_client/models/create_session_response.rb +16 -1
  84. data/lib/fuse_client/models/currency.rb +235 -0
  85. data/lib/fuse_client/models/delete_financial_connection_response.rb +255 -0
  86. data/lib/fuse_client/models/entity.rb +1 -1
  87. data/lib/fuse_client/models/exchange_financial_connections_public_token_request.rb +1 -1
  88. data/lib/fuse_client/models/exchange_financial_connections_public_token_response.rb +16 -1
  89. data/lib/fuse_client/models/financial_connection_data.rb +11 -1
  90. data/lib/fuse_client/models/financial_connection_details.rb +345 -0
  91. data/lib/fuse_client/models/financial_connection_details_mx.rb +241 -0
  92. data/lib/fuse_client/models/{get_transactions_request.rb → financial_connection_details_plaid.rb} +19 -23
  93. data/lib/fuse_client/models/financial_connection_details_teller.rb +241 -0
  94. data/lib/fuse_client/models/financial_connections_account.rb +59 -14
  95. data/lib/fuse_client/models/financial_connections_account_balance.rb +21 -6
  96. data/lib/fuse_client/models/financial_connections_account_cached_balance.rb +250 -0
  97. data/lib/fuse_client/models/financial_connections_account_details.rb +11 -1
  98. data/lib/fuse_client/models/financial_connections_account_details_ach.rb +1 -1
  99. data/lib/fuse_client/models/financial_connections_account_institution.rb +1 -1
  100. data/lib/fuse_client/models/financial_connections_account_liability.rb +59 -14
  101. data/lib/fuse_client/models/financial_connections_account_liability_all_of.rb +1 -1
  102. data/lib/fuse_client/models/financial_connections_account_liability_all_of_aprs.rb +1 -1
  103. data/lib/fuse_client/models/financial_connections_holding.rb +52 -23
  104. data/lib/fuse_client/models/financial_connections_investment_security.rb +92 -24
  105. data/lib/fuse_client/models/financial_connections_investment_security_exchange.rb +220 -0
  106. data/lib/fuse_client/models/financial_connections_investment_transaction.rb +158 -10
  107. data/lib/fuse_client/models/financial_connections_owner.rb +21 -1
  108. data/lib/fuse_client/models/financial_connections_owner_addresses_inner.rb +1 -1
  109. data/lib/fuse_client/models/financial_connections_owner_addresses_inner_data.rb +1 -1
  110. data/lib/fuse_client/models/financial_connections_owner_emails_inner.rb +6 -1
  111. data/lib/fuse_client/models/financial_connections_owner_names_inner.rb +6 -1
  112. data/lib/fuse_client/models/financial_connections_owner_phone_numbers_inner.rb +6 -1
  113. data/lib/fuse_client/models/financial_institution.rb +22 -5
  114. data/lib/fuse_client/models/financial_institution_logo.rb +1 -1
  115. data/lib/fuse_client/models/fuse_api_error.rb +25 -1
  116. data/lib/fuse_client/models/fuse_api_error_data.rb +24 -2
  117. data/lib/fuse_client/models/fuse_api_warning.rb +1 -1
  118. data/lib/fuse_client/models/fuse_api_warning_data.rb +24 -2
  119. data/lib/fuse_client/models/fuse_api_warning_data_warnings_inner.rb +1 -1
  120. data/lib/fuse_client/models/get_asset_report_request.rb +1 -1
  121. data/lib/fuse_client/models/get_asset_report_response.rb +1 -1
  122. data/lib/fuse_client/models/get_asset_report_response_report.rb +1 -1
  123. data/lib/fuse_client/models/get_asset_report_response_report_accounts_inner.rb +1 -1
  124. data/lib/fuse_client/models/get_asset_report_response_report_accounts_inner_balances.rb +1 -1
  125. data/lib/fuse_client/models/get_asset_report_response_report_accounts_inner_historical_balances_inner.rb +1 -1
  126. data/lib/fuse_client/models/get_entity_response.rb +29 -2
  127. data/lib/fuse_client/models/{get_transactions_response.rb → get_financial_connection_response.rb} +21 -33
  128. data/lib/fuse_client/models/get_financial_connections_account_details_request.rb +1 -1
  129. data/lib/fuse_client/models/get_financial_connections_account_details_response.rb +16 -1
  130. data/lib/fuse_client/models/get_financial_connections_accounts_request.rb +1 -1
  131. data/lib/fuse_client/models/get_financial_connections_accounts_response.rb +16 -1
  132. data/lib/fuse_client/models/get_financial_connections_balance_request.rb +14 -5
  133. data/lib/fuse_client/models/get_financial_connections_balance_request_options.rb +222 -0
  134. data/lib/fuse_client/models/{get_financial_connections_account_balance_response.rb → get_financial_connections_balance_response.rb} +14 -4
  135. data/lib/fuse_client/models/get_financial_connections_owners_request.rb +1 -1
  136. data/lib/fuse_client/models/get_financial_connections_owners_response.rb +6 -1
  137. data/lib/fuse_client/models/get_financial_connections_owners_response_accounts_inner.rb +16 -1
  138. data/lib/fuse_client/models/get_financial_connections_transactions_request.rb +334 -0
  139. data/lib/fuse_client/models/get_financial_connections_transactions_response.rb +256 -0
  140. data/lib/fuse_client/models/get_financial_institution_response.rb +11 -1
  141. data/lib/fuse_client/models/get_investment_holdings_request.rb +9 -10
  142. data/lib/fuse_client/models/get_investment_holdings_request_options.rb +222 -0
  143. data/lib/fuse_client/models/get_investment_holdings_response.rb +18 -14
  144. data/lib/fuse_client/models/get_investment_transactions_request.rb +95 -5
  145. data/lib/fuse_client/models/get_investment_transactions_request_options.rb +222 -0
  146. data/lib/fuse_client/models/get_investment_transactions_response.rb +18 -14
  147. data/lib/fuse_client/models/get_liabilities_request.rb +1 -1
  148. data/lib/fuse_client/models/get_liabilities_response.rb +1 -1
  149. data/lib/fuse_client/models/migrate_financial_connections_aggregator_connection_data.rb +229 -0
  150. data/lib/fuse_client/models/migrate_financial_connections_aggregator_connection_data_mx.rb +236 -0
  151. data/lib/fuse_client/models/migrate_financial_connections_aggregator_connection_data_plaid.rb +226 -0
  152. data/lib/fuse_client/models/{financial_connections_investment_account.rb → migrate_financial_connections_token_request.rb} +86 -70
  153. data/lib/fuse_client/models/{transaction_common_model.rb → migrate_financial_connections_token_request_entity.rb} +12 -13
  154. data/lib/fuse_client/models/migrate_financial_connections_token_response.rb +264 -0
  155. data/lib/fuse_client/models/product.rb +3 -3
  156. data/lib/fuse_client/models/refresh_asset_report_request.rb +1 -1
  157. data/lib/fuse_client/models/sync_financial_connections_data_response.rb +1 -1
  158. data/lib/fuse_client/models/sync_transactions_request.rb +1 -1
  159. data/lib/fuse_client/models/sync_transactions_response.rb +3 -3
  160. data/lib/fuse_client/models/sync_transactions_response_removed_inner.rb +1 -1
  161. data/lib/fuse_client/models/{get_transactions_response_data_inner.rb → transaction.rb} +110 -21
  162. data/lib/fuse_client/models/{get_transactions_response_data_inner_merchant.rb → transaction_merchant.rb} +4 -4
  163. data/lib/fuse_client/models/update_entity_request.rb +1 -1
  164. data/lib/fuse_client/models/update_entity_response.rb +1 -1
  165. data/lib/fuse_client/models/{financial_connections_investment_transaction_data_inner.rb → webhook_event.rb} +94 -63
  166. data/lib/fuse_client/models/webhook_source.rb +43 -0
  167. data/lib/fuse_client/models/webhook_type.rb +42 -0
  168. data/lib/fuse_client/version.rb +2 -2
  169. data/lib/fuse_client.rb +30 -9
  170. data/spec/api/fuse_api_spec.rb +40 -39
  171. data/spec/api_client_spec.rb +3 -1
  172. data/spec/configuration_spec.rb +1 -1
  173. data/spec/models/account_subtype_spec.rb +28 -0
  174. data/spec/models/account_type_spec.rb +28 -0
  175. data/spec/models/aggregator_spec.rb +1 -1
  176. data/spec/models/country_code_spec.rb +28 -0
  177. data/spec/models/create_asset_report_request_spec.rb +1 -1
  178. data/spec/models/create_asset_report_response_spec.rb +1 -1
  179. data/spec/models/create_entity_request_spec.rb +1 -1
  180. data/spec/models/create_entity_response_spec.rb +1 -1
  181. data/spec/models/create_link_token_request_mx_spec.rb +1 -1
  182. data/spec/models/create_link_token_request_plaid_spec.rb +1 -1
  183. data/spec/models/create_link_token_request_spec.rb +1 -7
  184. data/spec/models/create_link_token_response_spec.rb +1 -1
  185. data/spec/models/create_session_request_spec.rb +25 -1
  186. data/spec/models/create_session_response_spec.rb +1 -1
  187. data/spec/models/{get_transactions_response_data_inner_merchant_spec.rb → currency_spec.rb} +13 -7
  188. data/spec/models/{get_transactions_request_spec.rb → delete_financial_connection_response_spec.rb} +10 -10
  189. data/spec/models/entity_spec.rb +1 -1
  190. data/spec/models/exchange_financial_connections_public_token_request_spec.rb +1 -1
  191. data/spec/models/exchange_financial_connections_public_token_response_spec.rb +1 -1
  192. data/spec/models/financial_connection_data_spec.rb +1 -1
  193. data/spec/models/financial_connection_details_mx_spec.rb +40 -0
  194. data/spec/models/financial_connection_details_plaid_spec.rb +40 -0
  195. data/spec/models/{financial_connections_investment_transaction_data_inner_spec.rb → financial_connection_details_spec.rb} +18 -14
  196. data/spec/models/financial_connection_details_teller_spec.rb +40 -0
  197. data/spec/models/financial_connections_account_balance_spec.rb +7 -1
  198. data/spec/models/financial_connections_account_cached_balance_spec.rb +52 -0
  199. data/spec/models/financial_connections_account_details_ach_spec.rb +1 -1
  200. data/spec/models/financial_connections_account_details_spec.rb +1 -1
  201. data/spec/models/financial_connections_account_institution_spec.rb +1 -1
  202. data/spec/models/financial_connections_account_liability_all_of_aprs_spec.rb +1 -1
  203. data/spec/models/financial_connections_account_liability_all_of_spec.rb +1 -1
  204. data/spec/models/financial_connections_account_liability_spec.rb +2 -2
  205. data/spec/models/financial_connections_account_spec.rb +2 -2
  206. data/spec/models/financial_connections_holding_spec.rb +4 -4
  207. data/spec/models/financial_connections_investment_security_exchange_spec.rb +34 -0
  208. data/spec/models/financial_connections_investment_security_spec.rb +34 -4
  209. data/spec/models/financial_connections_investment_transaction_spec.rb +62 -2
  210. data/spec/models/financial_connections_owner_addresses_inner_data_spec.rb +1 -1
  211. data/spec/models/financial_connections_owner_addresses_inner_spec.rb +1 -1
  212. data/spec/models/financial_connections_owner_emails_inner_spec.rb +1 -1
  213. data/spec/models/financial_connections_owner_names_inner_spec.rb +1 -1
  214. data/spec/models/financial_connections_owner_phone_numbers_inner_spec.rb +1 -1
  215. data/spec/models/financial_connections_owner_spec.rb +1 -1
  216. data/spec/models/financial_institution_logo_spec.rb +1 -1
  217. data/spec/models/financial_institution_spec.rb +7 -1
  218. data/spec/models/fuse_api_error_data_spec.rb +1 -1
  219. data/spec/models/fuse_api_error_spec.rb +9 -1
  220. data/spec/models/fuse_api_warning_data_spec.rb +1 -1
  221. data/spec/models/fuse_api_warning_data_warnings_inner_spec.rb +1 -1
  222. data/spec/models/fuse_api_warning_spec.rb +1 -1
  223. data/spec/models/get_asset_report_request_spec.rb +1 -1
  224. data/spec/models/get_asset_report_response_report_accounts_inner_balances_spec.rb +1 -1
  225. data/spec/models/get_asset_report_response_report_accounts_inner_historical_balances_inner_spec.rb +1 -1
  226. data/spec/models/get_asset_report_response_report_accounts_inner_spec.rb +1 -1
  227. data/spec/models/get_asset_report_response_report_spec.rb +1 -1
  228. data/spec/models/get_asset_report_response_spec.rb +1 -1
  229. data/spec/models/get_entity_response_spec.rb +7 -1
  230. data/spec/models/get_financial_connection_response_spec.rb +40 -0
  231. data/spec/models/get_financial_connections_account_details_request_spec.rb +1 -1
  232. data/spec/models/get_financial_connections_account_details_response_spec.rb +1 -1
  233. data/spec/models/get_financial_connections_accounts_request_spec.rb +1 -1
  234. data/spec/models/get_financial_connections_accounts_response_spec.rb +1 -1
  235. data/spec/models/get_financial_connections_balance_request_options_spec.rb +34 -0
  236. data/spec/models/get_financial_connections_balance_request_spec.rb +7 -1
  237. data/spec/models/{get_financial_connections_account_balance_response_spec.rb → get_financial_connections_balance_response_spec.rb} +7 -7
  238. data/spec/models/get_financial_connections_owners_request_spec.rb +1 -1
  239. data/spec/models/get_financial_connections_owners_response_accounts_inner_spec.rb +1 -1
  240. data/spec/models/get_financial_connections_owners_response_spec.rb +1 -1
  241. data/spec/models/get_financial_connections_transactions_request_spec.rb +58 -0
  242. data/spec/models/get_financial_connections_transactions_response_spec.rb +46 -0
  243. data/spec/models/get_financial_institution_response_spec.rb +1 -1
  244. data/spec/models/get_investment_holdings_request_options_spec.rb +34 -0
  245. data/spec/models/get_investment_holdings_request_spec.rb +2 -2
  246. data/spec/models/get_investment_holdings_response_spec.rb +1 -7
  247. data/spec/models/get_investment_transactions_request_options_spec.rb +34 -0
  248. data/spec/models/get_investment_transactions_request_spec.rb +31 -1
  249. data/spec/models/get_investment_transactions_response_spec.rb +1 -7
  250. data/spec/models/get_liabilities_request_spec.rb +1 -1
  251. data/spec/models/get_liabilities_response_spec.rb +1 -1
  252. data/spec/models/migrate_financial_connections_aggregator_connection_data_mx_spec.rb +40 -0
  253. data/spec/models/migrate_financial_connections_aggregator_connection_data_plaid_spec.rb +34 -0
  254. data/spec/models/migrate_financial_connections_aggregator_connection_data_spec.rb +40 -0
  255. data/spec/models/migrate_financial_connections_token_request_entity_spec.rb +34 -0
  256. data/spec/models/migrate_financial_connections_token_request_spec.rb +56 -0
  257. data/spec/models/{get_transactions_response_spec.rb → migrate_financial_connections_token_response_spec.rb} +10 -10
  258. data/spec/models/product_spec.rb +1 -1
  259. data/spec/models/refresh_asset_report_request_spec.rb +1 -1
  260. data/spec/models/sync_financial_connections_data_response_spec.rb +1 -1
  261. data/spec/models/sync_transactions_request_spec.rb +1 -1
  262. data/spec/models/sync_transactions_response_removed_inner_spec.rb +1 -1
  263. data/spec/models/sync_transactions_response_spec.rb +1 -1
  264. data/spec/models/{transaction_common_model_spec.rb → transaction_merchant_spec.rb} +8 -8
  265. data/spec/models/{get_transactions_response_data_inner_spec.rb → transaction_spec.rb} +23 -13
  266. data/spec/models/update_entity_request_spec.rb +1 -1
  267. data/spec/models/update_entity_response_spec.rb +1 -1
  268. data/spec/models/{financial_connections_investment_account_spec.rb → webhook_event_spec.rb} +17 -25
  269. data/spec/models/webhook_source_spec.rb +28 -0
  270. data/spec/models/webhook_type_spec.rb +28 -0
  271. data/spec/spec_helper.rb +1 -1
  272. metadata +118 -34
  273. data/docs/FinancialConnectionsInvestmentAccount.md +0 -32
  274. data/docs/FinancialConnectionsInvestmentTransactionDataInner.md +0 -32
  275. data/docs/GetTransactionsRequest.md +0 -22
  276. data/docs/GetTransactionsResponse.md +0 -24
  277. data/docs/TransactionCommonModel.md +0 -18
@@ -0,0 +1,226 @@
1
+ =begin
2
+ #Fuse
3
+
4
+ #No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
5
+
6
+ The version of the OpenAPI document: 1.0.0
7
+
8
+ Generated by: https://openapi-generator.tech
9
+ OpenAPI Generator version: 6.4.0
10
+
11
+ =end
12
+
13
+ require 'date'
14
+ require 'time'
15
+
16
+ module FuseClient
17
+ # Details of the Plaid connection to migrate into the unified Fuse API.
18
+ class MigrateFinancialConnectionsAggregatorConnectionDataPlaid
19
+ # The Plaid access token associated with the user's financial accounts.
20
+ attr_accessor :access_token
21
+
22
+ # Attribute mapping from ruby-style variable name to JSON key.
23
+ def self.attribute_map
24
+ {
25
+ :'access_token' => :'access_token'
26
+ }
27
+ end
28
+
29
+ # Returns all the JSON keys this model knows about
30
+ def self.acceptable_attributes
31
+ attribute_map.values
32
+ end
33
+
34
+ # Attribute type mapping.
35
+ def self.openapi_types
36
+ {
37
+ :'access_token' => :'String'
38
+ }
39
+ end
40
+
41
+ # List of attributes with nullable: true
42
+ def self.openapi_nullable
43
+ Set.new([
44
+ ])
45
+ end
46
+
47
+ # Initializes the object
48
+ # @param [Hash] attributes Model attributes in the form of hash
49
+ def initialize(attributes = {})
50
+ if (!attributes.is_a?(Hash))
51
+ fail ArgumentError, "The input argument (attributes) must be a hash in `FuseClient::MigrateFinancialConnectionsAggregatorConnectionDataPlaid` initialize method"
52
+ end
53
+
54
+ # check to see if the attribute exists and convert string to symbol for hash key
55
+ attributes = attributes.each_with_object({}) { |(k, v), h|
56
+ if (!self.class.attribute_map.key?(k.to_sym))
57
+ fail ArgumentError, "`#{k}` is not a valid attribute in `FuseClient::MigrateFinancialConnectionsAggregatorConnectionDataPlaid`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
58
+ end
59
+ h[k.to_sym] = v
60
+ }
61
+
62
+ if attributes.key?(:'access_token')
63
+ self.access_token = attributes[:'access_token']
64
+ end
65
+ end
66
+
67
+ # Show invalid properties with the reasons. Usually used together with valid?
68
+ # @return Array for valid properties with the reasons
69
+ def list_invalid_properties
70
+ invalid_properties = Array.new
71
+ if @access_token.nil?
72
+ invalid_properties.push('invalid value for "access_token", access_token cannot be nil.')
73
+ end
74
+
75
+ invalid_properties
76
+ end
77
+
78
+ # Check to see if the all the properties in the model are valid
79
+ # @return true if the model is valid
80
+ def valid?
81
+ return false if @access_token.nil?
82
+ true
83
+ end
84
+
85
+ # Checks equality by comparing each attribute.
86
+ # @param [Object] Object to be compared
87
+ def ==(o)
88
+ return true if self.equal?(o)
89
+ self.class == o.class &&
90
+ access_token == o.access_token
91
+ end
92
+
93
+ # @see the `==` method
94
+ # @param [Object] Object to be compared
95
+ def eql?(o)
96
+ self == o
97
+ end
98
+
99
+ # Calculates hash code according to all attributes.
100
+ # @return [Integer] Hash code
101
+ def hash
102
+ [access_token].hash
103
+ end
104
+
105
+ # Builds the object from hash
106
+ # @param [Hash] attributes Model attributes in the form of hash
107
+ # @return [Object] Returns the model itself
108
+ def self.build_from_hash(attributes)
109
+ new.build_from_hash(attributes)
110
+ end
111
+
112
+ # Builds the object from hash
113
+ # @param [Hash] attributes Model attributes in the form of hash
114
+ # @return [Object] Returns the model itself
115
+ def build_from_hash(attributes)
116
+ return nil unless attributes.is_a?(Hash)
117
+ attributes = attributes.transform_keys(&:to_sym)
118
+ self.class.openapi_types.each_pair do |key, type|
119
+ if attributes[self.class.attribute_map[key]].nil? && self.class.openapi_nullable.include?(key)
120
+ self.send("#{key}=", nil)
121
+ elsif type =~ /\AArray<(.*)>/i
122
+ # check to ensure the input is an array given that the attribute
123
+ # is documented as an array but the input is not
124
+ if attributes[self.class.attribute_map[key]].is_a?(Array)
125
+ self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
126
+ end
127
+ elsif !attributes[self.class.attribute_map[key]].nil?
128
+ self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
129
+ end
130
+ end
131
+
132
+ self
133
+ end
134
+
135
+ # Deserializes the data based on type
136
+ # @param string type Data type
137
+ # @param string value Value to be deserialized
138
+ # @return [Object] Deserialized data
139
+ def _deserialize(type, value)
140
+ case type.to_sym
141
+ when :Time
142
+ Time.parse(value)
143
+ when :Date
144
+ Date.parse(value)
145
+ when :String
146
+ value.to_s
147
+ when :Integer
148
+ value.to_i
149
+ when :Float
150
+ value.to_f
151
+ when :Boolean
152
+ if value.to_s =~ /\A(true|t|yes|y|1)\z/i
153
+ true
154
+ else
155
+ false
156
+ end
157
+ when :Object
158
+ # generic object (usually a Hash), return directly
159
+ value
160
+ when /\AArray<(?<inner_type>.+)>\z/
161
+ inner_type = Regexp.last_match[:inner_type]
162
+ value.map { |v| _deserialize(inner_type, v) }
163
+ when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
164
+ k_type = Regexp.last_match[:k_type]
165
+ v_type = Regexp.last_match[:v_type]
166
+ {}.tap do |hash|
167
+ value.each do |k, v|
168
+ hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
169
+ end
170
+ end
171
+ else # model
172
+ # models (e.g. Pet) or oneOf
173
+ klass = FuseClient.const_get(type)
174
+ klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
175
+ end
176
+ end
177
+
178
+ # Returns the string representation of the object
179
+ # @return [String] String presentation of the object
180
+ def to_s
181
+ to_hash.to_s
182
+ end
183
+
184
+ # to_body is an alias to to_hash (backward compatibility)
185
+ # @return [Hash] Returns the object in the form of hash
186
+ def to_body
187
+ to_hash
188
+ end
189
+
190
+ # Returns the object in the form of hash
191
+ # @return [Hash] Returns the object in the form of hash
192
+ def to_hash
193
+ hash = {}
194
+ self.class.attribute_map.each_pair do |attr, param|
195
+ value = self.send(attr)
196
+ if value.nil?
197
+ is_nullable = self.class.openapi_nullable.include?(attr)
198
+ next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
199
+ end
200
+
201
+ hash[param] = _to_hash(value)
202
+ end
203
+ hash
204
+ end
205
+
206
+ # Outputs non-array value in the form of hash
207
+ # For object, use to_hash. Otherwise, just return the value
208
+ # @param [Object] value Any valid value
209
+ # @return [Hash] Returns the value in the form of hash
210
+ def _to_hash(value)
211
+ if value.is_a?(Array)
212
+ value.compact.map { |v| _to_hash(v) }
213
+ elsif value.is_a?(Hash)
214
+ {}.tap do |hash|
215
+ value.each { |k, v| hash[k] = _to_hash(v) }
216
+ end
217
+ elsif value.respond_to? :to_hash
218
+ value.to_hash
219
+ else
220
+ value
221
+ end
222
+ end
223
+
224
+ end
225
+
226
+ end
@@ -6,7 +6,7 @@
6
6
  The version of the OpenAPI document: 1.0.0
7
7
 
8
8
  Generated by: https://openapi-generator.tech
9
- OpenAPI Generator version: 6.3.0
9
+ OpenAPI Generator version: 6.4.0
10
10
 
11
11
  =end
12
12
 
@@ -14,40 +14,46 @@ require 'date'
14
14
  require 'time'
15
15
 
16
16
  module FuseClient
17
- class FinancialConnectionsInvestmentAccount
18
- # Remote Id of the account, ie Plaid or Teller account id
19
- attr_accessor :remote_id
20
-
21
- # Uniquely identifies this account across all accounts associated with your organization. See more information here: https://letsfuse.readme.io/docs/duplicate-accounts
22
- attr_accessor :fingerprint
23
-
24
- attr_accessor :institution
25
-
26
- # The last four digits of the account number.
27
- attr_accessor :last_four
28
-
29
- # The account's name, ie 'My Checking'
30
- attr_accessor :name
31
-
32
- # The account's type e.g depository.
33
- attr_accessor :type
34
-
35
- # The account's subtype e.g checking
36
- attr_accessor :subtype
17
+ class MigrateFinancialConnectionsTokenRequest
18
+ attr_accessor :connection_data
19
+
20
+ # The aggregator being migrated (either 'plaid' or 'mx').
21
+ attr_accessor :aggregator
22
+
23
+ attr_accessor :entity
24
+
25
+ # A list of Fuse products that the migrated connection will have access to.
26
+ attr_accessor :fuse_products
27
+
28
+ class EnumAttributeValidator
29
+ attr_reader :datatype
30
+ attr_reader :allowable_values
31
+
32
+ def initialize(datatype, allowable_values)
33
+ @allowable_values = allowable_values.map do |value|
34
+ case datatype.to_s
35
+ when /Integer/i
36
+ value.to_i
37
+ when /Float/i
38
+ value.to_f
39
+ else
40
+ value
41
+ end
42
+ end
43
+ end
37
44
 
38
- attr_accessor :balance
45
+ def valid?(value)
46
+ !value || allowable_values.include?(value)
47
+ end
48
+ end
39
49
 
40
50
  # Attribute mapping from ruby-style variable name to JSON key.
41
51
  def self.attribute_map
42
52
  {
43
- :'remote_id' => :'remote_id',
44
- :'fingerprint' => :'fingerprint',
45
- :'institution' => :'institution',
46
- :'last_four' => :'last_four',
47
- :'name' => :'name',
48
- :'type' => :'type',
49
- :'subtype' => :'subtype',
50
- :'balance' => :'balance'
53
+ :'connection_data' => :'connection_data',
54
+ :'aggregator' => :'aggregator',
55
+ :'entity' => :'entity',
56
+ :'fuse_products' => :'fuse_products'
51
57
  }
52
58
  end
53
59
 
@@ -59,14 +65,10 @@ module FuseClient
59
65
  # Attribute type mapping.
60
66
  def self.openapi_types
61
67
  {
62
- :'remote_id' => :'String',
63
- :'fingerprint' => :'String',
64
- :'institution' => :'FinancialConnectionsAccountInstitution',
65
- :'last_four' => :'String',
66
- :'name' => :'String',
67
- :'type' => :'String',
68
- :'subtype' => :'String',
69
- :'balance' => :'FinancialConnectionsAccountBalance'
68
+ :'connection_data' => :'MigrateFinancialConnectionsAggregatorConnectionData',
69
+ :'aggregator' => :'String',
70
+ :'entity' => :'MigrateFinancialConnectionsTokenRequestEntity',
71
+ :'fuse_products' => :'Array<Product>'
70
72
  }
71
73
  end
72
74
 
@@ -80,76 +82,90 @@ module FuseClient
80
82
  # @param [Hash] attributes Model attributes in the form of hash
81
83
  def initialize(attributes = {})
82
84
  if (!attributes.is_a?(Hash))
83
- fail ArgumentError, "The input argument (attributes) must be a hash in `FuseClient::FinancialConnectionsInvestmentAccount` initialize method"
85
+ fail ArgumentError, "The input argument (attributes) must be a hash in `FuseClient::MigrateFinancialConnectionsTokenRequest` initialize method"
84
86
  end
85
87
 
86
88
  # check to see if the attribute exists and convert string to symbol for hash key
87
89
  attributes = attributes.each_with_object({}) { |(k, v), h|
88
90
  if (!self.class.attribute_map.key?(k.to_sym))
89
- fail ArgumentError, "`#{k}` is not a valid attribute in `FuseClient::FinancialConnectionsInvestmentAccount`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
91
+ fail ArgumentError, "`#{k}` is not a valid attribute in `FuseClient::MigrateFinancialConnectionsTokenRequest`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
90
92
  end
91
93
  h[k.to_sym] = v
92
94
  }
93
95
 
94
- if attributes.key?(:'remote_id')
95
- self.remote_id = attributes[:'remote_id']
96
+ if attributes.key?(:'connection_data')
97
+ self.connection_data = attributes[:'connection_data']
96
98
  end
97
99
 
98
- if attributes.key?(:'fingerprint')
99
- self.fingerprint = attributes[:'fingerprint']
100
+ if attributes.key?(:'aggregator')
101
+ self.aggregator = attributes[:'aggregator']
100
102
  end
101
103
 
102
- if attributes.key?(:'institution')
103
- self.institution = attributes[:'institution']
104
+ if attributes.key?(:'entity')
105
+ self.entity = attributes[:'entity']
104
106
  end
105
107
 
106
- if attributes.key?(:'last_four')
107
- self.last_four = attributes[:'last_four']
108
+ if attributes.key?(:'fuse_products')
109
+ if (value = attributes[:'fuse_products']).is_a?(Array)
110
+ self.fuse_products = value
111
+ end
108
112
  end
113
+ end
109
114
 
110
- if attributes.key?(:'name')
111
- self.name = attributes[:'name']
115
+ # Show invalid properties with the reasons. Usually used together with valid?
116
+ # @return Array for valid properties with the reasons
117
+ def list_invalid_properties
118
+ invalid_properties = Array.new
119
+ if @connection_data.nil?
120
+ invalid_properties.push('invalid value for "connection_data", connection_data cannot be nil.')
112
121
  end
113
122
 
114
- if attributes.key?(:'type')
115
- self.type = attributes[:'type']
123
+ if @aggregator.nil?
124
+ invalid_properties.push('invalid value for "aggregator", aggregator cannot be nil.')
116
125
  end
117
126
 
118
- if attributes.key?(:'subtype')
119
- self.subtype = attributes[:'subtype']
127
+ if @entity.nil?
128
+ invalid_properties.push('invalid value for "entity", entity cannot be nil.')
120
129
  end
121
130
 
122
- if attributes.key?(:'balance')
123
- self.balance = attributes[:'balance']
131
+ if @fuse_products.nil?
132
+ invalid_properties.push('invalid value for "fuse_products", fuse_products cannot be nil.')
124
133
  end
125
- end
126
134
 
127
- # Show invalid properties with the reasons. Usually used together with valid?
128
- # @return Array for valid properties with the reasons
129
- def list_invalid_properties
130
- invalid_properties = Array.new
131
135
  invalid_properties
132
136
  end
133
137
 
134
138
  # Check to see if the all the properties in the model are valid
135
139
  # @return true if the model is valid
136
140
  def valid?
141
+ return false if @connection_data.nil?
142
+ return false if @aggregator.nil?
143
+ aggregator_validator = EnumAttributeValidator.new('String', ["plaid", "mx"])
144
+ return false unless aggregator_validator.valid?(@aggregator)
145
+ return false if @entity.nil?
146
+ return false if @fuse_products.nil?
137
147
  true
138
148
  end
139
149
 
150
+ # Custom attribute writer method checking allowed values (enum).
151
+ # @param [Object] aggregator Object to be assigned
152
+ def aggregator=(aggregator)
153
+ validator = EnumAttributeValidator.new('String', ["plaid", "mx"])
154
+ unless validator.valid?(aggregator)
155
+ fail ArgumentError, "invalid value for \"aggregator\", must be one of #{validator.allowable_values}."
156
+ end
157
+ @aggregator = aggregator
158
+ end
159
+
140
160
  # Checks equality by comparing each attribute.
141
161
  # @param [Object] Object to be compared
142
162
  def ==(o)
143
163
  return true if self.equal?(o)
144
164
  self.class == o.class &&
145
- remote_id == o.remote_id &&
146
- fingerprint == o.fingerprint &&
147
- institution == o.institution &&
148
- last_four == o.last_four &&
149
- name == o.name &&
150
- type == o.type &&
151
- subtype == o.subtype &&
152
- balance == o.balance
165
+ connection_data == o.connection_data &&
166
+ aggregator == o.aggregator &&
167
+ entity == o.entity &&
168
+ fuse_products == o.fuse_products
153
169
  end
154
170
 
155
171
  # @see the `==` method
@@ -161,7 +177,7 @@ module FuseClient
161
177
  # Calculates hash code according to all attributes.
162
178
  # @return [Integer] Hash code
163
179
  def hash
164
- [remote_id, fingerprint, institution, last_four, name, type, subtype, balance].hash
180
+ [connection_data, aggregator, entity, fuse_products].hash
165
181
  end
166
182
 
167
183
  # Builds the object from hash
@@ -6,7 +6,7 @@
6
6
  The version of the OpenAPI document: 1.0.0
7
7
 
8
8
  Generated by: https://openapi-generator.tech
9
- OpenAPI Generator version: 6.3.0
9
+ OpenAPI Generator version: 6.4.0
10
10
 
11
11
  =end
12
12
 
@@ -14,13 +14,14 @@ require 'date'
14
14
  require 'time'
15
15
 
16
16
  module FuseClient
17
- class TransactionCommonModel
18
- attr_accessor :data
17
+ class MigrateFinancialConnectionsTokenRequestEntity
18
+ # The unique identifier of the entity (user or business) associated with the financial connections.
19
+ attr_accessor :id
19
20
 
20
21
  # Attribute mapping from ruby-style variable name to JSON key.
21
22
  def self.attribute_map
22
23
  {
23
- :'data' => :'data'
24
+ :'id' => :'id'
24
25
  }
25
26
  end
26
27
 
@@ -32,7 +33,7 @@ module FuseClient
32
33
  # Attribute type mapping.
33
34
  def self.openapi_types
34
35
  {
35
- :'data' => :'Array<GetTransactionsResponseDataInner>'
36
+ :'id' => :'String'
36
37
  }
37
38
  end
38
39
 
@@ -46,21 +47,19 @@ module FuseClient
46
47
  # @param [Hash] attributes Model attributes in the form of hash
47
48
  def initialize(attributes = {})
48
49
  if (!attributes.is_a?(Hash))
49
- fail ArgumentError, "The input argument (attributes) must be a hash in `FuseClient::TransactionCommonModel` initialize method"
50
+ fail ArgumentError, "The input argument (attributes) must be a hash in `FuseClient::MigrateFinancialConnectionsTokenRequestEntity` initialize method"
50
51
  end
51
52
 
52
53
  # check to see if the attribute exists and convert string to symbol for hash key
53
54
  attributes = attributes.each_with_object({}) { |(k, v), h|
54
55
  if (!self.class.attribute_map.key?(k.to_sym))
55
- fail ArgumentError, "`#{k}` is not a valid attribute in `FuseClient::TransactionCommonModel`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
56
+ fail ArgumentError, "`#{k}` is not a valid attribute in `FuseClient::MigrateFinancialConnectionsTokenRequestEntity`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
56
57
  end
57
58
  h[k.to_sym] = v
58
59
  }
59
60
 
60
- if attributes.key?(:'data')
61
- if (value = attributes[:'data']).is_a?(Array)
62
- self.data = value
63
- end
61
+ if attributes.key?(:'id')
62
+ self.id = attributes[:'id']
64
63
  end
65
64
  end
66
65
 
@@ -82,7 +81,7 @@ module FuseClient
82
81
  def ==(o)
83
82
  return true if self.equal?(o)
84
83
  self.class == o.class &&
85
- data == o.data
84
+ id == o.id
86
85
  end
87
86
 
88
87
  # @see the `==` method
@@ -94,7 +93,7 @@ module FuseClient
94
93
  # Calculates hash code according to all attributes.
95
94
  # @return [Integer] Hash code
96
95
  def hash
97
- [data].hash
96
+ [id].hash
98
97
  end
99
98
 
100
99
  # Builds the object from hash