fuse_client 1.0.34 → 1.0.35
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/Gemfile.lock +4 -4
- data/README.md +1 -0
- data/docs/CreateLinkTokenRequestTellerConfig.md +3 -1
- data/docs/CreateLinkTokenRequestTellerConfigAccountFilter.md +20 -0
- data/docs/CreateLinkTokenRequestTellerConfigAccountFilterCredit.md +49 -0
- data/docs/CreateLinkTokenRequestTellerConfigAccountFilterCreditOneOf.md +18 -0
- data/docs/CreateLinkTokenRequestTellerConfigAccountFilterDepository.md +49 -0
- data/docs/CreateLinkTokenRequestTellerConfigAccountFilterDepositoryOneOf.md +18 -0
- data/docs/CreateSpendPowerCustomizationRequest.md +3 -1
- data/docs/EnrichedTransaction.md +3 -1
- data/docs/EvalSpendPowerResponse.md +8 -4
- data/docs/ExternalTransactionEvent.md +7 -9
- data/docs/FinQLComparisonFeature.md +26 -0
- data/docs/FinQLFeature.md +61 -0
- data/docs/FinQLFeatureOneOf.md +18 -0
- data/docs/FinQLFeatureOneOf1.md +18 -0
- data/docs/FinQLFeatureOneOf2.md +18 -0
- data/docs/FinQLFeatureOneOf3.md +18 -0
- data/docs/FinQLFeatureOneOf4.md +18 -0
- data/docs/FinQLFeatureOneOf5.md +18 -0
- data/docs/FinQLFeatureOneOf6.md +18 -0
- data/docs/FinQLFeatureOneOf7.md +18 -0
- data/docs/FinQLFeatureRequest.md +15 -0
- data/docs/FinQLFrequencyFeature.md +20 -0
- data/docs/FinQLIndividualMerchantFeature.md +20 -0
- data/docs/FinQLInterestFeature.md +18 -0
- data/docs/FinQLMerchantCategoriesFeatureInner.md +20 -0
- data/docs/FinQLMerchantCategoriesFeatureInnerResultInner.md +20 -0
- data/docs/FinQLPromptRequest.md +22 -0
- data/docs/FinQLPromptResponse.md +20 -0
- data/docs/FinQLTimeBasedFeatureInner.md +20 -0
- data/docs/FinQLTopMerchantsFeatureInner.md +22 -0
- data/docs/FinanceScore.md +30 -0
- data/docs/FinancialConnectionDetails.md +7 -1
- data/docs/FinancialConnectionDetailsFlinks.md +18 -0
- data/docs/FinancialConnectionDetailsMono.md +18 -0
- data/docs/FinancialConnectionDetailsSnaptrade.md +22 -0
- data/docs/FinancialConnectionsAccount.md +4 -2
- data/docs/FinancialConnectionsAccountDetails.md +3 -1
- data/docs/FinancialConnectionsAccountLiability.md +3 -1
- data/docs/FuseApi.md +81 -2
- data/docs/GetFinanceScoreResponse.md +1 -1
- data/docs/InAppTransactionEvent.md +7 -7
- data/docs/Merchant.md +22 -0
- data/docs/{EnrichedTransactionLogo.md → MerchantLogo.md} +2 -2
- data/docs/SpendPower.md +5 -1
- data/docs/SpendPowerCustomization.md +5 -3
- data/docs/Transaction.md +2 -0
- data/docs/TransactionToEnrich.md +1 -1
- data/docs/UpdateSpendPowerCustomizationRequest.md +3 -1
- data/docs/UpdatedBalanceEvent.md +5 -5
- data/fuse_client.gemspec +1 -1
- data/lib/fuse_client/api/fuse_api.rb +65 -1
- data/lib/fuse_client/api/spend_power_api.rb +1 -1
- data/lib/fuse_client/api_client.rb +1 -1
- data/lib/fuse_client/api_error.rb +1 -1
- data/lib/fuse_client/configuration.rb +11 -11
- data/lib/fuse_client/models/account_subtype.rb +1 -1
- data/lib/fuse_client/models/account_type.rb +1 -1
- data/lib/fuse_client/models/add_account_events_request.rb +1 -1
- data/lib/fuse_client/models/add_account_events_request_events_inner.rb +1 -1
- data/lib/fuse_client/models/add_account_events_response.rb +1 -1
- data/lib/fuse_client/models/aggregator.rb +3 -3
- data/lib/fuse_client/models/asset_report.rb +1 -1
- data/lib/fuse_client/models/asset_report_accounts_inner.rb +1 -1
- data/lib/fuse_client/models/asset_report_accounts_inner_balance.rb +1 -1
- data/lib/fuse_client/models/asset_report_accounts_inner_historical_balances_inner.rb +1 -1
- data/lib/fuse_client/models/asset_report_response.rb +1 -1
- data/lib/fuse_client/models/asset_report_transaction.rb +1 -1
- data/lib/fuse_client/models/country_code.rb +6 -2
- data/lib/fuse_client/models/create_asset_report_request.rb +1 -1
- data/lib/fuse_client/models/create_asset_report_response.rb +1 -1
- data/lib/fuse_client/models/create_entity_request.rb +1 -1
- data/lib/fuse_client/models/create_entity_response.rb +1 -1
- data/lib/fuse_client/models/create_link_token_request.rb +1 -1
- data/lib/fuse_client/models/create_link_token_request_mx.rb +1 -1
- data/lib/fuse_client/models/create_link_token_request_plaid.rb +1 -1
- data/lib/fuse_client/models/create_link_token_request_teller.rb +1 -1
- data/lib/fuse_client/models/create_link_token_request_teller_config.rb +14 -5
- data/lib/fuse_client/models/create_link_token_request_teller_config_account_filter.rb +229 -0
- data/lib/fuse_client/models/create_link_token_request_teller_config_account_filter_credit.rb +105 -0
- data/lib/fuse_client/models/create_link_token_request_teller_config_account_filter_credit_one_of.rb +243 -0
- data/lib/fuse_client/models/create_link_token_request_teller_config_account_filter_depository.rb +105 -0
- data/lib/fuse_client/models/create_link_token_request_teller_config_account_filter_depository_one_of.rb +243 -0
- data/lib/fuse_client/models/create_link_token_response.rb +1 -1
- data/lib/fuse_client/models/create_session_request.rb +1 -1
- data/lib/fuse_client/models/create_session_response.rb +1 -1
- data/lib/fuse_client/models/create_spend_power_customization_request.rb +48 -5
- data/lib/fuse_client/models/create_spend_power_customization_response.rb +1 -1
- data/lib/fuse_client/models/create_spend_power_request.rb +1 -1
- data/lib/fuse_client/models/create_spend_power_response.rb +1 -1
- data/lib/fuse_client/models/currency.rb +1 -1
- data/lib/fuse_client/models/delete_financial_connection_response.rb +1 -1
- data/lib/fuse_client/models/delete_spend_power_response.rb +1 -1
- data/lib/fuse_client/models/enrich_transactions_request.rb +1 -1
- data/lib/fuse_client/models/enrich_transactions_response.rb +1 -1
- data/lib/fuse_client/models/enriched_transaction.rb +13 -3
- data/lib/fuse_client/models/entity.rb +1 -1
- data/lib/fuse_client/models/eval_spend_power_request.rb +1 -1
- data/lib/fuse_client/models/eval_spend_power_request_events_inner.rb +1 -1
- data/lib/fuse_client/models/eval_spend_power_response.rb +36 -16
- data/lib/fuse_client/models/exchange_financial_connections_public_token_request.rb +1 -1
- data/lib/fuse_client/models/exchange_financial_connections_public_token_response.rb +1 -1
- data/lib/fuse_client/models/external_transaction_event.rb +34 -48
- data/lib/fuse_client/models/external_transaction_event_status.rb +1 -1
- data/lib/fuse_client/models/fin_ql_comparison_feature.rb +255 -0
- data/lib/fuse_client/models/fin_ql_feature.rb +111 -0
- data/lib/fuse_client/models/fin_ql_feature_one_of.rb +219 -0
- data/lib/fuse_client/models/fin_ql_feature_one_of1.rb +219 -0
- data/lib/fuse_client/models/fin_ql_feature_one_of2.rb +221 -0
- data/lib/fuse_client/models/fin_ql_feature_one_of3.rb +219 -0
- data/lib/fuse_client/models/fin_ql_feature_one_of4.rb +219 -0
- data/lib/fuse_client/models/fin_ql_feature_one_of5.rb +221 -0
- data/lib/fuse_client/models/fin_ql_feature_one_of6.rb +219 -0
- data/lib/fuse_client/models/fin_ql_feature_one_of7.rb +221 -0
- data/lib/fuse_client/models/fin_ql_feature_request.rb +46 -0
- data/lib/fuse_client/models/fin_ql_frequency_feature.rb +262 -0
- data/lib/fuse_client/models/fin_ql_individual_merchant_feature.rb +228 -0
- data/lib/fuse_client/models/fin_ql_interest_feature.rb +219 -0
- data/lib/fuse_client/models/fin_ql_merchant_categories_feature_inner.rb +230 -0
- data/lib/fuse_client/models/fin_ql_merchant_categories_feature_inner_result_inner.rb +228 -0
- data/lib/fuse_client/models/fin_ql_prompt_request.rb +276 -0
- data/lib/fuse_client/models/fin_ql_prompt_response.rb +234 -0
- data/lib/fuse_client/models/fin_ql_time_based_feature_inner.rb +228 -0
- data/lib/fuse_client/models/fin_ql_top_merchants_feature_inner.rb +237 -0
- data/lib/fuse_client/models/finance_score.rb +315 -0
- data/lib/fuse_client/models/financial_connection_data.rb +1 -1
- data/lib/fuse_client/models/financial_connection_details.rb +32 -5
- data/lib/fuse_client/models/financial_connection_details_flinks.rb +226 -0
- data/lib/fuse_client/models/financial_connection_details_mono.rb +226 -0
- data/lib/fuse_client/models/financial_connection_details_mx.rb +1 -1
- data/lib/fuse_client/models/financial_connection_details_plaid.rb +1 -1
- data/lib/fuse_client/models/financial_connection_details_snaptrade.rb +256 -0
- data/lib/fuse_client/models/financial_connection_details_teller.rb +1 -1
- data/lib/fuse_client/models/financial_connections_account.rb +16 -6
- data/lib/fuse_client/models/financial_connections_account_balance.rb +1 -1
- data/lib/fuse_client/models/financial_connections_account_cached_balance.rb +1 -1
- data/lib/fuse_client/models/financial_connections_account_details.rb +15 -5
- data/lib/fuse_client/models/financial_connections_account_details_ach.rb +1 -1
- data/lib/fuse_client/models/financial_connections_account_institution.rb +1 -1
- data/lib/fuse_client/models/financial_connections_account_liability.rb +13 -3
- data/lib/fuse_client/models/financial_connections_account_liability_all_of.rb +1 -1
- data/lib/fuse_client/models/financial_connections_account_liability_all_of_aprs.rb +1 -1
- data/lib/fuse_client/models/financial_connections_holding.rb +1 -1
- data/lib/fuse_client/models/financial_connections_investment_security.rb +1 -1
- data/lib/fuse_client/models/financial_connections_investment_security_exchange.rb +1 -1
- data/lib/fuse_client/models/financial_connections_investment_security_type.rb +1 -1
- data/lib/fuse_client/models/financial_connections_investment_transaction.rb +1 -1
- data/lib/fuse_client/models/financial_connections_investment_transaction_subtype.rb +1 -1
- data/lib/fuse_client/models/financial_connections_owner.rb +1 -1
- data/lib/fuse_client/models/financial_connections_owner_addresses_inner.rb +1 -1
- data/lib/fuse_client/models/financial_connections_owner_addresses_inner_data.rb +1 -1
- data/lib/fuse_client/models/financial_connections_owner_emails_inner.rb +1 -1
- data/lib/fuse_client/models/financial_connections_owner_names_inner.rb +1 -1
- data/lib/fuse_client/models/financial_connections_owner_phone_numbers_inner.rb +1 -1
- data/lib/fuse_client/models/financial_institution.rb +1 -1
- data/lib/fuse_client/models/financial_institution_logo.rb +1 -1
- data/lib/fuse_client/models/fuse_api_aggregator_error.rb +1 -1
- data/lib/fuse_client/models/fuse_api_error.rb +1 -1
- data/lib/fuse_client/models/fuse_api_error_code.rb +5 -2
- data/lib/fuse_client/models/fuse_api_error_data.rb +1 -1
- data/lib/fuse_client/models/fuse_api_error_type.rb +1 -1
- data/lib/fuse_client/models/fuse_api_warning.rb +1 -1
- data/lib/fuse_client/models/fuse_api_warning_data.rb +1 -1
- data/lib/fuse_client/models/fuse_api_warning_data_warnings_inner.rb +1 -1
- data/lib/fuse_client/models/get_asset_report_request.rb +1 -1
- data/lib/fuse_client/models/get_entity_response.rb +1 -1
- data/lib/fuse_client/models/get_finance_score_response.rb +2 -3
- data/lib/fuse_client/models/get_financial_connection_response.rb +1 -1
- data/lib/fuse_client/models/get_financial_connections_account_details_request.rb +1 -1
- data/lib/fuse_client/models/get_financial_connections_account_details_response.rb +1 -1
- data/lib/fuse_client/models/get_financial_connections_account_statement_request.rb +1 -1
- data/lib/fuse_client/models/get_financial_connections_account_statement_response.rb +1 -1
- data/lib/fuse_client/models/get_financial_connections_accounts_request.rb +1 -1
- data/lib/fuse_client/models/get_financial_connections_accounts_response.rb +1 -1
- data/lib/fuse_client/models/get_financial_connections_balance_request.rb +1 -1
- data/lib/fuse_client/models/get_financial_connections_balance_request_options.rb +1 -1
- data/lib/fuse_client/models/get_financial_connections_balance_response.rb +1 -1
- data/lib/fuse_client/models/get_financial_connections_owners_request.rb +1 -1
- data/lib/fuse_client/models/get_financial_connections_owners_response.rb +1 -1
- data/lib/fuse_client/models/get_financial_connections_owners_response_accounts_inner.rb +1 -1
- data/lib/fuse_client/models/get_financial_connections_transactions_request.rb +1 -1
- data/lib/fuse_client/models/get_financial_connections_transactions_response.rb +1 -1
- data/lib/fuse_client/models/get_financial_institution_response.rb +1 -1
- data/lib/fuse_client/models/get_investment_holdings_request.rb +1 -1
- data/lib/fuse_client/models/get_investment_holdings_request_options.rb +1 -1
- data/lib/fuse_client/models/get_investment_holdings_response.rb +1 -1
- data/lib/fuse_client/models/get_investment_transactions_request.rb +1 -1
- data/lib/fuse_client/models/get_investment_transactions_request_options.rb +1 -1
- data/lib/fuse_client/models/get_investment_transactions_response.rb +1 -1
- data/lib/fuse_client/models/get_liabilities_request.rb +1 -1
- data/lib/fuse_client/models/get_liabilities_response.rb +1 -1
- data/lib/fuse_client/models/get_spend_power_customization_response.rb +1 -1
- data/lib/fuse_client/models/get_spend_power_response.rb +1 -1
- data/lib/fuse_client/models/in_app_transaction_event.rb +36 -31
- data/lib/fuse_client/models/in_app_transaction_event_status.rb +1 -1
- data/lib/fuse_client/models/merchant.rb +249 -0
- data/lib/fuse_client/models/{enriched_transaction_logo.rb → merchant_logo.rb} +4 -4
- data/lib/fuse_client/models/migrate_financial_connections_aggregator_connection_data.rb +1 -1
- data/lib/fuse_client/models/migrate_financial_connections_aggregator_connection_data_mx.rb +1 -1
- data/lib/fuse_client/models/migrate_financial_connections_aggregator_connection_data_plaid.rb +1 -1
- data/lib/fuse_client/models/migrate_financial_connections_aggregator_connection_data_teller.rb +1 -1
- data/lib/fuse_client/models/migrate_financial_connections_token_request.rb +1 -1
- data/lib/fuse_client/models/migrate_financial_connections_token_request_entity.rb +1 -1
- data/lib/fuse_client/models/migrate_financial_connections_token_response.rb +1 -1
- data/lib/fuse_client/models/product.rb +1 -1
- data/lib/fuse_client/models/refresh_asset_report_request.rb +1 -1
- data/lib/fuse_client/models/refresh_asset_report_response.rb +1 -1
- data/lib/fuse_client/models/spend_power.rb +34 -5
- data/lib/fuse_client/models/spend_power_customization.rb +40 -6
- data/lib/fuse_client/models/spend_power_time_frame.rb +1 -1
- data/lib/fuse_client/models/sync_financial_connections_data_response.rb +1 -1
- data/lib/fuse_client/models/sync_transactions_request.rb +1 -1
- data/lib/fuse_client/models/sync_transactions_response.rb +1 -1
- data/lib/fuse_client/models/sync_transactions_response_removed_inner.rb +1 -1
- data/lib/fuse_client/models/transaction.rb +12 -2
- data/lib/fuse_client/models/transaction_category.rb +1 -1
- data/lib/fuse_client/models/transaction_category_detailed.rb +23 -2
- data/lib/fuse_client/models/transaction_category_primary.rb +1 -1
- data/lib/fuse_client/models/transaction_event_type.rb +1 -1
- data/lib/fuse_client/models/transaction_merchant.rb +1 -1
- data/lib/fuse_client/models/transaction_to_enrich.rb +2 -2
- data/lib/fuse_client/models/update_entity_request.rb +1 -1
- data/lib/fuse_client/models/update_entity_response.rb +1 -1
- data/lib/fuse_client/models/update_spend_power_customization_request.rb +39 -5
- data/lib/fuse_client/models/update_spend_power_customization_response.rb +1 -1
- data/lib/fuse_client/models/updated_balance_event.rb +25 -25
- data/lib/fuse_client/models/webhook_event.rb +1 -1
- data/lib/fuse_client/models/webhook_source.rb +3 -2
- data/lib/fuse_client/models/webhook_type.rb +1 -1
- data/lib/fuse_client/version.rb +2 -2
- data/lib/fuse_client.rb +32 -2
- data/spec/api/fuse_api_spec.rb +41 -29
- data/spec/api/spend_power_api_spec.rb +3 -3
- data/spec/api_client_spec.rb +1 -1
- data/spec/configuration_spec.rb +1 -1
- data/spec/models/account_subtype_spec.rb +1 -1
- data/spec/models/account_type_spec.rb +1 -1
- data/spec/models/add_account_events_request_events_inner_spec.rb +1 -1
- data/spec/models/add_account_events_request_spec.rb +2 -2
- data/spec/models/add_account_events_response_spec.rb +3 -3
- data/spec/models/aggregator_spec.rb +1 -1
- data/spec/models/asset_report_accounts_inner_balance_spec.rb +4 -4
- data/spec/models/asset_report_accounts_inner_historical_balances_inner_spec.rb +4 -4
- data/spec/models/asset_report_accounts_inner_spec.rb +5 -5
- data/spec/models/asset_report_response_spec.rb +3 -3
- data/spec/models/asset_report_spec.rb +6 -6
- data/spec/models/asset_report_transaction_spec.rb +11 -11
- data/spec/models/country_code_spec.rb +1 -1
- data/spec/models/create_asset_report_request_spec.rb +3 -3
- data/spec/models/create_asset_report_response_spec.rb +4 -4
- data/spec/models/create_entity_request_spec.rb +5 -5
- data/spec/models/create_entity_response_spec.rb +6 -6
- data/spec/models/create_link_token_request_mx_spec.rb +2 -2
- data/spec/models/create_link_token_request_plaid_spec.rb +2 -2
- data/spec/models/create_link_token_request_spec.rb +9 -9
- data/spec/models/create_link_token_request_teller_config_account_filter_credit_one_of_spec.rb +38 -0
- data/spec/models/create_link_token_request_teller_config_account_filter_credit_spec.rb +31 -0
- data/spec/models/create_link_token_request_teller_config_account_filter_depository_one_of_spec.rb +38 -0
- data/spec/models/create_link_token_request_teller_config_account_filter_depository_spec.rb +31 -0
- data/spec/models/create_link_token_request_teller_config_account_filter_spec.rb +40 -0
- data/spec/models/create_link_token_request_teller_config_spec.rb +8 -2
- data/spec/models/create_link_token_request_teller_spec.rb +2 -2
- data/spec/models/create_link_token_response_spec.rb +3 -3
- data/spec/models/create_session_request_spec.rb +7 -7
- data/spec/models/create_session_response_spec.rb +4 -4
- data/spec/models/create_spend_power_customization_request_spec.rb +10 -4
- data/spec/models/create_spend_power_customization_response_spec.rb +3 -3
- data/spec/models/create_spend_power_request_spec.rb +4 -4
- data/spec/models/create_spend_power_response_spec.rb +3 -3
- data/spec/models/currency_spec.rb +3 -3
- data/spec/models/delete_financial_connection_response_spec.rb +4 -4
- data/spec/models/delete_spend_power_response_spec.rb +3 -3
- data/spec/models/enrich_transactions_request_spec.rb +2 -2
- data/spec/models/enrich_transactions_response_spec.rb +2 -2
- data/spec/models/enriched_transaction_spec.rb +22 -16
- data/spec/models/entity_spec.rb +4 -4
- data/spec/models/eval_spend_power_request_events_inner_spec.rb +3 -3
- data/spec/models/eval_spend_power_request_spec.rb +4 -4
- data/spec/models/eval_spend_power_response_spec.rb +17 -5
- data/spec/models/exchange_financial_connections_public_token_request_spec.rb +2 -2
- data/spec/models/exchange_financial_connections_public_token_response_spec.rb +4 -4
- data/spec/models/external_transaction_event_spec.rb +14 -20
- data/spec/models/external_transaction_event_status_spec.rb +1 -1
- data/spec/models/fin_ql_comparison_feature_spec.rb +58 -0
- data/spec/models/fin_ql_feature_one_of1_spec.rb +34 -0
- data/spec/models/fin_ql_feature_one_of2_spec.rb +34 -0
- data/spec/models/fin_ql_feature_one_of3_spec.rb +34 -0
- data/spec/models/fin_ql_feature_one_of4_spec.rb +34 -0
- data/spec/models/fin_ql_feature_one_of5_spec.rb +34 -0
- data/spec/models/fin_ql_feature_one_of6_spec.rb +34 -0
- data/spec/models/fin_ql_feature_one_of7_spec.rb +34 -0
- data/spec/models/fin_ql_feature_one_of_spec.rb +34 -0
- data/spec/models/fin_ql_feature_request_spec.rb +28 -0
- data/spec/models/fin_ql_feature_spec.rb +31 -0
- data/spec/models/fin_ql_frequency_feature_spec.rb +44 -0
- data/spec/models/fin_ql_individual_merchant_feature_spec.rb +40 -0
- data/spec/models/fin_ql_interest_feature_spec.rb +34 -0
- data/spec/models/fin_ql_merchant_categories_feature_inner_result_inner_spec.rb +40 -0
- data/spec/models/fin_ql_merchant_categories_feature_inner_spec.rb +40 -0
- data/spec/models/fin_ql_prompt_request_spec.rb +46 -0
- data/spec/models/fin_ql_prompt_response_spec.rb +40 -0
- data/spec/models/fin_ql_time_based_feature_inner_spec.rb +40 -0
- data/spec/models/fin_ql_top_merchants_feature_inner_spec.rb +46 -0
- data/spec/models/finance_score_spec.rb +70 -0
- data/spec/models/financial_connection_data_spec.rb +3 -3
- data/spec/models/financial_connection_details_flinks_spec.rb +34 -0
- data/spec/models/financial_connection_details_mono_spec.rb +34 -0
- data/spec/models/financial_connection_details_mx_spec.rb +3 -3
- data/spec/models/financial_connection_details_plaid_spec.rb +3 -3
- data/spec/models/financial_connection_details_snaptrade_spec.rb +46 -0
- data/spec/models/financial_connection_details_spec.rb +27 -9
- data/spec/models/financial_connection_details_teller_spec.rb +3 -3
- data/spec/models/financial_connections_account_balance_spec.rb +6 -6
- data/spec/models/financial_connections_account_cached_balance_spec.rb +5 -5
- data/spec/models/financial_connections_account_details_ach_spec.rb +5 -5
- data/spec/models/financial_connections_account_details_spec.rb +9 -3
- data/spec/models/financial_connections_account_institution_spec.rb +2 -2
- data/spec/models/financial_connections_account_liability_all_of_aprs_spec.rb +3 -3
- data/spec/models/financial_connections_account_liability_all_of_spec.rb +8 -8
- data/spec/models/financial_connections_account_liability_spec.rb +22 -16
- data/spec/models/financial_connections_account_spec.rb +15 -9
- data/spec/models/financial_connections_holding_spec.rb +7 -7
- data/spec/models/financial_connections_investment_security_exchange_spec.rb +2 -2
- data/spec/models/financial_connections_investment_security_spec.rb +11 -11
- data/spec/models/financial_connections_investment_security_type_spec.rb +1 -1
- data/spec/models/financial_connections_investment_transaction_spec.rb +14 -14
- data/spec/models/financial_connections_investment_transaction_subtype_spec.rb +1 -1
- data/spec/models/financial_connections_owner_addresses_inner_data_spec.rb +6 -6
- data/spec/models/financial_connections_owner_addresses_inner_spec.rb +3 -3
- data/spec/models/financial_connections_owner_emails_inner_spec.rb +4 -4
- data/spec/models/financial_connections_owner_names_inner_spec.rb +3 -3
- data/spec/models/financial_connections_owner_phone_numbers_inner_spec.rb +4 -4
- data/spec/models/financial_connections_owner_spec.rb +5 -5
- data/spec/models/financial_institution_logo_spec.rb +4 -4
- data/spec/models/financial_institution_spec.rb +6 -6
- data/spec/models/fuse_api_aggregator_error_spec.rb +7 -7
- data/spec/models/fuse_api_error_code_spec.rb +1 -1
- data/spec/models/fuse_api_error_data_spec.rb +3 -3
- data/spec/models/fuse_api_error_spec.rb +8 -8
- data/spec/models/fuse_api_error_type_spec.rb +1 -1
- data/spec/models/fuse_api_warning_data_spec.rb +3 -3
- data/spec/models/fuse_api_warning_data_warnings_inner_spec.rb +6 -6
- data/spec/models/fuse_api_warning_spec.rb +7 -7
- data/spec/models/get_asset_report_request_spec.rb +3 -3
- data/spec/models/get_entity_response_spec.rb +7 -7
- data/spec/models/get_finance_score_response_spec.rb +3 -3
- data/spec/models/get_financial_connection_response_spec.rb +3 -3
- data/spec/models/get_financial_connections_account_details_request_spec.rb +2 -2
- data/spec/models/get_financial_connections_account_details_response_spec.rb +4 -4
- data/spec/models/get_financial_connections_account_statement_request_spec.rb +4 -4
- data/spec/models/get_financial_connections_account_statement_response_spec.rb +3 -3
- data/spec/models/get_financial_connections_accounts_request_spec.rb +2 -2
- data/spec/models/get_financial_connections_accounts_response_spec.rb +4 -4
- data/spec/models/get_financial_connections_balance_request_options_spec.rb +2 -2
- data/spec/models/get_financial_connections_balance_request_spec.rb +3 -3
- data/spec/models/get_financial_connections_balance_response_spec.rb +3 -3
- data/spec/models/get_financial_connections_owners_request_spec.rb +2 -2
- data/spec/models/get_financial_connections_owners_response_accounts_inner_spec.rb +4 -4
- data/spec/models/get_financial_connections_owners_response_spec.rb +2 -2
- data/spec/models/get_financial_connections_transactions_request_spec.rb +6 -6
- data/spec/models/get_financial_connections_transactions_response_spec.rb +4 -4
- data/spec/models/get_financial_institution_response_spec.rb +3 -3
- data/spec/models/get_investment_holdings_request_options_spec.rb +2 -2
- data/spec/models/get_investment_holdings_request_spec.rb +3 -3
- data/spec/models/get_investment_holdings_response_spec.rb +4 -4
- data/spec/models/get_investment_transactions_request_options_spec.rb +2 -2
- data/spec/models/get_investment_transactions_request_spec.rb +7 -7
- data/spec/models/get_investment_transactions_response_spec.rb +5 -5
- data/spec/models/get_liabilities_request_spec.rb +2 -2
- data/spec/models/get_liabilities_response_spec.rb +3 -3
- data/spec/models/get_spend_power_customization_response_spec.rb +3 -3
- data/spec/models/get_spend_power_response_spec.rb +3 -3
- data/spec/models/in_app_transaction_event_spec.rb +16 -16
- data/spec/models/in_app_transaction_event_status_spec.rb +1 -1
- data/spec/models/merchant_logo_spec.rb +34 -0
- data/spec/models/merchant_spec.rb +46 -0
- data/spec/models/migrate_financial_connections_aggregator_connection_data_mx_spec.rb +3 -3
- data/spec/models/migrate_financial_connections_aggregator_connection_data_plaid_spec.rb +3 -3
- data/spec/models/migrate_financial_connections_aggregator_connection_data_spec.rb +4 -4
- data/spec/models/migrate_financial_connections_aggregator_connection_data_teller_spec.rb +2 -2
- data/spec/models/migrate_financial_connections_token_request_entity_spec.rb +2 -2
- data/spec/models/migrate_financial_connections_token_request_spec.rb +5 -5
- data/spec/models/migrate_financial_connections_token_response_spec.rb +5 -5
- data/spec/models/product_spec.rb +1 -1
- data/spec/models/refresh_asset_report_request_spec.rb +4 -4
- data/spec/models/refresh_asset_report_response_spec.rb +4 -4
- data/spec/models/spend_power_customization_spec.rb +11 -5
- data/spec/models/spend_power_spec.rb +20 -8
- data/spec/models/spend_power_time_frame_spec.rb +1 -1
- data/spec/models/sync_financial_connections_data_response_spec.rb +3 -3
- data/spec/models/sync_transactions_request_spec.rb +4 -4
- data/spec/models/sync_transactions_response_removed_inner_spec.rb +2 -2
- data/spec/models/sync_transactions_response_spec.rb +7 -7
- data/spec/models/transaction_category_detailed_spec.rb +1 -1
- data/spec/models/transaction_category_primary_spec.rb +1 -1
- data/spec/models/transaction_category_spec.rb +3 -3
- data/spec/models/transaction_event_type_spec.rb +1 -1
- data/spec/models/transaction_merchant_spec.rb +2 -2
- data/spec/models/transaction_spec.rb +18 -12
- data/spec/models/transaction_to_enrich_spec.rb +6 -6
- data/spec/models/update_entity_request_spec.rb +4 -4
- data/spec/models/update_entity_response_spec.rb +6 -6
- data/spec/models/update_spend_power_customization_request_spec.rb +10 -4
- data/spec/models/update_spend_power_customization_response_spec.rb +3 -3
- data/spec/models/updated_balance_event_spec.rb +10 -10
- data/spec/models/webhook_event_spec.rb +10 -10
- data/spec/models/webhook_source_spec.rb +1 -1
- data/spec/models/webhook_type_spec.rb +1 -1
- data/spec/spec_helper.rb +1 -1
- metadata +126 -6
- data/spec/models/enriched_transaction_logo_spec.rb +0 -34
@@ -0,0 +1,229 @@
|
|
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
|
+
# Filter the types of account returned by Teller when enrolling a customer
|
18
|
+
class CreateLinkTokenRequestTellerConfigAccountFilter
|
19
|
+
attr_accessor :depository
|
20
|
+
|
21
|
+
attr_accessor :credit
|
22
|
+
|
23
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
24
|
+
def self.attribute_map
|
25
|
+
{
|
26
|
+
:'depository' => :'depository',
|
27
|
+
:'credit' => :'credit'
|
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
|
+
:'depository' => :'CreateLinkTokenRequestTellerConfigAccountFilterDepository',
|
40
|
+
:'credit' => :'CreateLinkTokenRequestTellerConfigAccountFilterCredit'
|
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::CreateLinkTokenRequestTellerConfigAccountFilter` 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::CreateLinkTokenRequestTellerConfigAccountFilter`. 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?(:'depository')
|
66
|
+
self.depository = attributes[:'depository']
|
67
|
+
end
|
68
|
+
|
69
|
+
if attributes.key?(:'credit')
|
70
|
+
self.credit = attributes[:'credit']
|
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
|
+
invalid_properties
|
79
|
+
end
|
80
|
+
|
81
|
+
# Check to see if the all the properties in the model are valid
|
82
|
+
# @return true if the model is valid
|
83
|
+
def valid?
|
84
|
+
true
|
85
|
+
end
|
86
|
+
|
87
|
+
# Checks equality by comparing each attribute.
|
88
|
+
# @param [Object] Object to be compared
|
89
|
+
def ==(o)
|
90
|
+
return true if self.equal?(o)
|
91
|
+
self.class == o.class &&
|
92
|
+
depository == o.depository &&
|
93
|
+
credit == o.credit
|
94
|
+
end
|
95
|
+
|
96
|
+
# @see the `==` method
|
97
|
+
# @param [Object] Object to be compared
|
98
|
+
def eql?(o)
|
99
|
+
self == o
|
100
|
+
end
|
101
|
+
|
102
|
+
# Calculates hash code according to all attributes.
|
103
|
+
# @return [Integer] Hash code
|
104
|
+
def hash
|
105
|
+
[depository, credit].hash
|
106
|
+
end
|
107
|
+
|
108
|
+
# Builds the object from hash
|
109
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
110
|
+
# @return [Object] Returns the model itself
|
111
|
+
def self.build_from_hash(attributes)
|
112
|
+
new.build_from_hash(attributes)
|
113
|
+
end
|
114
|
+
|
115
|
+
# Builds the object from hash
|
116
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
117
|
+
# @return [Object] Returns the model itself
|
118
|
+
def build_from_hash(attributes)
|
119
|
+
return nil unless attributes.is_a?(Hash)
|
120
|
+
attributes = attributes.transform_keys(&:to_sym)
|
121
|
+
self.class.openapi_types.each_pair do |key, type|
|
122
|
+
if attributes[self.class.attribute_map[key]].nil? && self.class.openapi_nullable.include?(key)
|
123
|
+
self.send("#{key}=", nil)
|
124
|
+
elsif type =~ /\AArray<(.*)>/i
|
125
|
+
# check to ensure the input is an array given that the attribute
|
126
|
+
# is documented as an array but the input is not
|
127
|
+
if attributes[self.class.attribute_map[key]].is_a?(Array)
|
128
|
+
self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
|
129
|
+
end
|
130
|
+
elsif !attributes[self.class.attribute_map[key]].nil?
|
131
|
+
self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
|
132
|
+
end
|
133
|
+
end
|
134
|
+
|
135
|
+
self
|
136
|
+
end
|
137
|
+
|
138
|
+
# Deserializes the data based on type
|
139
|
+
# @param string type Data type
|
140
|
+
# @param string value Value to be deserialized
|
141
|
+
# @return [Object] Deserialized data
|
142
|
+
def _deserialize(type, value)
|
143
|
+
case type.to_sym
|
144
|
+
when :Time
|
145
|
+
Time.parse(value)
|
146
|
+
when :Date
|
147
|
+
Date.parse(value)
|
148
|
+
when :String
|
149
|
+
value.to_s
|
150
|
+
when :Integer
|
151
|
+
value.to_i
|
152
|
+
when :Float
|
153
|
+
value.to_f
|
154
|
+
when :Boolean
|
155
|
+
if value.to_s =~ /\A(true|t|yes|y|1)\z/i
|
156
|
+
true
|
157
|
+
else
|
158
|
+
false
|
159
|
+
end
|
160
|
+
when :Object
|
161
|
+
# generic object (usually a Hash), return directly
|
162
|
+
value
|
163
|
+
when /\AArray<(?<inner_type>.+)>\z/
|
164
|
+
inner_type = Regexp.last_match[:inner_type]
|
165
|
+
value.map { |v| _deserialize(inner_type, v) }
|
166
|
+
when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
|
167
|
+
k_type = Regexp.last_match[:k_type]
|
168
|
+
v_type = Regexp.last_match[:v_type]
|
169
|
+
{}.tap do |hash|
|
170
|
+
value.each do |k, v|
|
171
|
+
hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
|
172
|
+
end
|
173
|
+
end
|
174
|
+
else # model
|
175
|
+
# models (e.g. Pet) or oneOf
|
176
|
+
klass = FuseClient.const_get(type)
|
177
|
+
klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
|
178
|
+
end
|
179
|
+
end
|
180
|
+
|
181
|
+
# Returns the string representation of the object
|
182
|
+
# @return [String] String presentation of the object
|
183
|
+
def to_s
|
184
|
+
to_hash.to_s
|
185
|
+
end
|
186
|
+
|
187
|
+
# to_body is an alias to to_hash (backward compatibility)
|
188
|
+
# @return [Hash] Returns the object in the form of hash
|
189
|
+
def to_body
|
190
|
+
to_hash
|
191
|
+
end
|
192
|
+
|
193
|
+
# Returns the object in the form of hash
|
194
|
+
# @return [Hash] Returns the object in the form of hash
|
195
|
+
def to_hash
|
196
|
+
hash = {}
|
197
|
+
self.class.attribute_map.each_pair do |attr, param|
|
198
|
+
value = self.send(attr)
|
199
|
+
if value.nil?
|
200
|
+
is_nullable = self.class.openapi_nullable.include?(attr)
|
201
|
+
next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
|
202
|
+
end
|
203
|
+
|
204
|
+
hash[param] = _to_hash(value)
|
205
|
+
end
|
206
|
+
hash
|
207
|
+
end
|
208
|
+
|
209
|
+
# Outputs non-array value in the form of hash
|
210
|
+
# For object, use to_hash. Otherwise, just return the value
|
211
|
+
# @param [Object] value Any valid value
|
212
|
+
# @return [Hash] Returns the value in the form of hash
|
213
|
+
def _to_hash(value)
|
214
|
+
if value.is_a?(Array)
|
215
|
+
value.compact.map { |v| _to_hash(v) }
|
216
|
+
elsif value.is_a?(Hash)
|
217
|
+
{}.tap do |hash|
|
218
|
+
value.each { |k, v| hash[k] = _to_hash(v) }
|
219
|
+
end
|
220
|
+
elsif value.respond_to? :to_hash
|
221
|
+
value.to_hash
|
222
|
+
else
|
223
|
+
value
|
224
|
+
end
|
225
|
+
end
|
226
|
+
|
227
|
+
end
|
228
|
+
|
229
|
+
end
|
@@ -0,0 +1,105 @@
|
|
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
|
+
module CreateLinkTokenRequestTellerConfigAccountFilterCredit
|
18
|
+
class << self
|
19
|
+
# List of class defined in oneOf (OpenAPI v3)
|
20
|
+
def openapi_one_of
|
21
|
+
[
|
22
|
+
:'CreateLinkTokenRequestTellerConfigAccountFilterCreditOneOf',
|
23
|
+
:'String'
|
24
|
+
]
|
25
|
+
end
|
26
|
+
|
27
|
+
# Builds the object
|
28
|
+
# @param [Mixed] Data to be matched against the list of oneOf items
|
29
|
+
# @return [Object] Returns the model or the data itself
|
30
|
+
def build(data)
|
31
|
+
# Go through the list of oneOf items and attempt to identify the appropriate one.
|
32
|
+
# Note:
|
33
|
+
# - We do not attempt to check whether exactly one item matches.
|
34
|
+
# - No advanced validation of types in some cases (e.g. "x: { type: string }" will happily match { x: 123 })
|
35
|
+
# due to the way the deserialization is made in the base_object template (it just casts without verifying).
|
36
|
+
# - TODO: scalar values are de facto behaving as if they were nullable.
|
37
|
+
# - TODO: logging when debugging is set.
|
38
|
+
openapi_one_of.each do |klass|
|
39
|
+
begin
|
40
|
+
next if klass == :AnyType # "nullable: true"
|
41
|
+
typed_data = find_and_cast_into_type(klass, data)
|
42
|
+
return typed_data if typed_data
|
43
|
+
rescue # rescue all errors so we keep iterating even if the current item lookup raises
|
44
|
+
end
|
45
|
+
end
|
46
|
+
|
47
|
+
openapi_one_of.include?(:AnyType) ? data : nil
|
48
|
+
end
|
49
|
+
|
50
|
+
private
|
51
|
+
|
52
|
+
SchemaMismatchError = Class.new(StandardError)
|
53
|
+
|
54
|
+
# Note: 'File' is missing here because in the regular case we get the data _after_ a call to JSON.parse.
|
55
|
+
def find_and_cast_into_type(klass, data)
|
56
|
+
return if data.nil?
|
57
|
+
|
58
|
+
case klass.to_s
|
59
|
+
when 'Boolean'
|
60
|
+
return data if data.instance_of?(TrueClass) || data.instance_of?(FalseClass)
|
61
|
+
when 'Float'
|
62
|
+
return data if data.instance_of?(Float)
|
63
|
+
when 'Integer'
|
64
|
+
return data if data.instance_of?(Integer)
|
65
|
+
when 'Time'
|
66
|
+
return Time.parse(data)
|
67
|
+
when 'Date'
|
68
|
+
return Date.parse(data)
|
69
|
+
when 'String'
|
70
|
+
return data if data.instance_of?(String)
|
71
|
+
when 'Object' # "type: object"
|
72
|
+
return data if data.instance_of?(Hash)
|
73
|
+
when /\AArray<(?<sub_type>.+)>\z/ # "type: array"
|
74
|
+
if data.instance_of?(Array)
|
75
|
+
sub_type = Regexp.last_match[:sub_type]
|
76
|
+
return data.map { |item| find_and_cast_into_type(sub_type, item) }
|
77
|
+
end
|
78
|
+
when /\AHash<String, (?<sub_type>.+)>\z/ # "type: object" with "additionalProperties: { ... }"
|
79
|
+
if data.instance_of?(Hash) && data.keys.all? { |k| k.instance_of?(Symbol) || k.instance_of?(String) }
|
80
|
+
sub_type = Regexp.last_match[:sub_type]
|
81
|
+
return data.each_with_object({}) { |(k, v), hsh| hsh[k] = find_and_cast_into_type(sub_type, v) }
|
82
|
+
end
|
83
|
+
else # model
|
84
|
+
const = FuseClient.const_get(klass)
|
85
|
+
if const
|
86
|
+
if const.respond_to?(:openapi_one_of) # nested oneOf model
|
87
|
+
model = const.build(data)
|
88
|
+
return model if model
|
89
|
+
else
|
90
|
+
# raise if data contains keys that are not known to the model
|
91
|
+
raise unless (data.keys - const.acceptable_attributes).empty?
|
92
|
+
model = const.build_from_hash(data)
|
93
|
+
return model if model && model.valid?
|
94
|
+
end
|
95
|
+
end
|
96
|
+
end
|
97
|
+
|
98
|
+
raise # if no match by now, raise
|
99
|
+
rescue
|
100
|
+
raise SchemaMismatchError, "#{data} doesn't match the #{klass} type"
|
101
|
+
end
|
102
|
+
end
|
103
|
+
end
|
104
|
+
|
105
|
+
end
|
data/lib/fuse_client/models/create_link_token_request_teller_config_account_filter_credit_one_of.rb
ADDED
@@ -0,0 +1,243 @@
|
|
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 CreateLinkTokenRequestTellerConfigAccountFilterCreditOneOf
|
18
|
+
attr_accessor :subtypes
|
19
|
+
|
20
|
+
class EnumAttributeValidator
|
21
|
+
attr_reader :datatype
|
22
|
+
attr_reader :allowable_values
|
23
|
+
|
24
|
+
def initialize(datatype, allowable_values)
|
25
|
+
@allowable_values = allowable_values.map do |value|
|
26
|
+
case datatype.to_s
|
27
|
+
when /Integer/i
|
28
|
+
value.to_i
|
29
|
+
when /Float/i
|
30
|
+
value.to_f
|
31
|
+
else
|
32
|
+
value
|
33
|
+
end
|
34
|
+
end
|
35
|
+
end
|
36
|
+
|
37
|
+
def valid?(value)
|
38
|
+
!value || allowable_values.include?(value)
|
39
|
+
end
|
40
|
+
end
|
41
|
+
|
42
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
43
|
+
def self.attribute_map
|
44
|
+
{
|
45
|
+
:'subtypes' => :'subtypes'
|
46
|
+
}
|
47
|
+
end
|
48
|
+
|
49
|
+
# Returns all the JSON keys this model knows about
|
50
|
+
def self.acceptable_attributes
|
51
|
+
attribute_map.values
|
52
|
+
end
|
53
|
+
|
54
|
+
# Attribute type mapping.
|
55
|
+
def self.openapi_types
|
56
|
+
{
|
57
|
+
:'subtypes' => :'Array<String>'
|
58
|
+
}
|
59
|
+
end
|
60
|
+
|
61
|
+
# List of attributes with nullable: true
|
62
|
+
def self.openapi_nullable
|
63
|
+
Set.new([
|
64
|
+
])
|
65
|
+
end
|
66
|
+
|
67
|
+
# Initializes the object
|
68
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
69
|
+
def initialize(attributes = {})
|
70
|
+
if (!attributes.is_a?(Hash))
|
71
|
+
fail ArgumentError, "The input argument (attributes) must be a hash in `FuseClient::CreateLinkTokenRequestTellerConfigAccountFilterCreditOneOf` initialize method"
|
72
|
+
end
|
73
|
+
|
74
|
+
# check to see if the attribute exists and convert string to symbol for hash key
|
75
|
+
attributes = attributes.each_with_object({}) { |(k, v), h|
|
76
|
+
if (!self.class.attribute_map.key?(k.to_sym))
|
77
|
+
fail ArgumentError, "`#{k}` is not a valid attribute in `FuseClient::CreateLinkTokenRequestTellerConfigAccountFilterCreditOneOf`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
|
78
|
+
end
|
79
|
+
h[k.to_sym] = v
|
80
|
+
}
|
81
|
+
|
82
|
+
if attributes.key?(:'subtypes')
|
83
|
+
if (value = attributes[:'subtypes']).is_a?(Array)
|
84
|
+
self.subtypes = value
|
85
|
+
end
|
86
|
+
end
|
87
|
+
end
|
88
|
+
|
89
|
+
# Show invalid properties with the reasons. Usually used together with valid?
|
90
|
+
# @return Array for valid properties with the reasons
|
91
|
+
def list_invalid_properties
|
92
|
+
invalid_properties = Array.new
|
93
|
+
invalid_properties
|
94
|
+
end
|
95
|
+
|
96
|
+
# Check to see if the all the properties in the model are valid
|
97
|
+
# @return true if the model is valid
|
98
|
+
def valid?
|
99
|
+
true
|
100
|
+
end
|
101
|
+
|
102
|
+
# Checks equality by comparing each attribute.
|
103
|
+
# @param [Object] Object to be compared
|
104
|
+
def ==(o)
|
105
|
+
return true if self.equal?(o)
|
106
|
+
self.class == o.class &&
|
107
|
+
subtypes == o.subtypes
|
108
|
+
end
|
109
|
+
|
110
|
+
# @see the `==` method
|
111
|
+
# @param [Object] Object to be compared
|
112
|
+
def eql?(o)
|
113
|
+
self == o
|
114
|
+
end
|
115
|
+
|
116
|
+
# Calculates hash code according to all attributes.
|
117
|
+
# @return [Integer] Hash code
|
118
|
+
def hash
|
119
|
+
[subtypes].hash
|
120
|
+
end
|
121
|
+
|
122
|
+
# Builds the object from hash
|
123
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
124
|
+
# @return [Object] Returns the model itself
|
125
|
+
def self.build_from_hash(attributes)
|
126
|
+
new.build_from_hash(attributes)
|
127
|
+
end
|
128
|
+
|
129
|
+
# Builds the object from hash
|
130
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
131
|
+
# @return [Object] Returns the model itself
|
132
|
+
def build_from_hash(attributes)
|
133
|
+
return nil unless attributes.is_a?(Hash)
|
134
|
+
attributes = attributes.transform_keys(&:to_sym)
|
135
|
+
self.class.openapi_types.each_pair do |key, type|
|
136
|
+
if attributes[self.class.attribute_map[key]].nil? && self.class.openapi_nullable.include?(key)
|
137
|
+
self.send("#{key}=", nil)
|
138
|
+
elsif type =~ /\AArray<(.*)>/i
|
139
|
+
# check to ensure the input is an array given that the attribute
|
140
|
+
# is documented as an array but the input is not
|
141
|
+
if attributes[self.class.attribute_map[key]].is_a?(Array)
|
142
|
+
self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
|
143
|
+
end
|
144
|
+
elsif !attributes[self.class.attribute_map[key]].nil?
|
145
|
+
self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
|
146
|
+
end
|
147
|
+
end
|
148
|
+
|
149
|
+
self
|
150
|
+
end
|
151
|
+
|
152
|
+
# Deserializes the data based on type
|
153
|
+
# @param string type Data type
|
154
|
+
# @param string value Value to be deserialized
|
155
|
+
# @return [Object] Deserialized data
|
156
|
+
def _deserialize(type, value)
|
157
|
+
case type.to_sym
|
158
|
+
when :Time
|
159
|
+
Time.parse(value)
|
160
|
+
when :Date
|
161
|
+
Date.parse(value)
|
162
|
+
when :String
|
163
|
+
value.to_s
|
164
|
+
when :Integer
|
165
|
+
value.to_i
|
166
|
+
when :Float
|
167
|
+
value.to_f
|
168
|
+
when :Boolean
|
169
|
+
if value.to_s =~ /\A(true|t|yes|y|1)\z/i
|
170
|
+
true
|
171
|
+
else
|
172
|
+
false
|
173
|
+
end
|
174
|
+
when :Object
|
175
|
+
# generic object (usually a Hash), return directly
|
176
|
+
value
|
177
|
+
when /\AArray<(?<inner_type>.+)>\z/
|
178
|
+
inner_type = Regexp.last_match[:inner_type]
|
179
|
+
value.map { |v| _deserialize(inner_type, v) }
|
180
|
+
when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
|
181
|
+
k_type = Regexp.last_match[:k_type]
|
182
|
+
v_type = Regexp.last_match[:v_type]
|
183
|
+
{}.tap do |hash|
|
184
|
+
value.each do |k, v|
|
185
|
+
hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
|
186
|
+
end
|
187
|
+
end
|
188
|
+
else # model
|
189
|
+
# models (e.g. Pet) or oneOf
|
190
|
+
klass = FuseClient.const_get(type)
|
191
|
+
klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
|
192
|
+
end
|
193
|
+
end
|
194
|
+
|
195
|
+
# Returns the string representation of the object
|
196
|
+
# @return [String] String presentation of the object
|
197
|
+
def to_s
|
198
|
+
to_hash.to_s
|
199
|
+
end
|
200
|
+
|
201
|
+
# to_body is an alias to to_hash (backward compatibility)
|
202
|
+
# @return [Hash] Returns the object in the form of hash
|
203
|
+
def to_body
|
204
|
+
to_hash
|
205
|
+
end
|
206
|
+
|
207
|
+
# Returns the object in the form of hash
|
208
|
+
# @return [Hash] Returns the object in the form of hash
|
209
|
+
def to_hash
|
210
|
+
hash = {}
|
211
|
+
self.class.attribute_map.each_pair do |attr, param|
|
212
|
+
value = self.send(attr)
|
213
|
+
if value.nil?
|
214
|
+
is_nullable = self.class.openapi_nullable.include?(attr)
|
215
|
+
next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
|
216
|
+
end
|
217
|
+
|
218
|
+
hash[param] = _to_hash(value)
|
219
|
+
end
|
220
|
+
hash
|
221
|
+
end
|
222
|
+
|
223
|
+
# Outputs non-array value in the form of hash
|
224
|
+
# For object, use to_hash. Otherwise, just return the value
|
225
|
+
# @param [Object] value Any valid value
|
226
|
+
# @return [Hash] Returns the value in the form of hash
|
227
|
+
def _to_hash(value)
|
228
|
+
if value.is_a?(Array)
|
229
|
+
value.compact.map { |v| _to_hash(v) }
|
230
|
+
elsif value.is_a?(Hash)
|
231
|
+
{}.tap do |hash|
|
232
|
+
value.each { |k, v| hash[k] = _to_hash(v) }
|
233
|
+
end
|
234
|
+
elsif value.respond_to? :to_hash
|
235
|
+
value.to_hash
|
236
|
+
else
|
237
|
+
value
|
238
|
+
end
|
239
|
+
end
|
240
|
+
|
241
|
+
end
|
242
|
+
|
243
|
+
end
|
data/lib/fuse_client/models/create_link_token_request_teller_config_account_filter_depository.rb
ADDED
@@ -0,0 +1,105 @@
|
|
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
|
+
module CreateLinkTokenRequestTellerConfigAccountFilterDepository
|
18
|
+
class << self
|
19
|
+
# List of class defined in oneOf (OpenAPI v3)
|
20
|
+
def openapi_one_of
|
21
|
+
[
|
22
|
+
:'CreateLinkTokenRequestTellerConfigAccountFilterDepositoryOneOf',
|
23
|
+
:'String'
|
24
|
+
]
|
25
|
+
end
|
26
|
+
|
27
|
+
# Builds the object
|
28
|
+
# @param [Mixed] Data to be matched against the list of oneOf items
|
29
|
+
# @return [Object] Returns the model or the data itself
|
30
|
+
def build(data)
|
31
|
+
# Go through the list of oneOf items and attempt to identify the appropriate one.
|
32
|
+
# Note:
|
33
|
+
# - We do not attempt to check whether exactly one item matches.
|
34
|
+
# - No advanced validation of types in some cases (e.g. "x: { type: string }" will happily match { x: 123 })
|
35
|
+
# due to the way the deserialization is made in the base_object template (it just casts without verifying).
|
36
|
+
# - TODO: scalar values are de facto behaving as if they were nullable.
|
37
|
+
# - TODO: logging when debugging is set.
|
38
|
+
openapi_one_of.each do |klass|
|
39
|
+
begin
|
40
|
+
next if klass == :AnyType # "nullable: true"
|
41
|
+
typed_data = find_and_cast_into_type(klass, data)
|
42
|
+
return typed_data if typed_data
|
43
|
+
rescue # rescue all errors so we keep iterating even if the current item lookup raises
|
44
|
+
end
|
45
|
+
end
|
46
|
+
|
47
|
+
openapi_one_of.include?(:AnyType) ? data : nil
|
48
|
+
end
|
49
|
+
|
50
|
+
private
|
51
|
+
|
52
|
+
SchemaMismatchError = Class.new(StandardError)
|
53
|
+
|
54
|
+
# Note: 'File' is missing here because in the regular case we get the data _after_ a call to JSON.parse.
|
55
|
+
def find_and_cast_into_type(klass, data)
|
56
|
+
return if data.nil?
|
57
|
+
|
58
|
+
case klass.to_s
|
59
|
+
when 'Boolean'
|
60
|
+
return data if data.instance_of?(TrueClass) || data.instance_of?(FalseClass)
|
61
|
+
when 'Float'
|
62
|
+
return data if data.instance_of?(Float)
|
63
|
+
when 'Integer'
|
64
|
+
return data if data.instance_of?(Integer)
|
65
|
+
when 'Time'
|
66
|
+
return Time.parse(data)
|
67
|
+
when 'Date'
|
68
|
+
return Date.parse(data)
|
69
|
+
when 'String'
|
70
|
+
return data if data.instance_of?(String)
|
71
|
+
when 'Object' # "type: object"
|
72
|
+
return data if data.instance_of?(Hash)
|
73
|
+
when /\AArray<(?<sub_type>.+)>\z/ # "type: array"
|
74
|
+
if data.instance_of?(Array)
|
75
|
+
sub_type = Regexp.last_match[:sub_type]
|
76
|
+
return data.map { |item| find_and_cast_into_type(sub_type, item) }
|
77
|
+
end
|
78
|
+
when /\AHash<String, (?<sub_type>.+)>\z/ # "type: object" with "additionalProperties: { ... }"
|
79
|
+
if data.instance_of?(Hash) && data.keys.all? { |k| k.instance_of?(Symbol) || k.instance_of?(String) }
|
80
|
+
sub_type = Regexp.last_match[:sub_type]
|
81
|
+
return data.each_with_object({}) { |(k, v), hsh| hsh[k] = find_and_cast_into_type(sub_type, v) }
|
82
|
+
end
|
83
|
+
else # model
|
84
|
+
const = FuseClient.const_get(klass)
|
85
|
+
if const
|
86
|
+
if const.respond_to?(:openapi_one_of) # nested oneOf model
|
87
|
+
model = const.build(data)
|
88
|
+
return model if model
|
89
|
+
else
|
90
|
+
# raise if data contains keys that are not known to the model
|
91
|
+
raise unless (data.keys - const.acceptable_attributes).empty?
|
92
|
+
model = const.build_from_hash(data)
|
93
|
+
return model if model && model.valid?
|
94
|
+
end
|
95
|
+
end
|
96
|
+
end
|
97
|
+
|
98
|
+
raise # if no match by now, raise
|
99
|
+
rescue
|
100
|
+
raise SchemaMismatchError, "#{data} doesn't match the #{klass} type"
|
101
|
+
end
|
102
|
+
end
|
103
|
+
end
|
104
|
+
|
105
|
+
end
|