fuse_client 1.0.33 → 1.0.35

Sign up to get free protection for your applications and to get access to all the features.
Files changed (443) hide show
  1. checksums.yaml +4 -4
  2. data/Gemfile.lock +4 -4
  3. data/README.md +7 -1
  4. data/docs/AddAccountEventsRequest.md +18 -0
  5. data/docs/AddAccountEventsRequestEventsInner.md +51 -0
  6. data/docs/{AddSpendPowerTransactionResponse.md → AddAccountEventsResponse.md} +2 -2
  7. data/docs/AssetReportTransaction.md +1 -1
  8. data/docs/CreateLinkTokenRequestTellerConfig.md +3 -1
  9. data/docs/CreateLinkTokenRequestTellerConfigAccountFilter.md +20 -0
  10. data/docs/CreateLinkTokenRequestTellerConfigAccountFilterCredit.md +49 -0
  11. data/docs/CreateLinkTokenRequestTellerConfigAccountFilterCreditOneOf.md +18 -0
  12. data/docs/CreateLinkTokenRequestTellerConfigAccountFilterDepository.md +49 -0
  13. data/docs/CreateLinkTokenRequestTellerConfigAccountFilterDepositoryOneOf.md +18 -0
  14. data/docs/CreateSessionRequest.md +1 -1
  15. data/docs/CreateSpendPowerCustomizationRequest.md +24 -0
  16. data/docs/CreateSpendPowerRequest.md +5 -5
  17. data/docs/CreateSpendPowerResponse.md +1 -1
  18. data/docs/DeleteSpendPowerResponse.md +2 -2
  19. data/docs/EnrichTransactionsRequest.md +18 -0
  20. data/docs/EnrichTransactionsResponse.md +18 -0
  21. data/docs/EnrichedTransaction.md +48 -0
  22. data/docs/EvalSpendPowerRequest.md +22 -0
  23. data/docs/EvalSpendPowerRequestEventsInner.md +20 -0
  24. data/docs/EvalSpendPowerResponse.md +24 -0
  25. data/docs/ExternalTransactionEvent.md +34 -0
  26. data/docs/ExternalTransactionEventStatus.md +15 -0
  27. data/docs/FinQLComparisonFeature.md +26 -0
  28. data/docs/FinQLFeature.md +61 -0
  29. data/docs/FinQLFeatureOneOf.md +18 -0
  30. data/docs/FinQLFeatureOneOf1.md +18 -0
  31. data/docs/FinQLFeatureOneOf2.md +18 -0
  32. data/docs/FinQLFeatureOneOf3.md +18 -0
  33. data/docs/FinQLFeatureOneOf4.md +18 -0
  34. data/docs/FinQLFeatureOneOf5.md +18 -0
  35. data/docs/FinQLFeatureOneOf6.md +18 -0
  36. data/docs/FinQLFeatureOneOf7.md +18 -0
  37. data/docs/FinQLFeatureRequest.md +15 -0
  38. data/docs/FinQLFrequencyFeature.md +20 -0
  39. data/docs/FinQLIndividualMerchantFeature.md +20 -0
  40. data/docs/FinQLInterestFeature.md +18 -0
  41. data/docs/FinQLMerchantCategoriesFeatureInner.md +20 -0
  42. data/docs/FinQLMerchantCategoriesFeatureInnerResultInner.md +20 -0
  43. data/docs/FinQLPromptRequest.md +22 -0
  44. data/docs/FinQLPromptResponse.md +20 -0
  45. data/docs/FinQLTimeBasedFeatureInner.md +20 -0
  46. data/docs/FinQLTopMerchantsFeatureInner.md +22 -0
  47. data/docs/FinanceScore.md +30 -0
  48. data/docs/FinancialConnectionDetails.md +7 -1
  49. data/docs/FinancialConnectionDetailsFlinks.md +18 -0
  50. data/docs/FinancialConnectionDetailsMono.md +18 -0
  51. data/docs/FinancialConnectionDetailsSnaptrade.md +22 -0
  52. data/docs/FinancialConnectionsAccount.md +4 -2
  53. data/docs/FinancialConnectionsAccountBalance.md +2 -2
  54. data/docs/FinancialConnectionsAccountCachedBalance.md +2 -2
  55. data/docs/FinancialConnectionsAccountDetails.md +3 -1
  56. data/docs/FinancialConnectionsAccountLiability.md +3 -1
  57. data/docs/FinancialConnectionsHolding.md +3 -3
  58. data/docs/FinancialConnectionsInvestmentSecurity.md +1 -1
  59. data/docs/FinancialConnectionsInvestmentTransaction.md +5 -3
  60. data/docs/FinancialConnectionsInvestmentTransactionSubtype.md +15 -0
  61. data/docs/FuseApi.md +272 -35
  62. data/docs/GetFinanceScoreResponse.md +20 -0
  63. data/docs/GetInvestmentTransactionsRequest.md +4 -4
  64. data/docs/GetSpendPowerCustomizationResponse.md +20 -0
  65. data/docs/InAppTransactionEvent.md +34 -0
  66. data/docs/InAppTransactionEventStatus.md +15 -0
  67. data/docs/Merchant.md +22 -0
  68. data/docs/MerchantLogo.md +18 -0
  69. data/docs/SpendPower.md +11 -7
  70. data/docs/SpendPowerApi.md +87 -44
  71. data/docs/SpendPowerCustomization.md +8 -4
  72. data/docs/SpendPowerTimeFrame.md +15 -0
  73. data/docs/Transaction.md +3 -1
  74. data/docs/TransactionCategory.md +20 -0
  75. data/docs/TransactionCategoryDetailed.md +15 -0
  76. data/docs/TransactionCategoryPrimary.md +15 -0
  77. data/docs/TransactionEventType.md +15 -0
  78. data/docs/TransactionToEnrich.md +26 -0
  79. data/docs/UpdateSpendPowerCustomizationRequest.md +24 -0
  80. data/docs/UpdatedBalanceEvent.md +26 -0
  81. data/fuse_client.gemspec +1 -1
  82. data/lib/fuse_client/api/fuse_api.rb +241 -32
  83. data/lib/fuse_client/api/spend_power_api.rb +79 -53
  84. data/lib/fuse_client/api_client.rb +1 -1
  85. data/lib/fuse_client/api_error.rb +1 -1
  86. data/lib/fuse_client/configuration.rb +11 -11
  87. data/lib/fuse_client/models/account_subtype.rb +1 -1
  88. data/lib/fuse_client/models/account_type.rb +1 -1
  89. data/lib/fuse_client/models/add_account_events_request.rb +254 -0
  90. data/lib/fuse_client/models/add_account_events_request_events_inner.rb +106 -0
  91. data/lib/fuse_client/models/{add_spend_power_transaction_response.rb → add_account_events_response.rb} +4 -4
  92. data/lib/fuse_client/models/aggregator.rb +3 -3
  93. data/lib/fuse_client/models/asset_report.rb +1 -1
  94. data/lib/fuse_client/models/asset_report_accounts_inner.rb +1 -1
  95. data/lib/fuse_client/models/asset_report_accounts_inner_balance.rb +1 -1
  96. data/lib/fuse_client/models/asset_report_accounts_inner_historical_balances_inner.rb +1 -1
  97. data/lib/fuse_client/models/asset_report_response.rb +1 -1
  98. data/lib/fuse_client/models/asset_report_transaction.rb +2 -2
  99. data/lib/fuse_client/models/country_code.rb +7 -2
  100. data/lib/fuse_client/models/create_asset_report_request.rb +1 -1
  101. data/lib/fuse_client/models/create_asset_report_response.rb +1 -1
  102. data/lib/fuse_client/models/create_entity_request.rb +1 -1
  103. data/lib/fuse_client/models/create_entity_response.rb +1 -1
  104. data/lib/fuse_client/models/create_link_token_request.rb +1 -1
  105. data/lib/fuse_client/models/create_link_token_request_mx.rb +1 -1
  106. data/lib/fuse_client/models/create_link_token_request_plaid.rb +1 -1
  107. data/lib/fuse_client/models/create_link_token_request_teller.rb +1 -1
  108. data/lib/fuse_client/models/create_link_token_request_teller_config.rb +14 -5
  109. data/lib/fuse_client/models/create_link_token_request_teller_config_account_filter.rb +229 -0
  110. data/lib/fuse_client/models/create_link_token_request_teller_config_account_filter_credit.rb +105 -0
  111. data/lib/fuse_client/models/create_link_token_request_teller_config_account_filter_credit_one_of.rb +243 -0
  112. data/lib/fuse_client/models/create_link_token_request_teller_config_account_filter_depository.rb +105 -0
  113. data/lib/fuse_client/models/create_link_token_request_teller_config_account_filter_depository_one_of.rb +243 -0
  114. data/lib/fuse_client/models/create_link_token_response.rb +1 -1
  115. data/lib/fuse_client/models/create_session_request.rb +2 -2
  116. data/lib/fuse_client/models/create_session_response.rb +1 -1
  117. data/lib/fuse_client/models/create_spend_power_customization_request.rb +357 -0
  118. data/lib/fuse_client/models/create_spend_power_customization_response.rb +1 -1
  119. data/lib/fuse_client/models/create_spend_power_request.rb +23 -23
  120. data/lib/fuse_client/models/create_spend_power_response.rb +2 -2
  121. data/lib/fuse_client/models/currency.rb +1 -1
  122. data/lib/fuse_client/models/delete_financial_connection_response.rb +1 -1
  123. data/lib/fuse_client/models/delete_spend_power_response.rb +12 -11
  124. data/lib/fuse_client/models/enrich_transactions_request.rb +226 -0
  125. data/lib/fuse_client/models/enrich_transactions_response.rb +222 -0
  126. data/lib/fuse_client/models/enriched_transaction.rb +407 -0
  127. data/lib/fuse_client/models/entity.rb +1 -1
  128. data/lib/fuse_client/models/eval_spend_power_request.rb +296 -0
  129. data/lib/fuse_client/models/eval_spend_power_request_events_inner.rb +239 -0
  130. data/lib/fuse_client/models/eval_spend_power_response.rb +250 -0
  131. data/lib/fuse_client/models/exchange_financial_connections_public_token_request.rb +1 -1
  132. data/lib/fuse_client/models/exchange_financial_connections_public_token_response.rb +1 -1
  133. data/lib/fuse_client/models/external_transaction_event.rb +370 -0
  134. data/lib/fuse_client/models/external_transaction_event_status.rb +40 -0
  135. data/lib/fuse_client/models/fin_ql_comparison_feature.rb +255 -0
  136. data/lib/fuse_client/models/fin_ql_feature.rb +111 -0
  137. data/lib/fuse_client/models/fin_ql_feature_one_of.rb +219 -0
  138. data/lib/fuse_client/models/fin_ql_feature_one_of1.rb +219 -0
  139. data/lib/fuse_client/models/fin_ql_feature_one_of2.rb +221 -0
  140. data/lib/fuse_client/models/fin_ql_feature_one_of3.rb +219 -0
  141. data/lib/fuse_client/models/fin_ql_feature_one_of4.rb +219 -0
  142. data/lib/fuse_client/models/fin_ql_feature_one_of5.rb +221 -0
  143. data/lib/fuse_client/models/fin_ql_feature_one_of6.rb +219 -0
  144. data/lib/fuse_client/models/fin_ql_feature_one_of7.rb +221 -0
  145. data/lib/fuse_client/models/fin_ql_feature_request.rb +46 -0
  146. data/lib/fuse_client/models/fin_ql_frequency_feature.rb +262 -0
  147. data/lib/fuse_client/models/fin_ql_individual_merchant_feature.rb +228 -0
  148. data/lib/fuse_client/models/fin_ql_interest_feature.rb +219 -0
  149. data/lib/fuse_client/models/fin_ql_merchant_categories_feature_inner.rb +230 -0
  150. data/lib/fuse_client/models/fin_ql_merchant_categories_feature_inner_result_inner.rb +228 -0
  151. data/lib/fuse_client/models/fin_ql_prompt_request.rb +276 -0
  152. data/lib/fuse_client/models/fin_ql_prompt_response.rb +234 -0
  153. data/lib/fuse_client/models/fin_ql_time_based_feature_inner.rb +228 -0
  154. data/lib/fuse_client/models/fin_ql_top_merchants_feature_inner.rb +237 -0
  155. data/lib/fuse_client/models/finance_score.rb +315 -0
  156. data/lib/fuse_client/models/financial_connection_data.rb +1 -1
  157. data/lib/fuse_client/models/financial_connection_details.rb +32 -5
  158. data/lib/fuse_client/models/financial_connection_details_flinks.rb +226 -0
  159. data/lib/fuse_client/models/financial_connection_details_mono.rb +226 -0
  160. data/lib/fuse_client/models/financial_connection_details_mx.rb +1 -1
  161. data/lib/fuse_client/models/financial_connection_details_plaid.rb +1 -1
  162. data/lib/fuse_client/models/financial_connection_details_snaptrade.rb +256 -0
  163. data/lib/fuse_client/models/financial_connection_details_teller.rb +1 -1
  164. data/lib/fuse_client/models/financial_connections_account.rb +16 -6
  165. data/lib/fuse_client/models/financial_connections_account_balance.rb +3 -3
  166. data/lib/fuse_client/models/financial_connections_account_cached_balance.rb +3 -3
  167. data/lib/fuse_client/models/financial_connections_account_details.rb +15 -5
  168. data/lib/fuse_client/models/financial_connections_account_details_ach.rb +1 -1
  169. data/lib/fuse_client/models/financial_connections_account_institution.rb +1 -1
  170. data/lib/fuse_client/models/financial_connections_account_liability.rb +13 -3
  171. data/lib/fuse_client/models/financial_connections_account_liability_all_of.rb +1 -1
  172. data/lib/fuse_client/models/financial_connections_account_liability_all_of_aprs.rb +1 -1
  173. data/lib/fuse_client/models/financial_connections_holding.rb +4 -4
  174. data/lib/fuse_client/models/financial_connections_investment_security.rb +2 -2
  175. data/lib/fuse_client/models/financial_connections_investment_security_exchange.rb +1 -1
  176. data/lib/fuse_client/models/financial_connections_investment_security_type.rb +1 -1
  177. data/lib/fuse_client/models/financial_connections_investment_transaction.rb +14 -5
  178. data/lib/fuse_client/models/financial_connections_investment_transaction_subtype.rb +87 -0
  179. data/lib/fuse_client/models/financial_connections_owner.rb +1 -1
  180. data/lib/fuse_client/models/financial_connections_owner_addresses_inner.rb +1 -1
  181. data/lib/fuse_client/models/financial_connections_owner_addresses_inner_data.rb +1 -1
  182. data/lib/fuse_client/models/financial_connections_owner_emails_inner.rb +1 -1
  183. data/lib/fuse_client/models/financial_connections_owner_names_inner.rb +1 -1
  184. data/lib/fuse_client/models/financial_connections_owner_phone_numbers_inner.rb +1 -1
  185. data/lib/fuse_client/models/financial_institution.rb +1 -1
  186. data/lib/fuse_client/models/financial_institution_logo.rb +1 -1
  187. data/lib/fuse_client/models/fuse_api_aggregator_error.rb +1 -1
  188. data/lib/fuse_client/models/fuse_api_error.rb +1 -1
  189. data/lib/fuse_client/models/fuse_api_error_code.rb +7 -2
  190. data/lib/fuse_client/models/fuse_api_error_data.rb +1 -1
  191. data/lib/fuse_client/models/fuse_api_error_type.rb +1 -1
  192. data/lib/fuse_client/models/fuse_api_warning.rb +1 -1
  193. data/lib/fuse_client/models/fuse_api_warning_data.rb +1 -1
  194. data/lib/fuse_client/models/fuse_api_warning_data_warnings_inner.rb +1 -1
  195. data/lib/fuse_client/models/get_asset_report_request.rb +1 -1
  196. data/lib/fuse_client/models/get_entity_response.rb +1 -1
  197. data/lib/fuse_client/models/get_finance_score_response.rb +239 -0
  198. data/lib/fuse_client/models/get_financial_connection_response.rb +1 -1
  199. data/lib/fuse_client/models/get_financial_connections_account_details_request.rb +1 -1
  200. data/lib/fuse_client/models/get_financial_connections_account_details_response.rb +1 -1
  201. data/lib/fuse_client/models/get_financial_connections_account_statement_request.rb +1 -1
  202. data/lib/fuse_client/models/get_financial_connections_account_statement_response.rb +1 -1
  203. data/lib/fuse_client/models/get_financial_connections_accounts_request.rb +1 -1
  204. data/lib/fuse_client/models/get_financial_connections_accounts_response.rb +1 -1
  205. data/lib/fuse_client/models/get_financial_connections_balance_request.rb +1 -1
  206. data/lib/fuse_client/models/get_financial_connections_balance_request_options.rb +1 -1
  207. data/lib/fuse_client/models/get_financial_connections_balance_response.rb +1 -1
  208. data/lib/fuse_client/models/get_financial_connections_owners_request.rb +1 -1
  209. data/lib/fuse_client/models/get_financial_connections_owners_response.rb +1 -1
  210. data/lib/fuse_client/models/get_financial_connections_owners_response_accounts_inner.rb +1 -1
  211. data/lib/fuse_client/models/get_financial_connections_transactions_request.rb +1 -1
  212. data/lib/fuse_client/models/get_financial_connections_transactions_response.rb +1 -1
  213. data/lib/fuse_client/models/get_financial_institution_response.rb +1 -1
  214. data/lib/fuse_client/models/get_investment_holdings_request.rb +1 -1
  215. data/lib/fuse_client/models/get_investment_holdings_request_options.rb +1 -1
  216. data/lib/fuse_client/models/get_investment_holdings_response.rb +1 -1
  217. data/lib/fuse_client/models/get_investment_transactions_request.rb +38 -10
  218. data/lib/fuse_client/models/get_investment_transactions_request_options.rb +1 -1
  219. data/lib/fuse_client/models/get_investment_transactions_response.rb +1 -1
  220. data/lib/fuse_client/models/get_liabilities_request.rb +1 -1
  221. data/lib/fuse_client/models/get_liabilities_response.rb +1 -1
  222. data/lib/fuse_client/models/get_spend_power_customization_response.rb +239 -0
  223. data/lib/fuse_client/models/get_spend_power_response.rb +1 -1
  224. data/lib/fuse_client/models/in_app_transaction_event.rb +369 -0
  225. data/lib/fuse_client/models/in_app_transaction_event_status.rb +41 -0
  226. data/lib/fuse_client/models/merchant.rb +249 -0
  227. data/lib/fuse_client/models/merchant_logo.rb +220 -0
  228. data/lib/fuse_client/models/migrate_financial_connections_aggregator_connection_data.rb +1 -1
  229. data/lib/fuse_client/models/migrate_financial_connections_aggregator_connection_data_mx.rb +1 -1
  230. data/lib/fuse_client/models/migrate_financial_connections_aggregator_connection_data_plaid.rb +1 -1
  231. data/lib/fuse_client/models/migrate_financial_connections_aggregator_connection_data_teller.rb +1 -1
  232. data/lib/fuse_client/models/migrate_financial_connections_token_request.rb +1 -1
  233. data/lib/fuse_client/models/migrate_financial_connections_token_request_entity.rb +1 -1
  234. data/lib/fuse_client/models/migrate_financial_connections_token_response.rb +1 -1
  235. data/lib/fuse_client/models/product.rb +1 -1
  236. data/lib/fuse_client/models/refresh_asset_report_request.rb +1 -1
  237. data/lib/fuse_client/models/refresh_asset_report_response.rb +1 -1
  238. data/lib/fuse_client/models/spend_power.rb +51 -22
  239. data/lib/fuse_client/models/spend_power_customization.rb +91 -17
  240. data/lib/fuse_client/models/spend_power_time_frame.rb +41 -0
  241. data/lib/fuse_client/models/sync_financial_connections_data_response.rb +1 -1
  242. data/lib/fuse_client/models/sync_transactions_request.rb +1 -1
  243. data/lib/fuse_client/models/sync_transactions_response.rb +1 -1
  244. data/lib/fuse_client/models/sync_transactions_response_removed_inner.rb +1 -1
  245. data/lib/fuse_client/models/transaction.rb +13 -3
  246. data/lib/fuse_client/models/transaction_category.rb +260 -0
  247. data/lib/fuse_client/models/transaction_category_detailed.rb +156 -0
  248. data/lib/fuse_client/models/transaction_category_primary.rb +59 -0
  249. data/lib/fuse_client/models/transaction_event_type.rb +65 -0
  250. data/lib/fuse_client/models/transaction_merchant.rb +1 -1
  251. data/lib/fuse_client/models/{add_spend_power_transaction_request.rb → transaction_to_enrich.rb} +48 -28
  252. data/lib/fuse_client/models/update_entity_request.rb +1 -1
  253. data/lib/fuse_client/models/update_entity_response.rb +1 -1
  254. data/lib/fuse_client/models/update_spend_power_customization_request.rb +325 -0
  255. data/lib/fuse_client/models/update_spend_power_customization_response.rb +1 -1
  256. data/lib/fuse_client/models/updated_balance_event.rb +308 -0
  257. data/lib/fuse_client/models/webhook_event.rb +1 -1
  258. data/lib/fuse_client/models/webhook_source.rb +3 -2
  259. data/lib/fuse_client/models/webhook_type.rb +1 -1
  260. data/lib/fuse_client/version.rb +2 -2
  261. data/lib/fuse_client.rb +57 -3
  262. data/spec/api/fuse_api_spec.rb +72 -34
  263. data/spec/api/spend_power_api_spec.rb +16 -19
  264. data/spec/api_client_spec.rb +1 -1
  265. data/spec/configuration_spec.rb +1 -1
  266. data/spec/models/account_subtype_spec.rb +1 -1
  267. data/spec/models/account_type_spec.rb +1 -1
  268. data/spec/models/add_account_events_request_events_inner_spec.rb +31 -0
  269. data/spec/models/add_account_events_request_spec.rb +34 -0
  270. data/spec/models/add_account_events_response_spec.rb +40 -0
  271. data/spec/models/aggregator_spec.rb +1 -1
  272. data/spec/models/asset_report_accounts_inner_balance_spec.rb +4 -4
  273. data/spec/models/asset_report_accounts_inner_historical_balances_inner_spec.rb +4 -4
  274. data/spec/models/asset_report_accounts_inner_spec.rb +5 -5
  275. data/spec/models/asset_report_response_spec.rb +3 -3
  276. data/spec/models/asset_report_spec.rb +6 -6
  277. data/spec/models/asset_report_transaction_spec.rb +11 -11
  278. data/spec/models/country_code_spec.rb +1 -1
  279. data/spec/models/create_asset_report_request_spec.rb +3 -3
  280. data/spec/models/create_asset_report_response_spec.rb +4 -4
  281. data/spec/models/create_entity_request_spec.rb +5 -5
  282. data/spec/models/create_entity_response_spec.rb +6 -6
  283. data/spec/models/create_link_token_request_mx_spec.rb +2 -2
  284. data/spec/models/create_link_token_request_plaid_spec.rb +2 -2
  285. data/spec/models/create_link_token_request_spec.rb +9 -9
  286. data/spec/models/create_link_token_request_teller_config_account_filter_credit_one_of_spec.rb +38 -0
  287. data/spec/models/create_link_token_request_teller_config_account_filter_credit_spec.rb +31 -0
  288. data/spec/models/create_link_token_request_teller_config_account_filter_depository_one_of_spec.rb +38 -0
  289. data/spec/models/create_link_token_request_teller_config_account_filter_depository_spec.rb +31 -0
  290. data/spec/models/create_link_token_request_teller_config_account_filter_spec.rb +40 -0
  291. data/spec/models/create_link_token_request_teller_config_spec.rb +8 -2
  292. data/spec/models/create_link_token_request_teller_spec.rb +2 -2
  293. data/spec/models/create_link_token_response_spec.rb +3 -3
  294. data/spec/models/create_session_request_spec.rb +7 -7
  295. data/spec/models/create_session_response_spec.rb +4 -4
  296. data/spec/models/create_spend_power_customization_request_spec.rb +52 -0
  297. data/spec/models/create_spend_power_customization_response_spec.rb +3 -3
  298. data/spec/models/create_spend_power_request_spec.rb +6 -6
  299. data/spec/models/create_spend_power_response_spec.rb +3 -3
  300. data/spec/models/currency_spec.rb +3 -3
  301. data/spec/models/delete_financial_connection_response_spec.rb +4 -4
  302. data/spec/models/delete_spend_power_response_spec.rb +4 -4
  303. data/spec/models/enrich_transactions_request_spec.rb +34 -0
  304. data/spec/models/enrich_transactions_response_spec.rb +34 -0
  305. data/spec/models/enriched_transaction_spec.rb +128 -0
  306. data/spec/models/entity_spec.rb +4 -4
  307. data/spec/models/eval_spend_power_request_events_inner_spec.rb +40 -0
  308. data/spec/models/eval_spend_power_request_spec.rb +46 -0
  309. data/spec/models/eval_spend_power_response_spec.rb +52 -0
  310. data/spec/models/exchange_financial_connections_public_token_request_spec.rb +2 -2
  311. data/spec/models/exchange_financial_connections_public_token_response_spec.rb +4 -4
  312. data/spec/models/external_transaction_event_spec.rb +86 -0
  313. data/spec/models/external_transaction_event_status_spec.rb +28 -0
  314. data/spec/models/fin_ql_comparison_feature_spec.rb +58 -0
  315. data/spec/models/fin_ql_feature_one_of1_spec.rb +34 -0
  316. data/spec/models/fin_ql_feature_one_of2_spec.rb +34 -0
  317. data/spec/models/fin_ql_feature_one_of3_spec.rb +34 -0
  318. data/spec/models/fin_ql_feature_one_of4_spec.rb +34 -0
  319. data/spec/models/fin_ql_feature_one_of5_spec.rb +34 -0
  320. data/spec/models/fin_ql_feature_one_of6_spec.rb +34 -0
  321. data/spec/models/fin_ql_feature_one_of7_spec.rb +34 -0
  322. data/spec/models/fin_ql_feature_one_of_spec.rb +34 -0
  323. data/spec/models/fin_ql_feature_request_spec.rb +28 -0
  324. data/spec/models/fin_ql_feature_spec.rb +31 -0
  325. data/spec/models/fin_ql_frequency_feature_spec.rb +44 -0
  326. data/spec/models/fin_ql_individual_merchant_feature_spec.rb +40 -0
  327. data/spec/models/fin_ql_interest_feature_spec.rb +34 -0
  328. data/spec/models/fin_ql_merchant_categories_feature_inner_result_inner_spec.rb +40 -0
  329. data/spec/models/fin_ql_merchant_categories_feature_inner_spec.rb +40 -0
  330. data/spec/models/fin_ql_prompt_request_spec.rb +46 -0
  331. data/spec/models/fin_ql_prompt_response_spec.rb +40 -0
  332. data/spec/models/fin_ql_time_based_feature_inner_spec.rb +40 -0
  333. data/spec/models/fin_ql_top_merchants_feature_inner_spec.rb +46 -0
  334. data/spec/models/finance_score_spec.rb +70 -0
  335. data/spec/models/financial_connection_data_spec.rb +3 -3
  336. data/spec/models/financial_connection_details_flinks_spec.rb +34 -0
  337. data/spec/models/financial_connection_details_mono_spec.rb +34 -0
  338. data/spec/models/financial_connection_details_mx_spec.rb +3 -3
  339. data/spec/models/financial_connection_details_plaid_spec.rb +3 -3
  340. data/spec/models/financial_connection_details_snaptrade_spec.rb +46 -0
  341. data/spec/models/financial_connection_details_spec.rb +27 -9
  342. data/spec/models/financial_connection_details_teller_spec.rb +3 -3
  343. data/spec/models/financial_connections_account_balance_spec.rb +6 -6
  344. data/spec/models/financial_connections_account_cached_balance_spec.rb +5 -5
  345. data/spec/models/financial_connections_account_details_ach_spec.rb +5 -5
  346. data/spec/models/financial_connections_account_details_spec.rb +9 -3
  347. data/spec/models/financial_connections_account_institution_spec.rb +2 -2
  348. data/spec/models/financial_connections_account_liability_all_of_aprs_spec.rb +3 -3
  349. data/spec/models/financial_connections_account_liability_all_of_spec.rb +8 -8
  350. data/spec/models/financial_connections_account_liability_spec.rb +22 -16
  351. data/spec/models/financial_connections_account_spec.rb +15 -9
  352. data/spec/models/financial_connections_holding_spec.rb +7 -7
  353. data/spec/models/financial_connections_investment_security_exchange_spec.rb +2 -2
  354. data/spec/models/financial_connections_investment_security_spec.rb +11 -11
  355. data/spec/models/financial_connections_investment_security_type_spec.rb +1 -1
  356. data/spec/models/financial_connections_investment_transaction_spec.rb +19 -13
  357. data/spec/models/financial_connections_investment_transaction_subtype_spec.rb +28 -0
  358. data/spec/models/financial_connections_owner_addresses_inner_data_spec.rb +6 -6
  359. data/spec/models/financial_connections_owner_addresses_inner_spec.rb +3 -3
  360. data/spec/models/financial_connections_owner_emails_inner_spec.rb +4 -4
  361. data/spec/models/financial_connections_owner_names_inner_spec.rb +3 -3
  362. data/spec/models/financial_connections_owner_phone_numbers_inner_spec.rb +4 -4
  363. data/spec/models/financial_connections_owner_spec.rb +5 -5
  364. data/spec/models/financial_institution_logo_spec.rb +4 -4
  365. data/spec/models/financial_institution_spec.rb +6 -6
  366. data/spec/models/fuse_api_aggregator_error_spec.rb +7 -7
  367. data/spec/models/fuse_api_error_code_spec.rb +1 -1
  368. data/spec/models/fuse_api_error_data_spec.rb +3 -3
  369. data/spec/models/fuse_api_error_spec.rb +8 -8
  370. data/spec/models/fuse_api_error_type_spec.rb +1 -1
  371. data/spec/models/fuse_api_warning_data_spec.rb +3 -3
  372. data/spec/models/fuse_api_warning_data_warnings_inner_spec.rb +6 -6
  373. data/spec/models/fuse_api_warning_spec.rb +7 -7
  374. data/spec/models/get_asset_report_request_spec.rb +3 -3
  375. data/spec/models/get_entity_response_spec.rb +7 -7
  376. data/spec/models/get_finance_score_response_spec.rb +40 -0
  377. data/spec/models/get_financial_connection_response_spec.rb +3 -3
  378. data/spec/models/get_financial_connections_account_details_request_spec.rb +2 -2
  379. data/spec/models/get_financial_connections_account_details_response_spec.rb +4 -4
  380. data/spec/models/get_financial_connections_account_statement_request_spec.rb +4 -4
  381. data/spec/models/get_financial_connections_account_statement_response_spec.rb +3 -3
  382. data/spec/models/get_financial_connections_accounts_request_spec.rb +2 -2
  383. data/spec/models/get_financial_connections_accounts_response_spec.rb +4 -4
  384. data/spec/models/get_financial_connections_balance_request_options_spec.rb +2 -2
  385. data/spec/models/get_financial_connections_balance_request_spec.rb +3 -3
  386. data/spec/models/get_financial_connections_balance_response_spec.rb +3 -3
  387. data/spec/models/get_financial_connections_owners_request_spec.rb +2 -2
  388. data/spec/models/get_financial_connections_owners_response_accounts_inner_spec.rb +4 -4
  389. data/spec/models/get_financial_connections_owners_response_spec.rb +2 -2
  390. data/spec/models/get_financial_connections_transactions_request_spec.rb +6 -6
  391. data/spec/models/get_financial_connections_transactions_response_spec.rb +4 -4
  392. data/spec/models/get_financial_institution_response_spec.rb +3 -3
  393. data/spec/models/get_investment_holdings_request_options_spec.rb +2 -2
  394. data/spec/models/get_investment_holdings_request_spec.rb +3 -3
  395. data/spec/models/get_investment_holdings_response_spec.rb +4 -4
  396. data/spec/models/get_investment_transactions_request_options_spec.rb +2 -2
  397. data/spec/models/get_investment_transactions_request_spec.rb +7 -7
  398. data/spec/models/get_investment_transactions_response_spec.rb +5 -5
  399. data/spec/models/get_liabilities_request_spec.rb +2 -2
  400. data/spec/models/get_liabilities_response_spec.rb +3 -3
  401. data/spec/models/get_spend_power_customization_response_spec.rb +40 -0
  402. data/spec/models/get_spend_power_response_spec.rb +3 -3
  403. data/spec/models/in_app_transaction_event_spec.rb +86 -0
  404. data/spec/models/in_app_transaction_event_status_spec.rb +28 -0
  405. data/spec/models/merchant_logo_spec.rb +34 -0
  406. data/spec/models/merchant_spec.rb +46 -0
  407. data/spec/models/migrate_financial_connections_aggregator_connection_data_mx_spec.rb +3 -3
  408. data/spec/models/migrate_financial_connections_aggregator_connection_data_plaid_spec.rb +3 -3
  409. data/spec/models/migrate_financial_connections_aggregator_connection_data_spec.rb +4 -4
  410. data/spec/models/migrate_financial_connections_aggregator_connection_data_teller_spec.rb +2 -2
  411. data/spec/models/migrate_financial_connections_token_request_entity_spec.rb +2 -2
  412. data/spec/models/migrate_financial_connections_token_request_spec.rb +5 -5
  413. data/spec/models/migrate_financial_connections_token_response_spec.rb +5 -5
  414. data/spec/models/product_spec.rb +1 -1
  415. data/spec/models/refresh_asset_report_request_spec.rb +4 -4
  416. data/spec/models/refresh_asset_report_response_spec.rb +4 -4
  417. data/spec/models/spend_power_customization_spec.rb +16 -8
  418. data/spec/models/spend_power_spec.rb +21 -9
  419. data/spec/models/spend_power_time_frame_spec.rb +28 -0
  420. data/spec/models/sync_financial_connections_data_response_spec.rb +3 -3
  421. data/spec/models/sync_transactions_request_spec.rb +4 -4
  422. data/spec/models/sync_transactions_response_removed_inner_spec.rb +2 -2
  423. data/spec/models/sync_transactions_response_spec.rb +7 -7
  424. data/spec/models/transaction_category_detailed_spec.rb +28 -0
  425. data/spec/models/transaction_category_primary_spec.rb +28 -0
  426. data/spec/models/transaction_category_spec.rb +40 -0
  427. data/spec/models/transaction_event_type_spec.rb +28 -0
  428. data/spec/models/transaction_merchant_spec.rb +2 -2
  429. data/spec/models/transaction_spec.rb +18 -12
  430. data/spec/models/transaction_to_enrich_spec.rb +62 -0
  431. data/spec/models/update_entity_request_spec.rb +4 -4
  432. data/spec/models/update_entity_response_spec.rb +6 -6
  433. data/spec/models/update_spend_power_customization_request_spec.rb +52 -0
  434. data/spec/models/update_spend_power_customization_response_spec.rb +3 -3
  435. data/spec/models/updated_balance_event_spec.rb +62 -0
  436. data/spec/models/webhook_event_spec.rb +10 -10
  437. data/spec/models/webhook_source_spec.rb +1 -1
  438. data/spec/models/webhook_type_spec.rb +1 -1
  439. data/spec/spec_helper.rb +1 -1
  440. metadata +226 -10
  441. data/docs/AddSpendPowerTransactionRequest.md +0 -22
  442. data/spec/models/add_spend_power_transaction_request_spec.rb +0 -50
  443. data/spec/models/add_spend_power_transaction_response_spec.rb +0 -40
@@ -0,0 +1,239 @@
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.6.0
10
+
11
+ =end
12
+
13
+ require 'date'
14
+ require 'time'
15
+
16
+ module FuseClient
17
+ class GetSpendPowerCustomizationResponse
18
+ attr_accessor :spend_power_customization
19
+
20
+ # An identifier that is exclusive to the request and can serve as a means for investigating and resolving issues.
21
+ attr_accessor :request_id
22
+
23
+ # Attribute mapping from ruby-style variable name to JSON key.
24
+ def self.attribute_map
25
+ {
26
+ :'spend_power_customization' => :'spend_power_customization',
27
+ :'request_id' => :'request_id'
28
+ }
29
+ end
30
+
31
+ # Returns all the JSON keys this model knows about
32
+ def self.acceptable_attributes
33
+ attribute_map.values
34
+ end
35
+
36
+ # Attribute type mapping.
37
+ def self.openapi_types
38
+ {
39
+ :'spend_power_customization' => :'SpendPowerCustomization',
40
+ :'request_id' => :'String'
41
+ }
42
+ end
43
+
44
+ # List of attributes with nullable: true
45
+ def self.openapi_nullable
46
+ Set.new([
47
+ ])
48
+ end
49
+
50
+ # Initializes the object
51
+ # @param [Hash] attributes Model attributes in the form of hash
52
+ def initialize(attributes = {})
53
+ if (!attributes.is_a?(Hash))
54
+ fail ArgumentError, "The input argument (attributes) must be a hash in `FuseClient::GetSpendPowerCustomizationResponse` initialize method"
55
+ end
56
+
57
+ # check to see if the attribute exists and convert string to symbol for hash key
58
+ attributes = attributes.each_with_object({}) { |(k, v), h|
59
+ if (!self.class.attribute_map.key?(k.to_sym))
60
+ fail ArgumentError, "`#{k}` is not a valid attribute in `FuseClient::GetSpendPowerCustomizationResponse`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
61
+ end
62
+ h[k.to_sym] = v
63
+ }
64
+
65
+ if attributes.key?(:'spend_power_customization')
66
+ self.spend_power_customization = attributes[:'spend_power_customization']
67
+ end
68
+
69
+ if attributes.key?(:'request_id')
70
+ self.request_id = attributes[:'request_id']
71
+ end
72
+ end
73
+
74
+ # Show invalid properties with the reasons. Usually used together with valid?
75
+ # @return Array for valid properties with the reasons
76
+ def list_invalid_properties
77
+ invalid_properties = Array.new
78
+ if @spend_power_customization.nil?
79
+ invalid_properties.push('invalid value for "spend_power_customization", spend_power_customization cannot be nil.')
80
+ end
81
+
82
+ if @request_id.nil?
83
+ invalid_properties.push('invalid value for "request_id", request_id cannot be nil.')
84
+ end
85
+
86
+ invalid_properties
87
+ end
88
+
89
+ # Check to see if the all the properties in the model are valid
90
+ # @return true if the model is valid
91
+ def valid?
92
+ return false if @spend_power_customization.nil?
93
+ return false if @request_id.nil?
94
+ true
95
+ end
96
+
97
+ # Checks equality by comparing each attribute.
98
+ # @param [Object] Object to be compared
99
+ def ==(o)
100
+ return true if self.equal?(o)
101
+ self.class == o.class &&
102
+ spend_power_customization == o.spend_power_customization &&
103
+ request_id == o.request_id
104
+ end
105
+
106
+ # @see the `==` method
107
+ # @param [Object] Object to be compared
108
+ def eql?(o)
109
+ self == o
110
+ end
111
+
112
+ # Calculates hash code according to all attributes.
113
+ # @return [Integer] Hash code
114
+ def hash
115
+ [spend_power_customization, request_id].hash
116
+ end
117
+
118
+ # Builds the object from hash
119
+ # @param [Hash] attributes Model attributes in the form of hash
120
+ # @return [Object] Returns the model itself
121
+ def self.build_from_hash(attributes)
122
+ new.build_from_hash(attributes)
123
+ end
124
+
125
+ # Builds the object from hash
126
+ # @param [Hash] attributes Model attributes in the form of hash
127
+ # @return [Object] Returns the model itself
128
+ def build_from_hash(attributes)
129
+ return nil unless attributes.is_a?(Hash)
130
+ attributes = attributes.transform_keys(&:to_sym)
131
+ self.class.openapi_types.each_pair do |key, type|
132
+ if attributes[self.class.attribute_map[key]].nil? && self.class.openapi_nullable.include?(key)
133
+ self.send("#{key}=", nil)
134
+ elsif type =~ /\AArray<(.*)>/i
135
+ # check to ensure the input is an array given that the attribute
136
+ # is documented as an array but the input is not
137
+ if attributes[self.class.attribute_map[key]].is_a?(Array)
138
+ self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
139
+ end
140
+ elsif !attributes[self.class.attribute_map[key]].nil?
141
+ self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
142
+ end
143
+ end
144
+
145
+ self
146
+ end
147
+
148
+ # Deserializes the data based on type
149
+ # @param string type Data type
150
+ # @param string value Value to be deserialized
151
+ # @return [Object] Deserialized data
152
+ def _deserialize(type, value)
153
+ case type.to_sym
154
+ when :Time
155
+ Time.parse(value)
156
+ when :Date
157
+ Date.parse(value)
158
+ when :String
159
+ value.to_s
160
+ when :Integer
161
+ value.to_i
162
+ when :Float
163
+ value.to_f
164
+ when :Boolean
165
+ if value.to_s =~ /\A(true|t|yes|y|1)\z/i
166
+ true
167
+ else
168
+ false
169
+ end
170
+ when :Object
171
+ # generic object (usually a Hash), return directly
172
+ value
173
+ when /\AArray<(?<inner_type>.+)>\z/
174
+ inner_type = Regexp.last_match[:inner_type]
175
+ value.map { |v| _deserialize(inner_type, v) }
176
+ when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
177
+ k_type = Regexp.last_match[:k_type]
178
+ v_type = Regexp.last_match[:v_type]
179
+ {}.tap do |hash|
180
+ value.each do |k, v|
181
+ hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
182
+ end
183
+ end
184
+ else # model
185
+ # models (e.g. Pet) or oneOf
186
+ klass = FuseClient.const_get(type)
187
+ klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
188
+ end
189
+ end
190
+
191
+ # Returns the string representation of the object
192
+ # @return [String] String presentation of the object
193
+ def to_s
194
+ to_hash.to_s
195
+ end
196
+
197
+ # to_body is an alias to to_hash (backward compatibility)
198
+ # @return [Hash] Returns the object in the form of hash
199
+ def to_body
200
+ to_hash
201
+ end
202
+
203
+ # Returns the object in the form of hash
204
+ # @return [Hash] Returns the object in the form of hash
205
+ def to_hash
206
+ hash = {}
207
+ self.class.attribute_map.each_pair do |attr, param|
208
+ value = self.send(attr)
209
+ if value.nil?
210
+ is_nullable = self.class.openapi_nullable.include?(attr)
211
+ next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
212
+ end
213
+
214
+ hash[param] = _to_hash(value)
215
+ end
216
+ hash
217
+ end
218
+
219
+ # Outputs non-array value in the form of hash
220
+ # For object, use to_hash. Otherwise, just return the value
221
+ # @param [Object] value Any valid value
222
+ # @return [Hash] Returns the value in the form of hash
223
+ def _to_hash(value)
224
+ if value.is_a?(Array)
225
+ value.compact.map { |v| _to_hash(v) }
226
+ elsif value.is_a?(Hash)
227
+ {}.tap do |hash|
228
+ value.each { |k, v| hash[k] = _to_hash(v) }
229
+ end
230
+ elsif value.respond_to? :to_hash
231
+ value.to_hash
232
+ else
233
+ value
234
+ end
235
+ end
236
+
237
+ end
238
+
239
+ 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.5.0
9
+ OpenAPI Generator version: 6.6.0
10
10
 
11
11
  =end
12
12
 
@@ -0,0 +1,369 @@
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.6.0
10
+
11
+ =end
12
+
13
+ require 'date'
14
+ require 'time'
15
+
16
+ module FuseClient
17
+ class InAppTransactionEvent
18
+ # ID of the transaction
19
+ attr_accessor :id
20
+
21
+ attr_accessor :event_type
22
+
23
+ attr_accessor :status
24
+
25
+ attr_accessor :amount
26
+
27
+ # The ISO-4217 currency code.
28
+ attr_accessor :iso_currency_code
29
+
30
+ attr_accessor :transaction_type
31
+
32
+ attr_accessor :merchant_name
33
+
34
+ # Datetime of the transaction In ISO-8601 format
35
+ attr_accessor :timestamp
36
+
37
+ # The running balance of the account after the transaction has occurred, in cents.
38
+ attr_accessor :balance
39
+
40
+ class EnumAttributeValidator
41
+ attr_reader :datatype
42
+ attr_reader :allowable_values
43
+
44
+ def initialize(datatype, allowable_values)
45
+ @allowable_values = allowable_values.map do |value|
46
+ case datatype.to_s
47
+ when /Integer/i
48
+ value.to_i
49
+ when /Float/i
50
+ value.to_f
51
+ else
52
+ value
53
+ end
54
+ end
55
+ end
56
+
57
+ def valid?(value)
58
+ !value || allowable_values.include?(value)
59
+ end
60
+ end
61
+
62
+ # Attribute mapping from ruby-style variable name to JSON key.
63
+ def self.attribute_map
64
+ {
65
+ :'id' => :'id',
66
+ :'event_type' => :'event_type',
67
+ :'status' => :'status',
68
+ :'amount' => :'amount',
69
+ :'iso_currency_code' => :'iso_currency_code',
70
+ :'transaction_type' => :'transaction_type',
71
+ :'merchant_name' => :'merchant_name',
72
+ :'timestamp' => :'timestamp',
73
+ :'balance' => :'balance'
74
+ }
75
+ end
76
+
77
+ # Returns all the JSON keys this model knows about
78
+ def self.acceptable_attributes
79
+ attribute_map.values
80
+ end
81
+
82
+ # Attribute type mapping.
83
+ def self.openapi_types
84
+ {
85
+ :'id' => :'String',
86
+ :'event_type' => :'String',
87
+ :'status' => :'InAppTransactionEventStatus',
88
+ :'amount' => :'Float',
89
+ :'iso_currency_code' => :'String',
90
+ :'transaction_type' => :'TransactionEventType',
91
+ :'merchant_name' => :'String',
92
+ :'timestamp' => :'String',
93
+ :'balance' => :'Float'
94
+ }
95
+ end
96
+
97
+ # List of attributes with nullable: true
98
+ def self.openapi_nullable
99
+ Set.new([
100
+ ])
101
+ end
102
+
103
+ # Initializes the object
104
+ # @param [Hash] attributes Model attributes in the form of hash
105
+ def initialize(attributes = {})
106
+ if (!attributes.is_a?(Hash))
107
+ fail ArgumentError, "The input argument (attributes) must be a hash in `FuseClient::InAppTransactionEvent` initialize method"
108
+ end
109
+
110
+ # check to see if the attribute exists and convert string to symbol for hash key
111
+ attributes = attributes.each_with_object({}) { |(k, v), h|
112
+ if (!self.class.attribute_map.key?(k.to_sym))
113
+ fail ArgumentError, "`#{k}` is not a valid attribute in `FuseClient::InAppTransactionEvent`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
114
+ end
115
+ h[k.to_sym] = v
116
+ }
117
+
118
+ if attributes.key?(:'id')
119
+ self.id = attributes[:'id']
120
+ end
121
+
122
+ if attributes.key?(:'event_type')
123
+ self.event_type = attributes[:'event_type']
124
+ end
125
+
126
+ if attributes.key?(:'status')
127
+ self.status = attributes[:'status']
128
+ end
129
+
130
+ if attributes.key?(:'amount')
131
+ self.amount = attributes[:'amount']
132
+ end
133
+
134
+ if attributes.key?(:'iso_currency_code')
135
+ self.iso_currency_code = attributes[:'iso_currency_code']
136
+ end
137
+
138
+ if attributes.key?(:'transaction_type')
139
+ self.transaction_type = attributes[:'transaction_type']
140
+ end
141
+
142
+ if attributes.key?(:'merchant_name')
143
+ self.merchant_name = attributes[:'merchant_name']
144
+ end
145
+
146
+ if attributes.key?(:'timestamp')
147
+ self.timestamp = attributes[:'timestamp']
148
+ end
149
+
150
+ if attributes.key?(:'balance')
151
+ self.balance = attributes[:'balance']
152
+ end
153
+ end
154
+
155
+ # Show invalid properties with the reasons. Usually used together with valid?
156
+ # @return Array for valid properties with the reasons
157
+ def list_invalid_properties
158
+ invalid_properties = Array.new
159
+ if @id.nil?
160
+ invalid_properties.push('invalid value for "id", id cannot be nil.')
161
+ end
162
+
163
+ if @event_type.nil?
164
+ invalid_properties.push('invalid value for "event_type", event_type cannot be nil.')
165
+ end
166
+
167
+ if @status.nil?
168
+ invalid_properties.push('invalid value for "status", status cannot be nil.')
169
+ end
170
+
171
+ if @amount.nil?
172
+ invalid_properties.push('invalid value for "amount", amount cannot be nil.')
173
+ end
174
+
175
+ if @iso_currency_code.nil?
176
+ invalid_properties.push('invalid value for "iso_currency_code", iso_currency_code cannot be nil.')
177
+ end
178
+
179
+ if @transaction_type.nil?
180
+ invalid_properties.push('invalid value for "transaction_type", transaction_type cannot be nil.')
181
+ end
182
+
183
+ if @merchant_name.nil?
184
+ invalid_properties.push('invalid value for "merchant_name", merchant_name cannot be nil.')
185
+ end
186
+
187
+ if @timestamp.nil?
188
+ invalid_properties.push('invalid value for "timestamp", timestamp cannot be nil.')
189
+ end
190
+
191
+ invalid_properties
192
+ end
193
+
194
+ # Check to see if the all the properties in the model are valid
195
+ # @return true if the model is valid
196
+ def valid?
197
+ return false if @id.nil?
198
+ return false if @event_type.nil?
199
+ event_type_validator = EnumAttributeValidator.new('String', ["in_app_transaction"])
200
+ return false unless event_type_validator.valid?(@event_type)
201
+ return false if @status.nil?
202
+ return false if @amount.nil?
203
+ return false if @iso_currency_code.nil?
204
+ return false if @transaction_type.nil?
205
+ return false if @merchant_name.nil?
206
+ return false if @timestamp.nil?
207
+ true
208
+ end
209
+
210
+ # Custom attribute writer method checking allowed values (enum).
211
+ # @param [Object] event_type Object to be assigned
212
+ def event_type=(event_type)
213
+ validator = EnumAttributeValidator.new('String', ["in_app_transaction"])
214
+ unless validator.valid?(event_type)
215
+ fail ArgumentError, "invalid value for \"event_type\", must be one of #{validator.allowable_values}."
216
+ end
217
+ @event_type = event_type
218
+ end
219
+
220
+ # Checks equality by comparing each attribute.
221
+ # @param [Object] Object to be compared
222
+ def ==(o)
223
+ return true if self.equal?(o)
224
+ self.class == o.class &&
225
+ id == o.id &&
226
+ event_type == o.event_type &&
227
+ status == o.status &&
228
+ amount == o.amount &&
229
+ iso_currency_code == o.iso_currency_code &&
230
+ transaction_type == o.transaction_type &&
231
+ merchant_name == o.merchant_name &&
232
+ timestamp == o.timestamp &&
233
+ balance == o.balance
234
+ end
235
+
236
+ # @see the `==` method
237
+ # @param [Object] Object to be compared
238
+ def eql?(o)
239
+ self == o
240
+ end
241
+
242
+ # Calculates hash code according to all attributes.
243
+ # @return [Integer] Hash code
244
+ def hash
245
+ [id, event_type, status, amount, iso_currency_code, transaction_type, merchant_name, timestamp, balance].hash
246
+ end
247
+
248
+ # Builds the object from hash
249
+ # @param [Hash] attributes Model attributes in the form of hash
250
+ # @return [Object] Returns the model itself
251
+ def self.build_from_hash(attributes)
252
+ new.build_from_hash(attributes)
253
+ end
254
+
255
+ # Builds the object from hash
256
+ # @param [Hash] attributes Model attributes in the form of hash
257
+ # @return [Object] Returns the model itself
258
+ def build_from_hash(attributes)
259
+ return nil unless attributes.is_a?(Hash)
260
+ attributes = attributes.transform_keys(&:to_sym)
261
+ self.class.openapi_types.each_pair do |key, type|
262
+ if attributes[self.class.attribute_map[key]].nil? && self.class.openapi_nullable.include?(key)
263
+ self.send("#{key}=", nil)
264
+ elsif type =~ /\AArray<(.*)>/i
265
+ # check to ensure the input is an array given that the attribute
266
+ # is documented as an array but the input is not
267
+ if attributes[self.class.attribute_map[key]].is_a?(Array)
268
+ self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
269
+ end
270
+ elsif !attributes[self.class.attribute_map[key]].nil?
271
+ self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
272
+ end
273
+ end
274
+
275
+ self
276
+ end
277
+
278
+ # Deserializes the data based on type
279
+ # @param string type Data type
280
+ # @param string value Value to be deserialized
281
+ # @return [Object] Deserialized data
282
+ def _deserialize(type, value)
283
+ case type.to_sym
284
+ when :Time
285
+ Time.parse(value)
286
+ when :Date
287
+ Date.parse(value)
288
+ when :String
289
+ value.to_s
290
+ when :Integer
291
+ value.to_i
292
+ when :Float
293
+ value.to_f
294
+ when :Boolean
295
+ if value.to_s =~ /\A(true|t|yes|y|1)\z/i
296
+ true
297
+ else
298
+ false
299
+ end
300
+ when :Object
301
+ # generic object (usually a Hash), return directly
302
+ value
303
+ when /\AArray<(?<inner_type>.+)>\z/
304
+ inner_type = Regexp.last_match[:inner_type]
305
+ value.map { |v| _deserialize(inner_type, v) }
306
+ when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
307
+ k_type = Regexp.last_match[:k_type]
308
+ v_type = Regexp.last_match[:v_type]
309
+ {}.tap do |hash|
310
+ value.each do |k, v|
311
+ hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
312
+ end
313
+ end
314
+ else # model
315
+ # models (e.g. Pet) or oneOf
316
+ klass = FuseClient.const_get(type)
317
+ klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
318
+ end
319
+ end
320
+
321
+ # Returns the string representation of the object
322
+ # @return [String] String presentation of the object
323
+ def to_s
324
+ to_hash.to_s
325
+ end
326
+
327
+ # to_body is an alias to to_hash (backward compatibility)
328
+ # @return [Hash] Returns the object in the form of hash
329
+ def to_body
330
+ to_hash
331
+ end
332
+
333
+ # Returns the object in the form of hash
334
+ # @return [Hash] Returns the object in the form of hash
335
+ def to_hash
336
+ hash = {}
337
+ self.class.attribute_map.each_pair do |attr, param|
338
+ value = self.send(attr)
339
+ if value.nil?
340
+ is_nullable = self.class.openapi_nullable.include?(attr)
341
+ next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
342
+ end
343
+
344
+ hash[param] = _to_hash(value)
345
+ end
346
+ hash
347
+ end
348
+
349
+ # Outputs non-array value in the form of hash
350
+ # For object, use to_hash. Otherwise, just return the value
351
+ # @param [Object] value Any valid value
352
+ # @return [Hash] Returns the value in the form of hash
353
+ def _to_hash(value)
354
+ if value.is_a?(Array)
355
+ value.compact.map { |v| _to_hash(v) }
356
+ elsif value.is_a?(Hash)
357
+ {}.tap do |hash|
358
+ value.each { |k, v| hash[k] = _to_hash(v) }
359
+ end
360
+ elsif value.respond_to? :to_hash
361
+ value.to_hash
362
+ else
363
+ value
364
+ end
365
+ end
366
+
367
+ end
368
+
369
+ end
@@ -0,0 +1,41 @@
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.6.0
10
+
11
+ =end
12
+
13
+ require 'date'
14
+ require 'time'
15
+
16
+ module FuseClient
17
+ class InAppTransactionEventStatus
18
+ PENDING = "pending".freeze
19
+ SUCCEEDED = "succeeded".freeze
20
+ FAILED = "failed".freeze
21
+
22
+ def self.all_vars
23
+ @all_vars ||= [PENDING, SUCCEEDED, FAILED].freeze
24
+ end
25
+
26
+ # Builds the enum from string
27
+ # @param [String] The enum value in the form of the string
28
+ # @return [String] The enum value
29
+ def self.build_from_hash(value)
30
+ new.build_from_hash(value)
31
+ end
32
+
33
+ # Builds the enum from string
34
+ # @param [String] The enum value in the form of the string
35
+ # @return [String] The enum value
36
+ def build_from_hash(value)
37
+ return value if InAppTransactionEventStatus.all_vars.include?(value)
38
+ raise "Invalid ENUM value #{value} for class #InAppTransactionEventStatus"
39
+ end
40
+ end
41
+ end