moneykit 0.0.2 → 0.0.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/README.md +2 -2
- data/lib/moneykit/api/access_token_api.rb +53 -55
- data/lib/moneykit/api/account_numbers_api.rb +26 -26
- data/lib/moneykit/api/accounts_api.rb +88 -82
- data/lib/moneykit/api/identity_api.rb +31 -30
- data/lib/moneykit/api/institutions_api.rb +50 -48
- data/lib/moneykit/api/link_session_api.rb +47 -50
- data/lib/moneykit/api/links_api.rb +137 -81
- data/lib/moneykit/api/products_api.rb +33 -35
- data/lib/moneykit/api/transactions_api.rb +126 -101
- data/lib/moneykit/api/users_api.rb +100 -83
- data/lib/moneykit/api/webhooks_api.rb +97 -0
- data/lib/moneykit/api_client.rb +100 -103
- data/lib/moneykit/api_error.rb +14 -16
- data/lib/moneykit/configuration.rb +52 -65
- data/lib/moneykit/models/account.rb +69 -112
- data/lib/moneykit/models/account_balances.rb +64 -78
- data/lib/moneykit/models/account_group.rb +58 -61
- data/lib/moneykit/models/account_identity.rb +79 -124
- data/lib/moneykit/models/account_numbers.rb +96 -71
- data/lib/moneykit/models/account_numbers_link_product.rb +57 -69
- data/lib/moneykit/models/account_numbers_product_settings.rb +59 -63
- data/lib/moneykit/models/account_type.rb +23 -23
- data/lib/moneykit/models/account_with_account_numbers.rb +76 -124
- data/lib/moneykit/models/accounts_link_product.rb +53 -61
- data/lib/moneykit/models/ach_number.rb +57 -65
- data/lib/moneykit/models/address.rb +70 -90
- data/lib/moneykit/models/api_error_auth_expired_access_token_response.rb +72 -78
- data/lib/moneykit/models/api_error_auth_unauthorized_response.rb +69 -78
- data/lib/moneykit/models/api_error_rate_limit_exceeded_response.rb +72 -78
- data/lib/moneykit/models/app.rb +46 -50
- data/lib/moneykit/models/bacs_number.rb +53 -61
- data/lib/moneykit/models/balances.rb +58 -64
- data/lib/moneykit/models/basic_account_details.rb +62 -77
- data/lib/moneykit/models/country.rb +13 -14
- data/lib/moneykit/models/create_link_session_request.rb +109 -119
- data/lib/moneykit/models/create_link_session_response.rb +48 -52
- data/lib/moneykit/models/currency.rb +193 -193
- data/lib/moneykit/models/cursor.rb +40 -39
- data/lib/moneykit/models/cursor_pagination.rb +49 -54
- data/lib/moneykit/models/cursors.rb +40 -39
- data/lib/moneykit/models/customer_app.rb +54 -64
- data/lib/moneykit/models/customer_user.rb +59 -69
- data/lib/moneykit/models/eft_number.rb +56 -67
- data/lib/moneykit/models/email.rb +56 -63
- data/lib/moneykit/models/email1.rb +50 -53
- data/lib/moneykit/models/exchange_token_request.rb +48 -52
- data/lib/moneykit/models/exchange_token_response.rb +54 -64
- data/lib/moneykit/models/generate_access_token_response.rb +59 -73
- data/lib/moneykit/models/get_account_numbers_response.rb +58 -66
- data/lib/moneykit/models/get_account_response.rb +55 -67
- data/lib/moneykit/models/get_accounts_response.rb +58 -67
- data/lib/moneykit/models/get_institutions_response.rb +58 -67
- data/lib/moneykit/models/get_transactions_response.rb +81 -105
- data/lib/moneykit/models/get_user_accounts_response.rb +50 -58
- data/lib/moneykit/models/get_user_links_response.rb +50 -58
- data/lib/moneykit/models/get_user_transactions_response.rb +75 -95
- data/lib/moneykit/models/http_validation_error.rb +77 -84
- data/lib/moneykit/models/identity.rb +49 -49
- data/lib/moneykit/models/identity_link_product.rb +57 -69
- data/lib/moneykit/models/identity_product_settings.rb +59 -63
- data/lib/moneykit/models/identity_response.rb +58 -67
- data/lib/moneykit/models/institution.rb +85 -113
- data/lib/moneykit/models/institution_error_not_found_response.rb +72 -80
- data/lib/moneykit/models/institution_styling_response.rb +77 -93
- data/lib/moneykit/models/international_number.rb +54 -64
- data/lib/moneykit/models/introspect_client_response.rb +70 -89
- data/lib/moneykit/models/jwk_set.rb +51 -55
- data/lib/moneykit/models/link.rb +78 -100
- data/lib/moneykit/models/link1.rb +78 -100
- data/lib/moneykit/models/link2.rb +78 -100
- data/lib/moneykit/models/link3.rb +78 -100
- data/lib/moneykit/models/link4.rb +78 -100
- data/lib/moneykit/models/link_common.rb +82 -117
- data/lib/moneykit/models/link_error.rb +19 -19
- data/lib/moneykit/models/link_error_bad_config_response.rb +269 -0
- data/lib/moneykit/models/link_error_bad_state_response.rb +71 -88
- data/lib/moneykit/models/link_error_deleted_response.rb +72 -80
- data/lib/moneykit/models/link_error_forbidden_action_response.rb +69 -78
- data/lib/moneykit/models/link_error_not_found_response.rb +72 -80
- data/lib/moneykit/models/link_error_unauthorized_access_response.rb +72 -80
- data/lib/moneykit/models/link_permission_scope.rb +14 -15
- data/lib/moneykit/models/link_permissions.rb +52 -62
- data/lib/moneykit/models/link_products.rb +62 -78
- data/lib/moneykit/models/link_response.rb +95 -136
- data/lib/moneykit/models/link_session_customer_user.rb +65 -83
- data/lib/moneykit/models/link_session_customer_user_email.rb +59 -68
- data/lib/moneykit/models/link_session_customer_user_phone.rb +67 -82
- data/lib/moneykit/models/link_session_error_forbidden_config_response.rb +69 -78
- data/lib/moneykit/models/link_session_error_invalid_token_exchange.rb +69 -78
- data/lib/moneykit/models/link_session_setting_overrides.rb +64 -99
- data/lib/moneykit/models/link_state.rb +15 -16
- data/lib/moneykit/models/link_state_changed_webhook.rb +121 -148
- data/lib/moneykit/models/location_inner.rb +41 -46
- data/lib/moneykit/models/money_kit_env.rb +12 -13
- data/lib/moneykit/models/money_link_features.rb +62 -66
- data/lib/moneykit/models/moneylink_features.rb +50 -49
- data/lib/moneykit/models/numbers.rb +60 -73
- data/lib/moneykit/models/owner.rb +76 -89
- data/lib/moneykit/models/phone.rb +60 -68
- data/lib/moneykit/models/phone_number.rb +63 -74
- data/lib/moneykit/models/phone_number_type.rb +14 -15
- data/lib/moneykit/models/product.rb +14 -15
- data/lib/moneykit/models/products.rb +52 -64
- data/lib/moneykit/models/products1.rb +48 -56
- data/lib/moneykit/models/products_settings.rb +58 -70
- data/lib/moneykit/models/provider.rb +18 -17
- data/lib/moneykit/models/public_link_error.rb +43 -0
- data/lib/moneykit/models/refresh_products_request.rb +52 -65
- data/lib/moneykit/models/requested_link_permission.rb +60 -75
- data/lib/moneykit/models/response401_disconnect_links_id_delete.rb +83 -283
- data/lib/moneykit/models/response401_exchange_token_link_session_exchange_token_post.rb +82 -281
- data/lib/moneykit/models/response401_get_account_links_id_accounts_account_id_get.rb +83 -283
- data/lib/moneykit/models/response401_get_account_numbers_links_id_accounts_numbers_get.rb +83 -283
- data/lib/moneykit/models/response401_get_accounts_links_id_accounts_get.rb +83 -283
- data/lib/moneykit/models/response401_get_identities_links_id_identity_get.rb +83 -283
- data/lib/moneykit/models/response401_get_institution_institutions_institution_id_get.rb +82 -281
- data/lib/moneykit/models/response401_get_institution_styling_institutions_institution_id_styling_get.rb +66 -72
- data/lib/moneykit/models/response401_get_institutions_institutions_get.rb +82 -281
- data/lib/moneykit/models/response401_get_link_links_id_get.rb +83 -283
- data/lib/moneykit/models/response401_get_transactions_diff_links_id_transactions_sync_get.rb +83 -283
- data/lib/moneykit/models/response401_get_transactions_links_id_transactions_get.rb +83 -283
- data/lib/moneykit/models/response401_get_user_accounts_users_id_accounts_get.rb +82 -281
- data/lib/moneykit/models/response401_get_user_links_users_id_links_get.rb +82 -281
- data/lib/moneykit/models/response401_get_user_transactions_users_id_transactions_get.rb +82 -281
- data/lib/moneykit/models/response401_get_well_known_jwks_well_known_jwks_json_get.rb +82 -281
- data/lib/moneykit/models/response401_instrospect_client_auth_introspect_get.rb +82 -281
- data/lib/moneykit/models/response401_refresh_products_links_id_products_post.rb +83 -283
- data/lib/moneykit/models/response401_reset_login_links_id_reset_post.rb +102 -0
- data/lib/moneykit/models/response401_trigger_test_link_webhook_event_webhooks_test_link_id_post.rb +102 -0
- data/lib/moneykit/models/response401_update_link_links_id_patch.rb +83 -283
- data/lib/moneykit/models/settings.rb +61 -73
- data/lib/moneykit/models/supported_version.rb +11 -12
- data/lib/moneykit/models/transaction.rb +104 -131
- data/lib/moneykit/models/transaction_diff.rb +69 -78
- data/lib/moneykit/models/transaction_sync_response.rb +65 -87
- data/lib/moneykit/models/transaction_type.rb +12 -13
- data/lib/moneykit/models/transaction_type_filter.rb +12 -13
- data/lib/moneykit/models/transactions.rb +58 -57
- data/lib/moneykit/models/transactions1.rb +55 -63
- data/lib/moneykit/models/transactions_link_product.rb +57 -69
- data/lib/moneykit/models/transactions_product_settings.rb +67 -71
- data/lib/moneykit/models/update_link_request.rb +63 -69
- data/lib/moneykit/models/user_accounts_out.rb +40 -40
- data/lib/moneykit/models/user_links_out.rb +40 -40
- data/lib/moneykit/models/user_transactions_paged_response.rb +40 -40
- data/lib/moneykit/models/validation_error.rb +63 -77
- data/lib/moneykit/models/validation_error_location_inner.rb +101 -0
- data/lib/moneykit/models/webhook_link_test_event.rb +40 -0
- data/lib/moneykit/models/webhook_test_link_request.rb +252 -0
- data/lib/moneykit/models/webhook_test_link_response.rb +220 -0
- data/lib/moneykit/version.rb +10 -12
- data/lib/moneykit.rb +18 -39
- data/lib/plaid_compatible/money_kit_plaid_compatible/api/plaid_api.rb +738 -737
- data/lib/plaid_compatible/money_kit_plaid_compatible/api_client.rb +339 -340
- data/lib/plaid_compatible/money_kit_plaid_compatible/api_error.rb +47 -47
- data/lib/plaid_compatible/money_kit_plaid_compatible/configuration.rb +258 -260
- data/lib/plaid_compatible/money_kit_plaid_compatible/models/account_balance.rb +210 -212
- data/lib/plaid_compatible/money_kit_plaid_compatible/models/account_base.rb +221 -237
- data/lib/plaid_compatible/money_kit_plaid_compatible/models/account_identity.rb +231 -252
- data/lib/plaid_compatible/money_kit_plaid_compatible/models/account_subtype.rb +100 -101
- data/lib/plaid_compatible/money_kit_plaid_compatible/models/account_type.rb +35 -36
- data/lib/plaid_compatible/money_kit_plaid_compatible/models/accounts_get_request.rb +209 -211
- data/lib/plaid_compatible/money_kit_plaid_compatible/models/accounts_get_request_options.rb +188 -185
- data/lib/plaid_compatible/money_kit_plaid_compatible/models/accounts_get_response.rb +205 -210
- data/lib/plaid_compatible/money_kit_plaid_compatible/models/address.rb +195 -193
- data/lib/plaid_compatible/money_kit_plaid_compatible/models/address_data.rb +222 -226
- data/lib/plaid_compatible/money_kit_plaid_compatible/models/auth_get_numbers.rb +218 -226
- data/lib/plaid_compatible/money_kit_plaid_compatible/models/auth_get_request.rb +209 -211
- data/lib/plaid_compatible/money_kit_plaid_compatible/models/auth_get_request_options.rb +188 -185
- data/lib/plaid_compatible/money_kit_plaid_compatible/models/auth_get_response.rb +211 -222
- data/lib/plaid_compatible/money_kit_plaid_compatible/models/country_code.rb +32 -33
- data/lib/plaid_compatible/money_kit_plaid_compatible/models/email.rb +197 -198
- data/lib/plaid_compatible/money_kit_plaid_compatible/models/http_validation_error.rb +183 -181
- data/lib/plaid_compatible/money_kit_plaid_compatible/models/identity_get_request.rb +209 -211
- data/lib/plaid_compatible/money_kit_plaid_compatible/models/identity_get_request_options.rb +188 -185
- data/lib/plaid_compatible/money_kit_plaid_compatible/models/identity_get_response.rb +205 -210
- data/lib/plaid_compatible/money_kit_plaid_compatible/models/institution.rb +228 -232
- data/lib/plaid_compatible/money_kit_plaid_compatible/models/institutions_get_by_id_request.rb +216 -217
- data/lib/plaid_compatible/money_kit_plaid_compatible/models/institutions_get_by_id_response.rb +195 -196
- data/lib/plaid_compatible/money_kit_plaid_compatible/models/item.rb +251 -261
- data/lib/plaid_compatible/money_kit_plaid_compatible/models/item_error_webhook.rb +217 -229
- data/lib/plaid_compatible/money_kit_plaid_compatible/models/item_get_request.rb +205 -205
- data/lib/plaid_compatible/money_kit_plaid_compatible/models/item_get_response.rb +201 -205
- data/lib/plaid_compatible/money_kit_plaid_compatible/models/item_public_token_exchange_request.rb +205 -205
- data/lib/plaid_compatible/money_kit_plaid_compatible/models/item_public_token_exchange_response.rb +206 -211
- data/lib/plaid_compatible/money_kit_plaid_compatible/models/item_remove_request.rb +205 -205
- data/lib/plaid_compatible/money_kit_plaid_compatible/models/item_remove_response.rb +188 -185
- data/lib/plaid_compatible/money_kit_plaid_compatible/models/item_status_investments.rb +195 -193
- data/lib/plaid_compatible/money_kit_plaid_compatible/models/item_status_last_webhook.rb +195 -193
- data/lib/plaid_compatible/money_kit_plaid_compatible/models/item_status_nullable.rb +194 -198
- data/lib/plaid_compatible/money_kit_plaid_compatible/models/item_status_transactions.rb +195 -193
- data/lib/plaid_compatible/money_kit_plaid_compatible/models/link_token_create_request.rb +272 -291
- data/lib/plaid_compatible/money_kit_plaid_compatible/models/link_token_create_request_user.rb +225 -225
- data/lib/plaid_compatible/money_kit_plaid_compatible/models/link_token_create_response.rb +206 -211
- data/lib/plaid_compatible/money_kit_plaid_compatible/models/numbers_ach.rb +215 -221
- data/lib/plaid_compatible/money_kit_plaid_compatible/models/numbers_bacs.rb +206 -211
- data/lib/plaid_compatible/money_kit_plaid_compatible/models/numbers_eft.rb +215 -224
- data/lib/plaid_compatible/money_kit_plaid_compatible/models/numbers_international.rb +206 -211
- data/lib/plaid_compatible/money_kit_plaid_compatible/models/owner.rb +218 -226
- data/lib/plaid_compatible/money_kit_plaid_compatible/models/personal_finance_category.rb +197 -198
- data/lib/plaid_compatible/money_kit_plaid_compatible/models/phone_number.rb +206 -211
- data/lib/plaid_compatible/money_kit_plaid_compatible/models/plaid_error.rb +253 -266
- data/lib/plaid_compatible/money_kit_plaid_compatible/models/plaid_error_type.rb +43 -44
- data/lib/plaid_compatible/money_kit_plaid_compatible/models/products.rb +33 -34
- data/lib/plaid_compatible/money_kit_plaid_compatible/models/removed_transaction.rb +187 -183
- data/lib/plaid_compatible/money_kit_plaid_compatible/models/transaction.rb +288 -315
- data/lib/plaid_compatible/money_kit_plaid_compatible/models/transactions_get_request.rb +225 -235
- data/lib/plaid_compatible/money_kit_plaid_compatible/models/transactions_get_request_options.rb +222 -224
- data/lib/plaid_compatible/money_kit_plaid_compatible/models/transactions_get_response.rb +225 -236
- data/lib/plaid_compatible/money_kit_plaid_compatible/models/transactions_refresh_request.rb +205 -205
- data/lib/plaid_compatible/money_kit_plaid_compatible/models/transactions_refresh_response.rb +188 -185
- data/lib/plaid_compatible/money_kit_plaid_compatible/models/transactions_sync_request.rb +223 -229
- data/lib/plaid_compatible/money_kit_plaid_compatible/models/transactions_sync_request_options.rb +197 -193
- data/lib/plaid_compatible/money_kit_plaid_compatible/models/transactions_sync_response.rb +235 -252
- data/lib/plaid_compatible/money_kit_plaid_compatible/models/validation_error.rb +198 -207
- data/lib/plaid_compatible/money_kit_plaid_compatible/models/webhook_environment_values.rb +32 -33
- data/lib/plaid_compatible/money_kit_plaid_compatible/version.rb +14 -14
- data/lib/plaid_compatible/money_kit_plaid_compatible.rb +24 -24
- data/moneykit.gemspec +22 -25
- metadata +14 -5
@@ -1,14 +1,12 @@
|
|
1
|
-
|
2
|
-
#
|
3
|
-
|
4
|
-
#
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
=end
|
1
|
+
# #MoneyKit API
|
2
|
+
#
|
3
|
+
# No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
|
4
|
+
#
|
5
|
+
# The version of the OpenAPI document: 0.1.0
|
6
|
+
#
|
7
|
+
# Generated by: https://openapi-generator.tech
|
8
|
+
# OpenAPI Generator version: 7.1.0
|
9
|
+
#
|
12
10
|
|
13
11
|
require 'date'
|
14
12
|
require 'time'
|
@@ -29,10 +27,10 @@ module MoneyKit
|
|
29
27
|
# Attribute mapping from ruby-style variable name to JSON key.
|
30
28
|
def self.attribute_map
|
31
29
|
{
|
32
|
-
|
33
|
-
|
34
|
-
|
35
|
-
|
30
|
+
'name': :name,
|
31
|
+
'last_synced_at': :last_synced_at,
|
32
|
+
'institution_id': :institution_id,
|
33
|
+
'link_id': :link_id
|
36
34
|
}
|
37
35
|
end
|
38
36
|
|
@@ -44,67 +42,57 @@ module MoneyKit
|
|
44
42
|
# Attribute type mapping.
|
45
43
|
def self.openapi_types
|
46
44
|
{
|
47
|
-
|
48
|
-
|
49
|
-
|
50
|
-
|
45
|
+
'name': :String,
|
46
|
+
'last_synced_at': :Time,
|
47
|
+
'institution_id': :String,
|
48
|
+
'link_id': :String
|
51
49
|
}
|
52
50
|
end
|
53
51
|
|
54
52
|
# List of attributes with nullable: true
|
55
53
|
def self.openapi_nullable
|
56
|
-
Set.new([
|
57
|
-
:'last_synced_at',
|
58
|
-
])
|
54
|
+
Set.new([])
|
59
55
|
end
|
60
56
|
|
61
57
|
# Initializes the object
|
62
58
|
# @param [Hash] attributes Model attributes in the form of hash
|
63
59
|
def initialize(attributes = {})
|
64
|
-
|
65
|
-
|
60
|
+
unless attributes.is_a?(Hash)
|
61
|
+
raise ArgumentError,
|
62
|
+
'The input argument (attributes) must be a hash in `MoneyKit::BasicAccountDetails` initialize method'
|
66
63
|
end
|
67
64
|
|
68
65
|
# check to see if the attribute exists and convert string to symbol for hash key
|
69
|
-
attributes = attributes.each_with_object({})
|
70
|
-
|
71
|
-
|
66
|
+
attributes = attributes.each_with_object({}) do |(k, v), h|
|
67
|
+
unless self.class.attribute_map.key?(k.to_sym)
|
68
|
+
raise ArgumentError,
|
69
|
+
"`#{k}` is not a valid attribute in `MoneyKit::BasicAccountDetails`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
|
72
70
|
end
|
73
|
-
h[k.to_sym] = v
|
74
|
-
}
|
75
71
|
|
76
|
-
|
77
|
-
self.name = attributes[:'name']
|
72
|
+
h[k.to_sym] = v
|
78
73
|
end
|
79
74
|
|
80
|
-
if attributes.key?(:
|
81
|
-
self.last_synced_at = attributes[:'last_synced_at']
|
82
|
-
end
|
75
|
+
self.name = (attributes[:name] if attributes.key?(:name))
|
83
76
|
|
84
|
-
if attributes.key?(:
|
85
|
-
self.institution_id = attributes[:'institution_id']
|
86
|
-
end
|
77
|
+
self.last_synced_at = attributes[:last_synced_at] if attributes.key?(:last_synced_at)
|
87
78
|
|
88
|
-
if attributes.key?(:
|
89
|
-
|
90
|
-
|
79
|
+
self.institution_id = (attributes[:institution_id] if attributes.key?(:institution_id))
|
80
|
+
|
81
|
+
self.link_id = (attributes[:link_id] if attributes.key?(:link_id))
|
91
82
|
end
|
92
83
|
|
93
84
|
# Show invalid properties with the reasons. Usually used together with valid?
|
94
85
|
# @return Array for valid properties with the reasons
|
95
86
|
def list_invalid_properties
|
96
|
-
|
97
|
-
|
98
|
-
|
99
|
-
end
|
87
|
+
warn '[DEPRECATED] the `list_invalid_properties` method is obsolete'
|
88
|
+
invalid_properties = []
|
89
|
+
invalid_properties.push('invalid value for "name", name cannot be nil.') if @name.nil?
|
100
90
|
|
101
91
|
if @institution_id.nil?
|
102
92
|
invalid_properties.push('invalid value for "institution_id", institution_id cannot be nil.')
|
103
93
|
end
|
104
94
|
|
105
|
-
if @link_id.nil?
|
106
|
-
invalid_properties.push('invalid value for "link_id", link_id cannot be nil.')
|
107
|
-
end
|
95
|
+
invalid_properties.push('invalid value for "link_id", link_id cannot be nil.') if @link_id.nil?
|
108
96
|
|
109
97
|
invalid_properties
|
110
98
|
end
|
@@ -112,27 +100,30 @@ module MoneyKit
|
|
112
100
|
# Check to see if the all the properties in the model are valid
|
113
101
|
# @return true if the model is valid
|
114
102
|
def valid?
|
103
|
+
warn '[DEPRECATED] the `valid?` method is obsolete'
|
115
104
|
return false if @name.nil?
|
116
105
|
return false if @institution_id.nil?
|
117
106
|
return false if @link_id.nil?
|
107
|
+
|
118
108
|
true
|
119
109
|
end
|
120
110
|
|
121
111
|
# Checks equality by comparing each attribute.
|
122
112
|
# @param [Object] Object to be compared
|
123
|
-
def ==(
|
124
|
-
return true if
|
125
|
-
|
126
|
-
|
127
|
-
|
128
|
-
|
129
|
-
|
113
|
+
def ==(other)
|
114
|
+
return true if equal?(other)
|
115
|
+
|
116
|
+
self.class == other.class &&
|
117
|
+
name == other.name &&
|
118
|
+
last_synced_at == other.last_synced_at &&
|
119
|
+
institution_id == other.institution_id &&
|
120
|
+
link_id == other.link_id
|
130
121
|
end
|
131
122
|
|
132
123
|
# @see the `==` method
|
133
124
|
# @param [Object] Object to be compared
|
134
|
-
def eql?(
|
135
|
-
self ==
|
125
|
+
def eql?(other)
|
126
|
+
self == other
|
136
127
|
end
|
137
128
|
|
138
129
|
# Calculates hash code according to all attributes.
|
@@ -145,37 +136,33 @@ module MoneyKit
|
|
145
136
|
# @param [Hash] attributes Model attributes in the form of hash
|
146
137
|
# @return [Object] Returns the model itself
|
147
138
|
def self.build_from_hash(attributes)
|
148
|
-
new.build_from_hash(attributes)
|
149
|
-
end
|
150
|
-
|
151
|
-
# Builds the object from hash
|
152
|
-
# @param [Hash] attributes Model attributes in the form of hash
|
153
|
-
# @return [Object] Returns the model itself
|
154
|
-
def build_from_hash(attributes)
|
155
139
|
return nil unless attributes.is_a?(Hash)
|
140
|
+
|
156
141
|
attributes = attributes.transform_keys(&:to_sym)
|
157
|
-
|
158
|
-
|
159
|
-
|
142
|
+
transformed_hash = {}
|
143
|
+
openapi_types.each_pair do |key, type|
|
144
|
+
if attributes.key?(attribute_map[key]) && attributes[attribute_map[key]].nil?
|
145
|
+
transformed_hash["#{key}"] = nil
|
160
146
|
elsif type =~ /\AArray<(.*)>/i
|
161
147
|
# check to ensure the input is an array given that the attribute
|
162
148
|
# is documented as an array but the input is not
|
163
|
-
if attributes[
|
164
|
-
|
149
|
+
if attributes[attribute_map[key]].is_a?(Array)
|
150
|
+
transformed_hash["#{key}"] = attributes[attribute_map[key]].map do |v|
|
151
|
+
_deserialize(::Regexp.last_match(1), v)
|
152
|
+
end
|
165
153
|
end
|
166
|
-
elsif !attributes[
|
167
|
-
|
154
|
+
elsif !attributes[attribute_map[key]].nil?
|
155
|
+
transformed_hash["#{key}"] = _deserialize(type, attributes[attribute_map[key]])
|
168
156
|
end
|
169
157
|
end
|
170
|
-
|
171
|
-
self
|
158
|
+
new(transformed_hash)
|
172
159
|
end
|
173
160
|
|
174
161
|
# Deserializes the data based on type
|
175
162
|
# @param string type Data type
|
176
163
|
# @param string value Value to be deserialized
|
177
164
|
# @return [Object] Deserialized data
|
178
|
-
def _deserialize(type, value)
|
165
|
+
def self._deserialize(type, value)
|
179
166
|
case type.to_sym
|
180
167
|
when :Time
|
181
168
|
Time.parse(value)
|
@@ -210,7 +197,7 @@ module MoneyKit
|
|
210
197
|
else # model
|
211
198
|
# models (e.g. Pet) or oneOf
|
212
199
|
klass = MoneyKit.const_get(type)
|
213
|
-
klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
|
200
|
+
klass.respond_to?(:openapi_any_of) || klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
|
214
201
|
end
|
215
202
|
end
|
216
203
|
|
@@ -231,7 +218,7 @@ module MoneyKit
|
|
231
218
|
def to_hash
|
232
219
|
hash = {}
|
233
220
|
self.class.attribute_map.each_pair do |attr, param|
|
234
|
-
value =
|
221
|
+
value = send(attr)
|
235
222
|
if value.nil?
|
236
223
|
is_nullable = self.class.openapi_nullable.include?(attr)
|
237
224
|
next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
|
@@ -259,7 +246,5 @@ module MoneyKit
|
|
259
246
|
value
|
260
247
|
end
|
261
248
|
end
|
262
|
-
|
263
249
|
end
|
264
|
-
|
265
250
|
end
|
@@ -1,23 +1,21 @@
|
|
1
|
-
|
2
|
-
#
|
3
|
-
|
4
|
-
#
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
=end
|
1
|
+
# #MoneyKit API
|
2
|
+
#
|
3
|
+
# No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
|
4
|
+
#
|
5
|
+
# The version of the OpenAPI document: 0.1.0
|
6
|
+
#
|
7
|
+
# Generated by: https://openapi-generator.tech
|
8
|
+
# OpenAPI Generator version: 7.1.0
|
9
|
+
#
|
12
10
|
|
13
11
|
require 'date'
|
14
12
|
require 'time'
|
15
13
|
|
16
14
|
module MoneyKit
|
17
15
|
class Country
|
18
|
-
US =
|
19
|
-
GB =
|
20
|
-
CA =
|
16
|
+
US = 'US'.freeze
|
17
|
+
GB = 'GB'.freeze
|
18
|
+
CA = 'CA'.freeze
|
21
19
|
|
22
20
|
def self.all_vars
|
23
21
|
@all_vars ||= [US, GB, CA].freeze
|
@@ -35,6 +33,7 @@ module MoneyKit
|
|
35
33
|
# @return [String] The enum value
|
36
34
|
def build_from_hash(value)
|
37
35
|
return value if Country.all_vars.include?(value)
|
36
|
+
|
38
37
|
raise "Invalid ENUM value #{value} for class #Country"
|
39
38
|
end
|
40
39
|
end
|
@@ -1,48 +1,43 @@
|
|
1
|
-
|
2
|
-
#
|
3
|
-
|
4
|
-
#
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
=end
|
1
|
+
# #MoneyKit API
|
2
|
+
#
|
3
|
+
# No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
|
4
|
+
#
|
5
|
+
# The version of the OpenAPI document: 0.1.0
|
6
|
+
#
|
7
|
+
# Generated by: https://openapi-generator.tech
|
8
|
+
# OpenAPI Generator version: 7.1.0
|
9
|
+
#
|
12
10
|
|
13
11
|
require 'date'
|
14
12
|
require 'time'
|
15
13
|
|
16
14
|
module MoneyKit
|
17
15
|
class CreateLinkSessionRequest
|
18
|
-
attr_accessor :settings
|
19
|
-
|
20
|
-
attr_accessor :customer_user
|
16
|
+
attr_accessor :settings, :customer_user, :link_tags, :moneylink_features
|
21
17
|
|
22
18
|
# Supply the existing `link_id` if you are asking the user to reconnect this link.
|
23
19
|
attr_accessor :existing_link_id
|
24
20
|
|
21
|
+
# The ID of the institution you want to link to. Providing this will skip the institution selection step. `existing_link_id` will take precedence over this field if both are provided.
|
22
|
+
attr_accessor :institution_id
|
23
|
+
|
25
24
|
# For Oauth linking, a URI indicating the destination, in your application, where the user should be sent after authenticating with the institution. The `redirect_uri` should not contain any query parameters, and it must be pre-approved by MoneyKit during the customer setup process.
|
26
25
|
attr_accessor :redirect_uri
|
27
26
|
|
28
27
|
# The destination URL to which any webhooks should be sent.
|
29
28
|
attr_accessor :webhook
|
30
29
|
|
31
|
-
# You can supply one or more arbitrary strings as tags to describe this link.
|
32
|
-
attr_accessor :link_tags
|
33
|
-
|
34
|
-
attr_accessor :moneylink_features
|
35
|
-
|
36
30
|
# Attribute mapping from ruby-style variable name to JSON key.
|
37
31
|
def self.attribute_map
|
38
32
|
{
|
39
|
-
|
40
|
-
|
41
|
-
|
42
|
-
|
43
|
-
|
44
|
-
|
45
|
-
|
33
|
+
'settings': :settings,
|
34
|
+
'customer_user': :customer_user,
|
35
|
+
'existing_link_id': :existing_link_id,
|
36
|
+
'institution_id': :institution_id,
|
37
|
+
'redirect_uri': :redirect_uri,
|
38
|
+
'webhook': :webhook,
|
39
|
+
'link_tags': :link_tags,
|
40
|
+
'moneylink_features': :moneylink_features
|
46
41
|
}
|
47
42
|
end
|
48
43
|
|
@@ -54,89 +49,79 @@ module MoneyKit
|
|
54
49
|
# Attribute type mapping.
|
55
50
|
def self.openapi_types
|
56
51
|
{
|
57
|
-
|
58
|
-
|
59
|
-
|
60
|
-
|
61
|
-
|
62
|
-
|
63
|
-
|
52
|
+
'settings': :LinkSessionSettingOverrides,
|
53
|
+
'customer_user': :LinkSessionCustomerUser,
|
54
|
+
'existing_link_id': :String,
|
55
|
+
'institution_id': :String,
|
56
|
+
'redirect_uri': :String,
|
57
|
+
'webhook': :String,
|
58
|
+
'link_tags': :'Array<String>',
|
59
|
+
'moneylink_features': :MoneyLinkFeatures
|
64
60
|
}
|
65
61
|
end
|
66
62
|
|
67
63
|
# List of attributes with nullable: true
|
68
64
|
def self.openapi_nullable
|
69
|
-
Set.new([
|
70
|
-
:'settings',
|
71
|
-
:'existing_link_id',
|
72
|
-
:'redirect_uri',
|
73
|
-
:'webhook',
|
74
|
-
])
|
65
|
+
Set.new([])
|
75
66
|
end
|
76
67
|
|
77
68
|
# Initializes the object
|
78
69
|
# @param [Hash] attributes Model attributes in the form of hash
|
79
70
|
def initialize(attributes = {})
|
80
|
-
|
81
|
-
|
71
|
+
unless attributes.is_a?(Hash)
|
72
|
+
raise ArgumentError,
|
73
|
+
'The input argument (attributes) must be a hash in `MoneyKit::CreateLinkSessionRequest` initialize method'
|
82
74
|
end
|
83
75
|
|
84
76
|
# check to see if the attribute exists and convert string to symbol for hash key
|
85
|
-
attributes = attributes.each_with_object({})
|
86
|
-
|
87
|
-
|
77
|
+
attributes = attributes.each_with_object({}) do |(k, v), h|
|
78
|
+
unless self.class.attribute_map.key?(k.to_sym)
|
79
|
+
raise ArgumentError,
|
80
|
+
"`#{k}` is not a valid attribute in `MoneyKit::CreateLinkSessionRequest`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
|
88
81
|
end
|
89
|
-
h[k.to_sym] = v
|
90
|
-
}
|
91
82
|
|
92
|
-
|
93
|
-
self.settings = attributes[:'settings']
|
83
|
+
h[k.to_sym] = v
|
94
84
|
end
|
95
85
|
|
96
|
-
if attributes.key?(:
|
97
|
-
self.customer_user = attributes[:'customer_user']
|
98
|
-
end
|
86
|
+
self.settings = attributes[:settings] if attributes.key?(:settings)
|
99
87
|
|
100
|
-
if attributes.key?(:
|
101
|
-
self.existing_link_id = attributes[:'existing_link_id']
|
102
|
-
end
|
88
|
+
self.customer_user = (attributes[:customer_user] if attributes.key?(:customer_user))
|
103
89
|
|
104
|
-
if attributes.key?(:
|
105
|
-
self.redirect_uri = attributes[:'redirect_uri']
|
106
|
-
end
|
90
|
+
self.existing_link_id = attributes[:existing_link_id] if attributes.key?(:existing_link_id)
|
107
91
|
|
108
|
-
if attributes.key?(:
|
109
|
-
self.webhook = attributes[:'webhook']
|
110
|
-
end
|
92
|
+
self.institution_id = attributes[:institution_id] if attributes.key?(:institution_id)
|
111
93
|
|
112
|
-
if attributes.key?(:
|
113
|
-
if (value = attributes[:'link_tags']).is_a?(Array)
|
114
|
-
self.link_tags = value
|
115
|
-
end
|
116
|
-
end
|
94
|
+
self.redirect_uri = (attributes[:redirect_uri] if attributes.key?(:redirect_uri))
|
117
95
|
|
118
|
-
if attributes.key?(:
|
119
|
-
|
96
|
+
self.webhook = attributes[:webhook] if attributes.key?(:webhook)
|
97
|
+
|
98
|
+
if attributes.key?(:link_tags) && (value = attributes[:link_tags]).is_a?(Array)
|
99
|
+
self.link_tags = value
|
120
100
|
end
|
101
|
+
|
102
|
+
return unless attributes.key?(:moneylink_features)
|
103
|
+
|
104
|
+
self.moneylink_features = attributes[:moneylink_features]
|
121
105
|
end
|
122
106
|
|
123
107
|
# Show invalid properties with the reasons. Usually used together with valid?
|
124
108
|
# @return Array for valid properties with the reasons
|
125
109
|
def list_invalid_properties
|
126
|
-
|
127
|
-
|
128
|
-
|
129
|
-
|
110
|
+
warn '[DEPRECATED] the `list_invalid_properties` method is obsolete'
|
111
|
+
invalid_properties = []
|
112
|
+
invalid_properties.push('invalid value for "customer_user", customer_user cannot be nil.') if @customer_user.nil?
|
113
|
+
|
114
|
+
invalid_properties.push('invalid value for "redirect_uri", redirect_uri cannot be nil.') if @redirect_uri.nil?
|
130
115
|
|
131
|
-
if
|
116
|
+
if @redirect_uri.to_s.length > 65_536
|
132
117
|
invalid_properties.push('invalid value for "redirect_uri", the character length must be smaller than or equal to 65536.')
|
133
118
|
end
|
134
119
|
|
135
|
-
if
|
120
|
+
if @redirect_uri.to_s.length < 1
|
136
121
|
invalid_properties.push('invalid value for "redirect_uri", the character length must be great than or equal to 1.')
|
137
122
|
end
|
138
123
|
|
139
|
-
if !@webhook.nil? && @webhook.to_s.length >
|
124
|
+
if !@webhook.nil? && @webhook.to_s.length > 65_536
|
140
125
|
invalid_properties.push('invalid value for "webhook", the character length must be smaller than or equal to 65536.')
|
141
126
|
end
|
142
127
|
|
@@ -150,23 +135,29 @@ module MoneyKit
|
|
150
135
|
# Check to see if the all the properties in the model are valid
|
151
136
|
# @return true if the model is valid
|
152
137
|
def valid?
|
138
|
+
warn '[DEPRECATED] the `valid?` method is obsolete'
|
153
139
|
return false if @customer_user.nil?
|
154
|
-
return false if
|
155
|
-
return false if
|
156
|
-
return false if
|
140
|
+
return false if @redirect_uri.nil?
|
141
|
+
return false if @redirect_uri.to_s.length > 65_536
|
142
|
+
return false if @redirect_uri.to_s.length < 1
|
143
|
+
return false if !@webhook.nil? && @webhook.to_s.length > 65_536
|
157
144
|
return false if !@webhook.nil? && @webhook.to_s.length < 1
|
145
|
+
|
158
146
|
true
|
159
147
|
end
|
160
148
|
|
161
149
|
# Custom attribute writer method with validation
|
162
150
|
# @param [Object] redirect_uri Value to be assigned
|
163
151
|
def redirect_uri=(redirect_uri)
|
164
|
-
|
165
|
-
|
152
|
+
raise ArgumentError, 'redirect_uri cannot be nil' if redirect_uri.nil?
|
153
|
+
|
154
|
+
if redirect_uri.to_s.length > 65_536
|
155
|
+
raise ArgumentError,
|
156
|
+
'invalid value for "redirect_uri", the character length must be smaller than or equal to 65536.'
|
166
157
|
end
|
167
158
|
|
168
|
-
if
|
169
|
-
|
159
|
+
if redirect_uri.to_s.length < 1
|
160
|
+
raise ArgumentError, 'invalid value for "redirect_uri", the character length must be great than or equal to 1.'
|
170
161
|
end
|
171
162
|
|
172
163
|
@redirect_uri = redirect_uri
|
@@ -175,12 +166,14 @@ module MoneyKit
|
|
175
166
|
# Custom attribute writer method with validation
|
176
167
|
# @param [Object] webhook Value to be assigned
|
177
168
|
def webhook=(webhook)
|
178
|
-
|
179
|
-
|
169
|
+
raise ArgumentError, 'webhook cannot be nil' if webhook.nil?
|
170
|
+
|
171
|
+
if webhook.to_s.length > 65_536
|
172
|
+
raise ArgumentError, 'invalid value for "webhook", the character length must be smaller than or equal to 65536.'
|
180
173
|
end
|
181
174
|
|
182
|
-
if
|
183
|
-
|
175
|
+
if webhook.to_s.length < 1
|
176
|
+
raise ArgumentError, 'invalid value for "webhook", the character length must be great than or equal to 1.'
|
184
177
|
end
|
185
178
|
|
186
179
|
@webhook = webhook
|
@@ -188,65 +181,64 @@ module MoneyKit
|
|
188
181
|
|
189
182
|
# Checks equality by comparing each attribute.
|
190
183
|
# @param [Object] Object to be compared
|
191
|
-
def ==(
|
192
|
-
return true if
|
193
|
-
|
194
|
-
|
195
|
-
|
196
|
-
|
197
|
-
|
198
|
-
|
199
|
-
|
200
|
-
|
184
|
+
def ==(other)
|
185
|
+
return true if equal?(other)
|
186
|
+
|
187
|
+
self.class == other.class &&
|
188
|
+
settings == other.settings &&
|
189
|
+
customer_user == other.customer_user &&
|
190
|
+
existing_link_id == other.existing_link_id &&
|
191
|
+
institution_id == other.institution_id &&
|
192
|
+
redirect_uri == other.redirect_uri &&
|
193
|
+
webhook == other.webhook &&
|
194
|
+
link_tags == other.link_tags &&
|
195
|
+
moneylink_features == other.moneylink_features
|
201
196
|
end
|
202
197
|
|
203
198
|
# @see the `==` method
|
204
199
|
# @param [Object] Object to be compared
|
205
|
-
def eql?(
|
206
|
-
self ==
|
200
|
+
def eql?(other)
|
201
|
+
self == other
|
207
202
|
end
|
208
203
|
|
209
204
|
# Calculates hash code according to all attributes.
|
210
205
|
# @return [Integer] Hash code
|
211
206
|
def hash
|
212
|
-
[settings, customer_user, existing_link_id, redirect_uri, webhook, link_tags,
|
207
|
+
[settings, customer_user, existing_link_id, institution_id, redirect_uri, webhook, link_tags,
|
208
|
+
moneylink_features].hash
|
213
209
|
end
|
214
210
|
|
215
211
|
# Builds the object from hash
|
216
212
|
# @param [Hash] attributes Model attributes in the form of hash
|
217
213
|
# @return [Object] Returns the model itself
|
218
214
|
def self.build_from_hash(attributes)
|
219
|
-
new.build_from_hash(attributes)
|
220
|
-
end
|
221
|
-
|
222
|
-
# Builds the object from hash
|
223
|
-
# @param [Hash] attributes Model attributes in the form of hash
|
224
|
-
# @return [Object] Returns the model itself
|
225
|
-
def build_from_hash(attributes)
|
226
215
|
return nil unless attributes.is_a?(Hash)
|
216
|
+
|
227
217
|
attributes = attributes.transform_keys(&:to_sym)
|
228
|
-
|
229
|
-
|
230
|
-
|
218
|
+
transformed_hash = {}
|
219
|
+
openapi_types.each_pair do |key, type|
|
220
|
+
if attributes.key?(attribute_map[key]) && attributes[attribute_map[key]].nil?
|
221
|
+
transformed_hash["#{key}"] = nil
|
231
222
|
elsif type =~ /\AArray<(.*)>/i
|
232
223
|
# check to ensure the input is an array given that the attribute
|
233
224
|
# is documented as an array but the input is not
|
234
|
-
if attributes[
|
235
|
-
|
225
|
+
if attributes[attribute_map[key]].is_a?(Array)
|
226
|
+
transformed_hash["#{key}"] = attributes[attribute_map[key]].map do |v|
|
227
|
+
_deserialize(::Regexp.last_match(1), v)
|
228
|
+
end
|
236
229
|
end
|
237
|
-
elsif !attributes[
|
238
|
-
|
230
|
+
elsif !attributes[attribute_map[key]].nil?
|
231
|
+
transformed_hash["#{key}"] = _deserialize(type, attributes[attribute_map[key]])
|
239
232
|
end
|
240
233
|
end
|
241
|
-
|
242
|
-
self
|
234
|
+
new(transformed_hash)
|
243
235
|
end
|
244
236
|
|
245
237
|
# Deserializes the data based on type
|
246
238
|
# @param string type Data type
|
247
239
|
# @param string value Value to be deserialized
|
248
240
|
# @return [Object] Deserialized data
|
249
|
-
def _deserialize(type, value)
|
241
|
+
def self._deserialize(type, value)
|
250
242
|
case type.to_sym
|
251
243
|
when :Time
|
252
244
|
Time.parse(value)
|
@@ -281,7 +273,7 @@ module MoneyKit
|
|
281
273
|
else # model
|
282
274
|
# models (e.g. Pet) or oneOf
|
283
275
|
klass = MoneyKit.const_get(type)
|
284
|
-
klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
|
276
|
+
klass.respond_to?(:openapi_any_of) || klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
|
285
277
|
end
|
286
278
|
end
|
287
279
|
|
@@ -302,7 +294,7 @@ module MoneyKit
|
|
302
294
|
def to_hash
|
303
295
|
hash = {}
|
304
296
|
self.class.attribute_map.each_pair do |attr, param|
|
305
|
-
value =
|
297
|
+
value = send(attr)
|
306
298
|
if value.nil?
|
307
299
|
is_nullable = self.class.openapi_nullable.include?(attr)
|
308
300
|
next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
|
@@ -330,7 +322,5 @@ module MoneyKit
|
|
330
322
|
value
|
331
323
|
end
|
332
324
|
end
|
333
|
-
|
334
325
|
end
|
335
|
-
|
336
326
|
end
|