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,415 @@
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
+ # InsightsApi
8
+ class InsightsApi < BaseApi
9
+ # Use this endpoint to list all insights associated with an account GUID.
10
+ # @param [String] accept_version Required parameter: MX Platform API
11
+ # version.
12
+ # @param [String] account_guid Required parameter: The unique id for an
13
+ # `account`.
14
+ # @param [String] user_guid Required parameter: The unique identifier for a
15
+ # `user`, beginning with the prefix `USR-`.
16
+ # @param [Integer] page Optional parameter: Results are paginated. Specify
17
+ # current page.
18
+ # @param [Integer] records_per_page Optional parameter: This specifies the
19
+ # number of records to be returned on each page. Defaults to `25`. The valid
20
+ # range is from `10` to `100`. If the value exceeds `100`, the default value
21
+ # of `25` will be used instead.
22
+ # @return [ApiResponse] Complete http response with raw body and status code.
23
+ def list_insights_by_account(accept_version,
24
+ account_guid,
25
+ user_guid,
26
+ page: nil,
27
+ records_per_page: nil)
28
+ @api_call
29
+ .request(new_request_builder(HttpMethodEnum::GET,
30
+ '/users/{user_guid}/accounts/{account_guid}/insights',
31
+ Server::DEFAULT)
32
+ .header_param(new_parameter(accept_version, key: 'Accept-Version')
33
+ .is_required(true))
34
+ .template_param(new_parameter(account_guid, key: 'account_guid')
35
+ .is_required(true)
36
+ .should_encode(true))
37
+ .template_param(new_parameter(user_guid, key: 'user_guid')
38
+ .is_required(true)
39
+ .should_encode(true))
40
+ .query_param(new_parameter(page, key: 'page'))
41
+ .query_param(new_parameter(records_per_page, key: 'records_per_page'))
42
+ .header_param(new_parameter('application/json', key: 'accept'))
43
+ .auth(Single.new('basicAuth')))
44
+ .response(new_response_handler
45
+ .deserializer(APIHelper.method(:custom_type_deserializer))
46
+ .deserialize_into(InsightsResponseBody.method(:from_hash))
47
+ .is_api_response(true))
48
+ .execute
49
+ end
50
+
51
+ # Use this endpoint to list all the insights associated with the user.
52
+ # @param [String] accept_version Required parameter: MX Platform API
53
+ # version.
54
+ # @param [String] user_guid Required parameter: The unique identifier for a
55
+ # `user`, beginning with the prefix `USR-`.
56
+ # @param [Integer] page Optional parameter: Results are paginated. Specify
57
+ # current page.
58
+ # @param [Integer] records_per_page Optional parameter: This specifies the
59
+ # number of records to be returned on each page. Defaults to `25`. The valid
60
+ # range is from `10` to `100`. If the value exceeds `100`, the default value
61
+ # of `25` will be used instead.
62
+ # @return [ApiResponse] Complete http response with raw body and status code.
63
+ def list_insights_user(accept_version,
64
+ user_guid,
65
+ page: nil,
66
+ records_per_page: nil)
67
+ @api_call
68
+ .request(new_request_builder(HttpMethodEnum::GET,
69
+ '/users/{user_guid}/insights',
70
+ Server::DEFAULT)
71
+ .header_param(new_parameter(accept_version, key: 'Accept-Version')
72
+ .is_required(true))
73
+ .template_param(new_parameter(user_guid, key: 'user_guid')
74
+ .is_required(true)
75
+ .should_encode(true))
76
+ .query_param(new_parameter(page, key: 'page'))
77
+ .query_param(new_parameter(records_per_page, key: 'records_per_page'))
78
+ .header_param(new_parameter('application/json', key: 'accept'))
79
+ .auth(Single.new('basicAuth')))
80
+ .response(new_response_handler
81
+ .deserializer(APIHelper.method(:custom_type_deserializer))
82
+ .deserialize_into(InsightsResponseBody.method(:from_hash))
83
+ .is_api_response(true))
84
+ .execute
85
+ end
86
+
87
+ # Use this endpoint to list all the categories associated with the insight.
88
+ # @param [String] accept_version Required parameter: MX Platform API
89
+ # version.
90
+ # @param [String] user_guid Required parameter: The unique identifier for a
91
+ # `user`, beginning with the prefix `USR-`.
92
+ # @param [String] insight_guid Required parameter: The unique identifier for
93
+ # the insight. Defined by MX.
94
+ # @param [Integer] page Optional parameter: Results are paginated. Specify
95
+ # current page.
96
+ # @param [Integer] records_per_page Optional parameter: This specifies the
97
+ # number of records to be returned on each page. Defaults to `25`. The valid
98
+ # range is from `10` to `100`. If the value exceeds `100`, the default value
99
+ # of `25` will be used instead.
100
+ # @return [ApiResponse] Complete http response with raw body and status code.
101
+ def list_categories_insight(accept_version,
102
+ user_guid,
103
+ insight_guid,
104
+ page: nil,
105
+ records_per_page: nil)
106
+ @api_call
107
+ .request(new_request_builder(HttpMethodEnum::GET,
108
+ '/users/{user_guid}/insights/{insight_guid}/categories',
109
+ Server::DEFAULT)
110
+ .header_param(new_parameter(accept_version, key: 'Accept-Version')
111
+ .is_required(true))
112
+ .template_param(new_parameter(user_guid, key: 'user_guid')
113
+ .is_required(true)
114
+ .should_encode(true))
115
+ .template_param(new_parameter(insight_guid, key: 'insight_guid')
116
+ .is_required(true)
117
+ .should_encode(true))
118
+ .query_param(new_parameter(page, key: 'page'))
119
+ .query_param(new_parameter(records_per_page, key: 'records_per_page'))
120
+ .header_param(new_parameter('application/json', key: 'accept'))
121
+ .auth(Single.new('basicAuth')))
122
+ .response(new_response_handler
123
+ .deserializer(APIHelper.method(:custom_type_deserializer))
124
+ .deserialize_into(CategoriesResponseBody.method(:from_hash))
125
+ .is_api_response(true))
126
+ .execute
127
+ end
128
+
129
+ # Use this endpoint to list all the accounts associated with the insight.
130
+ # @param [String] accept_version Required parameter: MX Platform API
131
+ # version.
132
+ # @param [String] user_guid Required parameter: The unique identifier for a
133
+ # `user`, beginning with the prefix `USR-`.
134
+ # @param [String] insight_guid Required parameter: The unique identifier for
135
+ # the insight. Defined by MX.
136
+ # @param [Integer] page Optional parameter: Results are paginated. Specify
137
+ # current page.
138
+ # @param [Integer] records_per_page Optional parameter: This specifies the
139
+ # number of records to be returned on each page. Defaults to `25`. The valid
140
+ # range is from `10` to `100`. If the value exceeds `100`, the default value
141
+ # of `25` will be used instead.
142
+ # @return [ApiResponse] Complete http response with raw body and status code.
143
+ def list_accounts_insight(accept_version,
144
+ user_guid,
145
+ insight_guid,
146
+ page: nil,
147
+ records_per_page: nil)
148
+ @api_call
149
+ .request(new_request_builder(HttpMethodEnum::GET,
150
+ '/users/{user_guid}/insights/{insight_guid}/accounts',
151
+ Server::DEFAULT)
152
+ .header_param(new_parameter(accept_version, key: 'Accept-Version')
153
+ .is_required(true))
154
+ .template_param(new_parameter(user_guid, key: 'user_guid')
155
+ .is_required(true)
156
+ .should_encode(true))
157
+ .template_param(new_parameter(insight_guid, key: 'insight_guid')
158
+ .is_required(true)
159
+ .should_encode(true))
160
+ .query_param(new_parameter(page, key: 'page'))
161
+ .query_param(new_parameter(records_per_page, key: 'records_per_page'))
162
+ .header_param(new_parameter('application/json', key: 'accept'))
163
+ .auth(Single.new('basicAuth')))
164
+ .response(new_response_handler
165
+ .deserializer(APIHelper.method(:custom_type_deserializer))
166
+ .deserialize_into(AccountsResponseBody.method(:from_hash))
167
+ .is_api_response(true))
168
+ .execute
169
+ end
170
+
171
+ # Use this endpoint to list all the merchants associated with the insight.
172
+ # @param [String] accept_version Required parameter: MX Platform API
173
+ # version.
174
+ # @param [String] user_guid Required parameter: The unique identifier for a
175
+ # `user`, beginning with the prefix `USR-`.
176
+ # @param [String] insight_guid Required parameter: The unique identifier for
177
+ # the insight. Defined by MX.
178
+ # @param [Integer] page Optional parameter: Results are paginated. Specify
179
+ # current page.
180
+ # @param [Integer] records_per_page Optional parameter: This specifies the
181
+ # number of records to be returned on each page. Defaults to `25`. The valid
182
+ # range is from `10` to `100`. If the value exceeds `100`, the default value
183
+ # of `25` will be used instead.
184
+ # @return [ApiResponse] Complete http response with raw body and status code.
185
+ def list_merchants_insight(accept_version,
186
+ user_guid,
187
+ insight_guid,
188
+ page: nil,
189
+ records_per_page: nil)
190
+ @api_call
191
+ .request(new_request_builder(HttpMethodEnum::GET,
192
+ '/users/{user_guid}/insights/{insight_guid}/merchants',
193
+ Server::DEFAULT)
194
+ .header_param(new_parameter(accept_version, key: 'Accept-Version')
195
+ .is_required(true))
196
+ .template_param(new_parameter(user_guid, key: 'user_guid')
197
+ .is_required(true)
198
+ .should_encode(true))
199
+ .template_param(new_parameter(insight_guid, key: 'insight_guid')
200
+ .is_required(true)
201
+ .should_encode(true))
202
+ .query_param(new_parameter(page, key: 'page'))
203
+ .query_param(new_parameter(records_per_page, key: 'records_per_page'))
204
+ .header_param(new_parameter('application/json', key: 'accept'))
205
+ .auth(Single.new('basicAuth')))
206
+ .response(new_response_handler
207
+ .deserializer(APIHelper.method(:custom_type_deserializer))
208
+ .deserialize_into(MerchantsResponseBody.method(:from_hash))
209
+ .is_api_response(true))
210
+ .execute
211
+ end
212
+
213
+ # Use this endpoint to list all the scheduled payments associated with the
214
+ # insight.
215
+ # @param [String] accept_version Required parameter: MX Platform API
216
+ # version.
217
+ # @param [String] user_guid Required parameter: The unique identifier for a
218
+ # `user`, beginning with the prefix `USR-`.
219
+ # @param [String] insight_guid Required parameter: The unique identifier for
220
+ # the insight. Defined by MX.
221
+ # @param [Integer] page Optional parameter: Results are paginated. Specify
222
+ # current page.
223
+ # @param [Integer] records_per_page Optional parameter: This specifies the
224
+ # number of records to be returned on each page. Defaults to `25`. The valid
225
+ # range is from `10` to `100`. If the value exceeds `100`, the default value
226
+ # of `25` will be used instead.
227
+ # @return [ApiResponse] Complete http response with raw body and status code.
228
+ def list_scheduled_payments_insight(accept_version,
229
+ user_guid,
230
+ insight_guid,
231
+ page: nil,
232
+ records_per_page: nil)
233
+ @api_call
234
+ .request(new_request_builder(HttpMethodEnum::GET,
235
+ '/users/{user_guid}/insights/{insight_guid}/scheduled_payments',
236
+ Server::DEFAULT)
237
+ .header_param(new_parameter(accept_version, key: 'Accept-Version')
238
+ .is_required(true))
239
+ .template_param(new_parameter(user_guid, key: 'user_guid')
240
+ .is_required(true)
241
+ .should_encode(true))
242
+ .template_param(new_parameter(insight_guid, key: 'insight_guid')
243
+ .is_required(true)
244
+ .should_encode(true))
245
+ .query_param(new_parameter(page, key: 'page'))
246
+ .query_param(new_parameter(records_per_page, key: 'records_per_page'))
247
+ .header_param(new_parameter('application/json', key: 'accept'))
248
+ .auth(Single.new('basicAuth')))
249
+ .response(new_response_handler
250
+ .deserializer(APIHelper.method(:custom_type_deserializer))
251
+ .deserialize_into(ScheduledPaymentsResponseBody.method(:from_hash))
252
+ .is_api_response(true))
253
+ .execute
254
+ end
255
+
256
+ # Use this endpoint to list all the transactions associated with the
257
+ # insight.
258
+ # @param [String] accept_version Required parameter: MX Platform API
259
+ # version.
260
+ # @param [String] user_guid Required parameter: The unique identifier for a
261
+ # `user`, beginning with the prefix `USR-`.
262
+ # @param [String] insight_guid Required parameter: The unique identifier for
263
+ # the insight. Defined by MX.
264
+ # @param [Integer] page Optional parameter: Results are paginated. Specify
265
+ # current page.
266
+ # @param [Integer] records_per_page Optional parameter: This specifies the
267
+ # number of records to be returned on each page. Defaults to `25`. The valid
268
+ # range is from `10` to `100`. If the value exceeds `100`, the default value
269
+ # of `25` will be used instead.
270
+ # @return [ApiResponse] Complete http response with raw body and status code.
271
+ def list_transactions_insight(accept_version,
272
+ user_guid,
273
+ insight_guid,
274
+ page: nil,
275
+ records_per_page: nil)
276
+ @api_call
277
+ .request(new_request_builder(HttpMethodEnum::GET,
278
+ '/users/{user_guid}/insights/{insight_guid}/transactions',
279
+ Server::DEFAULT)
280
+ .header_param(new_parameter(accept_version, key: 'Accept-Version')
281
+ .is_required(true))
282
+ .template_param(new_parameter(user_guid, key: 'user_guid')
283
+ .is_required(true)
284
+ .should_encode(true))
285
+ .template_param(new_parameter(insight_guid, key: 'insight_guid')
286
+ .is_required(true)
287
+ .should_encode(true))
288
+ .query_param(new_parameter(page, key: 'page'))
289
+ .query_param(new_parameter(records_per_page, key: 'records_per_page'))
290
+ .header_param(new_parameter('application/json', key: 'accept'))
291
+ .auth(Single.new('basicAuth')))
292
+ .response(new_response_handler
293
+ .deserializer(APIHelper.method(:custom_type_deserializer))
294
+ .deserialize_into(TransactionsResponseBody.method(:from_hash))
295
+ .is_api_response(true))
296
+ .execute
297
+ end
298
+
299
+ # Use this endpoint to read the attributes of an insight according to its
300
+ # unique GUID.
301
+ # @param [String] accept_version Required parameter: MX Platform API
302
+ # version.
303
+ # @param [String] user_guid Required parameter: The unique identifier for a
304
+ # `user`, beginning with the prefix `USR-`.
305
+ # @param [String] insight_guid Required parameter: The unique identifier for
306
+ # the insight. Defined by MX.
307
+ # @return [ApiResponse] Complete http response with raw body and status code.
308
+ def read_insight_user(accept_version,
309
+ user_guid,
310
+ insight_guid)
311
+ @api_call
312
+ .request(new_request_builder(HttpMethodEnum::GET,
313
+ '/users/{user_guid}/insights/{insight_guid}',
314
+ Server::DEFAULT)
315
+ .header_param(new_parameter(accept_version, key: 'Accept-Version')
316
+ .is_required(true))
317
+ .template_param(new_parameter(user_guid, key: 'user_guid')
318
+ .is_required(true)
319
+ .should_encode(true))
320
+ .template_param(new_parameter(insight_guid, key: 'insight_guid')
321
+ .is_required(true)
322
+ .should_encode(true))
323
+ .header_param(new_parameter('application/json', key: 'accept'))
324
+ .auth(Single.new('basicAuth')))
325
+ .response(new_response_handler
326
+ .deserializer(APIHelper.method(:custom_type_deserializer))
327
+ .deserialize_into(InsightResponseBody.method(:from_hash))
328
+ .is_api_response(true))
329
+ .execute
330
+ end
331
+
332
+ # Use this endpoint to update the attributes of an insight according to its
333
+ # unique GUID.
334
+ # @param [String] accept_version Required parameter: MX Platform API
335
+ # version.
336
+ # @param [String] user_guid Required parameter: The unique identifier for a
337
+ # `user`, beginning with the prefix `USR-`.
338
+ # @param [String] insight_guid Required parameter: The unique identifier for
339
+ # the insight. Defined by MX.
340
+ # @param [InsightUpdateRequestBody] body Required parameter: The insight to
341
+ # be updated (None of these parameters are required, but the user object
342
+ # cannot be empty.)
343
+ # @return [ApiResponse] Complete http response with raw body and status code.
344
+ def update_insight(accept_version,
345
+ user_guid,
346
+ insight_guid,
347
+ body)
348
+ @api_call
349
+ .request(new_request_builder(HttpMethodEnum::PUT,
350
+ '/users/{user_guid}/insights/{insight_guid}',
351
+ Server::DEFAULT)
352
+ .header_param(new_parameter(accept_version, key: 'Accept-Version')
353
+ .is_required(true))
354
+ .template_param(new_parameter(user_guid, key: 'user_guid')
355
+ .is_required(true)
356
+ .should_encode(true))
357
+ .template_param(new_parameter(insight_guid, key: 'insight_guid')
358
+ .is_required(true)
359
+ .should_encode(true))
360
+ .header_param(new_parameter('application/json', key: 'Content-Type'))
361
+ .body_param(new_parameter(body)
362
+ .is_required(true))
363
+ .header_param(new_parameter('application/json', key: 'accept'))
364
+ .body_serializer(proc do |param| param.to_json unless param.nil? end)
365
+ .auth(Single.new('basicAuth')))
366
+ .response(new_response_handler
367
+ .deserializer(APIHelper.method(:custom_type_deserializer))
368
+ .deserialize_into(InsightResponse.method(:from_hash))
369
+ .is_api_response(true))
370
+ .execute
371
+ end
372
+
373
+ # Use this endpoint to list all insights associated with a transaction GUID.
374
+ # @param [String] accept_version Required parameter: MX Platform API
375
+ # version.
376
+ # @param [String] transaction_guid Required parameter: The unique id for a
377
+ # `transaction`.
378
+ # @param [String] user_guid Required parameter: The unique identifier for a
379
+ # `user`, beginning with the prefix `USR-`.
380
+ # @param [Integer] page Optional parameter: Results are paginated. Specify
381
+ # current page.
382
+ # @param [Integer] records_per_page Optional parameter: This specifies the
383
+ # number of records to be returned on each page. Defaults to `25`. The valid
384
+ # range is from `10` to `100`. If the value exceeds `100`, the default value
385
+ # of `25` will be used instead.
386
+ # @return [ApiResponse] Complete http response with raw body and status code.
387
+ def list_insights_by_transaction(accept_version,
388
+ transaction_guid,
389
+ user_guid,
390
+ page: nil,
391
+ records_per_page: nil)
392
+ @api_call
393
+ .request(new_request_builder(HttpMethodEnum::GET,
394
+ '/users/{user_guid}/transactions/{transaction_guid}/insights',
395
+ Server::DEFAULT)
396
+ .header_param(new_parameter(accept_version, key: 'Accept-Version')
397
+ .is_required(true))
398
+ .template_param(new_parameter(transaction_guid, key: 'transaction_guid')
399
+ .is_required(true)
400
+ .should_encode(true))
401
+ .template_param(new_parameter(user_guid, key: 'user_guid')
402
+ .is_required(true)
403
+ .should_encode(true))
404
+ .query_param(new_parameter(page, key: 'page'))
405
+ .query_param(new_parameter(records_per_page, key: 'records_per_page'))
406
+ .header_param(new_parameter('application/json', key: 'accept'))
407
+ .auth(Single.new('basicAuth')))
408
+ .response(new_response_handler
409
+ .deserializer(APIHelper.method(:custom_type_deserializer))
410
+ .deserialize_into(InsightsResponseBody.method(:from_hash))
411
+ .is_api_response(true))
412
+ .execute
413
+ end
414
+ end
415
+ end
@@ -0,0 +1,159 @@
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
+ # InstitutionsApi
8
+ class InstitutionsApi < BaseApi
9
+ # Lists financial institutions available through the MX platform. This
10
+ # endpoint has been updated in `v20250224` to enhance search and filtering
11
+ # capabilities based on the products supported by each institution.
12
+ # @param [String] accept_version Required parameter: MX Platform API
13
+ # version.
14
+ # @param [String] name Optional parameter: This will list only institutions
15
+ # in which the appended string appears.
16
+ # @param [Array[String]] iso_country_code Optional parameter: An array of
17
+ # strings that filters institutions in the widget by the specified country
18
+ # code. Acceptable codes include `US`, `CA`, and `MX` (Mexico).
19
+ # @param [Integer] page Optional parameter: Results are paginated. Specify
20
+ # current page.
21
+ # @param [Integer] records_per_page Optional parameter: This specifies the
22
+ # number of records to be returned on each page. Defaults to `25`. The valid
23
+ # range is from `10` to `1000`. If the value exceeds `1000`, the default
24
+ # value of `25` will be used instead.
25
+ # @param [Array[SupportedProduct1]] supported_products Optional parameter:
26
+ # Filters institutions that support specific products. Values may include
27
+ # account_verification, identity_verification, transactions,
28
+ # transaction_history, statements, investments. For example, institutions
29
+ # that support account_verification and statements,
30
+ # `?supported_products[]=account_verification&supported_products[]=statement
31
+ # s`.
32
+ # @return [ApiResponse] Complete http response with raw body and status code.
33
+ def list_institutions(accept_version,
34
+ name: nil,
35
+ iso_country_code: nil,
36
+ page: nil,
37
+ records_per_page: nil,
38
+ supported_products: nil)
39
+ @api_call
40
+ .request(new_request_builder(HttpMethodEnum::GET,
41
+ '/institutions',
42
+ Server::DEFAULT)
43
+ .header_param(new_parameter(accept_version, key: 'Accept-Version')
44
+ .is_required(true))
45
+ .query_param(new_parameter(name, key: 'name'))
46
+ .query_param(new_parameter(iso_country_code, key: 'iso_country_code'))
47
+ .query_param(new_parameter(page, key: 'page'))
48
+ .query_param(new_parameter(records_per_page, key: 'records_per_page'))
49
+ .query_param(new_parameter(supported_products, key: 'supported_products'))
50
+ .header_param(new_parameter('application/json', key: 'accept'))
51
+ .auth(Single.new('basicAuth')))
52
+ .response(new_response_handler
53
+ .deserializer(APIHelper.method(:custom_type_deserializer))
54
+ .deserialize_into(InstitutionsResponseBody.method(:from_hash))
55
+ .is_api_response(true))
56
+ .execute
57
+ end
58
+
59
+ # This endpoint returns a paginated list containing institutions that have
60
+ # been set as favorites, sorted by popularity. Please contact MX to set a
61
+ # list of favorites.
62
+ # @param [Array[String]] iso_country_code Optional parameter: An array of
63
+ # strings that filters institutions in the widget by the specified country
64
+ # code. Acceptable codes include `US`, `CA`, and `MX` (Mexico).
65
+ # @param [Integer] page Optional parameter: Results are paginated. Specify
66
+ # current page.
67
+ # @param [Integer] records_per_page Optional parameter: This specifies the
68
+ # number of records to be returned on each page. Defaults to `25`. The valid
69
+ # range is from `10` to `1000`. If the value exceeds `1000`, the default
70
+ # value of `25` will be used instead.
71
+ # @return [ApiResponse] Complete http response with raw body and status code.
72
+ def list_favorite_institutions(iso_country_code: nil,
73
+ page: nil,
74
+ records_per_page: nil)
75
+ @api_call
76
+ .request(new_request_builder(HttpMethodEnum::GET,
77
+ '/institutions/favorites',
78
+ Server::DEFAULT)
79
+ .query_param(new_parameter(iso_country_code, key: 'iso_country_code'))
80
+ .query_param(new_parameter(page, key: 'page'))
81
+ .query_param(new_parameter(records_per_page, key: 'records_per_page'))
82
+ .header_param(new_parameter('application/json', key: 'accept'))
83
+ .auth(Single.new('basicAuth')))
84
+ .response(new_response_handler
85
+ .deserializer(APIHelper.method(:custom_type_deserializer))
86
+ .deserialize_into(InstitutionsResponseBody.method(:from_hash))
87
+ .is_api_response(true))
88
+ .execute
89
+ end
90
+
91
+ # This endpoint returns information about the institution specified by
92
+ # `institution_code`. The `v20250224` update enhances the granularity of the
93
+ # information provided about the services and products supported by the
94
+ # institution.
95
+ # @param [String] accept_version Required parameter: MX Platform API
96
+ # version.
97
+ # @param [String] institution_code Required parameter: A unique identifier
98
+ # for each institution, defined by MX.
99
+ # @return [ApiResponse] Complete http response with raw body and status code.
100
+ def read_institution(accept_version,
101
+ institution_code)
102
+ @api_call
103
+ .request(new_request_builder(HttpMethodEnum::GET,
104
+ '/institutions/{institution_code}',
105
+ Server::DEFAULT)
106
+ .header_param(new_parameter(accept_version, key: 'Accept-Version')
107
+ .is_required(true))
108
+ .template_param(new_parameter(institution_code, key: 'institution_code')
109
+ .is_required(true)
110
+ .should_encode(true))
111
+ .header_param(new_parameter('application/json', key: 'accept'))
112
+ .auth(Single.new('basicAuth')))
113
+ .response(new_response_handler
114
+ .deserializer(APIHelper.method(:custom_type_deserializer))
115
+ .deserialize_into(InstitutionResponseBody.method(:from_hash))
116
+ .is_api_response(true))
117
+ .execute
118
+ end
119
+
120
+ # Use this endpoint to see which credentials will be needed to create a
121
+ # member for a specific institution.
122
+ # Passing an invalid `institution_identifier` returns a `404`.
123
+ # @param [String] accept_version Required parameter: MX Platform API
124
+ # version.
125
+ # @param [String] institution_identifier Required parameter: The identifier
126
+ # for the institution. For this identifier, use either the
127
+ # `institution_code` or the institution `guid`.
128
+ # @param [Integer] page Optional parameter: Results are paginated. Specify
129
+ # current page.
130
+ # @param [Integer] records_per_page Optional parameter: This specifies the
131
+ # number of records to be returned on each page. Defaults to `25`. The valid
132
+ # range is from `10` to `1000`. If the value exceeds `1000`, the default
133
+ # value of `25` will be used instead.
134
+ # @return [ApiResponse] Complete http response with raw body and status code.
135
+ def list_institution_credentials(accept_version,
136
+ institution_identifier,
137
+ page: nil,
138
+ records_per_page: nil)
139
+ @api_call
140
+ .request(new_request_builder(HttpMethodEnum::GET,
141
+ '/institutions/{institution_identifier}/credentials',
142
+ Server::DEFAULT)
143
+ .header_param(new_parameter(accept_version, key: 'Accept-Version')
144
+ .is_required(true))
145
+ .template_param(new_parameter(institution_identifier, key: 'institution_identifier')
146
+ .is_required(true)
147
+ .should_encode(true))
148
+ .query_param(new_parameter(page, key: 'page'))
149
+ .query_param(new_parameter(records_per_page, key: 'records_per_page'))
150
+ .header_param(new_parameter('application/json', key: 'accept'))
151
+ .auth(Single.new('basicAuth')))
152
+ .response(new_response_handler
153
+ .deserializer(APIHelper.method(:custom_type_deserializer))
154
+ .deserialize_into(CredentialsResponseBody.method(:from_hash))
155
+ .is_api_response(true))
156
+ .execute
157
+ end
158
+ end
159
+ end