apimatic-ak-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 (229) hide show
  1. checksums.yaml +7 -0
  2. data/LICENSE +28 -0
  3. data/README.md +190 -0
  4. data/bin/console +15 -0
  5. data/lib/akoya/api_helper.rb +10 -0
  6. data/lib/akoya/client.rb +117 -0
  7. data/lib/akoya/configuration.rb +195 -0
  8. data/lib/akoya/controllers/account_information_controller.rb +93 -0
  9. data/lib/akoya/controllers/balances_controller.rb +92 -0
  10. data/lib/akoya/controllers/base_controller.rb +65 -0
  11. data/lib/akoya/controllers/customers_controller.rb +112 -0
  12. data/lib/akoya/controllers/investments_controller.rb +95 -0
  13. data/lib/akoya/controllers/payments_controller.rb +70 -0
  14. data/lib/akoya/controllers/statements_controller.rb +158 -0
  15. data/lib/akoya/controllers/tokens_controller.rb +122 -0
  16. data/lib/akoya/controllers/transactions_controller.rb +108 -0
  17. data/lib/akoya/exceptions/api_exception.rb +21 -0
  18. data/lib/akoya/exceptions/error_entity_exception.rb +54 -0
  19. data/lib/akoya/exceptions/error_response_exception.rb +53 -0
  20. data/lib/akoya/http/api_response.rb +19 -0
  21. data/lib/akoya/http/auth/basic_auth.rb +62 -0
  22. data/lib/akoya/http/auth/bearer_auth.rb +53 -0
  23. data/lib/akoya/http/http_call_back.rb +10 -0
  24. data/lib/akoya/http/http_method_enum.rb +10 -0
  25. data/lib/akoya/http/http_request.rb +10 -0
  26. data/lib/akoya/http/http_response.rb +10 -0
  27. data/lib/akoya/http/proxy_settings.rb +22 -0
  28. data/lib/akoya/logging/configuration/api_logging_configuration.rb +186 -0
  29. data/lib/akoya/logging/sdk_logger.rb +17 -0
  30. data/lib/akoya/models/account.rb +86 -0
  31. data/lib/akoya/models/account_category.rb +50 -0
  32. data/lib/akoya/models/account_contact_entity.rb +132 -0
  33. data/lib/akoya/models/account_holder_entity.rb +178 -0
  34. data/lib/akoya/models/account_holder_relationship.rb +110 -0
  35. data/lib/akoya/models/account_holder_relationship_account_holder_entity.rb +110 -0
  36. data/lib/akoya/models/account_information.rb +335 -0
  37. data/lib/akoya/models/action.rb +48 -0
  38. data/lib/akoya/models/address.rb +144 -0
  39. data/lib/akoya/models/akoya_account_info_product.rb +88 -0
  40. data/lib/akoya/models/an_array_of_statements.rb +95 -0
  41. data/lib/akoya/models/an_investment_holding.rb +493 -0
  42. data/lib/akoya/models/annual_increase_type.rb +40 -0
  43. data/lib/akoya/models/annuity_account.rb +370 -0
  44. data/lib/akoya/models/annuity_account_info.rb +86 -0
  45. data/lib/akoya/models/annuity_balance_details.rb +87 -0
  46. data/lib/akoya/models/annuity_balances.rb +477 -0
  47. data/lib/akoya/models/annuity_product_type.rb +36 -0
  48. data/lib/akoya/models/annuity_value_basis.rb +36 -0
  49. data/lib/akoya/models/array_of_account_payment_networks.rb +85 -0
  50. data/lib/akoya/models/asset_class.rb +95 -0
  51. data/lib/akoya/models/asset_class_an_investment_holding.rb +85 -0
  52. data/lib/akoya/models/asset_class_asset_class.rb +56 -0
  53. data/lib/akoya/models/asset_class_citi_bank_investment_holdings.rb +86 -0
  54. data/lib/akoya/models/balance_type.rb +37 -0
  55. data/lib/akoya/models/balance_type_investment_balance_list.rb +36 -0
  56. data/lib/akoya/models/balances.rb +88 -0
  57. data/lib/akoya/models/base_model.rb +110 -0
  58. data/lib/akoya/models/business_customer_entity.rb +127 -0
  59. data/lib/akoya/models/business_customer_entity_account_holder_entity.rb +126 -0
  60. data/lib/akoya/models/business_customer_entity_customer.rb +126 -0
  61. data/lib/akoya/models/call_type.rb +44 -0
  62. data/lib/akoya/models/citi_bank_investment.rb +535 -0
  63. data/lib/akoya/models/citi_bank_investment_details.rb +75 -0
  64. data/lib/akoya/models/citi_bank_investment_holdings.rb +210 -0
  65. data/lib/akoya/models/compounding_period.rb +56 -0
  66. data/lib/akoya/models/contribution_entity.rb +266 -0
  67. data/lib/akoya/models/coupon_mature_frequency.rb +48 -0
  68. data/lib/akoya/models/currency.rb +108 -0
  69. data/lib/akoya/models/currency_citi_bank_investment_holdings.rb +86 -0
  70. data/lib/akoya/models/currency_entity.rb +109 -0
  71. data/lib/akoya/models/current_customer.rb +75 -0
  72. data/lib/akoya/models/customer.rb +164 -0
  73. data/lib/akoya/models/customer_current_customer.rb +164 -0
  74. data/lib/akoya/models/customer_name.rb +127 -0
  75. data/lib/akoya/models/customer_name_account_holder_entity.rb +127 -0
  76. data/lib/akoya/models/customer_name_customer.rb +127 -0
  77. data/lib/akoya/models/debit_credit_memo.rb +37 -0
  78. data/lib/akoya/models/debt_class.rb +44 -0
  79. data/lib/akoya/models/debt_security.rb +137 -0
  80. data/lib/akoya/models/debt_security_entity.rb +216 -0
  81. data/lib/akoya/models/debt_type.rb +36 -0
  82. data/lib/akoya/models/delivery_address.rb +153 -0
  83. data/lib/akoya/models/deposit_account.rb +375 -0
  84. data/lib/akoya/models/deposit_account_info.rb +86 -0
  85. data/lib/akoya/models/deposit_balance_details.rb +87 -0
  86. data/lib/akoya/models/deposit_balances.rb +438 -0
  87. data/lib/akoya/models/deposit_transaction.rb +369 -0
  88. data/lib/akoya/models/deposit_transaction_details.rb +87 -0
  89. data/lib/akoya/models/domicile.rb +85 -0
  90. data/lib/akoya/models/equity_grant.rb +199 -0
  91. data/lib/akoya/models/error_entity_account_information.rb +97 -0
  92. data/lib/akoya/models/error_entity_annuity_account.rb +97 -0
  93. data/lib/akoya/models/error_entity_annuity_balances.rb +97 -0
  94. data/lib/akoya/models/error_entity_citi_bank_investment.rb +97 -0
  95. data/lib/akoya/models/error_entity_deposit_account.rb +97 -0
  96. data/lib/akoya/models/error_entity_deposit_balances.rb +97 -0
  97. data/lib/akoya/models/error_entity_insurance_account.rb +97 -0
  98. data/lib/akoya/models/error_entity_insurance_balances.rb +97 -0
  99. data/lib/akoya/models/error_entity_investment_account.rb +97 -0
  100. data/lib/akoya/models/error_entity_investment_balances.rb +97 -0
  101. data/lib/akoya/models/error_entity_line_of_credit_balances.rb +97 -0
  102. data/lib/akoya/models/error_entity_loan_account.rb +97 -0
  103. data/lib/akoya/models/error_entity_loan_balances.rb +97 -0
  104. data/lib/akoya/models/error_entity_us_bank_investment.rb +97 -0
  105. data/lib/akoya/models/fi_asset_class.rb +95 -0
  106. data/lib/akoya/models/fi_asset_class_an_investment_holding.rb +85 -0
  107. data/lib/akoya/models/fi_attribute.rb +95 -0
  108. data/lib/akoya/models/fi_attribute_entity.rb +95 -0
  109. data/lib/akoya/models/frequency.rb +56 -0
  110. data/lib/akoya/models/hateoas_link.rb +105 -0
  111. data/lib/akoya/models/held_in_account.rb +44 -0
  112. data/lib/akoya/models/holding_sub_type.rb +36 -0
  113. data/lib/akoya/models/holding_type.rb +56 -0
  114. data/lib/akoya/models/income_type.rb +41 -0
  115. data/lib/akoya/models/industry_code.rb +85 -0
  116. data/lib/akoya/models/insurance_account.rb +349 -0
  117. data/lib/akoya/models/insurance_account_info.rb +87 -0
  118. data/lib/akoya/models/insurance_balance_details.rb +87 -0
  119. data/lib/akoya/models/insurance_balances.rb +420 -0
  120. data/lib/akoya/models/insurance_transaction.rb +351 -0
  121. data/lib/akoya/models/insurance_transaction_details.rb +87 -0
  122. data/lib/akoya/models/interest_rate_type.rb +36 -0
  123. data/lib/akoya/models/inv401_k_source.rb +56 -0
  124. data/lib/akoya/models/inv401_k_source_open_order_entity.rb +57 -0
  125. data/lib/akoya/models/inv401_k_surce.rb +56 -0
  126. data/lib/akoya/models/investment_account.rb +411 -0
  127. data/lib/akoya/models/investment_account_annuity_balance.rb +87 -0
  128. data/lib/akoya/models/investment_account_deposit_balance.rb +87 -0
  129. data/lib/akoya/models/investment_account_info.rb +87 -0
  130. data/lib/akoya/models/investment_account_insurance_balance.rb +87 -0
  131. data/lib/akoya/models/investment_account_loan_balance.rb +86 -0
  132. data/lib/akoya/models/investment_account_loc_balance.rb +86 -0
  133. data/lib/akoya/models/investment_balance_details.rb +87 -0
  134. data/lib/akoya/models/investment_balance_list.rb +148 -0
  135. data/lib/akoya/models/investment_balances.rb +525 -0
  136. data/lib/akoya/models/investment_details.rb +88 -0
  137. data/lib/akoya/models/investment_loan_entity.rb +271 -0
  138. data/lib/akoya/models/investment_transaction.rb +783 -0
  139. data/lib/akoya/models/investment_transaction_details.rb +87 -0
  140. data/lib/akoya/models/investments.rb +88 -0
  141. data/lib/akoya/models/line_item.rb +156 -0
  142. data/lib/akoya/models/line_of_credit_balances.rb +601 -0
  143. data/lib/akoya/models/links.rb +95 -0
  144. data/lib/akoya/models/loan_account.rb +417 -0
  145. data/lib/akoya/models/loan_account_info.rb +86 -0
  146. data/lib/akoya/models/loan_balance_details.rb +86 -0
  147. data/lib/akoya/models/loan_balances.rb +556 -0
  148. data/lib/akoya/models/loan_payment_frequency.rb +68 -0
  149. data/lib/akoya/models/loan_transaction.rb +360 -0
  150. data/lib/akoya/models/loan_transaction_details.rb +87 -0
  151. data/lib/akoya/models/loc_account_info.rb +86 -0
  152. data/lib/akoya/models/loc_balance_details.rb +86 -0
  153. data/lib/akoya/models/loc_transaction.rb +372 -0
  154. data/lib/akoya/models/loc_transaction_details.rb +86 -0
  155. data/lib/akoya/models/mnext.rb +84 -0
  156. data/lib/akoya/models/mode.rb +36 -0
  157. data/lib/akoya/models/mutual_fund_security.rb +99 -0
  158. data/lib/akoya/models/mutual_fund_security_entity.rb +150 -0
  159. data/lib/akoya/models/mutual_fund_type.rb +40 -0
  160. data/lib/akoya/models/obtain_tokens.rb +99 -0
  161. data/lib/akoya/models/open_order_entity.rb +228 -0
  162. data/lib/akoya/models/option_security.rb +125 -0
  163. data/lib/akoya/models/option_security_entity.rb +127 -0
  164. data/lib/akoya/models/option_type.rb +36 -0
  165. data/lib/akoya/models/order_duration.rb +40 -0
  166. data/lib/akoya/models/order_type.rb +60 -0
  167. data/lib/akoya/models/other_security_entity.rb +77 -0
  168. data/lib/akoya/models/paginated_array.rb +75 -0
  169. data/lib/akoya/models/payment_details.rb +142 -0
  170. data/lib/akoya/models/payment_frequency.rb +56 -0
  171. data/lib/akoya/models/payment_frequency_annuity_account.rb +44 -0
  172. data/lib/akoya/models/payment_frequency_annuity_balances.rb +44 -0
  173. data/lib/akoya/models/payment_network_supported_by_account.rb +129 -0
  174. data/lib/akoya/models/pension_source_entity.rb +143 -0
  175. data/lib/akoya/models/period_certain_guarantee.rb +48 -0
  176. data/lib/akoya/models/policy_premium_term.rb +36 -0
  177. data/lib/akoya/models/position_type.rb +36 -0
  178. data/lib/akoya/models/postion_type.rb +36 -0
  179. data/lib/akoya/models/prev.rb +84 -0
  180. data/lib/akoya/models/refresh_tokens.rb +103 -0
  181. data/lib/akoya/models/secured.rb +36 -0
  182. data/lib/akoya/models/security_id_type.rb +52 -0
  183. data/lib/akoya/models/security_id_type_investment_transaction.rb +52 -0
  184. data/lib/akoya/models/security_type.rb +56 -0
  185. data/lib/akoya/models/statement_entity.rb +136 -0
  186. data/lib/akoya/models/status.rb +56 -0
  187. data/lib/akoya/models/status_deposit_transaction.rb +44 -0
  188. data/lib/akoya/models/status_insurance_transaction.rb +44 -0
  189. data/lib/akoya/models/status_investment_transaction.rb +44 -0
  190. data/lib/akoya/models/status_loan_transaction.rb +44 -0
  191. data/lib/akoya/models/status_loc_transaction.rb +44 -0
  192. data/lib/akoya/models/status_statement_entity.rb +40 -0
  193. data/lib/akoya/models/status_transaction.rb +44 -0
  194. data/lib/akoya/models/stock_security_entity.rb +137 -0
  195. data/lib/akoya/models/stock_type.rb +56 -0
  196. data/lib/akoya/models/sub_account.rb +44 -0
  197. data/lib/akoya/models/sub_account_fund.rb +44 -0
  198. data/lib/akoya/models/sub_account_sec.rb +44 -0
  199. data/lib/akoya/models/sweep_security_entity.rb +118 -0
  200. data/lib/akoya/models/tax_lot.rb +137 -0
  201. data/lib/akoya/models/tax_lot_an_investment_holding.rb +139 -0
  202. data/lib/akoya/models/telephone.rb +95 -0
  203. data/lib/akoya/models/telephone_number.rb +95 -0
  204. data/lib/akoya/models/token_example_response.rb +101 -0
  205. data/lib/akoya/models/transaction.rb +328 -0
  206. data/lib/akoya/models/transaction_reason.rb +41 -0
  207. data/lib/akoya/models/transaction_type.rb +84 -0
  208. data/lib/akoya/models/transaction_type_insurance_transaction.rb +44 -0
  209. data/lib/akoya/models/transaction_type_investment_transaction.rb +192 -0
  210. data/lib/akoya/models/transaction_type_loan_transaction.rb +44 -0
  211. data/lib/akoya/models/transaction_type_loc_transaction.rb +84 -0
  212. data/lib/akoya/models/transactions_entity.rb +98 -0
  213. data/lib/akoya/models/transfer_action.rb +36 -0
  214. data/lib/akoya/models/type.rb +44 -0
  215. data/lib/akoya/models/type_hateoas_link.rb +52 -0
  216. data/lib/akoya/models/type_telephone_number.rb +44 -0
  217. data/lib/akoya/models/unit_type.rb +36 -0
  218. data/lib/akoya/models/unit_type_open_order_entity.rb +36 -0
  219. data/lib/akoya/models/us_bank_investment.rb +535 -0
  220. data/lib/akoya/models/us_bank_investment_details.rb +75 -0
  221. data/lib/akoya/models/us_bank_investment_holdings.rb +403 -0
  222. data/lib/akoya/models/vesting.rb +135 -0
  223. data/lib/akoya/models/vesting_entity.rb +185 -0
  224. data/lib/akoya/models/x_akoya_interaction_type.rb +36 -0
  225. data/lib/akoya/utilities/date_time_helper.rb +11 -0
  226. data/lib/akoya/utilities/file_wrapper.rb +28 -0
  227. data/lib/akoya/utilities/union_type_lookup.rb +91 -0
  228. data/lib/akoya.rb +250 -0
  229. metadata +312 -0
@@ -0,0 +1,186 @@
1
+ # akoya
2
+ #
3
+ # This file was automatically generated by APIMATIC v3.0 (
4
+ # https://www.apimatic.io ).
5
+
6
+ module Akoya
7
+ # Initializes a new instance of RequestLoggingConfiguration.
8
+ class RequestLoggingConfiguration < CoreLibrary::ApiRequestLoggingConfiguration
9
+ # @param log_body [Boolean] Indicates whether the message body should be logged. Default is false.
10
+ # @param log_headers [Boolean] Indicates whether the message headers should be logged. Default is false.
11
+ # @param headers_to_exclude [Array<String>] Array of headers not displayed in logging. Default is an empty array.
12
+ # @param headers_to_include [Array<String>] Array of headers to be displayed in logging. Default is an empty array.
13
+ # @param headers_to_unmask [Array<String>] Array of headers which values are non-sensitive to display in logging.
14
+ # Default is an empty array.
15
+ def initialize(log_body: false, log_headers: false, headers_to_include: nil,
16
+ headers_to_exclude: nil, headers_to_unmask: nil,
17
+ include_query_in_path: false)
18
+ super(
19
+ log_body,
20
+ log_headers,
21
+ headers_to_exclude,
22
+ headers_to_include,
23
+ headers_to_unmask,
24
+ include_query_in_path
25
+ )
26
+ end
27
+
28
+ def clone_with(log_body: nil, log_headers: nil, headers_to_include: nil,
29
+ headers_to_exclude: nil, headers_to_unmask: nil, include_query_in_path: nil)
30
+ log_body ||= self.log_body
31
+ log_headers ||= self.log_headers
32
+ headers_to_include ||= self.headers_to_include
33
+ headers_to_exclude ||= self.headers_to_exclude
34
+ headers_to_unmask ||= self.headers_to_unmask
35
+ include_query_in_path ||= self.include_query_in_path
36
+
37
+ RequestLoggingConfiguration.new(
38
+ log_body: log_body,
39
+ log_headers: log_headers,
40
+ headers_to_include: headers_to_include,
41
+ headers_to_exclude: headers_to_exclude,
42
+ headers_to_unmask: headers_to_unmask,
43
+ include_query_in_path: include_query_in_path
44
+ )
45
+ end
46
+
47
+ def self.from_env
48
+ log_body = ENV['REQUEST_LOG_BODY']
49
+ log_headers = ENV['REQUEST_LOG_HEADERS']
50
+ headers_to_include = ENV['REQUEST_HEADERS_TO_INCLUDE']
51
+ headers_to_exclude = ENV['REQUEST_HEADERS_TO_EXCLUDE']
52
+ headers_to_unmask = ENV['REQUEST_HEADERS_TO_UNMASK']
53
+ include_query_in_path = ENV['REQUEST_INCLUDE_QUERY_IN_PATH']
54
+
55
+ new(
56
+ log_body: log_body,
57
+ log_headers: log_headers,
58
+ headers_to_include: headers_to_include,
59
+ headers_to_exclude: headers_to_exclude,
60
+ headers_to_unmask: headers_to_unmask,
61
+ include_query_in_path: include_query_in_path
62
+ )
63
+ end
64
+
65
+ def self.any_logging_configured?
66
+ %w[
67
+ REQUEST_LOG_BODY
68
+ REQUEST_LOG_HEADERS
69
+ REQUEST_HEADERS_TO_INCLUDE
70
+ REQUEST_HEADERS_TO_EXCLUDE
71
+ REQUEST_HEADERS_TO_UNMASK
72
+ REQUEST_INCLUDE_QUERY_IN_PATH
73
+ ].any? { |key| ENV.key?(key) && !ENV[key].nil? && !ENV[key].empty? }
74
+ end
75
+ end
76
+
77
+ # Initializes a new instance of ResponseLoggingConfiguration.
78
+ class ResponseLoggingConfiguration < CoreLibrary::ApiResponseLoggingConfiguration
79
+ def initialize(log_body: false, log_headers: false, headers_to_include: nil,
80
+ headers_to_exclude: nil, headers_to_unmask: nil)
81
+ super(
82
+ log_body,
83
+ log_headers,
84
+ headers_to_exclude,
85
+ headers_to_include,
86
+ headers_to_unmask
87
+ )
88
+ end
89
+
90
+ def clone_with(log_body: nil, log_headers: nil, headers_to_include: nil,
91
+ headers_to_exclude: nil, headers_to_unmask: nil)
92
+ log_body ||= self.log_body
93
+ log_headers ||= self.log_headers
94
+ headers_to_include ||= self.headers_to_include
95
+ headers_to_exclude ||= self.headers_to_exclude
96
+ headers_to_unmask ||= self.headers_to_unmask
97
+
98
+ ResponseLoggingConfiguration.new(
99
+ log_body: log_body,
100
+ log_headers: log_headers,
101
+ headers_to_include: headers_to_include,
102
+ headers_to_exclude: headers_to_exclude,
103
+ headers_to_unmask: headers_to_unmask
104
+ )
105
+ end
106
+
107
+ def self.from_env
108
+ log_body = ENV['RESPONSE_LOG_BODY']
109
+ log_headers = ENV['RESPONSE_LOG_HEADERS']
110
+ headers_to_include = ENV['RESPONSE_HEADERS_TO_INCLUDE']
111
+ headers_to_exclude = ENV['RESPONSE_HEADERS_TO_EXCLUDE']
112
+ headers_to_unmask = ENV['RESPONSE_HEADERS_TO_UNMASK']
113
+
114
+ new(
115
+ log_body: log_body,
116
+ log_headers: log_headers,
117
+ headers_to_include: headers_to_include,
118
+ headers_to_exclude: headers_to_exclude,
119
+ headers_to_unmask: headers_to_unmask
120
+ )
121
+ end
122
+
123
+ def self.any_logging_configured?
124
+ %w[
125
+ RESPONSE_LOG_BODY
126
+ RESPONSE_LOG_HEADERS
127
+ RESPONSE_HEADERS_TO_INCLUDE
128
+ RESPONSE_HEADERS_TO_EXCLUDE
129
+ RESPONSE_HEADERS_TO_UNMASK
130
+ ].any? { |key| ENV.key?(key) && !ENV[key].nil? && !ENV[key].empty? }
131
+ end
132
+ end
133
+
134
+ # Initializes a new instance of LoggingConfiguration.
135
+ class LoggingConfiguration < CoreLibrary::ApiLoggingConfiguration
136
+ def initialize(logger: nil, log_level: nil, mask_sensitive_headers: true,
137
+ request_logging_config: nil,
138
+ response_logging_config: nil)
139
+ request_logging_config ||= RequestLoggingConfiguration.new
140
+ response_logging_config ||= ResponseLoggingConfiguration.new
141
+ super(
142
+ logger,
143
+ log_level,
144
+ request_logging_config,
145
+ response_logging_config,
146
+ mask_sensitive_headers
147
+ )
148
+ end
149
+
150
+ def clone_with(logger: nil, log_level: nil, mask_sensitive_headers: nil,
151
+ request_logging_config: nil, response_logging_config: nil)
152
+ logger ||= self.logger
153
+ log_level ||= self.log_level
154
+ mask_sensitive_headers ||= self.mask_sensitive_headers
155
+ request_logging_config ||= self.request_logging_config.clone
156
+ response_logging_config ||= self.response_logging_config.clone
157
+
158
+ LoggingConfiguration.new(
159
+ logger: logger,
160
+ log_level: log_level,
161
+ mask_sensitive_headers: mask_sensitive_headers,
162
+ request_logging_config: request_logging_config,
163
+ response_logging_config: response_logging_config
164
+ )
165
+ end
166
+
167
+ def self.from_env
168
+ log_level = ENV['LOG_LEVEL']
169
+ mask_sensitive_headers = ENV['MASK_SENSITIVE_HEADERS']
170
+
171
+ new(
172
+ log_level: log_level,
173
+ mask_sensitive_headers: mask_sensitive_headers,
174
+ request_logging_config: RequestLoggingConfiguration.from_env,
175
+ response_logging_config: ResponseLoggingConfiguration.from_env
176
+ )
177
+ end
178
+
179
+ def self.any_logging_configured?
180
+ RequestLoggingConfiguration.any_logging_configured? ||
181
+ ResponseLoggingConfiguration.any_logging_configured? ||
182
+ ENV.key?('LOG_LEVEL') ||
183
+ ENV.key?('MASK_SENSITIVE_HEADERS')
184
+ end
185
+ end
186
+ end
@@ -0,0 +1,17 @@
1
+ # akoya
2
+ #
3
+ # This file was automatically generated by APIMATIC v3.0 (
4
+ # https://www.apimatic.io ).
5
+
6
+ module Akoya
7
+ # Represents the generic logger facade
8
+ class AbstractLogger < Logger
9
+ # Logs a message with a specified log level and additional parameters.
10
+ # @param level [Symbol] The log level of the message.
11
+ # @param message [String] The message to log.
12
+ # @param params [Hash] Additional parameters to include in the log message.
13
+ def log(level, message, params)
14
+ raise NotImplementedError, 'This method needs to be implemented in a child class.'
15
+ end
16
+ end
17
+ end
@@ -0,0 +1,86 @@
1
+ # akoya
2
+ #
3
+ # This file was automatically generated by APIMATIC v3.0 (
4
+ # https://www.apimatic.io ).
5
+
6
+ module Akoya
7
+ # Account Model.
8
+ class Account < BaseModel
9
+ SKIP = Object.new
10
+ private_constant :SKIP
11
+
12
+ # Account ID of the related account
13
+ # @return [String]
14
+ attr_accessor :account_id
15
+
16
+ # Types of relationships between accounts and holders. Suggested values
17
+ # @return [AccountHolderRelationship]
18
+ attr_accessor :relationship
19
+
20
+ # A mapping from model property names to API property names.
21
+ def self.names
22
+ @_hash = {} if @_hash.nil?
23
+ @_hash['account_id'] = 'accountId'
24
+ @_hash['relationship'] = 'relationship'
25
+ @_hash
26
+ end
27
+
28
+ # An array for optional fields
29
+ def self.optionals
30
+ %w[
31
+ account_id
32
+ relationship
33
+ ]
34
+ end
35
+
36
+ # An array for nullable fields
37
+ def self.nullables
38
+ []
39
+ end
40
+
41
+ def initialize(account_id: SKIP, relationship: SKIP,
42
+ additional_properties: nil)
43
+ # Add additional model properties to the instance
44
+ additional_properties = {} if additional_properties.nil?
45
+
46
+ @account_id = account_id unless account_id == SKIP
47
+ @relationship = relationship unless relationship == SKIP
48
+ @additional_properties = additional_properties
49
+ end
50
+
51
+ # Creates an instance of the object from a hash.
52
+ def self.from_hash(hash)
53
+ return nil unless hash
54
+
55
+ # Extract variables from the hash.
56
+ account_id = hash.key?('accountId') ? hash['accountId'] : SKIP
57
+ relationship = hash.key?('relationship') ? hash['relationship'] : SKIP
58
+
59
+ # Create a new hash for additional properties, removing known properties.
60
+ new_hash = hash.reject { |k, _| names.value?(k) }
61
+
62
+ additional_properties = APIHelper.get_additional_properties(
63
+ new_hash, proc { |value| value }
64
+ )
65
+
66
+ # Create object from extracted values.
67
+ Account.new(account_id: account_id,
68
+ relationship: relationship,
69
+ additional_properties: additional_properties)
70
+ end
71
+
72
+ # Provides a human-readable string representation of the object.
73
+ def to_s
74
+ class_name = self.class.name.split('::').last
75
+ "<#{class_name} account_id: #{@account_id}, relationship: #{@relationship},"\
76
+ " additional_properties: #{@additional_properties}>"
77
+ end
78
+
79
+ # Provides a debugging-friendly string with detailed object information.
80
+ def inspect
81
+ class_name = self.class.name.split('::').last
82
+ "<#{class_name} account_id: #{@account_id.inspect}, relationship: #{@relationship.inspect},"\
83
+ " additional_properties: #{@additional_properties}>"
84
+ end
85
+ end
86
+ end
@@ -0,0 +1,50 @@
1
+ # akoya
2
+ #
3
+ # This file was automatically generated by APIMATIC v3.0 (
4
+ # https://www.apimatic.io ).
5
+
6
+ module Akoya
7
+ # The account category of the insurance account. Possible enums:
8
+ # DEPOSIT_ACCOUNT, INVESTMENT_ACCOUNT, LOAN_ACCOUNT, LOC_ACCOUNT,
9
+ # INSURANCE_ACCOUNT
10
+ class AccountCategory
11
+ ACCOUNT_CATEGORY = [
12
+ # TODO: Write general description for DEPOSIT_ACCOUNT
13
+ DEPOSIT_ACCOUNT = 'DEPOSIT_ACCOUNT'.freeze,
14
+
15
+ # TODO: Write general description for INVESTMENT_ACCOUNT
16
+ INVESTMENT_ACCOUNT = 'INVESTMENT_ACCOUNT'.freeze,
17
+
18
+ # TODO: Write general description for LOAN_ACCOUNT
19
+ LOAN_ACCOUNT = 'LOAN_ACCOUNT'.freeze,
20
+
21
+ # TODO: Write general description for LOC_ACCOUNT
22
+ LOC_ACCOUNT = 'LOC_ACCOUNT'.freeze,
23
+
24
+ # TODO: Write general description for INSURANCE_ACCOUNT
25
+ INSURANCE_ACCOUNT = 'INSURANCE_ACCOUNT'.freeze
26
+ ].freeze
27
+
28
+ def self.validate(value)
29
+ return false if value.nil?
30
+
31
+ true
32
+ end
33
+
34
+ def self.from_value(value, default_value = DEPOSIT_ACCOUNT)
35
+ return default_value if value.nil?
36
+
37
+ str = value.to_s.strip
38
+
39
+ case str.downcase
40
+ when 'deposit_account' then DEPOSIT_ACCOUNT
41
+ when 'investment_account' then INVESTMENT_ACCOUNT
42
+ when 'loan_account' then LOAN_ACCOUNT
43
+ when 'loc_account' then LOC_ACCOUNT
44
+ when 'insurance_account' then INSURANCE_ACCOUNT
45
+ else
46
+ default_value
47
+ end
48
+ end
49
+ end
50
+ end
@@ -0,0 +1,132 @@
1
+ # akoya
2
+ #
3
+ # This file was automatically generated by APIMATIC v3.0 (
4
+ # https://www.apimatic.io ).
5
+
6
+ module Akoya
7
+ # Contact information for the account
8
+ class AccountContactEntity < BaseModel
9
+ SKIP = Object.new
10
+ private_constant :SKIP
11
+
12
+ # Owners of the account
13
+ # @return [Array[AccountHolderEntity]]
14
+ attr_accessor :holders
15
+
16
+ # Email addresses associated with the account
17
+ # @return [Array[String]]
18
+ attr_accessor :emails
19
+
20
+ # Physical mail addresses associated with the account
21
+ # @return [Array[DeliveryAddress]]
22
+ attr_accessor :addresses
23
+
24
+ # Telephone numbers associated with the account
25
+ # @return [Array[TelephoneNumber]]
26
+ attr_accessor :telephones
27
+
28
+ # A mapping from model property names to API property names.
29
+ def self.names
30
+ @_hash = {} if @_hash.nil?
31
+ @_hash['holders'] = 'holders'
32
+ @_hash['emails'] = 'emails'
33
+ @_hash['addresses'] = 'addresses'
34
+ @_hash['telephones'] = 'telephones'
35
+ @_hash
36
+ end
37
+
38
+ # An array for optional fields
39
+ def self.optionals
40
+ %w[
41
+ holders
42
+ emails
43
+ addresses
44
+ telephones
45
+ ]
46
+ end
47
+
48
+ # An array for nullable fields
49
+ def self.nullables
50
+ []
51
+ end
52
+
53
+ def initialize(holders: SKIP, emails: SKIP, addresses: SKIP,
54
+ telephones: SKIP, additional_properties: nil)
55
+ # Add additional model properties to the instance
56
+ additional_properties = {} if additional_properties.nil?
57
+
58
+ @holders = holders unless holders == SKIP
59
+ @emails = emails unless emails == SKIP
60
+ @addresses = addresses unless addresses == SKIP
61
+ @telephones = telephones unless telephones == SKIP
62
+ @additional_properties = additional_properties
63
+ end
64
+
65
+ # Creates an instance of the object from a hash.
66
+ def self.from_hash(hash)
67
+ return nil unless hash
68
+
69
+ # Extract variables from the hash.
70
+ # Parameter is an array, so we need to iterate through it
71
+ holders = nil
72
+ unless hash['holders'].nil?
73
+ holders = []
74
+ hash['holders'].each do |structure|
75
+ holders << (AccountHolderEntity.from_hash(structure) if structure)
76
+ end
77
+ end
78
+
79
+ holders = SKIP unless hash.key?('holders')
80
+ emails = hash.key?('emails') ? hash['emails'] : SKIP
81
+ # Parameter is an array, so we need to iterate through it
82
+ addresses = nil
83
+ unless hash['addresses'].nil?
84
+ addresses = []
85
+ hash['addresses'].each do |structure|
86
+ addresses << (DeliveryAddress.from_hash(structure) if structure)
87
+ end
88
+ end
89
+
90
+ addresses = SKIP unless hash.key?('addresses')
91
+ # Parameter is an array, so we need to iterate through it
92
+ telephones = nil
93
+ unless hash['telephones'].nil?
94
+ telephones = []
95
+ hash['telephones'].each do |structure|
96
+ telephones << (TelephoneNumber.from_hash(structure) if structure)
97
+ end
98
+ end
99
+
100
+ telephones = SKIP unless hash.key?('telephones')
101
+
102
+ # Create a new hash for additional properties, removing known properties.
103
+ new_hash = hash.reject { |k, _| names.value?(k) }
104
+
105
+ additional_properties = APIHelper.get_additional_properties(
106
+ new_hash, proc { |value| value }
107
+ )
108
+
109
+ # Create object from extracted values.
110
+ AccountContactEntity.new(holders: holders,
111
+ emails: emails,
112
+ addresses: addresses,
113
+ telephones: telephones,
114
+ additional_properties: additional_properties)
115
+ end
116
+
117
+ # Provides a human-readable string representation of the object.
118
+ def to_s
119
+ class_name = self.class.name.split('::').last
120
+ "<#{class_name} holders: #{@holders}, emails: #{@emails}, addresses: #{@addresses},"\
121
+ " telephones: #{@telephones}, additional_properties: #{@additional_properties}>"
122
+ end
123
+
124
+ # Provides a debugging-friendly string with detailed object information.
125
+ def inspect
126
+ class_name = self.class.name.split('::').last
127
+ "<#{class_name} holders: #{@holders.inspect}, emails: #{@emails.inspect}, addresses:"\
128
+ " #{@addresses.inspect}, telephones: #{@telephones.inspect}, additional_properties:"\
129
+ " #{@additional_properties}>"
130
+ end
131
+ end
132
+ end
@@ -0,0 +1,178 @@
1
+ # akoya
2
+ #
3
+ # This file was automatically generated by APIMATIC v3.0 (
4
+ # https://www.apimatic.io ).
5
+
6
+ module Akoya
7
+ # Extends `Customer` and adds a `relationship` field to define the customer's
8
+ # relationship with an account
9
+ class AccountHolderEntity < BaseModel
10
+ SKIP = Object.new
11
+ private_constant :SKIP
12
+
13
+ # Long-term persistent identity of the end-user. This identity must be
14
+ # unique to the owning institution
15
+ # @return [String]
16
+ attr_accessor :customer_id
17
+
18
+ # The end-user's name
19
+ # @return [CustomerNameAccountHolderEntity]
20
+ attr_accessor :name
21
+
22
+ # The business customer information, only used if 'type' is 'BUSINESS'.
23
+ # @return [BusinessCustomerEntityAccountHolderEntity]
24
+ attr_accessor :business_customer
25
+
26
+ # An array of the customer's physical mail addresses
27
+ # @return [Array[DeliveryAddress]]
28
+ attr_accessor :addresses
29
+
30
+ # An array of the customer's physical mail addresses
31
+ # @return [Array[Telephone]]
32
+ attr_accessor :telephones
33
+
34
+ # An array of the end-user's electronic mail addresses
35
+ # @return [Array[String]]
36
+ attr_accessor :email
37
+
38
+ # List of accounts related to this end-user
39
+ # @return [Array[Account]]
40
+ attr_accessor :accounts
41
+
42
+ # Customer's relationship to the account
43
+ # @return [AccountHolderRelationshipAccountHolderEntity]
44
+ attr_accessor :relationship
45
+
46
+ # A mapping from model property names to API property names.
47
+ def self.names
48
+ @_hash = {} if @_hash.nil?
49
+ @_hash['customer_id'] = 'customerId'
50
+ @_hash['name'] = 'name'
51
+ @_hash['business_customer'] = 'businessCustomer'
52
+ @_hash['addresses'] = 'addresses'
53
+ @_hash['telephones'] = 'telephones'
54
+ @_hash['email'] = 'email'
55
+ @_hash['accounts'] = 'accounts'
56
+ @_hash['relationship'] = 'relationship'
57
+ @_hash
58
+ end
59
+
60
+ # An array for optional fields
61
+ def self.optionals
62
+ %w[
63
+ customer_id
64
+ name
65
+ business_customer
66
+ addresses
67
+ telephones
68
+ email
69
+ accounts
70
+ relationship
71
+ ]
72
+ end
73
+
74
+ # An array for nullable fields
75
+ def self.nullables
76
+ []
77
+ end
78
+
79
+ def initialize(customer_id: SKIP, name: SKIP, business_customer: SKIP,
80
+ addresses: SKIP, telephones: SKIP, email: SKIP,
81
+ accounts: SKIP, relationship: SKIP,
82
+ additional_properties: nil)
83
+ # Add additional model properties to the instance
84
+ additional_properties = {} if additional_properties.nil?
85
+
86
+ @customer_id = customer_id unless customer_id == SKIP
87
+ @name = name unless name == SKIP
88
+ @business_customer = business_customer unless business_customer == SKIP
89
+ @addresses = addresses unless addresses == SKIP
90
+ @telephones = telephones unless telephones == SKIP
91
+ @email = email unless email == SKIP
92
+ @accounts = accounts unless accounts == SKIP
93
+ @relationship = relationship unless relationship == SKIP
94
+ @additional_properties = additional_properties
95
+ end
96
+
97
+ # Creates an instance of the object from a hash.
98
+ def self.from_hash(hash)
99
+ return nil unless hash
100
+
101
+ # Extract variables from the hash.
102
+ customer_id = hash.key?('customerId') ? hash['customerId'] : SKIP
103
+ name = CustomerNameAccountHolderEntity.from_hash(hash['name']) if hash['name']
104
+ if hash['businessCustomer']
105
+ business_customer = BusinessCustomerEntityAccountHolderEntity.from_hash(hash['businessCustomer'])
106
+ end
107
+ # Parameter is an array, so we need to iterate through it
108
+ addresses = nil
109
+ unless hash['addresses'].nil?
110
+ addresses = []
111
+ hash['addresses'].each do |structure|
112
+ addresses << (DeliveryAddress.from_hash(structure) if structure)
113
+ end
114
+ end
115
+
116
+ addresses = SKIP unless hash.key?('addresses')
117
+ # Parameter is an array, so we need to iterate through it
118
+ telephones = nil
119
+ unless hash['telephones'].nil?
120
+ telephones = []
121
+ hash['telephones'].each do |structure|
122
+ telephones << (Telephone.from_hash(structure) if structure)
123
+ end
124
+ end
125
+
126
+ telephones = SKIP unless hash.key?('telephones')
127
+ email = hash.key?('email') ? hash['email'] : SKIP
128
+ # Parameter is an array, so we need to iterate through it
129
+ accounts = nil
130
+ unless hash['accounts'].nil?
131
+ accounts = []
132
+ hash['accounts'].each do |structure|
133
+ accounts << (Account.from_hash(structure) if structure)
134
+ end
135
+ end
136
+
137
+ accounts = SKIP unless hash.key?('accounts')
138
+ relationship = hash.key?('relationship') ? hash['relationship'] : SKIP
139
+
140
+ # Create a new hash for additional properties, removing known properties.
141
+ new_hash = hash.reject { |k, _| names.value?(k) }
142
+
143
+ additional_properties = APIHelper.get_additional_properties(
144
+ new_hash, proc { |value| value }
145
+ )
146
+
147
+ # Create object from extracted values.
148
+ AccountHolderEntity.new(customer_id: customer_id,
149
+ name: name,
150
+ business_customer: business_customer,
151
+ addresses: addresses,
152
+ telephones: telephones,
153
+ email: email,
154
+ accounts: accounts,
155
+ relationship: relationship,
156
+ additional_properties: additional_properties)
157
+ end
158
+
159
+ # Provides a human-readable string representation of the object.
160
+ def to_s
161
+ class_name = self.class.name.split('::').last
162
+ "<#{class_name} customer_id: #{@customer_id}, name: #{@name}, business_customer:"\
163
+ " #{@business_customer}, addresses: #{@addresses}, telephones: #{@telephones}, email:"\
164
+ " #{@email}, accounts: #{@accounts}, relationship: #{@relationship}, additional_properties:"\
165
+ " #{@additional_properties}>"
166
+ end
167
+
168
+ # Provides a debugging-friendly string with detailed object information.
169
+ def inspect
170
+ class_name = self.class.name.split('::').last
171
+ "<#{class_name} customer_id: #{@customer_id.inspect}, name: #{@name.inspect},"\
172
+ " business_customer: #{@business_customer.inspect}, addresses: #{@addresses.inspect},"\
173
+ " telephones: #{@telephones.inspect}, email: #{@email.inspect}, accounts:"\
174
+ " #{@accounts.inspect}, relationship: #{@relationship.inspect}, additional_properties:"\
175
+ " #{@additional_properties}>"
176
+ end
177
+ end
178
+ end