moneykit 0.0.2 → 0.0.3

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.
Files changed (212) hide show
  1. checksums.yaml +4 -4
  2. data/lib/moneykit/api/access_token_api.rb +53 -55
  3. data/lib/moneykit/api/account_numbers_api.rb +24 -24
  4. data/lib/moneykit/api/accounts_api.rb +86 -80
  5. data/lib/moneykit/api/identity_api.rb +29 -28
  6. data/lib/moneykit/api/institutions_api.rb +50 -48
  7. data/lib/moneykit/api/link_session_api.rb +47 -50
  8. data/lib/moneykit/api/links_api.rb +74 -81
  9. data/lib/moneykit/api/products_api.rb +31 -33
  10. data/lib/moneykit/api/transactions_api.rb +112 -87
  11. data/lib/moneykit/api/users_api.rb +96 -79
  12. data/lib/moneykit/api_client.rb +64 -71
  13. data/lib/moneykit/api_error.rb +14 -16
  14. data/lib/moneykit/configuration.rb +42 -45
  15. data/lib/moneykit/models/account.rb +62 -78
  16. data/lib/moneykit/models/account_balances.rb +58 -63
  17. data/lib/moneykit/models/account_group.rb +47 -47
  18. data/lib/moneykit/models/account_identity.rb +69 -89
  19. data/lib/moneykit/models/account_numbers.rb +50 -49
  20. data/lib/moneykit/models/account_numbers_link_product.rb +52 -54
  21. data/lib/moneykit/models/account_numbers_product_settings.rb +49 -48
  22. data/lib/moneykit/models/account_type.rb +23 -23
  23. data/lib/moneykit/models/account_with_account_numbers.rb +68 -89
  24. data/lib/moneykit/models/accounts_link_product.rb +46 -46
  25. data/lib/moneykit/models/ach_number.rb +48 -49
  26. data/lib/moneykit/models/address.rb +66 -75
  27. data/lib/moneykit/models/api_error_auth_expired_access_token_response.rb +63 -62
  28. data/lib/moneykit/models/api_error_auth_unauthorized_response.rb +60 -62
  29. data/lib/moneykit/models/api_error_rate_limit_exceeded_response.rb +63 -62
  30. data/lib/moneykit/models/app.rb +46 -50
  31. data/lib/moneykit/models/bacs_number.rb +45 -46
  32. data/lib/moneykit/models/balances.rb +58 -64
  33. data/lib/moneykit/models/basic_account_details.rb +55 -61
  34. data/lib/moneykit/models/country.rb +13 -14
  35. data/lib/moneykit/models/create_link_session_request.rb +83 -96
  36. data/lib/moneykit/models/create_link_session_response.rb +40 -37
  37. data/lib/moneykit/models/currency.rb +193 -193
  38. data/lib/moneykit/models/cursor.rb +40 -39
  39. data/lib/moneykit/models/cursor_pagination.rb +40 -38
  40. data/lib/moneykit/models/cursors.rb +40 -39
  41. data/lib/moneykit/models/customer_app.rb +46 -49
  42. data/lib/moneykit/models/customer_user.rb +59 -69
  43. data/lib/moneykit/models/eft_number.rb +48 -52
  44. data/lib/moneykit/models/email.rb +46 -48
  45. data/lib/moneykit/models/email1.rb +50 -53
  46. data/lib/moneykit/models/exchange_token_request.rb +40 -37
  47. data/lib/moneykit/models/exchange_token_response.rb +46 -49
  48. data/lib/moneykit/models/generate_access_token_response.rb +51 -58
  49. data/lib/moneykit/models/get_account_numbers_response.rb +48 -53
  50. data/lib/moneykit/models/get_account_response.rb +47 -52
  51. data/lib/moneykit/models/get_accounts_response.rb +47 -50
  52. data/lib/moneykit/models/get_institutions_response.rb +47 -50
  53. data/lib/moneykit/models/get_transactions_response.rb +68 -87
  54. data/lib/moneykit/models/get_user_accounts_response.rb +42 -42
  55. data/lib/moneykit/models/get_user_links_response.rb +42 -42
  56. data/lib/moneykit/models/get_user_transactions_response.rb +64 -82
  57. data/lib/moneykit/models/http_validation_error.rb +68 -71
  58. data/lib/moneykit/models/identity.rb +49 -49
  59. data/lib/moneykit/models/identity_link_product.rb +52 -54
  60. data/lib/moneykit/models/identity_product_settings.rb +49 -48
  61. data/lib/moneykit/models/identity_response.rb +47 -50
  62. data/lib/moneykit/models/institution.rb +77 -96
  63. data/lib/moneykit/models/institution_error_not_found_response.rb +63 -64
  64. data/lib/moneykit/models/institution_styling_response.rb +77 -93
  65. data/lib/moneykit/models/international_number.rb +46 -49
  66. data/lib/moneykit/models/introspect_client_response.rb +61 -73
  67. data/lib/moneykit/models/jwk_set.rb +41 -42
  68. data/lib/moneykit/models/link.rb +78 -100
  69. data/lib/moneykit/models/link1.rb +78 -100
  70. data/lib/moneykit/models/link2.rb +78 -100
  71. data/lib/moneykit/models/link3.rb +78 -100
  72. data/lib/moneykit/models/link4.rb +78 -100
  73. data/lib/moneykit/models/link_common.rb +78 -99
  74. data/lib/moneykit/models/link_error.rb +19 -19
  75. data/lib/moneykit/models/link_error_bad_state_response.rb +64 -72
  76. data/lib/moneykit/models/link_error_deleted_response.rb +63 -64
  77. data/lib/moneykit/models/link_error_forbidden_action_response.rb +60 -62
  78. data/lib/moneykit/models/link_error_not_found_response.rb +63 -64
  79. data/lib/moneykit/models/link_error_unauthorized_access_response.rb +63 -64
  80. data/lib/moneykit/models/link_permission_scope.rb +14 -15
  81. data/lib/moneykit/models/link_permissions.rb +43 -43
  82. data/lib/moneykit/models/link_products.rb +52 -63
  83. data/lib/moneykit/models/link_response.rb +90 -118
  84. data/lib/moneykit/models/link_session_customer_user.rb +58 -68
  85. data/lib/moneykit/models/link_session_customer_user_email.rb +50 -52
  86. data/lib/moneykit/models/link_session_customer_user_phone.rb +60 -67
  87. data/lib/moneykit/models/link_session_error_forbidden_config_response.rb +60 -62
  88. data/lib/moneykit/models/link_session_error_invalid_token_exchange.rb +60 -62
  89. data/lib/moneykit/models/link_session_setting_overrides.rb +61 -72
  90. data/lib/moneykit/models/link_state.rb +15 -16
  91. data/lib/moneykit/models/link_state_changed_webhook.rb +110 -134
  92. data/lib/moneykit/models/location_inner.rb +41 -46
  93. data/lib/moneykit/models/money_kit_env.rb +12 -13
  94. data/lib/moneykit/models/money_link_features.rb +49 -48
  95. data/lib/moneykit/models/moneylink_features.rb +50 -49
  96. data/lib/moneykit/models/numbers.rb +60 -73
  97. data/lib/moneykit/models/owner.rb +59 -72
  98. data/lib/moneykit/models/phone.rb +60 -68
  99. data/lib/moneykit/models/phone_number.rb +55 -59
  100. data/lib/moneykit/models/phone_number_type.rb +14 -15
  101. data/lib/moneykit/models/product.rb +14 -15
  102. data/lib/moneykit/models/products.rb +52 -64
  103. data/lib/moneykit/models/products1.rb +48 -56
  104. data/lib/moneykit/models/products_settings.rb +48 -55
  105. data/lib/moneykit/models/provider.rb +15 -16
  106. data/lib/moneykit/models/refresh_products_request.rb +43 -45
  107. data/lib/moneykit/models/requested_link_permission.rb +52 -60
  108. data/lib/moneykit/models/response401_disconnect_links_id_delete.rb +71 -77
  109. data/lib/moneykit/models/response401_exchange_token_link_session_exchange_token_post.rb +66 -72
  110. data/lib/moneykit/models/response401_get_account_links_id_accounts_account_id_get.rb +71 -77
  111. data/lib/moneykit/models/response401_get_account_numbers_links_id_accounts_numbers_get.rb +71 -77
  112. data/lib/moneykit/models/response401_get_accounts_links_id_accounts_get.rb +71 -77
  113. data/lib/moneykit/models/response401_get_identities_links_id_identity_get.rb +71 -77
  114. data/lib/moneykit/models/response401_get_institution_institutions_institution_id_get.rb +66 -72
  115. data/lib/moneykit/models/response401_get_institution_styling_institutions_institution_id_styling_get.rb +66 -72
  116. data/lib/moneykit/models/response401_get_institutions_institutions_get.rb +66 -72
  117. data/lib/moneykit/models/response401_get_link_links_id_get.rb +71 -77
  118. data/lib/moneykit/models/response401_get_transactions_diff_links_id_transactions_sync_get.rb +71 -77
  119. data/lib/moneykit/models/response401_get_transactions_links_id_transactions_get.rb +71 -77
  120. data/lib/moneykit/models/response401_get_user_accounts_users_id_accounts_get.rb +66 -72
  121. data/lib/moneykit/models/response401_get_user_links_users_id_links_get.rb +66 -72
  122. data/lib/moneykit/models/response401_get_user_transactions_users_id_transactions_get.rb +66 -72
  123. data/lib/moneykit/models/response401_get_well_known_jwks_well_known_jwks_json_get.rb +66 -72
  124. data/lib/moneykit/models/response401_instrospect_client_auth_introspect_get.rb +66 -72
  125. data/lib/moneykit/models/response401_refresh_products_links_id_products_post.rb +71 -77
  126. data/lib/moneykit/models/response401_update_link_links_id_patch.rb +71 -77
  127. data/lib/moneykit/models/settings.rb +61 -73
  128. data/lib/moneykit/models/supported_version.rb +11 -12
  129. data/lib/moneykit/models/transaction.rb +87 -114
  130. data/lib/moneykit/models/transaction_diff.rb +54 -62
  131. data/lib/moneykit/models/transaction_sync_response.rb +57 -72
  132. data/lib/moneykit/models/transaction_type.rb +12 -13
  133. data/lib/moneykit/models/transaction_type_filter.rb +12 -13
  134. data/lib/moneykit/models/transactions.rb +58 -57
  135. data/lib/moneykit/models/transactions1.rb +55 -63
  136. data/lib/moneykit/models/transactions_link_product.rb +52 -54
  137. data/lib/moneykit/models/transactions_product_settings.rb +57 -56
  138. data/lib/moneykit/models/update_link_request.rb +53 -52
  139. data/lib/moneykit/models/user_accounts_out.rb +40 -40
  140. data/lib/moneykit/models/user_links_out.rb +40 -40
  141. data/lib/moneykit/models/user_transactions_paged_response.rb +40 -40
  142. data/lib/moneykit/models/validation_error.rb +53 -64
  143. data/lib/moneykit/version.rb +10 -12
  144. data/lib/moneykit.rb +9 -11
  145. data/lib/plaid_compatible/money_kit_plaid_compatible/api/plaid_api.rb +203 -207
  146. data/lib/plaid_compatible/money_kit_plaid_compatible/api_client.rb +75 -76
  147. data/lib/plaid_compatible/money_kit_plaid_compatible/api_error.rb +19 -19
  148. data/lib/plaid_compatible/money_kit_plaid_compatible/configuration.rb +38 -40
  149. data/lib/plaid_compatible/money_kit_plaid_compatible/models/account_balance.rb +59 -61
  150. data/lib/plaid_compatible/money_kit_plaid_compatible/models/account_base.rb +71 -87
  151. data/lib/plaid_compatible/money_kit_plaid_compatible/models/account_identity.rb +77 -98
  152. data/lib/plaid_compatible/money_kit_plaid_compatible/models/account_subtype.rb +85 -86
  153. data/lib/plaid_compatible/money_kit_plaid_compatible/models/account_type.rb +18 -19
  154. data/lib/plaid_compatible/money_kit_plaid_compatible/models/accounts_get_request.rb +59 -61
  155. data/lib/plaid_compatible/money_kit_plaid_compatible/models/accounts_get_request_options.rb +44 -41
  156. data/lib/plaid_compatible/money_kit_plaid_compatible/models/accounts_get_response.rb +55 -60
  157. data/lib/plaid_compatible/money_kit_plaid_compatible/models/address.rb +49 -47
  158. data/lib/plaid_compatible/money_kit_plaid_compatible/models/address_data.rb +65 -69
  159. data/lib/plaid_compatible/money_kit_plaid_compatible/models/auth_get_numbers.rb +63 -73
  160. data/lib/plaid_compatible/money_kit_plaid_compatible/models/auth_get_request.rb +59 -61
  161. data/lib/plaid_compatible/money_kit_plaid_compatible/models/auth_get_request_options.rb +44 -41
  162. data/lib/plaid_compatible/money_kit_plaid_compatible/models/auth_get_response.rb +61 -72
  163. data/lib/plaid_compatible/money_kit_plaid_compatible/models/country_code.rb +15 -16
  164. data/lib/plaid_compatible/money_kit_plaid_compatible/models/email.rb +49 -50
  165. data/lib/plaid_compatible/money_kit_plaid_compatible/models/http_validation_error.rb +43 -41
  166. data/lib/plaid_compatible/money_kit_plaid_compatible/models/identity_get_request.rb +59 -61
  167. data/lib/plaid_compatible/money_kit_plaid_compatible/models/identity_get_request_options.rb +44 -41
  168. data/lib/plaid_compatible/money_kit_plaid_compatible/models/identity_get_response.rb +55 -60
  169. data/lib/plaid_compatible/money_kit_plaid_compatible/models/institution.rb +65 -71
  170. data/lib/plaid_compatible/money_kit_plaid_compatible/models/institutions_get_by_id_request.rb +60 -61
  171. data/lib/plaid_compatible/money_kit_plaid_compatible/models/institutions_get_by_id_response.rb +49 -50
  172. data/lib/plaid_compatible/money_kit_plaid_compatible/models/item.rb +85 -96
  173. data/lib/plaid_compatible/money_kit_plaid_compatible/models/item_error_webhook.rb +65 -77
  174. data/lib/plaid_compatible/money_kit_plaid_compatible/models/item_get_request.rb +55 -55
  175. data/lib/plaid_compatible/money_kit_plaid_compatible/models/item_get_response.rb +55 -59
  176. data/lib/plaid_compatible/money_kit_plaid_compatible/models/item_public_token_exchange_request.rb +55 -55
  177. data/lib/plaid_compatible/money_kit_plaid_compatible/models/item_public_token_exchange_response.rb +54 -59
  178. data/lib/plaid_compatible/money_kit_plaid_compatible/models/item_remove_request.rb +55 -55
  179. data/lib/plaid_compatible/money_kit_plaid_compatible/models/item_remove_response.rb +44 -41
  180. data/lib/plaid_compatible/money_kit_plaid_compatible/models/item_status_investments.rb +49 -47
  181. data/lib/plaid_compatible/money_kit_plaid_compatible/models/item_status_last_webhook.rb +50 -48
  182. data/lib/plaid_compatible/money_kit_plaid_compatible/models/item_status_nullable.rb +55 -59
  183. data/lib/plaid_compatible/money_kit_plaid_compatible/models/item_status_transactions.rb +49 -47
  184. data/lib/plaid_compatible/money_kit_plaid_compatible/models/link_token_create_request.rb +100 -121
  185. data/lib/plaid_compatible/money_kit_plaid_compatible/models/link_token_create_request_user.rb +66 -66
  186. data/lib/plaid_compatible/money_kit_plaid_compatible/models/link_token_create_response.rb +54 -59
  187. data/lib/plaid_compatible/money_kit_plaid_compatible/models/numbers_ach.rb +59 -65
  188. data/lib/plaid_compatible/money_kit_plaid_compatible/models/numbers_bacs.rb +54 -59
  189. data/lib/plaid_compatible/money_kit_plaid_compatible/models/numbers_eft.rb +59 -68
  190. data/lib/plaid_compatible/money_kit_plaid_compatible/models/numbers_international.rb +54 -59
  191. data/lib/plaid_compatible/money_kit_plaid_compatible/models/owner.rb +63 -73
  192. data/lib/plaid_compatible/money_kit_plaid_compatible/models/personal_finance_category.rb +49 -50
  193. data/lib/plaid_compatible/money_kit_plaid_compatible/models/phone_number.rb +54 -59
  194. data/lib/plaid_compatible/money_kit_plaid_compatible/models/plaid_error.rb +88 -103
  195. data/lib/plaid_compatible/money_kit_plaid_compatible/models/plaid_error_type.rb +26 -27
  196. data/lib/plaid_compatible/money_kit_plaid_compatible/models/products.rb +16 -17
  197. data/lib/plaid_compatible/money_kit_plaid_compatible/models/removed_transaction.rb +43 -39
  198. data/lib/plaid_compatible/money_kit_plaid_compatible/models/transaction.rb +107 -134
  199. data/lib/plaid_compatible/money_kit_plaid_compatible/models/transactions_get_request.rb +69 -79
  200. data/lib/plaid_compatible/money_kit_plaid_compatible/models/transactions_get_request_options.rb +66 -68
  201. data/lib/plaid_compatible/money_kit_plaid_compatible/models/transactions_get_response.rb +65 -76
  202. data/lib/plaid_compatible/money_kit_plaid_compatible/models/transactions_refresh_request.rb +55 -55
  203. data/lib/plaid_compatible/money_kit_plaid_compatible/models/transactions_refresh_response.rb +44 -41
  204. data/lib/plaid_compatible/money_kit_plaid_compatible/models/transactions_sync_request.rb +69 -75
  205. data/lib/plaid_compatible/money_kit_plaid_compatible/models/transactions_sync_request_options.rb +50 -46
  206. data/lib/plaid_compatible/money_kit_plaid_compatible/models/transactions_sync_response.rb +72 -89
  207. data/lib/plaid_compatible/money_kit_plaid_compatible/models/validation_error.rb +56 -65
  208. data/lib/plaid_compatible/money_kit_plaid_compatible/models/webhook_environment_values.rb +15 -16
  209. data/lib/plaid_compatible/money_kit_plaid_compatible/version.rb +13 -13
  210. data/lib/plaid_compatible/money_kit_plaid_compatible.rb +12 -12
  211. data/moneykit.gemspec +21 -25
  212. metadata +1 -1
@@ -1,24 +1,22 @@
1
- =begin
2
- #MoneyKit API
3
-
4
- #No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
5
-
6
- The version of the OpenAPI document: 0.1.0
7
-
8
- Generated by: https://openapi-generator.tech
9
- OpenAPI Generator version: 6.5.0
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: 6.5.0
9
+ #
12
10
 
13
11
  require 'date'
14
12
  require 'time'
15
13
 
16
14
  module MoneyKit
17
15
  class PhoneNumberType
18
- HOME = "home".freeze
19
- WORK = "work".freeze
20
- MOBILE = "mobile".freeze
21
- OTHER = "other".freeze
16
+ HOME = 'home'.freeze
17
+ WORK = 'work'.freeze
18
+ MOBILE = 'mobile'.freeze
19
+ OTHER = 'other'.freeze
22
20
 
23
21
  def self.all_vars
24
22
  @all_vars ||= [HOME, WORK, MOBILE, OTHER].freeze
@@ -36,6 +34,7 @@ module MoneyKit
36
34
  # @return [String] The enum value
37
35
  def build_from_hash(value)
38
36
  return value if PhoneNumberType.all_vars.include?(value)
37
+
39
38
  raise "Invalid ENUM value #{value} for class #PhoneNumberType"
40
39
  end
41
40
  end
@@ -1,24 +1,22 @@
1
- =begin
2
- #MoneyKit API
3
-
4
- #No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
5
-
6
- The version of the OpenAPI document: 0.1.0
7
-
8
- Generated by: https://openapi-generator.tech
9
- OpenAPI Generator version: 6.5.0
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: 6.5.0
9
+ #
12
10
 
13
11
  require 'date'
14
12
  require 'time'
15
13
 
16
14
  module MoneyKit
17
15
  class Product
18
- ACCOUNTS = "accounts".freeze
19
- ACCOUNT_NUMBERS = "account_numbers".freeze
20
- IDENTITY = "identity".freeze
21
- TRANSACTIONS = "transactions".freeze
16
+ ACCOUNTS = 'accounts'.freeze
17
+ ACCOUNT_NUMBERS = 'account_numbers'.freeze
18
+ IDENTITY = 'identity'.freeze
19
+ TRANSACTIONS = 'transactions'.freeze
22
20
 
23
21
  def self.all_vars
24
22
  @all_vars ||= [ACCOUNTS, ACCOUNT_NUMBERS, IDENTITY, TRANSACTIONS].freeze
@@ -36,6 +34,7 @@ module MoneyKit
36
34
  # @return [String] The enum value
37
35
  def build_from_hash(value)
38
36
  return value if Product.all_vars.include?(value)
37
+
39
38
  raise "Invalid ENUM value #{value} for class #Product"
40
39
  end
41
40
  end
@@ -1,14 +1,12 @@
1
- =begin
2
- #MoneyKit API
3
-
4
- #No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
5
-
6
- The version of the OpenAPI document: 0.1.0
7
-
8
- Generated by: https://openapi-generator.tech
9
- OpenAPI Generator version: 6.5.0
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: 6.5.0
9
+ #
12
10
 
13
11
  require 'date'
14
12
  require 'time'
@@ -16,21 +14,15 @@ require 'time'
16
14
  module MoneyKit
17
15
  # The granted products available for this link.
18
16
  class Products
19
- attr_accessor :accounts
20
-
21
- attr_accessor :account_numbers
22
-
23
- attr_accessor :identity
24
-
25
- attr_accessor :transactions
17
+ attr_accessor :accounts, :account_numbers, :identity, :transactions
26
18
 
27
19
  # Attribute mapping from ruby-style variable name to JSON key.
28
20
  def self.attribute_map
29
21
  {
30
- :'accounts' => :'accounts',
31
- :'account_numbers' => :'account_numbers',
32
- :'identity' => :'identity',
33
- :'transactions' => :'transactions'
22
+ 'accounts': :accounts,
23
+ 'account_numbers': :account_numbers,
24
+ 'identity': :identity,
25
+ 'transactions': :transactions
34
26
  }
35
27
  end
36
28
 
@@ -42,63 +34,57 @@ module MoneyKit
42
34
  # Attribute type mapping.
43
35
  def self.openapi_types
44
36
  {
45
- :'accounts' => :'AccountsLinkProduct',
46
- :'account_numbers' => :'AccountNumbersLinkProduct',
47
- :'identity' => :'IdentityLinkProduct',
48
- :'transactions' => :'TransactionsLinkProduct'
37
+ 'accounts': :AccountsLinkProduct,
38
+ 'account_numbers': :AccountNumbersLinkProduct,
39
+ 'identity': :IdentityLinkProduct,
40
+ 'transactions': :TransactionsLinkProduct
49
41
  }
50
42
  end
51
43
 
52
44
  # List of attributes with nullable: true
53
45
  def self.openapi_nullable
54
- Set.new([
55
- ])
46
+ Set.new([])
56
47
  end
57
48
 
58
49
  # List of class defined in allOf (OpenAPI v3)
59
50
  def self.openapi_all_of
60
51
  [
61
- :'LinkProducts'
52
+ :LinkProducts
62
53
  ]
63
54
  end
64
55
 
65
56
  # Initializes the object
66
57
  # @param [Hash] attributes Model attributes in the form of hash
67
58
  def initialize(attributes = {})
68
- if (!attributes.is_a?(Hash))
69
- fail ArgumentError, "The input argument (attributes) must be a hash in `MoneyKit::Products` initialize method"
59
+ unless attributes.is_a?(Hash)
60
+ raise ArgumentError, 'The input argument (attributes) must be a hash in `MoneyKit::Products` initialize method'
70
61
  end
71
62
 
72
63
  # check to see if the attribute exists and convert string to symbol for hash key
73
- attributes = attributes.each_with_object({}) { |(k, v), h|
74
- if (!self.class.attribute_map.key?(k.to_sym))
75
- fail ArgumentError, "`#{k}` is not a valid attribute in `MoneyKit::Products`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
64
+ attributes = attributes.each_with_object({}) do |(k, v), h|
65
+ unless self.class.attribute_map.key?(k.to_sym)
66
+ raise ArgumentError,
67
+ "`#{k}` is not a valid attribute in `MoneyKit::Products`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
76
68
  end
77
- h[k.to_sym] = v
78
- }
79
69
 
80
- if attributes.key?(:'accounts')
81
- self.accounts = attributes[:'accounts']
70
+ h[k.to_sym] = v
82
71
  end
83
72
 
84
- if attributes.key?(:'account_numbers')
85
- self.account_numbers = attributes[:'account_numbers']
86
- end
73
+ self.accounts = attributes[:accounts] if attributes.key?(:accounts)
87
74
 
88
- if attributes.key?(:'identity')
89
- self.identity = attributes[:'identity']
90
- end
75
+ self.account_numbers = attributes[:account_numbers] if attributes.key?(:account_numbers)
91
76
 
92
- if attributes.key?(:'transactions')
93
- self.transactions = attributes[:'transactions']
94
- end
77
+ self.identity = attributes[:identity] if attributes.key?(:identity)
78
+
79
+ return unless attributes.key?(:transactions)
80
+
81
+ self.transactions = attributes[:transactions]
95
82
  end
96
83
 
97
84
  # Show invalid properties with the reasons. Usually used together with valid?
98
85
  # @return Array for valid properties with the reasons
99
86
  def list_invalid_properties
100
- invalid_properties = Array.new
101
- invalid_properties
87
+ []
102
88
  end
103
89
 
104
90
  # Check to see if the all the properties in the model are valid
@@ -109,19 +95,20 @@ module MoneyKit
109
95
 
110
96
  # Checks equality by comparing each attribute.
111
97
  # @param [Object] Object to be compared
112
- def ==(o)
113
- return true if self.equal?(o)
114
- self.class == o.class &&
115
- accounts == o.accounts &&
116
- account_numbers == o.account_numbers &&
117
- identity == o.identity &&
118
- transactions == o.transactions
98
+ def ==(other)
99
+ return true if equal?(other)
100
+
101
+ self.class == other.class &&
102
+ accounts == other.accounts &&
103
+ account_numbers == other.account_numbers &&
104
+ identity == other.identity &&
105
+ transactions == other.transactions
119
106
  end
120
107
 
121
108
  # @see the `==` method
122
109
  # @param [Object] Object to be compared
123
- def eql?(o)
124
- self == o
110
+ def eql?(other)
111
+ self == other
125
112
  end
126
113
 
127
114
  # Calculates hash code according to all attributes.
@@ -142,18 +129,21 @@ module MoneyKit
142
129
  # @return [Object] Returns the model itself
143
130
  def build_from_hash(attributes)
144
131
  return nil unless attributes.is_a?(Hash)
132
+
145
133
  attributes = attributes.transform_keys(&:to_sym)
146
134
  self.class.openapi_types.each_pair do |key, type|
147
135
  if attributes[self.class.attribute_map[key]].nil? && self.class.openapi_nullable.include?(key)
148
- self.send("#{key}=", nil)
136
+ send("#{key}=", nil)
149
137
  elsif type =~ /\AArray<(.*)>/i
150
138
  # check to ensure the input is an array given that the attribute
151
139
  # is documented as an array but the input is not
152
140
  if attributes[self.class.attribute_map[key]].is_a?(Array)
153
- self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
141
+ send("#{key}=", attributes[self.class.attribute_map[key]].map do |v|
142
+ _deserialize(::Regexp.last_match(1), v)
143
+ end)
154
144
  end
155
145
  elsif !attributes[self.class.attribute_map[key]].nil?
156
- self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
146
+ send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
157
147
  end
158
148
  end
159
149
 
@@ -220,7 +210,7 @@ module MoneyKit
220
210
  def to_hash
221
211
  hash = {}
222
212
  self.class.attribute_map.each_pair do |attr, param|
223
- value = self.send(attr)
213
+ value = send(attr)
224
214
  if value.nil?
225
215
  is_nullable = self.class.openapi_nullable.include?(attr)
226
216
  next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
@@ -248,7 +238,5 @@ module MoneyKit
248
238
  value
249
239
  end
250
240
  end
251
-
252
241
  end
253
-
254
242
  end
@@ -1,14 +1,12 @@
1
- =begin
2
- #MoneyKit API
3
-
4
- #No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
5
-
6
- The version of the OpenAPI document: 0.1.0
7
-
8
- Generated by: https://openapi-generator.tech
9
- OpenAPI Generator version: 6.5.0
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: 6.5.0
9
+ #
12
10
 
13
11
  require 'date'
14
12
  require 'time'
@@ -16,18 +14,14 @@ require 'time'
16
14
  module MoneyKit
17
15
  # If provided, configures what institutions are available and how data should be fetched.
18
16
  class Products1
19
- attr_accessor :account_numbers
20
-
21
- attr_accessor :identity
22
-
23
- attr_accessor :transactions
17
+ attr_accessor :account_numbers, :identity, :transactions
24
18
 
25
19
  # Attribute mapping from ruby-style variable name to JSON key.
26
20
  def self.attribute_map
27
21
  {
28
- :'account_numbers' => :'account_numbers',
29
- :'identity' => :'identity',
30
- :'transactions' => :'transactions'
22
+ 'account_numbers': :account_numbers,
23
+ 'identity': :identity,
24
+ 'transactions': :transactions
31
25
  }
32
26
  end
33
27
 
@@ -39,58 +33,54 @@ module MoneyKit
39
33
  # Attribute type mapping.
40
34
  def self.openapi_types
41
35
  {
42
- :'account_numbers' => :'AccountNumbers',
43
- :'identity' => :'Identity',
44
- :'transactions' => :'Transactions'
36
+ 'account_numbers': :AccountNumbers,
37
+ 'identity': :Identity,
38
+ 'transactions': :Transactions
45
39
  }
46
40
  end
47
41
 
48
42
  # List of attributes with nullable: true
49
43
  def self.openapi_nullable
50
- Set.new([
51
- ])
44
+ Set.new([])
52
45
  end
53
46
 
54
47
  # List of class defined in allOf (OpenAPI v3)
55
48
  def self.openapi_all_of
56
49
  [
57
- :'ProductsSettings'
50
+ :ProductsSettings
58
51
  ]
59
52
  end
60
53
 
61
54
  # Initializes the object
62
55
  # @param [Hash] attributes Model attributes in the form of hash
63
56
  def initialize(attributes = {})
64
- if (!attributes.is_a?(Hash))
65
- fail ArgumentError, "The input argument (attributes) must be a hash in `MoneyKit::Products1` initialize method"
57
+ unless attributes.is_a?(Hash)
58
+ raise ArgumentError, 'The input argument (attributes) must be a hash in `MoneyKit::Products1` initialize method'
66
59
  end
67
60
 
68
61
  # check to see if the attribute exists and convert string to symbol for hash key
69
- attributes = attributes.each_with_object({}) { |(k, v), h|
70
- if (!self.class.attribute_map.key?(k.to_sym))
71
- fail ArgumentError, "`#{k}` is not a valid attribute in `MoneyKit::Products1`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
62
+ attributes = attributes.each_with_object({}) do |(k, v), h|
63
+ unless self.class.attribute_map.key?(k.to_sym)
64
+ raise ArgumentError,
65
+ "`#{k}` is not a valid attribute in `MoneyKit::Products1`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
72
66
  end
73
- h[k.to_sym] = v
74
- }
75
67
 
76
- if attributes.key?(:'account_numbers')
77
- self.account_numbers = attributes[:'account_numbers']
68
+ h[k.to_sym] = v
78
69
  end
79
70
 
80
- if attributes.key?(:'identity')
81
- self.identity = attributes[:'identity']
82
- end
71
+ self.account_numbers = attributes[:account_numbers] if attributes.key?(:account_numbers)
83
72
 
84
- if attributes.key?(:'transactions')
85
- self.transactions = attributes[:'transactions']
86
- end
73
+ self.identity = attributes[:identity] if attributes.key?(:identity)
74
+
75
+ return unless attributes.key?(:transactions)
76
+
77
+ self.transactions = attributes[:transactions]
87
78
  end
88
79
 
89
80
  # Show invalid properties with the reasons. Usually used together with valid?
90
81
  # @return Array for valid properties with the reasons
91
82
  def list_invalid_properties
92
- invalid_properties = Array.new
93
- invalid_properties
83
+ []
94
84
  end
95
85
 
96
86
  # Check to see if the all the properties in the model are valid
@@ -101,18 +91,19 @@ module MoneyKit
101
91
 
102
92
  # Checks equality by comparing each attribute.
103
93
  # @param [Object] Object to be compared
104
- def ==(o)
105
- return true if self.equal?(o)
106
- self.class == o.class &&
107
- account_numbers == o.account_numbers &&
108
- identity == o.identity &&
109
- transactions == o.transactions
94
+ def ==(other)
95
+ return true if equal?(other)
96
+
97
+ self.class == other.class &&
98
+ account_numbers == other.account_numbers &&
99
+ identity == other.identity &&
100
+ transactions == other.transactions
110
101
  end
111
102
 
112
103
  # @see the `==` method
113
104
  # @param [Object] Object to be compared
114
- def eql?(o)
115
- self == o
105
+ def eql?(other)
106
+ self == other
116
107
  end
117
108
 
118
109
  # Calculates hash code according to all attributes.
@@ -133,18 +124,21 @@ module MoneyKit
133
124
  # @return [Object] Returns the model itself
134
125
  def build_from_hash(attributes)
135
126
  return nil unless attributes.is_a?(Hash)
127
+
136
128
  attributes = attributes.transform_keys(&:to_sym)
137
129
  self.class.openapi_types.each_pair do |key, type|
138
130
  if attributes[self.class.attribute_map[key]].nil? && self.class.openapi_nullable.include?(key)
139
- self.send("#{key}=", nil)
131
+ send("#{key}=", nil)
140
132
  elsif type =~ /\AArray<(.*)>/i
141
133
  # check to ensure the input is an array given that the attribute
142
134
  # is documented as an array but the input is not
143
135
  if attributes[self.class.attribute_map[key]].is_a?(Array)
144
- self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
136
+ send("#{key}=", attributes[self.class.attribute_map[key]].map do |v|
137
+ _deserialize(::Regexp.last_match(1), v)
138
+ end)
145
139
  end
146
140
  elsif !attributes[self.class.attribute_map[key]].nil?
147
- self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
141
+ send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
148
142
  end
149
143
  end
150
144
 
@@ -211,7 +205,7 @@ module MoneyKit
211
205
  def to_hash
212
206
  hash = {}
213
207
  self.class.attribute_map.each_pair do |attr, param|
214
- value = self.send(attr)
208
+ value = send(attr)
215
209
  if value.nil?
216
210
  is_nullable = self.class.openapi_nullable.include?(attr)
217
211
  next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
@@ -239,7 +233,5 @@ module MoneyKit
239
233
  value
240
234
  end
241
235
  end
242
-
243
236
  end
244
-
245
237
  end
@@ -1,32 +1,26 @@
1
- =begin
2
- #MoneyKit API
3
-
4
- #No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
5
-
6
- The version of the OpenAPI document: 0.1.0
7
-
8
- Generated by: https://openapi-generator.tech
9
- OpenAPI Generator version: 6.5.0
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: 6.5.0
9
+ #
12
10
 
13
11
  require 'date'
14
12
  require 'time'
15
13
 
16
14
  module MoneyKit
17
15
  class ProductsSettings
18
- attr_accessor :account_numbers
19
-
20
- attr_accessor :identity
21
-
22
- attr_accessor :transactions
16
+ attr_accessor :account_numbers, :identity, :transactions
23
17
 
24
18
  # Attribute mapping from ruby-style variable name to JSON key.
25
19
  def self.attribute_map
26
20
  {
27
- :'account_numbers' => :'account_numbers',
28
- :'identity' => :'identity',
29
- :'transactions' => :'transactions'
21
+ 'account_numbers': :account_numbers,
22
+ 'identity': :identity,
23
+ 'transactions': :transactions
30
24
  }
31
25
  end
32
26
 
@@ -38,51 +32,48 @@ module MoneyKit
38
32
  # Attribute type mapping.
39
33
  def self.openapi_types
40
34
  {
41
- :'account_numbers' => :'AccountNumbers',
42
- :'identity' => :'Identity',
43
- :'transactions' => :'Transactions'
35
+ 'account_numbers': :AccountNumbers,
36
+ 'identity': :Identity,
37
+ 'transactions': :Transactions
44
38
  }
45
39
  end
46
40
 
47
41
  # List of attributes with nullable: true
48
42
  def self.openapi_nullable
49
- Set.new([
50
- ])
43
+ Set.new([])
51
44
  end
52
45
 
53
46
  # Initializes the object
54
47
  # @param [Hash] attributes Model attributes in the form of hash
55
48
  def initialize(attributes = {})
56
- if (!attributes.is_a?(Hash))
57
- fail ArgumentError, "The input argument (attributes) must be a hash in `MoneyKit::ProductsSettings` initialize method"
49
+ unless attributes.is_a?(Hash)
50
+ raise ArgumentError,
51
+ 'The input argument (attributes) must be a hash in `MoneyKit::ProductsSettings` initialize method'
58
52
  end
59
53
 
60
54
  # check to see if the attribute exists and convert string to symbol for hash key
61
- attributes = attributes.each_with_object({}) { |(k, v), h|
62
- if (!self.class.attribute_map.key?(k.to_sym))
63
- fail ArgumentError, "`#{k}` is not a valid attribute in `MoneyKit::ProductsSettings`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
55
+ attributes = attributes.each_with_object({}) do |(k, v), h|
56
+ unless self.class.attribute_map.key?(k.to_sym)
57
+ raise ArgumentError,
58
+ "`#{k}` is not a valid attribute in `MoneyKit::ProductsSettings`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
64
59
  end
65
- h[k.to_sym] = v
66
- }
67
60
 
68
- if attributes.key?(:'account_numbers')
69
- self.account_numbers = attributes[:'account_numbers']
61
+ h[k.to_sym] = v
70
62
  end
71
63
 
72
- if attributes.key?(:'identity')
73
- self.identity = attributes[:'identity']
74
- end
64
+ self.account_numbers = attributes[:account_numbers] if attributes.key?(:account_numbers)
75
65
 
76
- if attributes.key?(:'transactions')
77
- self.transactions = attributes[:'transactions']
78
- end
66
+ self.identity = attributes[:identity] if attributes.key?(:identity)
67
+
68
+ return unless attributes.key?(:transactions)
69
+
70
+ self.transactions = attributes[:transactions]
79
71
  end
80
72
 
81
73
  # Show invalid properties with the reasons. Usually used together with valid?
82
74
  # @return Array for valid properties with the reasons
83
75
  def list_invalid_properties
84
- invalid_properties = Array.new
85
- invalid_properties
76
+ []
86
77
  end
87
78
 
88
79
  # Check to see if the all the properties in the model are valid
@@ -93,18 +84,19 @@ module MoneyKit
93
84
 
94
85
  # Checks equality by comparing each attribute.
95
86
  # @param [Object] Object to be compared
96
- def ==(o)
97
- return true if self.equal?(o)
98
- self.class == o.class &&
99
- account_numbers == o.account_numbers &&
100
- identity == o.identity &&
101
- transactions == o.transactions
87
+ def ==(other)
88
+ return true if equal?(other)
89
+
90
+ self.class == other.class &&
91
+ account_numbers == other.account_numbers &&
92
+ identity == other.identity &&
93
+ transactions == other.transactions
102
94
  end
103
95
 
104
96
  # @see the `==` method
105
97
  # @param [Object] Object to be compared
106
- def eql?(o)
107
- self == o
98
+ def eql?(other)
99
+ self == other
108
100
  end
109
101
 
110
102
  # Calculates hash code according to all attributes.
@@ -125,18 +117,21 @@ module MoneyKit
125
117
  # @return [Object] Returns the model itself
126
118
  def build_from_hash(attributes)
127
119
  return nil unless attributes.is_a?(Hash)
120
+
128
121
  attributes = attributes.transform_keys(&:to_sym)
129
122
  self.class.openapi_types.each_pair do |key, type|
130
123
  if attributes[self.class.attribute_map[key]].nil? && self.class.openapi_nullable.include?(key)
131
- self.send("#{key}=", nil)
124
+ send("#{key}=", nil)
132
125
  elsif type =~ /\AArray<(.*)>/i
133
126
  # check to ensure the input is an array given that the attribute
134
127
  # is documented as an array but the input is not
135
128
  if attributes[self.class.attribute_map[key]].is_a?(Array)
136
- self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
129
+ send("#{key}=", attributes[self.class.attribute_map[key]].map do |v|
130
+ _deserialize(::Regexp.last_match(1), v)
131
+ end)
137
132
  end
138
133
  elsif !attributes[self.class.attribute_map[key]].nil?
139
- self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
134
+ send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
140
135
  end
141
136
  end
142
137
 
@@ -203,7 +198,7 @@ module MoneyKit
203
198
  def to_hash
204
199
  hash = {}
205
200
  self.class.attribute_map.each_pair do |attr, param|
206
- value = self.send(attr)
201
+ value = send(attr)
207
202
  if value.nil?
208
203
  is_nullable = self.class.openapi_nullable.include?(attr)
209
204
  next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
@@ -231,7 +226,5 @@ module MoneyKit
231
226
  value
232
227
  end
233
228
  end
234
-
235
229
  end
236
-
237
230
  end