data-and-reporting-sdk 1.0.0

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 (178) hide show
  1. checksums.yaml +7 -0
  2. data/LICENSE +28 -0
  3. data/README.md +104 -0
  4. data/lib/shell_data_reporting_ap_is/api_helper.rb +10 -0
  5. data/lib/shell_data_reporting_ap_is/client.rb +84 -0
  6. data/lib/shell_data_reporting_ap_is/configuration.rb +110 -0
  7. data/lib/shell_data_reporting_ap_is/controllers/base_controller.rb +66 -0
  8. data/lib/shell_data_reporting_ap_is/controllers/customer_controller.rb +478 -0
  9. data/lib/shell_data_reporting_ap_is/controllers/invoice_controller.rb +470 -0
  10. data/lib/shell_data_reporting_ap_is/controllers/o_auth_authorization_controller.rb +42 -0
  11. data/lib/shell_data_reporting_ap_is/controllers/transaction_controller.rb +878 -0
  12. data/lib/shell_data_reporting_ap_is/exceptions/api_exception.rb +10 -0
  13. data/lib/shell_data_reporting_ap_is/exceptions/default_error_exception.rb +32 -0
  14. data/lib/shell_data_reporting_ap_is/exceptions/error_object_exception.rb +54 -0
  15. data/lib/shell_data_reporting_ap_is/exceptions/error_user_access_error1_exception.rb +32 -0
  16. data/lib/shell_data_reporting_ap_is/exceptions/o_auth_provider_exception.rb +48 -0
  17. data/lib/shell_data_reporting_ap_is/http/auth/basic_auth.rb +50 -0
  18. data/lib/shell_data_reporting_ap_is/http/auth/bearer_token.rb +89 -0
  19. data/lib/shell_data_reporting_ap_is/http/http_call_back.rb +10 -0
  20. data/lib/shell_data_reporting_ap_is/http/http_method_enum.rb +10 -0
  21. data/lib/shell_data_reporting_ap_is/http/http_request.rb +10 -0
  22. data/lib/shell_data_reporting_ap_is/http/http_response.rb +10 -0
  23. data/lib/shell_data_reporting_ap_is/models/account_access.rb +128 -0
  24. data/lib/shell_data_reporting_ap_is/models/account_request.rb +252 -0
  25. data/lib/shell_data_reporting_ap_is/models/account_response.rb +111 -0
  26. data/lib/shell_data_reporting_ap_is/models/account_response_accounts_items.rb +750 -0
  27. data/lib/shell_data_reporting_ap_is/models/accounts.rb +65 -0
  28. data/lib/shell_data_reporting_ap_is/models/address.rb +174 -0
  29. data/lib/shell_data_reporting_ap_is/models/associated_account.rb +98 -0
  30. data/lib/shell_data_reporting_ap_is/models/audit_request.rb +256 -0
  31. data/lib/shell_data_reporting_ap_is/models/audit_response.rb +111 -0
  32. data/lib/shell_data_reporting_ap_is/models/audit_response_audits_items.rb +450 -0
  33. data/lib/shell_data_reporting_ap_is/models/bank_account.rb +192 -0
  34. data/lib/shell_data_reporting_ap_is/models/base_model.rb +62 -0
  35. data/lib/shell_data_reporting_ap_is/models/bonus_configuration.rb +419 -0
  36. data/lib/shell_data_reporting_ap_is/models/bonus_history.rb +444 -0
  37. data/lib/shell_data_reporting_ap_is/models/card_day_time_restrictions.rb +159 -0
  38. data/lib/shell_data_reporting_ap_is/models/card_exceptions.rb +268 -0
  39. data/lib/shell_data_reporting_ap_is/models/card_group_request.rb +178 -0
  40. data/lib/shell_data_reporting_ap_is/models/card_group_response.rb +109 -0
  41. data/lib/shell_data_reporting_ap_is/models/card_group_response_card_groups_items.rb +301 -0
  42. data/lib/shell_data_reporting_ap_is/models/card_type_request.rb +145 -0
  43. data/lib/shell_data_reporting_ap_is/models/card_type_response.rb +79 -0
  44. data/lib/shell_data_reporting_ap_is/models/card_type_response_customer_card_types_items.rb +470 -0
  45. data/lib/shell_data_reporting_ap_is/models/card_type_response_error.rb +60 -0
  46. data/lib/shell_data_reporting_ap_is/models/card_usage_restrictions.rb +281 -0
  47. data/lib/shell_data_reporting_ap_is/models/card_usage_summary_request.rb +159 -0
  48. data/lib/shell_data_reporting_ap_is/models/card_usage_summary_response.rb +79 -0
  49. data/lib/shell_data_reporting_ap_is/models/col_co_access.rb +88 -0
  50. data/lib/shell_data_reporting_ap_is/models/current_volume.rb +99 -0
  51. data/lib/shell_data_reporting_ap_is/models/customer_contract.rb +63 -0
  52. data/lib/shell_data_reporting_ap_is/models/customer_detail_request.rb +123 -0
  53. data/lib/shell_data_reporting_ap_is/models/customer_detail_response.rb +437 -0
  54. data/lib/shell_data_reporting_ap_is/models/customer_price_list_request.rb +200 -0
  55. data/lib/shell_data_reporting_ap_is/models/customer_price_list_response.rb +82 -0
  56. data/lib/shell_data_reporting_ap_is/models/default_error_fault.rb +60 -0
  57. data/lib/shell_data_reporting_ap_is/models/default_error_fault_detail.rb +50 -0
  58. data/lib/shell_data_reporting_ap_is/models/delivery_addresses.rb +258 -0
  59. data/lib/shell_data_reporting_ap_is/models/eid_access.rb +75 -0
  60. data/lib/shell_data_reporting_ap_is/models/eid_document.rb +166 -0
  61. data/lib/shell_data_reporting_ap_is/models/eid_document_response.rb +140 -0
  62. data/lib/shell_data_reporting_ap_is/models/eid_download_req.rb +86 -0
  63. data/lib/shell_data_reporting_ap_is/models/eid_download_request.rb +50 -0
  64. data/lib/shell_data_reporting_ap_is/models/eid_search_req.rb +160 -0
  65. data/lib/shell_data_reporting_ap_is/models/eid_search_request.rb +70 -0
  66. data/lib/shell_data_reporting_ap_is/models/error_details.rb +81 -0
  67. data/lib/shell_data_reporting_ap_is/models/error_status.rb +60 -0
  68. data/lib/shell_data_reporting_ap_is/models/error_user_access.rb +50 -0
  69. data/lib/shell_data_reporting_ap_is/models/error_user_access_error.rb +60 -0
  70. data/lib/shell_data_reporting_ap_is/models/exception_product.rb +65 -0
  71. data/lib/shell_data_reporting_ap_is/models/exception_site_location.rb +63 -0
  72. data/lib/shell_data_reporting_ap_is/models/fee_item.rb +977 -0
  73. data/lib/shell_data_reporting_ap_is/models/fee_item_summary_all_of0.rb +194 -0
  74. data/lib/shell_data_reporting_ap_is/models/fee_rule_location.rb +153 -0
  75. data/lib/shell_data_reporting_ap_is/models/fee_rule_product.rb +98 -0
  76. data/lib/shell_data_reporting_ap_is/models/fee_rule_tier.rb +74 -0
  77. data/lib/shell_data_reporting_ap_is/models/fee_summary_response.rb +85 -0
  78. data/lib/shell_data_reporting_ap_is/models/fees_fee_rule_tiers.rb +124 -0
  79. data/lib/shell_data_reporting_ap_is/models/finance_currency.rb +98 -0
  80. data/lib/shell_data_reporting_ap_is/models/fuel_consumption_card.rb +73 -0
  81. data/lib/shell_data_reporting_ap_is/models/fuel_consumption_data.rb +267 -0
  82. data/lib/shell_data_reporting_ap_is/models/fuel_consumption_request.rb +197 -0
  83. data/lib/shell_data_reporting_ap_is/models/fuel_consumption_response.rb +79 -0
  84. data/lib/shell_data_reporting_ap_is/models/invoice_dates_data.rb +62 -0
  85. data/lib/shell_data_reporting_ap_is/models/invoice_dates_request.rb +50 -0
  86. data/lib/shell_data_reporting_ap_is/models/invoice_dates_request_filters.rb +146 -0
  87. data/lib/shell_data_reporting_ap_is/models/invoice_dates_response_data.rb +80 -0
  88. data/lib/shell_data_reporting_ap_is/models/invoice_distribution_method.rb +99 -0
  89. data/lib/shell_data_reporting_ap_is/models/invoice_download_req.rb +99 -0
  90. data/lib/shell_data_reporting_ap_is/models/invoice_download_request.rb +50 -0
  91. data/lib/shell_data_reporting_ap_is/models/invoice_search_additional_document.rb +80 -0
  92. data/lib/shell_data_reporting_ap_is/models/invoice_search_details.rb +913 -0
  93. data/lib/shell_data_reporting_ap_is/models/invoice_search_request.rb +91 -0
  94. data/lib/shell_data_reporting_ap_is/models/invoice_search_request_filters.rb +344 -0
  95. data/lib/shell_data_reporting_ap_is/models/invoice_search_response.rb +127 -0
  96. data/lib/shell_data_reporting_ap_is/models/invoice_summary_details.rb +129 -0
  97. data/lib/shell_data_reporting_ap_is/models/invoice_summary_request.rb +50 -0
  98. data/lib/shell_data_reporting_ap_is/models/invoice_summary_request_filters.rb +345 -0
  99. data/lib/shell_data_reporting_ap_is/models/invoice_summary_response.rb +79 -0
  100. data/lib/shell_data_reporting_ap_is/models/invoices_summaries.rb +221 -0
  101. data/lib/shell_data_reporting_ap_is/models/last_statement_of_account.rb +421 -0
  102. data/lib/shell_data_reporting_ap_is/models/logged_in_user_request.rb +107 -0
  103. data/lib/shell_data_reporting_ap_is/models/logged_in_user_response.rb +394 -0
  104. data/lib/shell_data_reporting_ap_is/models/monthly_invoice_trend.rb +112 -0
  105. data/lib/shell_data_reporting_ap_is/models/multi_priced_transaction_request.rb +360 -0
  106. data/lib/shell_data_reporting_ap_is/models/multi_priced_transaction_request_accounts_items.rb +84 -0
  107. data/lib/shell_data_reporting_ap_is/models/multi_priced_transaction_response.rb +110 -0
  108. data/lib/shell_data_reporting_ap_is/models/multi_priced_transaction_response_transactions_items.rb +1724 -0
  109. data/lib/shell_data_reporting_ap_is/models/o_auth_provider_error_enum.rb +45 -0
  110. data/lib/shell_data_reporting_ap_is/models/o_auth_token.rb +100 -0
  111. data/lib/shell_data_reporting_ap_is/models/past_statement_of_accounts.rb +502 -0
  112. data/lib/shell_data_reporting_ap_is/models/payer_access.rb +147 -0
  113. data/lib/shell_data_reporting_ap_is/models/payer_details.rb +1412 -0
  114. data/lib/shell_data_reporting_ap_is/models/payer_request.rb +126 -0
  115. data/lib/shell_data_reporting_ap_is/models/payer_response.rb +115 -0
  116. data/lib/shell_data_reporting_ap_is/models/payers.rb +109 -0
  117. data/lib/shell_data_reporting_ap_is/models/payments_since_last_soa.rb +322 -0
  118. data/lib/shell_data_reporting_ap_is/models/pin_advice_types.rb +80 -0
  119. data/lib/shell_data_reporting_ap_is/models/price_list.rb +485 -0
  120. data/lib/shell_data_reporting_ap_is/models/price_trans_summary_request.rb +477 -0
  121. data/lib/shell_data_reporting_ap_is/models/price_transaction_request.rb +572 -0
  122. data/lib/shell_data_reporting_ap_is/models/priced_request_data.rb +485 -0
  123. data/lib/shell_data_reporting_ap_is/models/priced_response_data.rb +2132 -0
  124. data/lib/shell_data_reporting_ap_is/models/priced_trans_summary_response.rb +79 -0
  125. data/lib/shell_data_reporting_ap_is/models/priced_trans_summary_response_transactions_summary_items.rb +242 -0
  126. data/lib/shell_data_reporting_ap_is/models/priced_transaction_items_location_items.rb +67 -0
  127. data/lib/shell_data_reporting_ap_is/models/priced_transaction_req_v2_invoice_status_enum.rb +27 -0
  128. data/lib/shell_data_reporting_ap_is/models/priced_transaction_req_v2_period_enum.rb +27 -0
  129. data/lib/shell_data_reporting_ap_is/models/priced_transaction_req_v2_sort_order_enum.rb +37 -0
  130. data/lib/shell_data_reporting_ap_is/models/priced_transaction_request_v2.rb +72 -0
  131. data/lib/shell_data_reporting_ap_is/models/priced_transaction_resp_v2_refund_flag_enum.rb +23 -0
  132. data/lib/shell_data_reporting_ap_is/models/priced_transaction_response.rb +59 -0
  133. data/lib/shell_data_reporting_ap_is/models/priced_transaction_response_transactions_items.rb +1719 -0
  134. data/lib/shell_data_reporting_ap_is/models/priced_transaction_response_v2.rb +110 -0
  135. data/lib/shell_data_reporting_ap_is/models/pricing_current_volume.rb +115 -0
  136. data/lib/shell_data_reporting_ap_is/models/pricing_history.rb +105 -0
  137. data/lib/shell_data_reporting_ap_is/models/purchase_categories.rb +114 -0
  138. data/lib/shell_data_reporting_ap_is/models/recent_transaction_req.rb +217 -0
  139. data/lib/shell_data_reporting_ap_is/models/recent_transaction_request.rb +66 -0
  140. data/lib/shell_data_reporting_ap_is/models/recent_transactions.rb +918 -0
  141. data/lib/shell_data_reporting_ap_is/models/recent_transactions_response.rb +110 -0
  142. data/lib/shell_data_reporting_ap_is/models/role.rb +102 -0
  143. data/lib/shell_data_reporting_ap_is/models/search_doc_req.rb +269 -0
  144. data/lib/shell_data_reporting_ap_is/models/search_documents_invoice.rb +204 -0
  145. data/lib/shell_data_reporting_ap_is/models/search_documents_request.rb +70 -0
  146. data/lib/shell_data_reporting_ap_is/models/search_documents_response.rb +122 -0
  147. data/lib/shell_data_reporting_ap_is/models/search_soa_req.rb +197 -0
  148. data/lib/shell_data_reporting_ap_is/models/search_statement_of_account.rb +220 -0
  149. data/lib/shell_data_reporting_ap_is/models/search_statement_of_account_request.rb +70 -0
  150. data/lib/shell_data_reporting_ap_is/models/search_statement_of_account_response.rb +120 -0
  151. data/lib/shell_data_reporting_ap_is/models/site_location.rb +67 -0
  152. data/lib/shell_data_reporting_ap_is/models/statement_of_account_request.rb +50 -0
  153. data/lib/shell_data_reporting_ap_is/models/statement_of_account_request_filters.rb +197 -0
  154. data/lib/shell_data_reporting_ap_is/models/statement_of_account_resp.rb +138 -0
  155. data/lib/shell_data_reporting_ap_is/models/statement_of_account_response.rb +80 -0
  156. data/lib/shell_data_reporting_ap_is/models/tier.rb +167 -0
  157. data/lib/shell_data_reporting_ap_is/models/transaction_exceptions.rb +1267 -0
  158. data/lib/shell_data_reporting_ap_is/models/transaction_exceptions_request.rb +267 -0
  159. data/lib/shell_data_reporting_ap_is/models/transaction_exceptions_response.rb +100 -0
  160. data/lib/shell_data_reporting_ap_is/models/transaction_fees_request.rb +348 -0
  161. data/lib/shell_data_reporting_ap_is/models/transaction_fees_response.rb +111 -0
  162. data/lib/shell_data_reporting_ap_is/models/update_odometer.rb +62 -0
  163. data/lib/shell_data_reporting_ap_is/models/update_odometer_reference.rb +67 -0
  164. data/lib/shell_data_reporting_ap_is/models/update_odometer_request.rb +146 -0
  165. data/lib/shell_data_reporting_ap_is/models/update_odometer_response.rb +93 -0
  166. data/lib/shell_data_reporting_ap_is/models/usage_summary.rb +202 -0
  167. data/lib/shell_data_reporting_ap_is/models/volume_based_bonus_request.rb +118 -0
  168. data/lib/shell_data_reporting_ap_is/models/volume_based_bonus_response.rb +120 -0
  169. data/lib/shell_data_reporting_ap_is/models/volume_based_pricing_request.rb +103 -0
  170. data/lib/shell_data_reporting_ap_is/models/volume_based_pricing_response.rb +120 -0
  171. data/lib/shell_data_reporting_ap_is/utilities/date_time_helper.rb +11 -0
  172. data/lib/shell_data_reporting_ap_is/utilities/file_wrapper.rb +16 -0
  173. data/lib/shell_data_reporting_ap_is.rb +229 -0
  174. data/test/controllers/controller_test_base.rb +34 -0
  175. data/test/controllers/test_invoice_controller.rb +398 -0
  176. data/test/controllers/test_transaction_controller.rb +235 -0
  177. data/test/http_response_catcher.rb +19 -0
  178. metadata +302 -0
@@ -0,0 +1,394 @@
1
+ # shell_data_reporting_ap_is
2
+ #
3
+ # This file was automatically generated by APIMATIC v2.0
4
+ # ( https://apimatic.io ).
5
+
6
+ module ShellDataReportingApIs
7
+ # LoggedInUserResponse Model.
8
+ class LoggedInUserResponse < BaseModel
9
+ SKIP = Object.new
10
+ private_constant :SKIP
11
+
12
+ # Logged in User Identifier
13
+ # @return [String]
14
+ attr_accessor :user_name
15
+
16
+ # Name of the logged in user.
17
+ # @return [String]
18
+ attr_accessor :display_name
19
+
20
+ # Single Sign On/Unique Identifier of the User in Identity Management system
21
+ # @return [String]
22
+ attr_accessor :id_mssoid
23
+
24
+ # ISO culture code/ Language chosen by the logged in user
25
+ # @return [String]
26
+ attr_accessor :preferred_language
27
+
28
+ # Whether the user is a super administrator
29
+ # @return [TrueClass | FalseClass]
30
+ attr_accessor :is_super_admin
31
+
32
+ # Preferred Date format for the logged in user
33
+ # @return [String]
34
+ attr_accessor :date_format
35
+
36
+ # Preferred Time format for the logged in user
37
+ # @return [String]
38
+ attr_accessor :time_format
39
+
40
+ # Preferred Day to Begin the Week. The value will be between 1 to 7 or null.
41
+ # @return [Integer]
42
+ attr_accessor :week_begins
43
+
44
+ # Preferred Display Week on Fuel Prices configuration for the logged in
45
+ # User.
46
+ # @return [TrueClass | FalseClass]
47
+ attr_accessor :display_week
48
+
49
+ # Preferred CSV Separator for the logged in user.
50
+ # @return [String]
51
+ attr_accessor :csv_separator
52
+
53
+ # Preferred Decimal separator configured for the logged in user
54
+ # Note: - Colco default value (configured at Microservices) is returned when
55
+ # the user is not provided or does not exist.
56
+ # @return [String]
57
+ attr_accessor :decimal_separator
58
+
59
+ # Preferred report format configured for the logged in user
60
+ # @return [String]
61
+ attr_accessor :report_format
62
+
63
+ # True/False
64
+ # True, if user has access to the requested API. This is validated based on
65
+ # the role Vs API access matrix and client Vs API access matrix.
66
+ # @return [TrueClass | FalseClass]
67
+ attr_accessor :has_api_access
68
+
69
+ # List of roles the user have access to
70
+ # @return [Array[Role]]
71
+ attr_accessor :roles
72
+
73
+ # List of payers which the user has access to.
74
+ # • It will return 250 payers only and it is configurable. If the user has
75
+ # more than that, the remaining will be ignored.
76
+ # • The payer which is marked as default will be the first item in the
77
+ # output.
78
+ # Note: This list will be empty for users mapped with roles which has either
79
+ # IsShellAdmin or IsServiceAccount set to true as their access level is
80
+ # controlled at ColCo level only.
81
+ # @return [Array[PayerAccess]]
82
+ attr_accessor :payers
83
+
84
+ # List of accounts which the user has access to.
85
+ # Note: This list will be empty for users mapped with roles which has either
86
+ # IsCustomerAdmin, IsShellAdmin or IsServiceAccount set to true as their
87
+ # access level is controller at either ColCo or payer level only.
88
+ # @return [Array[AccountAccess]]
89
+ attr_accessor :accounts
90
+
91
+ # List of collecting companies to which the user has access to
92
+ # Note: This list will be empty for users mapped with roles which has either
93
+ # IsCustomerAdmin or IsCustomerUser set to true as their access level is
94
+ # controller at Payer or Account level.
95
+ # @return [Array[ColCoAccess]]
96
+ attr_accessor :collecting_companies
97
+
98
+ # List of Electronic Invoice Data configured for the user.
99
+ # Note: This list will be empty if the value of EIDDetails is set to false
100
+ # or empty in the request.
101
+ # @return [Array[EIDAccess]]
102
+ attr_accessor :eid_access_details
103
+
104
+ # User classification by system.
105
+ # @return [String]
106
+ attr_accessor :user_classification_by_system
107
+
108
+ # User classification by Shell.
109
+ # @return [String]
110
+ attr_accessor :user_classification_by_shell
111
+
112
+ # Count of payers accessible to the user at the time when user was created
113
+ # or last updated.
114
+ # Note:
115
+ # Count may vary based on customer operations hence it may not be an up to
116
+ # date value.
117
+ # @return [Integer]
118
+ attr_accessor :payer_count
119
+
120
+ # Count of accounts at the time when the user was created or last updated.
121
+ # Note:
122
+ # Count may vary based on customer operations hence it may not be an up to
123
+ # date value.
124
+ # @return [Integer]
125
+ attr_accessor :account_count
126
+
127
+ # Count of cards at the time when the user was created or last updated.
128
+ # Note:
129
+ # Count may vary based on customer operations hence it may not be an up to
130
+ # date value.
131
+ # @return [Integer]
132
+ attr_accessor :card_count
133
+
134
+ # Count of cards at the time when the user was created or last updated.
135
+ # Note:
136
+ # Count may vary based on customer operations hence it may not be an up to
137
+ # date value.
138
+ # @return [ErrorStatus]
139
+ attr_accessor :error
140
+
141
+ # Request Id of the API call
142
+ # @return [String]
143
+ attr_accessor :request_id
144
+
145
+ # A mapping from model property names to API property names.
146
+ def self.names
147
+ @_hash = {} if @_hash.nil?
148
+ @_hash['user_name'] = 'UserName'
149
+ @_hash['display_name'] = 'DisplayName'
150
+ @_hash['id_mssoid'] = 'IdMSSOID'
151
+ @_hash['preferred_language'] = 'PreferredLanguage'
152
+ @_hash['is_super_admin'] = 'IsSuperAdmin'
153
+ @_hash['date_format'] = 'DateFormat'
154
+ @_hash['time_format'] = 'TimeFormat'
155
+ @_hash['week_begins'] = 'WeekBegins'
156
+ @_hash['display_week'] = 'DisplayWeek'
157
+ @_hash['csv_separator'] = 'CSVSeparator'
158
+ @_hash['decimal_separator'] = 'DecimalSeparator'
159
+ @_hash['report_format'] = 'ReportFormat'
160
+ @_hash['has_api_access'] = 'HasAPIAccess'
161
+ @_hash['roles'] = 'Roles'
162
+ @_hash['payers'] = 'Payers'
163
+ @_hash['accounts'] = 'Accounts'
164
+ @_hash['collecting_companies'] = 'CollectingCompanies'
165
+ @_hash['eid_access_details'] = 'EIDAccessDetails'
166
+ @_hash['user_classification_by_system'] = 'UserClassificationBySystem'
167
+ @_hash['user_classification_by_shell'] = 'UserClassificationByShell'
168
+ @_hash['payer_count'] = 'PayerCount'
169
+ @_hash['account_count'] = 'AccountCount'
170
+ @_hash['card_count'] = 'CardCount'
171
+ @_hash['error'] = 'Error'
172
+ @_hash['request_id'] = 'RequestId'
173
+ @_hash
174
+ end
175
+
176
+ # An array for optional fields
177
+ def self.optionals
178
+ %w[
179
+ user_name
180
+ display_name
181
+ id_mssoid
182
+ preferred_language
183
+ is_super_admin
184
+ date_format
185
+ time_format
186
+ week_begins
187
+ display_week
188
+ csv_separator
189
+ decimal_separator
190
+ report_format
191
+ has_api_access
192
+ roles
193
+ payers
194
+ accounts
195
+ collecting_companies
196
+ eid_access_details
197
+ user_classification_by_system
198
+ user_classification_by_shell
199
+ payer_count
200
+ account_count
201
+ card_count
202
+ error
203
+ request_id
204
+ ]
205
+ end
206
+
207
+ # An array for nullable fields
208
+ def self.nullables
209
+ %w[
210
+ user_name
211
+ display_name
212
+ id_mssoid
213
+ preferred_language
214
+ date_format
215
+ time_format
216
+ week_begins
217
+ csv_separator
218
+ decimal_separator
219
+ report_format
220
+ user_classification_by_system
221
+ user_classification_by_shell
222
+ payer_count
223
+ account_count
224
+ card_count
225
+ ]
226
+ end
227
+
228
+ def initialize(user_name = SKIP,
229
+ display_name = SKIP,
230
+ id_mssoid = SKIP,
231
+ preferred_language = SKIP,
232
+ is_super_admin = false,
233
+ date_format = SKIP,
234
+ time_format = SKIP,
235
+ week_begins = SKIP,
236
+ display_week = true,
237
+ csv_separator = SKIP,
238
+ decimal_separator = SKIP,
239
+ report_format = SKIP,
240
+ has_api_access = true,
241
+ roles = SKIP,
242
+ payers = SKIP,
243
+ accounts = SKIP,
244
+ collecting_companies = SKIP,
245
+ eid_access_details = SKIP,
246
+ user_classification_by_system = SKIP,
247
+ user_classification_by_shell = SKIP,
248
+ payer_count = SKIP,
249
+ account_count = SKIP,
250
+ card_count = SKIP,
251
+ error = SKIP,
252
+ request_id = SKIP)
253
+ @user_name = user_name unless user_name == SKIP
254
+ @display_name = display_name unless display_name == SKIP
255
+ @id_mssoid = id_mssoid unless id_mssoid == SKIP
256
+ @preferred_language = preferred_language unless preferred_language == SKIP
257
+ @is_super_admin = is_super_admin unless is_super_admin == SKIP
258
+ @date_format = date_format unless date_format == SKIP
259
+ @time_format = time_format unless time_format == SKIP
260
+ @week_begins = week_begins unless week_begins == SKIP
261
+ @display_week = display_week unless display_week == SKIP
262
+ @csv_separator = csv_separator unless csv_separator == SKIP
263
+ @decimal_separator = decimal_separator unless decimal_separator == SKIP
264
+ @report_format = report_format unless report_format == SKIP
265
+ @has_api_access = has_api_access unless has_api_access == SKIP
266
+ @roles = roles unless roles == SKIP
267
+ @payers = payers unless payers == SKIP
268
+ @accounts = accounts unless accounts == SKIP
269
+ @collecting_companies = collecting_companies unless collecting_companies == SKIP
270
+ @eid_access_details = eid_access_details unless eid_access_details == SKIP
271
+ unless user_classification_by_system == SKIP
272
+ @user_classification_by_system =
273
+ user_classification_by_system
274
+ end
275
+ unless user_classification_by_shell == SKIP
276
+ @user_classification_by_shell =
277
+ user_classification_by_shell
278
+ end
279
+ @payer_count = payer_count unless payer_count == SKIP
280
+ @account_count = account_count unless account_count == SKIP
281
+ @card_count = card_count unless card_count == SKIP
282
+ @error = error unless error == SKIP
283
+ @request_id = request_id unless request_id == SKIP
284
+ end
285
+
286
+ # Creates an instance of the object from a hash.
287
+ def self.from_hash(hash)
288
+ return nil unless hash
289
+
290
+ # Extract variables from the hash.
291
+ user_name = hash.key?('UserName') ? hash['UserName'] : SKIP
292
+ display_name = hash.key?('DisplayName') ? hash['DisplayName'] : SKIP
293
+ id_mssoid = hash.key?('IdMSSOID') ? hash['IdMSSOID'] : SKIP
294
+ preferred_language =
295
+ hash.key?('PreferredLanguage') ? hash['PreferredLanguage'] : SKIP
296
+ is_super_admin = hash['IsSuperAdmin'] ||= false
297
+ date_format = hash.key?('DateFormat') ? hash['DateFormat'] : SKIP
298
+ time_format = hash.key?('TimeFormat') ? hash['TimeFormat'] : SKIP
299
+ week_begins = hash.key?('WeekBegins') ? hash['WeekBegins'] : SKIP
300
+ display_week = hash['DisplayWeek'] ||= true
301
+ csv_separator = hash.key?('CSVSeparator') ? hash['CSVSeparator'] : SKIP
302
+ decimal_separator =
303
+ hash.key?('DecimalSeparator') ? hash['DecimalSeparator'] : SKIP
304
+ report_format = hash.key?('ReportFormat') ? hash['ReportFormat'] : SKIP
305
+ has_api_access = hash['HasAPIAccess'] ||= true
306
+ # Parameter is an array, so we need to iterate through it
307
+ roles = nil
308
+ unless hash['Roles'].nil?
309
+ roles = []
310
+ hash['Roles'].each do |structure|
311
+ roles << (Role.from_hash(structure) if structure)
312
+ end
313
+ end
314
+
315
+ roles = SKIP unless hash.key?('Roles')
316
+ # Parameter is an array, so we need to iterate through it
317
+ payers = nil
318
+ unless hash['Payers'].nil?
319
+ payers = []
320
+ hash['Payers'].each do |structure|
321
+ payers << (PayerAccess.from_hash(structure) if structure)
322
+ end
323
+ end
324
+
325
+ payers = SKIP unless hash.key?('Payers')
326
+ # Parameter is an array, so we need to iterate through it
327
+ accounts = nil
328
+ unless hash['Accounts'].nil?
329
+ accounts = []
330
+ hash['Accounts'].each do |structure|
331
+ accounts << (AccountAccess.from_hash(structure) if structure)
332
+ end
333
+ end
334
+
335
+ accounts = SKIP unless hash.key?('Accounts')
336
+ # Parameter is an array, so we need to iterate through it
337
+ collecting_companies = nil
338
+ unless hash['CollectingCompanies'].nil?
339
+ collecting_companies = []
340
+ hash['CollectingCompanies'].each do |structure|
341
+ collecting_companies << (ColCoAccess.from_hash(structure) if structure)
342
+ end
343
+ end
344
+
345
+ collecting_companies = SKIP unless hash.key?('CollectingCompanies')
346
+ # Parameter is an array, so we need to iterate through it
347
+ eid_access_details = nil
348
+ unless hash['EIDAccessDetails'].nil?
349
+ eid_access_details = []
350
+ hash['EIDAccessDetails'].each do |structure|
351
+ eid_access_details << (EIDAccess.from_hash(structure) if structure)
352
+ end
353
+ end
354
+
355
+ eid_access_details = SKIP unless hash.key?('EIDAccessDetails')
356
+ user_classification_by_system =
357
+ hash.key?('UserClassificationBySystem') ? hash['UserClassificationBySystem'] : SKIP
358
+ user_classification_by_shell =
359
+ hash.key?('UserClassificationByShell') ? hash['UserClassificationByShell'] : SKIP
360
+ payer_count = hash.key?('PayerCount') ? hash['PayerCount'] : SKIP
361
+ account_count = hash.key?('AccountCount') ? hash['AccountCount'] : SKIP
362
+ card_count = hash.key?('CardCount') ? hash['CardCount'] : SKIP
363
+ error = ErrorStatus.from_hash(hash['Error']) if hash['Error']
364
+ request_id = hash.key?('RequestId') ? hash['RequestId'] : SKIP
365
+
366
+ # Create object from extracted values.
367
+ LoggedInUserResponse.new(user_name,
368
+ display_name,
369
+ id_mssoid,
370
+ preferred_language,
371
+ is_super_admin,
372
+ date_format,
373
+ time_format,
374
+ week_begins,
375
+ display_week,
376
+ csv_separator,
377
+ decimal_separator,
378
+ report_format,
379
+ has_api_access,
380
+ roles,
381
+ payers,
382
+ accounts,
383
+ collecting_companies,
384
+ eid_access_details,
385
+ user_classification_by_system,
386
+ user_classification_by_shell,
387
+ payer_count,
388
+ account_count,
389
+ card_count,
390
+ error,
391
+ request_id)
392
+ end
393
+ end
394
+ end
@@ -0,0 +1,112 @@
1
+ # shell_data_reporting_ap_is
2
+ #
3
+ # This file was automatically generated by APIMATIC v2.0
4
+ # ( https://apimatic.io ).
5
+
6
+ module ShellDataReportingApIs
7
+ # MonthlyInvoiceTrend Model.
8
+ class MonthlyInvoiceTrend < BaseModel
9
+ SKIP = Object.new
10
+ private_constant :SKIP
11
+
12
+ # ISO code of invoice currency.
13
+ # Example: EUR
14
+ # @return [String]
15
+ attr_accessor :currency_code
16
+
17
+ # Symbol of invoice currency.
18
+ # Example: €
19
+ # @return [String]
20
+ attr_accessor :currency_symbol
21
+
22
+ # Month.
23
+ # @return [Integer]
24
+ attr_accessor :month
25
+
26
+ # Total net amount invoiced in this month.
27
+ # @return [Float]
28
+ attr_accessor :total_net_amount
29
+
30
+ # Total VAT amount invoiced in this month.
31
+ # @return [Float]
32
+ attr_accessor :total_vat_amount
33
+
34
+ # Year.
35
+ # @return [Integer]
36
+ attr_accessor :year
37
+
38
+ # A mapping from model property names to API property names.
39
+ def self.names
40
+ @_hash = {} if @_hash.nil?
41
+ @_hash['currency_code'] = 'CurrencyCode'
42
+ @_hash['currency_symbol'] = 'CurrencySymbol'
43
+ @_hash['month'] = 'Month'
44
+ @_hash['total_net_amount'] = 'TotalNetAmount'
45
+ @_hash['total_vat_amount'] = 'TotalVATAmount'
46
+ @_hash['year'] = 'Year'
47
+ @_hash
48
+ end
49
+
50
+ # An array for optional fields
51
+ def self.optionals
52
+ %w[
53
+ currency_code
54
+ currency_symbol
55
+ month
56
+ total_net_amount
57
+ total_vat_amount
58
+ year
59
+ ]
60
+ end
61
+
62
+ # An array for nullable fields
63
+ def self.nullables
64
+ %w[
65
+ currency_code
66
+ currency_symbol
67
+ month
68
+ total_net_amount
69
+ total_vat_amount
70
+ year
71
+ ]
72
+ end
73
+
74
+ def initialize(currency_code = SKIP,
75
+ currency_symbol = SKIP,
76
+ month = SKIP,
77
+ total_net_amount = SKIP,
78
+ total_vat_amount = SKIP,
79
+ year = SKIP)
80
+ @currency_code = currency_code unless currency_code == SKIP
81
+ @currency_symbol = currency_symbol unless currency_symbol == SKIP
82
+ @month = month unless month == SKIP
83
+ @total_net_amount = total_net_amount unless total_net_amount == SKIP
84
+ @total_vat_amount = total_vat_amount unless total_vat_amount == SKIP
85
+ @year = year unless year == SKIP
86
+ end
87
+
88
+ # Creates an instance of the object from a hash.
89
+ def self.from_hash(hash)
90
+ return nil unless hash
91
+
92
+ # Extract variables from the hash.
93
+ currency_code = hash.key?('CurrencyCode') ? hash['CurrencyCode'] : SKIP
94
+ currency_symbol =
95
+ hash.key?('CurrencySymbol') ? hash['CurrencySymbol'] : SKIP
96
+ month = hash.key?('Month') ? hash['Month'] : SKIP
97
+ total_net_amount =
98
+ hash.key?('TotalNetAmount') ? hash['TotalNetAmount'] : SKIP
99
+ total_vat_amount =
100
+ hash.key?('TotalVATAmount') ? hash['TotalVATAmount'] : SKIP
101
+ year = hash.key?('Year') ? hash['Year'] : SKIP
102
+
103
+ # Create object from extracted values.
104
+ MonthlyInvoiceTrend.new(currency_code,
105
+ currency_symbol,
106
+ month,
107
+ total_net_amount,
108
+ total_vat_amount,
109
+ year)
110
+ end
111
+ end
112
+ end