apimatic-mx-apis-sdk 0.0.1

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 (287) hide show
  1. checksums.yaml +7 -0
  2. data/LICENSE +28 -0
  3. data/README.md +207 -0
  4. data/bin/console +15 -0
  5. data/lib/mx_platform_api/api_helper.rb +10 -0
  6. data/lib/mx_platform_api/apis/accounts_api.rb +619 -0
  7. data/lib/mx_platform_api/apis/ach_return_api.rb +115 -0
  8. data/lib/mx_platform_api/apis/base_api.rb +67 -0
  9. data/lib/mx_platform_api/apis/budgets_api.rb +212 -0
  10. data/lib/mx_platform_api/apis/categories_api.rb +377 -0
  11. data/lib/mx_platform_api/apis/goals_api.rb +223 -0
  12. data/lib/mx_platform_api/apis/insights_api.rb +415 -0
  13. data/lib/mx_platform_api/apis/institutions_api.rb +159 -0
  14. data/lib/mx_platform_api/apis/investment_holdings_api.rb +191 -0
  15. data/lib/mx_platform_api/apis/jobs_api.rb +48 -0
  16. data/lib/mx_platform_api/apis/managed_data_deprecated_api.rb +773 -0
  17. data/lib/mx_platform_api/apis/members_api.rb +639 -0
  18. data/lib/mx_platform_api/apis/merchants_api.rb +98 -0
  19. data/lib/mx_platform_api/apis/microdeposits_api.rb +219 -0
  20. data/lib/mx_platform_api/apis/monthly_cash_flow_profile_api.rb +75 -0
  21. data/lib/mx_platform_api/apis/notifications_api.rb +115 -0
  22. data/lib/mx_platform_api/apis/processor_token_api.rb +141 -0
  23. data/lib/mx_platform_api/apis/rewards_api.rb +149 -0
  24. data/lib/mx_platform_api/apis/spending_plan_api.rb +621 -0
  25. data/lib/mx_platform_api/apis/statements_api.rb +165 -0
  26. data/lib/mx_platform_api/apis/taggings_api.rb +184 -0
  27. data/lib/mx_platform_api/apis/tags_api.rb +185 -0
  28. data/lib/mx_platform_api/apis/transaction_rules_api.rb +163 -0
  29. data/lib/mx_platform_api/apis/transactions_api.rb +1223 -0
  30. data/lib/mx_platform_api/apis/users_api.rb +188 -0
  31. data/lib/mx_platform_api/apis/verifiable_credentials_api.rb +114 -0
  32. data/lib/mx_platform_api/apis/widgets_api.rb +135 -0
  33. data/lib/mx_platform_api/client.rb +225 -0
  34. data/lib/mx_platform_api/configuration.rb +182 -0
  35. data/lib/mx_platform_api/exceptions/api_exception.rb +21 -0
  36. data/lib/mx_platform_api/http/api_response.rb +19 -0
  37. data/lib/mx_platform_api/http/auth/basic_auth.rb +62 -0
  38. data/lib/mx_platform_api/http/auth/bearer_auth.rb +53 -0
  39. data/lib/mx_platform_api/http/http_call_back.rb +10 -0
  40. data/lib/mx_platform_api/http/http_method_enum.rb +10 -0
  41. data/lib/mx_platform_api/http/http_request.rb +10 -0
  42. data/lib/mx_platform_api/http/http_response.rb +10 -0
  43. data/lib/mx_platform_api/http/proxy_settings.rb +22 -0
  44. data/lib/mx_platform_api/logging/configuration/api_logging_configuration.rb +186 -0
  45. data/lib/mx_platform_api/logging/sdk_logger.rb +17 -0
  46. data/lib/mx_platform_api/models/account_create_request.rb +309 -0
  47. data/lib/mx_platform_api/models/account_create_request_body.rb +75 -0
  48. data/lib/mx_platform_api/models/account_number.rb +199 -0
  49. data/lib/mx_platform_api/models/account_number_response.rb +215 -0
  50. data/lib/mx_platform_api/models/account_numbers_response_body.rb +95 -0
  51. data/lib/mx_platform_api/models/account_owner.rb +186 -0
  52. data/lib/mx_platform_api/models/account_owner_response.rb +219 -0
  53. data/lib/mx_platform_api/models/account_owners_response_body.rb +95 -0
  54. data/lib/mx_platform_api/models/account_ownership.rb +45 -0
  55. data/lib/mx_platform_api/models/account_response.rb +814 -0
  56. data/lib/mx_platform_api/models/account_response_body.rb +75 -0
  57. data/lib/mx_platform_api/models/account_type.rb +80 -0
  58. data/lib/mx_platform_api/models/account_type1.rb +80 -0
  59. data/lib/mx_platform_api/models/account_update_request.rb +301 -0
  60. data/lib/mx_platform_api/models/account_update_request_body.rb +75 -0
  61. data/lib/mx_platform_api/models/accounts_merge_request.rb +75 -0
  62. data/lib/mx_platform_api/models/accounts_merge_request_body.rb +75 -0
  63. data/lib/mx_platform_api/models/accounts_response_body.rb +94 -0
  64. data/lib/mx_platform_api/models/ach_response.rb +424 -0
  65. data/lib/mx_platform_api/models/ach_return_create_request.rb +256 -0
  66. data/lib/mx_platform_api/models/ach_return_create_request_body.rb +76 -0
  67. data/lib/mx_platform_api/models/ach_return_response_body.rb +76 -0
  68. data/lib/mx_platform_api/models/ach_returns_response_body.rb +95 -0
  69. data/lib/mx_platform_api/models/authorization_code_request.rb +77 -0
  70. data/lib/mx_platform_api/models/authorization_code_request_body.rb +77 -0
  71. data/lib/mx_platform_api/models/authorization_code_response.rb +76 -0
  72. data/lib/mx_platform_api/models/authorization_code_response_body.rb +77 -0
  73. data/lib/mx_platform_api/models/base_model.rb +110 -0
  74. data/lib/mx_platform_api/models/budget_create_request.rb +115 -0
  75. data/lib/mx_platform_api/models/budget_create_request_body.rb +75 -0
  76. data/lib/mx_platform_api/models/budget_response.rb +246 -0
  77. data/lib/mx_platform_api/models/budget_response_body.rb +75 -0
  78. data/lib/mx_platform_api/models/budget_update_request.rb +96 -0
  79. data/lib/mx_platform_api/models/budget_update_request_body.rb +75 -0
  80. data/lib/mx_platform_api/models/categories_response_body.rb +95 -0
  81. data/lib/mx_platform_api/models/category_create_request.rb +93 -0
  82. data/lib/mx_platform_api/models/category_create_request_body.rb +75 -0
  83. data/lib/mx_platform_api/models/category_response.rb +160 -0
  84. data/lib/mx_platform_api/models/category_response_body.rb +75 -0
  85. data/lib/mx_platform_api/models/category_update_request.rb +85 -0
  86. data/lib/mx_platform_api/models/category_update_request_body.rb +75 -0
  87. data/lib/mx_platform_api/models/challenge_response.rb +159 -0
  88. data/lib/mx_platform_api/models/challenges_response_body.rb +95 -0
  89. data/lib/mx_platform_api/models/channel.rb +47 -0
  90. data/lib/mx_platform_api/models/classification.rb +85 -0
  91. data/lib/mx_platform_api/models/color_scheme.rb +43 -0
  92. data/lib/mx_platform_api/models/connection_status.rb +118 -0
  93. data/lib/mx_platform_api/models/credential_request.rb +85 -0
  94. data/lib/mx_platform_api/models/credential_response.rb +133 -0
  95. data/lib/mx_platform_api/models/credentials_response_body.rb +95 -0
  96. data/lib/mx_platform_api/models/credit_card_product.rb +276 -0
  97. data/lib/mx_platform_api/models/credit_card_product_response.rb +77 -0
  98. data/lib/mx_platform_api/models/data_request.rb +76 -0
  99. data/lib/mx_platform_api/models/date_range.rb +87 -0
  100. data/lib/mx_platform_api/models/date_range_category_totals_response.rb +115 -0
  101. data/lib/mx_platform_api/models/date_range_category_totals_response_body.rb +88 -0
  102. data/lib/mx_platform_api/models/deep_link_params.rb +131 -0
  103. data/lib/mx_platform_api/models/enhance_transaction_response.rb +371 -0
  104. data/lib/mx_platform_api/models/enhance_transactions_request.rb +143 -0
  105. data/lib/mx_platform_api/models/enhance_transactions_request_body.rb +85 -0
  106. data/lib/mx_platform_api/models/enhance_transactions_response_body.rb +85 -0
  107. data/lib/mx_platform_api/models/error.rb +106 -0
  108. data/lib/mx_platform_api/models/federal_insurance_status.rb +42 -0
  109. data/lib/mx_platform_api/models/geolocation.rb +108 -0
  110. data/lib/mx_platform_api/models/goal_request.rb +179 -0
  111. data/lib/mx_platform_api/models/goal_request_body.rb +74 -0
  112. data/lib/mx_platform_api/models/goal_response.rb +241 -0
  113. data/lib/mx_platform_api/models/goal_response_body.rb +74 -0
  114. data/lib/mx_platform_api/models/goal_type_name.rb +36 -0
  115. data/lib/mx_platform_api/models/goals_response.rb +241 -0
  116. data/lib/mx_platform_api/models/goals_response_body.rb +94 -0
  117. data/lib/mx_platform_api/models/image_option_response.rb +110 -0
  118. data/lib/mx_platform_api/models/insight_response.rb +338 -0
  119. data/lib/mx_platform_api/models/insight_response_body.rb +75 -0
  120. data/lib/mx_platform_api/models/insight_update_request.rb +87 -0
  121. data/lib/mx_platform_api/models/insight_update_request_body.rb +75 -0
  122. data/lib/mx_platform_api/models/insights_response_body.rb +94 -0
  123. data/lib/mx_platform_api/models/institution_response.rb +290 -0
  124. data/lib/mx_platform_api/models/institution_response_body.rb +76 -0
  125. data/lib/mx_platform_api/models/institutions_response_body.rb +95 -0
  126. data/lib/mx_platform_api/models/investment_holding_response.rb +513 -0
  127. data/lib/mx_platform_api/models/investment_holding_response_body.rb +77 -0
  128. data/lib/mx_platform_api/models/investment_holdings_deactivation.rb +85 -0
  129. data/lib/mx_platform_api/models/investment_holdings_response_body.rb +95 -0
  130. data/lib/mx_platform_api/models/iso_country_code.rb +36 -0
  131. data/lib/mx_platform_api/models/item_type.rb +52 -0
  132. data/lib/mx_platform_api/models/job_response.rb +203 -0
  133. data/lib/mx_platform_api/models/job_response_body.rb +74 -0
  134. data/lib/mx_platform_api/models/managed_account_create_request.rb +422 -0
  135. data/lib/mx_platform_api/models/managed_account_create_request_body.rb +75 -0
  136. data/lib/mx_platform_api/models/managed_account_update_request.rb +428 -0
  137. data/lib/mx_platform_api/models/managed_account_update_request_body.rb +75 -0
  138. data/lib/mx_platform_api/models/managed_member_create_request.rb +105 -0
  139. data/lib/mx_platform_api/models/managed_member_create_request_body.rb +75 -0
  140. data/lib/mx_platform_api/models/managed_member_update_request.rb +95 -0
  141. data/lib/mx_platform_api/models/managed_member_update_request_body.rb +75 -0
  142. data/lib/mx_platform_api/models/managed_transaction_create_request.rb +282 -0
  143. data/lib/mx_platform_api/models/managed_transaction_create_request_body.rb +77 -0
  144. data/lib/mx_platform_api/models/managed_transaction_update_request.rb +289 -0
  145. data/lib/mx_platform_api/models/managed_transaction_update_request_body.rb +77 -0
  146. data/lib/mx_platform_api/models/member_create_request.rb +154 -0
  147. data/lib/mx_platform_api/models/member_create_request_body.rb +152 -0
  148. data/lib/mx_platform_api/models/member_elements.rb +96 -0
  149. data/lib/mx_platform_api/models/member_response.rb +406 -0
  150. data/lib/mx_platform_api/models/member_response_body.rb +75 -0
  151. data/lib/mx_platform_api/models/member_response_with_job_error.rb +406 -0
  152. data/lib/mx_platform_api/models/member_response_with_job_error_body.rb +75 -0
  153. data/lib/mx_platform_api/models/member_resume_request.rb +85 -0
  154. data/lib/mx_platform_api/models/member_resume_request_body.rb +75 -0
  155. data/lib/mx_platform_api/models/member_status_response.rb +236 -0
  156. data/lib/mx_platform_api/models/member_status_response_body.rb +75 -0
  157. data/lib/mx_platform_api/models/member_update_request.rb +133 -0
  158. data/lib/mx_platform_api/models/member_update_request_body.rb +75 -0
  159. data/lib/mx_platform_api/models/members_response_body.rb +94 -0
  160. data/lib/mx_platform_api/models/merchant.rb +105 -0
  161. data/lib/mx_platform_api/models/merchant_location_response.rb +208 -0
  162. data/lib/mx_platform_api/models/merchant_location_response_body.rb +77 -0
  163. data/lib/mx_platform_api/models/merchant_response.rb +136 -0
  164. data/lib/mx_platform_api/models/merchant_response_body.rb +75 -0
  165. data/lib/mx_platform_api/models/merchants_response_body.rb +95 -0
  166. data/lib/mx_platform_api/models/micro_deposit.rb +223 -0
  167. data/lib/mx_platform_api/models/microdeposit_elements.rb +141 -0
  168. data/lib/mx_platform_api/models/microdeposit_request_body.rb +77 -0
  169. data/lib/mx_platform_api/models/microdeposit_response.rb +149 -0
  170. data/lib/mx_platform_api/models/microdeposit_response_body.rb +85 -0
  171. data/lib/mx_platform_api/models/microdeposit_verify_request.rb +88 -0
  172. data/lib/mx_platform_api/models/microdeposit_verify_request_body.rb +77 -0
  173. data/lib/mx_platform_api/models/microdeposits_response_body.rb +95 -0
  174. data/lib/mx_platform_api/models/monthly_account_balance.rb +123 -0
  175. data/lib/mx_platform_api/models/monthly_account_balances_response_body.rb +85 -0
  176. data/lib/mx_platform_api/models/monthly_cash_flow_profile_request.rb +95 -0
  177. data/lib/mx_platform_api/models/monthly_cash_flow_profile_request_body.rb +81 -0
  178. data/lib/mx_platform_api/models/monthly_cash_flow_response.rb +157 -0
  179. data/lib/mx_platform_api/models/monthly_cash_flow_response_body.rb +81 -0
  180. data/lib/mx_platform_api/models/notification_request.rb +83 -0
  181. data/lib/mx_platform_api/models/notification_request_body.rb +76 -0
  182. data/lib/mx_platform_api/models/notification_response.rb +204 -0
  183. data/lib/mx_platform_api/models/notification_response_body.rb +76 -0
  184. data/lib/mx_platform_api/models/notifications_response_body.rb +85 -0
  185. data/lib/mx_platform_api/models/oauth_window_response.rb +91 -0
  186. data/lib/mx_platform_api/models/oauth_window_response_body.rb +75 -0
  187. data/lib/mx_platform_api/models/option_response.rb +99 -0
  188. data/lib/mx_platform_api/models/pagination_response.rb +106 -0
  189. data/lib/mx_platform_api/models/parent_class.rb +84 -0
  190. data/lib/mx_platform_api/models/payment_account.rb +183 -0
  191. data/lib/mx_platform_api/models/payment_account1.rb +213 -0
  192. data/lib/mx_platform_api/models/payment_account_body.rb +77 -0
  193. data/lib/mx_platform_api/models/processor_account_number.rb +168 -0
  194. data/lib/mx_platform_api/models/processor_account_number_body.rb +85 -0
  195. data/lib/mx_platform_api/models/processor_owner.rb +155 -0
  196. data/lib/mx_platform_api/models/processor_owner_body.rb +95 -0
  197. data/lib/mx_platform_api/models/property_type.rb +69 -0
  198. data/lib/mx_platform_api/models/recurrence_type.rb +26 -0
  199. data/lib/mx_platform_api/models/repeating_transaction.rb +102 -0
  200. data/lib/mx_platform_api/models/repeating_transaction_response.rb +203 -0
  201. data/lib/mx_platform_api/models/repeating_transaction_type.rb +44 -0
  202. data/lib/mx_platform_api/models/repeating_transactions_response_body.rb +85 -0
  203. data/lib/mx_platform_api/models/reposition_request.rb +82 -0
  204. data/lib/mx_platform_api/models/reposition_request_body.rb +84 -0
  205. data/lib/mx_platform_api/models/reposition_response_body.rb +84 -0
  206. data/lib/mx_platform_api/models/reward.rb +187 -0
  207. data/lib/mx_platform_api/models/reward_elements.rb +156 -0
  208. data/lib/mx_platform_api/models/reward_response_body.rb +75 -0
  209. data/lib/mx_platform_api/models/rewards_response_body.rb +94 -0
  210. data/lib/mx_platform_api/models/scheduled_payment_response.rb +208 -0
  211. data/lib/mx_platform_api/models/scheduled_payments_response_body.rb +95 -0
  212. data/lib/mx_platform_api/models/spending_plan_account_response.rb +142 -0
  213. data/lib/mx_platform_api/models/spending_plan_accounts_response.rb +95 -0
  214. data/lib/mx_platform_api/models/spending_plan_iteration_item_create_request_body.rb +124 -0
  215. data/lib/mx_platform_api/models/spending_plan_iteration_item_response.rb +224 -0
  216. data/lib/mx_platform_api/models/spending_plan_iteration_items_response_body.rb +95 -0
  217. data/lib/mx_platform_api/models/spending_plan_iteration_response.rb +162 -0
  218. data/lib/mx_platform_api/models/spending_plan_iterations_response.rb +95 -0
  219. data/lib/mx_platform_api/models/spending_plan_response.rb +129 -0
  220. data/lib/mx_platform_api/models/spending_plans_response_body.rb +95 -0
  221. data/lib/mx_platform_api/models/split_transaction_request.rb +106 -0
  222. data/lib/mx_platform_api/models/split_transaction_request_body.rb +75 -0
  223. data/lib/mx_platform_api/models/split_transactions_response_body.rb +85 -0
  224. data/lib/mx_platform_api/models/statement_response.rb +157 -0
  225. data/lib/mx_platform_api/models/statement_response_body.rb +76 -0
  226. data/lib/mx_platform_api/models/statements_response_body.rb +95 -0
  227. data/lib/mx_platform_api/models/status.rb +36 -0
  228. data/lib/mx_platform_api/models/style.rb +74 -0
  229. data/lib/mx_platform_api/models/supported_product.rb +56 -0
  230. data/lib/mx_platform_api/models/supported_product1.rb +52 -0
  231. data/lib/mx_platform_api/models/tag_create_request.rb +72 -0
  232. data/lib/mx_platform_api/models/tag_create_request_body.rb +74 -0
  233. data/lib/mx_platform_api/models/tag_response.rb +99 -0
  234. data/lib/mx_platform_api/models/tag_response_body.rb +74 -0
  235. data/lib/mx_platform_api/models/tag_update_request.rb +72 -0
  236. data/lib/mx_platform_api/models/tag_update_request_body.rb +74 -0
  237. data/lib/mx_platform_api/models/tagging_create_request.rb +83 -0
  238. data/lib/mx_platform_api/models/tagging_create_request_body.rb +75 -0
  239. data/lib/mx_platform_api/models/tagging_response.rb +130 -0
  240. data/lib/mx_platform_api/models/tagging_response_body.rb +75 -0
  241. data/lib/mx_platform_api/models/tagging_update_request.rb +73 -0
  242. data/lib/mx_platform_api/models/tagging_update_request_body.rb +75 -0
  243. data/lib/mx_platform_api/models/taggings_response_body.rb +94 -0
  244. data/lib/mx_platform_api/models/tags_response_body.rb +94 -0
  245. data/lib/mx_platform_api/models/token_request_body.rb +75 -0
  246. data/lib/mx_platform_api/models/token_response.rb +114 -0
  247. data/lib/mx_platform_api/models/token_response_body.rb +84 -0
  248. data/lib/mx_platform_api/models/track_type_name.rb +44 -0
  249. data/lib/mx_platform_api/models/transaction_create_request.rb +192 -0
  250. data/lib/mx_platform_api/models/transaction_create_request_body.rb +76 -0
  251. data/lib/mx_platform_api/models/transaction_create_response_body.rb +595 -0
  252. data/lib/mx_platform_api/models/transaction_includes_response.rb +643 -0
  253. data/lib/mx_platform_api/models/transaction_response.rb +597 -0
  254. data/lib/mx_platform_api/models/transaction_response_body.rb +76 -0
  255. data/lib/mx_platform_api/models/transaction_rule_create_request.rb +98 -0
  256. data/lib/mx_platform_api/models/transaction_rule_create_request_body.rb +77 -0
  257. data/lib/mx_platform_api/models/transaction_rule_response.rb +152 -0
  258. data/lib/mx_platform_api/models/transaction_rule_response_body.rb +77 -0
  259. data/lib/mx_platform_api/models/transaction_rule_update_request.rb +103 -0
  260. data/lib/mx_platform_api/models/transaction_rule_update_request_body.rb +77 -0
  261. data/lib/mx_platform_api/models/transaction_rules_response_body.rb +95 -0
  262. data/lib/mx_platform_api/models/transaction_type.rb +36 -0
  263. data/lib/mx_platform_api/models/transaction_update_request.rb +74 -0
  264. data/lib/mx_platform_api/models/transaction_update_request_body.rb +76 -0
  265. data/lib/mx_platform_api/models/transactions_response_body.rb +95 -0
  266. data/lib/mx_platform_api/models/transactions_response_body_includes.rb +95 -0
  267. data/lib/mx_platform_api/models/type.rb +36 -0
  268. data/lib/mx_platform_api/models/update_goal_request.rb +185 -0
  269. data/lib/mx_platform_api/models/update_goal_request_body.rb +74 -0
  270. data/lib/mx_platform_api/models/use_case.rb +36 -0
  271. data/lib/mx_platform_api/models/user_create_request.rb +105 -0
  272. data/lib/mx_platform_api/models/user_create_request_body.rb +74 -0
  273. data/lib/mx_platform_api/models/user_response.rb +119 -0
  274. data/lib/mx_platform_api/models/user_response_body.rb +74 -0
  275. data/lib/mx_platform_api/models/user_update_request.rb +105 -0
  276. data/lib/mx_platform_api/models/user_update_request_body.rb +74 -0
  277. data/lib/mx_platform_api/models/users_response_body.rb +94 -0
  278. data/lib/mx_platform_api/models/users_widget_urls_request.rb +76 -0
  279. data/lib/mx_platform_api/models/vc_response.rb +77 -0
  280. data/lib/mx_platform_api/models/widget_request.rb +466 -0
  281. data/lib/mx_platform_api/models/widget_response.rb +100 -0
  282. data/lib/mx_platform_api/models/widget_response_body.rb +76 -0
  283. data/lib/mx_platform_api/models/widget_type.rb +149 -0
  284. data/lib/mx_platform_api/utilities/date_time_helper.rb +11 -0
  285. data/lib/mx_platform_api/utilities/file_wrapper.rb +28 -0
  286. data/lib/mx_platform_api.rb +313 -0
  287. metadata +370 -0
@@ -0,0 +1,187 @@
1
+ # mx_platform_api
2
+ #
3
+ # This file was automatically generated by APIMATIC v3.0 (
4
+ # https://www.apimatic.io ).
5
+
6
+ module MxPlatformApi
7
+ # Reward Model.
8
+ class Reward < BaseModel
9
+ SKIP = Object.new
10
+ private_constant :SKIP
11
+
12
+ # The unique identifier for an account. Defined by MX.
13
+ # @return [String]
14
+ attr_accessor :account_guid
15
+
16
+ # The unique identifier for the member. Defined by MX.
17
+ # @return [String]
18
+ attr_accessor :member_guid
19
+
20
+ # The unique identifier for the user. Defined by MX.
21
+ # @return [String]
22
+ attr_accessor :user_guid
23
+
24
+ # The type of balance associated with the reward, for example,
25
+ # `BALANCE_TO_LEVEL`, or `TOTAL_BALANCE`.
26
+ # @return [String]
27
+ attr_accessor :balance_type
28
+
29
+ # The current balance of the account.
30
+ # `PENDING` transactions are typically not taken into account with the
31
+ # current balance, but this may not always be the case.
32
+ #
33
+ # The balance will usually be a positive value for all account types.
34
+ # Asset-type accounts (`CHECKING`, `SAVINGS`, `INVESTMENT`) may have a
35
+ # negative balance if they are in overdraft.
36
+ # Debt-type accounts (`CREDIT_CARD`, `LOAN`, `LINE_OF_CREDIT`, `MORTGAGE`)
37
+ # may have a negative balance if they are overpaid.
38
+ # @return [Float]
39
+ attr_accessor :balance
40
+
41
+ # The date and time the resource was created, represented in ISO 8601 format
42
+ # with a timestamp.
43
+ # @return [String]
44
+ attr_accessor :created_at
45
+
46
+ # The description for the reward as given by the data provider.
47
+ # @return [String]
48
+ attr_accessor :description
49
+
50
+ # The date on which the balance expires.
51
+ # @return [String]
52
+ attr_accessor :expires_on
53
+
54
+ # The unique identifier for the reward. Defined by MX.
55
+ # @return [String]
56
+ attr_accessor :guid
57
+
58
+ # The units in which the balance is given, for example, `MILES` or `POINTS`.
59
+ # @return [String]
60
+ attr_accessor :unit_type
61
+
62
+ # The date and time at which the account was last updated.
63
+ # @return [String]
64
+ attr_accessor :updated_at
65
+
66
+ # A mapping from model property names to API property names.
67
+ def self.names
68
+ @_hash = {} if @_hash.nil?
69
+ @_hash['account_guid'] = 'account_guid'
70
+ @_hash['member_guid'] = 'member_guid'
71
+ @_hash['user_guid'] = 'user_guid'
72
+ @_hash['balance_type'] = 'balance_type'
73
+ @_hash['balance'] = 'balance'
74
+ @_hash['created_at'] = 'created_at'
75
+ @_hash['description'] = 'description'
76
+ @_hash['expires_on'] = 'expires_on'
77
+ @_hash['guid'] = 'guid'
78
+ @_hash['unit_type'] = 'unit_type'
79
+ @_hash['updated_at'] = 'updated_at'
80
+ @_hash
81
+ end
82
+
83
+ # An array for optional fields
84
+ def self.optionals
85
+ %w[
86
+ account_guid
87
+ member_guid
88
+ user_guid
89
+ balance_type
90
+ balance
91
+ created_at
92
+ description
93
+ expires_on
94
+ guid
95
+ unit_type
96
+ updated_at
97
+ ]
98
+ end
99
+
100
+ # An array for nullable fields
101
+ def self.nullables
102
+ []
103
+ end
104
+
105
+ def initialize(account_guid: SKIP, member_guid: SKIP, user_guid: SKIP,
106
+ balance_type: SKIP, balance: SKIP, created_at: SKIP,
107
+ description: SKIP, expires_on: SKIP, guid: SKIP,
108
+ unit_type: SKIP, updated_at: SKIP,
109
+ additional_properties: nil)
110
+ # Add additional model properties to the instance
111
+ additional_properties = {} if additional_properties.nil?
112
+
113
+ @account_guid = account_guid unless account_guid == SKIP
114
+ @member_guid = member_guid unless member_guid == SKIP
115
+ @user_guid = user_guid unless user_guid == SKIP
116
+ @balance_type = balance_type unless balance_type == SKIP
117
+ @balance = balance unless balance == SKIP
118
+ @created_at = created_at unless created_at == SKIP
119
+ @description = description unless description == SKIP
120
+ @expires_on = expires_on unless expires_on == SKIP
121
+ @guid = guid unless guid == SKIP
122
+ @unit_type = unit_type unless unit_type == SKIP
123
+ @updated_at = updated_at unless updated_at == SKIP
124
+ @additional_properties = additional_properties
125
+ end
126
+
127
+ # Creates an instance of the object from a hash.
128
+ def self.from_hash(hash)
129
+ return nil unless hash
130
+
131
+ # Extract variables from the hash.
132
+ account_guid = hash.key?('account_guid') ? hash['account_guid'] : SKIP
133
+ member_guid = hash.key?('member_guid') ? hash['member_guid'] : SKIP
134
+ user_guid = hash.key?('user_guid') ? hash['user_guid'] : SKIP
135
+ balance_type = hash.key?('balance_type') ? hash['balance_type'] : SKIP
136
+ balance = hash.key?('balance') ? hash['balance'] : SKIP
137
+ created_at = hash.key?('created_at') ? hash['created_at'] : SKIP
138
+ description = hash.key?('description') ? hash['description'] : SKIP
139
+ expires_on = hash.key?('expires_on') ? hash['expires_on'] : SKIP
140
+ guid = hash.key?('guid') ? hash['guid'] : SKIP
141
+ unit_type = hash.key?('unit_type') ? hash['unit_type'] : SKIP
142
+ updated_at = hash.key?('updated_at') ? hash['updated_at'] : SKIP
143
+
144
+ # Create a new hash for additional properties, removing known properties.
145
+ new_hash = hash.reject { |k, _| names.value?(k) }
146
+
147
+ additional_properties = APIHelper.get_additional_properties(
148
+ new_hash, proc { |value| value }
149
+ )
150
+
151
+ # Create object from extracted values.
152
+ Reward.new(account_guid: account_guid,
153
+ member_guid: member_guid,
154
+ user_guid: user_guid,
155
+ balance_type: balance_type,
156
+ balance: balance,
157
+ created_at: created_at,
158
+ description: description,
159
+ expires_on: expires_on,
160
+ guid: guid,
161
+ unit_type: unit_type,
162
+ updated_at: updated_at,
163
+ additional_properties: additional_properties)
164
+ end
165
+
166
+ # Provides a human-readable string representation of the object.
167
+ def to_s
168
+ class_name = self.class.name.split('::').last
169
+ "<#{class_name} account_guid: #{@account_guid}, member_guid: #{@member_guid}, user_guid:"\
170
+ " #{@user_guid}, balance_type: #{@balance_type}, balance: #{@balance}, created_at:"\
171
+ " #{@created_at}, description: #{@description}, expires_on: #{@expires_on}, guid: #{@guid},"\
172
+ " unit_type: #{@unit_type}, updated_at: #{@updated_at}, additional_properties:"\
173
+ " #{@additional_properties}>"
174
+ end
175
+
176
+ # Provides a debugging-friendly string with detailed object information.
177
+ def inspect
178
+ class_name = self.class.name.split('::').last
179
+ "<#{class_name} account_guid: #{@account_guid.inspect}, member_guid:"\
180
+ " #{@member_guid.inspect}, user_guid: #{@user_guid.inspect}, balance_type:"\
181
+ " #{@balance_type.inspect}, balance: #{@balance.inspect}, created_at:"\
182
+ " #{@created_at.inspect}, description: #{@description.inspect}, expires_on:"\
183
+ " #{@expires_on.inspect}, guid: #{@guid.inspect}, unit_type: #{@unit_type.inspect},"\
184
+ " updated_at: #{@updated_at.inspect}, additional_properties: #{@additional_properties}>"
185
+ end
186
+ end
187
+ end
@@ -0,0 +1,156 @@
1
+ # mx_platform_api
2
+ #
3
+ # This file was automatically generated by APIMATIC v3.0 (
4
+ # https://www.apimatic.io ).
5
+
6
+ module MxPlatformApi
7
+ # RewardElements Model.
8
+ class RewardElements < BaseModel
9
+ SKIP = Object.new
10
+ private_constant :SKIP
11
+
12
+ # The type of balance associated with the reward, for example,
13
+ # `BALANCE_TO_LEVEL`, or `TOTAL_BALANCE`.
14
+ # @return [String]
15
+ attr_accessor :balance_type
16
+
17
+ # The current balance of the account.
18
+ # `PENDING` transactions are typically not taken into account with the
19
+ # current balance, but this may not always be the case.
20
+ #
21
+ # The balance will usually be a positive value for all account types.
22
+ # Asset-type accounts (`CHECKING`, `SAVINGS`, `INVESTMENT`) may have a
23
+ # negative balance if they are in overdraft.
24
+ # Debt-type accounts (`CREDIT_CARD`, `LOAN`, `LINE_OF_CREDIT`, `MORTGAGE`)
25
+ # may have a negative balance if they are overpaid.
26
+ # @return [Float]
27
+ attr_accessor :balance
28
+
29
+ # The date and time the resource was created, represented in ISO 8601 format
30
+ # with a timestamp.
31
+ # @return [String]
32
+ attr_accessor :created_at
33
+
34
+ # The description for the reward as given by the data provider.
35
+ # @return [String]
36
+ attr_accessor :description
37
+
38
+ # The date on which the balance expires.
39
+ # @return [String]
40
+ attr_accessor :expires_on
41
+
42
+ # The unique identifier for the reward. Defined by MX.
43
+ # @return [String]
44
+ attr_accessor :guid
45
+
46
+ # The units in which the balance is given, for example, `MILES` or `POINTS`.
47
+ # @return [String]
48
+ attr_accessor :unit_type
49
+
50
+ # The date and time at which the account was last updated.
51
+ # @return [String]
52
+ attr_accessor :updated_at
53
+
54
+ # A mapping from model property names to API property names.
55
+ def self.names
56
+ @_hash = {} if @_hash.nil?
57
+ @_hash['balance_type'] = 'balance_type'
58
+ @_hash['balance'] = 'balance'
59
+ @_hash['created_at'] = 'created_at'
60
+ @_hash['description'] = 'description'
61
+ @_hash['expires_on'] = 'expires_on'
62
+ @_hash['guid'] = 'guid'
63
+ @_hash['unit_type'] = 'unit_type'
64
+ @_hash['updated_at'] = 'updated_at'
65
+ @_hash
66
+ end
67
+
68
+ # An array for optional fields
69
+ def self.optionals
70
+ %w[
71
+ balance_type
72
+ balance
73
+ created_at
74
+ description
75
+ expires_on
76
+ guid
77
+ unit_type
78
+ updated_at
79
+ ]
80
+ end
81
+
82
+ # An array for nullable fields
83
+ def self.nullables
84
+ []
85
+ end
86
+
87
+ def initialize(balance_type: SKIP, balance: SKIP, created_at: SKIP,
88
+ description: SKIP, expires_on: SKIP, guid: SKIP,
89
+ unit_type: SKIP, updated_at: SKIP,
90
+ additional_properties: nil)
91
+ # Add additional model properties to the instance
92
+ additional_properties = {} if additional_properties.nil?
93
+
94
+ @balance_type = balance_type unless balance_type == SKIP
95
+ @balance = balance unless balance == SKIP
96
+ @created_at = created_at unless created_at == SKIP
97
+ @description = description unless description == SKIP
98
+ @expires_on = expires_on unless expires_on == SKIP
99
+ @guid = guid unless guid == SKIP
100
+ @unit_type = unit_type unless unit_type == SKIP
101
+ @updated_at = updated_at unless updated_at == SKIP
102
+ @additional_properties = additional_properties
103
+ end
104
+
105
+ # Creates an instance of the object from a hash.
106
+ def self.from_hash(hash)
107
+ return nil unless hash
108
+
109
+ # Extract variables from the hash.
110
+ balance_type = hash.key?('balance_type') ? hash['balance_type'] : SKIP
111
+ balance = hash.key?('balance') ? hash['balance'] : SKIP
112
+ created_at = hash.key?('created_at') ? hash['created_at'] : SKIP
113
+ description = hash.key?('description') ? hash['description'] : SKIP
114
+ expires_on = hash.key?('expires_on') ? hash['expires_on'] : SKIP
115
+ guid = hash.key?('guid') ? hash['guid'] : SKIP
116
+ unit_type = hash.key?('unit_type') ? hash['unit_type'] : SKIP
117
+ updated_at = hash.key?('updated_at') ? hash['updated_at'] : SKIP
118
+
119
+ # Create a new hash for additional properties, removing known properties.
120
+ new_hash = hash.reject { |k, _| names.value?(k) }
121
+
122
+ additional_properties = APIHelper.get_additional_properties(
123
+ new_hash, proc { |value| value }
124
+ )
125
+
126
+ # Create object from extracted values.
127
+ RewardElements.new(balance_type: balance_type,
128
+ balance: balance,
129
+ created_at: created_at,
130
+ description: description,
131
+ expires_on: expires_on,
132
+ guid: guid,
133
+ unit_type: unit_type,
134
+ updated_at: updated_at,
135
+ additional_properties: additional_properties)
136
+ end
137
+
138
+ # Provides a human-readable string representation of the object.
139
+ def to_s
140
+ class_name = self.class.name.split('::').last
141
+ "<#{class_name} balance_type: #{@balance_type}, balance: #{@balance}, created_at:"\
142
+ " #{@created_at}, description: #{@description}, expires_on: #{@expires_on}, guid: #{@guid},"\
143
+ " unit_type: #{@unit_type}, updated_at: #{@updated_at}, additional_properties:"\
144
+ " #{@additional_properties}>"
145
+ end
146
+
147
+ # Provides a debugging-friendly string with detailed object information.
148
+ def inspect
149
+ class_name = self.class.name.split('::').last
150
+ "<#{class_name} balance_type: #{@balance_type.inspect}, balance: #{@balance.inspect},"\
151
+ " created_at: #{@created_at.inspect}, description: #{@description.inspect}, expires_on:"\
152
+ " #{@expires_on.inspect}, guid: #{@guid.inspect}, unit_type: #{@unit_type.inspect},"\
153
+ " updated_at: #{@updated_at.inspect}, additional_properties: #{@additional_properties}>"
154
+ end
155
+ end
156
+ end
@@ -0,0 +1,75 @@
1
+ # mx_platform_api
2
+ #
3
+ # This file was automatically generated by APIMATIC v3.0 (
4
+ # https://www.apimatic.io ).
5
+
6
+ module MxPlatformApi
7
+ # RewardResponseBody Model.
8
+ class RewardResponseBody < BaseModel
9
+ SKIP = Object.new
10
+ private_constant :SKIP
11
+
12
+ # TODO: Write general description for this method
13
+ # @return [Reward]
14
+ attr_accessor :reward
15
+
16
+ # A mapping from model property names to API property names.
17
+ def self.names
18
+ @_hash = {} if @_hash.nil?
19
+ @_hash['reward'] = 'reward'
20
+ @_hash
21
+ end
22
+
23
+ # An array for optional fields
24
+ def self.optionals
25
+ %w[
26
+ reward
27
+ ]
28
+ end
29
+
30
+ # An array for nullable fields
31
+ def self.nullables
32
+ []
33
+ end
34
+
35
+ def initialize(reward: SKIP, additional_properties: nil)
36
+ # Add additional model properties to the instance
37
+ additional_properties = {} if additional_properties.nil?
38
+
39
+ @reward = reward unless reward == SKIP
40
+ @additional_properties = additional_properties
41
+ end
42
+
43
+ # Creates an instance of the object from a hash.
44
+ def self.from_hash(hash)
45
+ return nil unless hash
46
+
47
+ # Extract variables from the hash.
48
+ reward = Reward.from_hash(hash['reward']) if hash['reward']
49
+
50
+ # Create a new hash for additional properties, removing known properties.
51
+ new_hash = hash.reject { |k, _| names.value?(k) }
52
+
53
+ additional_properties = APIHelper.get_additional_properties(
54
+ new_hash, proc { |value| value }
55
+ )
56
+
57
+ # Create object from extracted values.
58
+ RewardResponseBody.new(reward: reward,
59
+ additional_properties: additional_properties)
60
+ end
61
+
62
+ # Provides a human-readable string representation of the object.
63
+ def to_s
64
+ class_name = self.class.name.split('::').last
65
+ "<#{class_name} reward: #{@reward}, additional_properties: #{@additional_properties}>"
66
+ end
67
+
68
+ # Provides a debugging-friendly string with detailed object information.
69
+ def inspect
70
+ class_name = self.class.name.split('::').last
71
+ "<#{class_name} reward: #{@reward.inspect}, additional_properties:"\
72
+ " #{@additional_properties}>"
73
+ end
74
+ end
75
+ end
@@ -0,0 +1,94 @@
1
+ # mx_platform_api
2
+ #
3
+ # This file was automatically generated by APIMATIC v3.0 (
4
+ # https://www.apimatic.io ).
5
+
6
+ module MxPlatformApi
7
+ # RewardsResponseBody Model.
8
+ class RewardsResponseBody < BaseModel
9
+ SKIP = Object.new
10
+ private_constant :SKIP
11
+
12
+ # TODO: Write general description for this method
13
+ # @return [Array[Reward]]
14
+ attr_accessor :rewards
15
+
16
+ # TODO: Write general description for this method
17
+ # @return [PaginationResponse]
18
+ attr_accessor :pagination
19
+
20
+ # A mapping from model property names to API property names.
21
+ def self.names
22
+ @_hash = {} if @_hash.nil?
23
+ @_hash['rewards'] = 'rewards'
24
+ @_hash['pagination'] = 'pagination'
25
+ @_hash
26
+ end
27
+
28
+ # An array for optional fields
29
+ def self.optionals
30
+ %w[
31
+ rewards
32
+ pagination
33
+ ]
34
+ end
35
+
36
+ # An array for nullable fields
37
+ def self.nullables
38
+ []
39
+ end
40
+
41
+ def initialize(rewards: SKIP, pagination: SKIP, additional_properties: nil)
42
+ # Add additional model properties to the instance
43
+ additional_properties = {} if additional_properties.nil?
44
+
45
+ @rewards = rewards unless rewards == SKIP
46
+ @pagination = pagination unless pagination == SKIP
47
+ @additional_properties = additional_properties
48
+ end
49
+
50
+ # Creates an instance of the object from a hash.
51
+ def self.from_hash(hash)
52
+ return nil unless hash
53
+
54
+ # Extract variables from the hash.
55
+ # Parameter is an array, so we need to iterate through it
56
+ rewards = nil
57
+ unless hash['rewards'].nil?
58
+ rewards = []
59
+ hash['rewards'].each do |structure|
60
+ rewards << (Reward.from_hash(structure) if structure)
61
+ end
62
+ end
63
+
64
+ rewards = SKIP unless hash.key?('rewards')
65
+ pagination = PaginationResponse.from_hash(hash['pagination']) if hash['pagination']
66
+
67
+ # Create a new hash for additional properties, removing known properties.
68
+ new_hash = hash.reject { |k, _| names.value?(k) }
69
+
70
+ additional_properties = APIHelper.get_additional_properties(
71
+ new_hash, proc { |value| value }
72
+ )
73
+
74
+ # Create object from extracted values.
75
+ RewardsResponseBody.new(rewards: rewards,
76
+ pagination: pagination,
77
+ additional_properties: additional_properties)
78
+ end
79
+
80
+ # Provides a human-readable string representation of the object.
81
+ def to_s
82
+ class_name = self.class.name.split('::').last
83
+ "<#{class_name} rewards: #{@rewards}, pagination: #{@pagination}, additional_properties:"\
84
+ " #{@additional_properties}>"
85
+ end
86
+
87
+ # Provides a debugging-friendly string with detailed object information.
88
+ def inspect
89
+ class_name = self.class.name.split('::').last
90
+ "<#{class_name} rewards: #{@rewards.inspect}, pagination: #{@pagination.inspect},"\
91
+ " additional_properties: #{@additional_properties}>"
92
+ end
93
+ end
94
+ end