data-and-reporting-sdk 1.0.0

Sign up to get free protection for your applications and to get access to all the features.
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,301 @@
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
+ # CardGroupResponseCardGroupsItems Model.
8
+ class CardGroupResponseCardGroupsItems < BaseModel
9
+ SKIP = Object.new
10
+ private_constant :SKIP
11
+
12
+ # Account Id for the associated card group
13
+ # @return [Integer]
14
+ attr_accessor :account_id
15
+
16
+ # Account number for the associated card group
17
+ # @return [String]
18
+ attr_accessor :account_number
19
+
20
+ # Account short name for the associated card group
21
+ # @return [String]
22
+ attr_accessor :account_short_name
23
+
24
+ # Total number of active cards for the given search criteria
25
+ # @return [Integer]
26
+ attr_accessor :active_cards
27
+
28
+ # Total number of cards for the given search criteria that are permanently
29
+ # blocked
30
+ # @return [Integer]
31
+ attr_accessor :blocked_cards
32
+
33
+ # Total number of cards for the given search criteria that are cancelled
34
+ # @return [Integer]
35
+ attr_accessor :cancelled_cards
36
+
37
+ # card delivery point enabled or not
38
+ # @return [TrueClass | FalseClass]
39
+ attr_accessor :card_delivery_point
40
+
41
+ # Id of the card group matching the search criteria.
42
+ # @return [Integer]
43
+ attr_accessor :card_group_id
44
+
45
+ # Name of the card group matching the search criteria.
46
+ # @return [String]
47
+ attr_accessor :card_group_name
48
+
49
+ # Card Type Code
50
+ # @return [String]
51
+ attr_accessor :card_type_code
52
+
53
+ # Card Type Id
54
+ # @return [Integer]
55
+ attr_accessor :card_type_id
56
+
57
+ # Card Type Name
58
+ # @return [String]
59
+ attr_accessor :card_type_name
60
+
61
+ # Total number of expired cards for the given search criteria
62
+ # @return [Integer]
63
+ attr_accessor :expired_cards
64
+
65
+ # Expiry date of the card.
66
+ # Format: yyyyMMdd
67
+ # Note: Clients to convert this to appropriate DateTime type.
68
+ # @return [String]
69
+ attr_accessor :expiry_date
70
+
71
+ # PrintOnCard true/false
72
+ # @return [TrueClass | FalseClass]
73
+ attr_accessor :print_on_card
74
+
75
+ # Total number of Renewal Pending Cards for the given search criteria
76
+ # @return [Integer]
77
+ attr_accessor :renewal_pending_cards
78
+
79
+ # Total number of Renewal Pending Cards for the given search criteria
80
+ # @return [Integer]
81
+ attr_accessor :replaced_cards
82
+
83
+ # Status of the card group.
84
+ # @return [String]
85
+ attr_accessor :status
86
+
87
+ # Total number of cards for the given search criteria that are temporarily
88
+ # blocked by customer
89
+ # @return [Integer]
90
+ attr_accessor :temporary_block_by_customer
91
+
92
+ # Total number of cards for the given search criteria that are temporarily
93
+ # blocked by Shell
94
+ # @return [Integer]
95
+ attr_accessor :temporary_block_by_shell
96
+
97
+ # Terminated Date.
98
+ # Format: yyyyMMdd
99
+ # Note: Clients to convert this to appropriate Date Time type.
100
+ # @return [String]
101
+ attr_accessor :terminated_date
102
+
103
+ # Total number of cards for the given search criteria
104
+ # @return [Integer]
105
+ attr_accessor :total_cards
106
+
107
+ # A mapping from model property names to API property names.
108
+ def self.names
109
+ @_hash = {} if @_hash.nil?
110
+ @_hash['account_id'] = 'AccountId'
111
+ @_hash['account_number'] = 'AccountNumber'
112
+ @_hash['account_short_name'] = 'AccountShortName'
113
+ @_hash['active_cards'] = 'ActiveCards'
114
+ @_hash['blocked_cards'] = 'BlockedCards'
115
+ @_hash['cancelled_cards'] = 'CancelledCards'
116
+ @_hash['card_delivery_point'] = 'CardDeliveryPoint'
117
+ @_hash['card_group_id'] = 'CardGroupId'
118
+ @_hash['card_group_name'] = 'CardGroupName'
119
+ @_hash['card_type_code'] = 'CardTypeCode'
120
+ @_hash['card_type_id'] = 'CardTypeId'
121
+ @_hash['card_type_name'] = 'CardTypeName'
122
+ @_hash['expired_cards'] = 'ExpiredCards'
123
+ @_hash['expiry_date'] = 'ExpiryDate'
124
+ @_hash['print_on_card'] = 'PrintOnCard'
125
+ @_hash['renewal_pending_cards'] = 'RenewalPendingCards'
126
+ @_hash['replaced_cards'] = 'ReplacedCards'
127
+ @_hash['status'] = 'Status'
128
+ @_hash['temporary_block_by_customer'] = 'TemporaryBlockByCustomer'
129
+ @_hash['temporary_block_by_shell'] = 'TemporaryBlockByShell'
130
+ @_hash['terminated_date'] = 'TerminatedDate'
131
+ @_hash['total_cards'] = 'TotalCards'
132
+ @_hash
133
+ end
134
+
135
+ # An array for optional fields
136
+ def self.optionals
137
+ %w[
138
+ account_id
139
+ account_number
140
+ account_short_name
141
+ active_cards
142
+ blocked_cards
143
+ cancelled_cards
144
+ card_delivery_point
145
+ card_group_id
146
+ card_group_name
147
+ card_type_code
148
+ card_type_id
149
+ card_type_name
150
+ expired_cards
151
+ expiry_date
152
+ print_on_card
153
+ renewal_pending_cards
154
+ replaced_cards
155
+ status
156
+ temporary_block_by_customer
157
+ temporary_block_by_shell
158
+ terminated_date
159
+ total_cards
160
+ ]
161
+ end
162
+
163
+ # An array for nullable fields
164
+ def self.nullables
165
+ %w[
166
+ account_id
167
+ account_number
168
+ account_short_name
169
+ active_cards
170
+ blocked_cards
171
+ cancelled_cards
172
+ card_delivery_point
173
+ card_group_id
174
+ card_group_name
175
+ card_type_code
176
+ card_type_id
177
+ card_type_name
178
+ expired_cards
179
+ expiry_date
180
+ print_on_card
181
+ renewal_pending_cards
182
+ replaced_cards
183
+ status
184
+ temporary_block_by_customer
185
+ temporary_block_by_shell
186
+ terminated_date
187
+ total_cards
188
+ ]
189
+ end
190
+
191
+ def initialize(account_id = SKIP,
192
+ account_number = SKIP,
193
+ account_short_name = SKIP,
194
+ active_cards = SKIP,
195
+ blocked_cards = SKIP,
196
+ cancelled_cards = SKIP,
197
+ card_delivery_point = SKIP,
198
+ card_group_id = SKIP,
199
+ card_group_name = SKIP,
200
+ card_type_code = SKIP,
201
+ card_type_id = SKIP,
202
+ card_type_name = SKIP,
203
+ expired_cards = SKIP,
204
+ expiry_date = SKIP,
205
+ print_on_card = SKIP,
206
+ renewal_pending_cards = SKIP,
207
+ replaced_cards = SKIP,
208
+ status = SKIP,
209
+ temporary_block_by_customer = SKIP,
210
+ temporary_block_by_shell = SKIP,
211
+ terminated_date = SKIP,
212
+ total_cards = SKIP)
213
+ @account_id = account_id unless account_id == SKIP
214
+ @account_number = account_number unless account_number == SKIP
215
+ @account_short_name = account_short_name unless account_short_name == SKIP
216
+ @active_cards = active_cards unless active_cards == SKIP
217
+ @blocked_cards = blocked_cards unless blocked_cards == SKIP
218
+ @cancelled_cards = cancelled_cards unless cancelled_cards == SKIP
219
+ @card_delivery_point = card_delivery_point unless card_delivery_point == SKIP
220
+ @card_group_id = card_group_id unless card_group_id == SKIP
221
+ @card_group_name = card_group_name unless card_group_name == SKIP
222
+ @card_type_code = card_type_code unless card_type_code == SKIP
223
+ @card_type_id = card_type_id unless card_type_id == SKIP
224
+ @card_type_name = card_type_name unless card_type_name == SKIP
225
+ @expired_cards = expired_cards unless expired_cards == SKIP
226
+ @expiry_date = expiry_date unless expiry_date == SKIP
227
+ @print_on_card = print_on_card unless print_on_card == SKIP
228
+ @renewal_pending_cards = renewal_pending_cards unless renewal_pending_cards == SKIP
229
+ @replaced_cards = replaced_cards unless replaced_cards == SKIP
230
+ @status = status unless status == SKIP
231
+ unless temporary_block_by_customer == SKIP
232
+ @temporary_block_by_customer =
233
+ temporary_block_by_customer
234
+ end
235
+ @temporary_block_by_shell = temporary_block_by_shell unless temporary_block_by_shell == SKIP
236
+ @terminated_date = terminated_date unless terminated_date == SKIP
237
+ @total_cards = total_cards unless total_cards == SKIP
238
+ end
239
+
240
+ # Creates an instance of the object from a hash.
241
+ def self.from_hash(hash)
242
+ return nil unless hash
243
+
244
+ # Extract variables from the hash.
245
+ account_id = hash.key?('AccountId') ? hash['AccountId'] : SKIP
246
+ account_number = hash.key?('AccountNumber') ? hash['AccountNumber'] : SKIP
247
+ account_short_name =
248
+ hash.key?('AccountShortName') ? hash['AccountShortName'] : SKIP
249
+ active_cards = hash.key?('ActiveCards') ? hash['ActiveCards'] : SKIP
250
+ blocked_cards = hash.key?('BlockedCards') ? hash['BlockedCards'] : SKIP
251
+ cancelled_cards =
252
+ hash.key?('CancelledCards') ? hash['CancelledCards'] : SKIP
253
+ card_delivery_point =
254
+ hash.key?('CardDeliveryPoint') ? hash['CardDeliveryPoint'] : SKIP
255
+ card_group_id = hash.key?('CardGroupId') ? hash['CardGroupId'] : SKIP
256
+ card_group_name =
257
+ hash.key?('CardGroupName') ? hash['CardGroupName'] : SKIP
258
+ card_type_code = hash.key?('CardTypeCode') ? hash['CardTypeCode'] : SKIP
259
+ card_type_id = hash.key?('CardTypeId') ? hash['CardTypeId'] : SKIP
260
+ card_type_name = hash.key?('CardTypeName') ? hash['CardTypeName'] : SKIP
261
+ expired_cards = hash.key?('ExpiredCards') ? hash['ExpiredCards'] : SKIP
262
+ expiry_date = hash.key?('ExpiryDate') ? hash['ExpiryDate'] : SKIP
263
+ print_on_card = hash.key?('PrintOnCard') ? hash['PrintOnCard'] : SKIP
264
+ renewal_pending_cards =
265
+ hash.key?('RenewalPendingCards') ? hash['RenewalPendingCards'] : SKIP
266
+ replaced_cards = hash.key?('ReplacedCards') ? hash['ReplacedCards'] : SKIP
267
+ status = hash.key?('Status') ? hash['Status'] : SKIP
268
+ temporary_block_by_customer =
269
+ hash.key?('TemporaryBlockByCustomer') ? hash['TemporaryBlockByCustomer'] : SKIP
270
+ temporary_block_by_shell =
271
+ hash.key?('TemporaryBlockByShell') ? hash['TemporaryBlockByShell'] : SKIP
272
+ terminated_date =
273
+ hash.key?('TerminatedDate') ? hash['TerminatedDate'] : SKIP
274
+ total_cards = hash.key?('TotalCards') ? hash['TotalCards'] : SKIP
275
+
276
+ # Create object from extracted values.
277
+ CardGroupResponseCardGroupsItems.new(account_id,
278
+ account_number,
279
+ account_short_name,
280
+ active_cards,
281
+ blocked_cards,
282
+ cancelled_cards,
283
+ card_delivery_point,
284
+ card_group_id,
285
+ card_group_name,
286
+ card_type_code,
287
+ card_type_id,
288
+ card_type_name,
289
+ expired_cards,
290
+ expiry_date,
291
+ print_on_card,
292
+ renewal_pending_cards,
293
+ replaced_cards,
294
+ status,
295
+ temporary_block_by_customer,
296
+ temporary_block_by_shell,
297
+ terminated_date,
298
+ total_cards)
299
+ end
300
+ end
301
+ end
@@ -0,0 +1,145 @@
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
+ # CardTypeRequest Model.
8
+ class CardTypeRequest < BaseModel
9
+ SKIP = Object.new
10
+ private_constant :SKIP
11
+
12
+ # Collecting Company Id of the selected payer.
13
+ # Optional if ColCoCode is passed else Mandatory.
14
+ # @return [Integer]
15
+ attr_accessor :col_co_id
16
+
17
+ # Collecting Company Code (Shell Code) of the selected payer.
18
+ # Mandatory for serviced OUs such as Romania, Latvia, Lithuania, Estonia,
19
+ # Ukraine etc. It is optional for other countries if ColCoID is provided.
20
+ # @return [Integer]
21
+ attr_accessor :col_co_code
22
+
23
+ # Payer Id of the selected payer.
24
+ # @return [Integer]
25
+ attr_accessor :payer_id
26
+
27
+ # Payer Number of the selected payer.
28
+ # @return [String]
29
+ attr_accessor :payer_number
30
+
31
+ # Account Id of the customer.
32
+ # Optional if AccountNumber is passed else Mandatory.
33
+ # @return [Integer]
34
+ attr_accessor :account_id
35
+
36
+ # Account Number of the customer.
37
+ # Optional if AccountId is passed else Mandatory
38
+ # Example: GB000000124
39
+ # @return [String]
40
+ attr_accessor :account_number
41
+
42
+ # Include usage restrictions in the response.
43
+ # Optional field– default value is False.
44
+ # Possible values: True/False
45
+ # @return [TrueClass | FalseClass]
46
+ attr_accessor :include_usage_restrictions
47
+
48
+ # Include purchase categories in the response.
49
+ # Optional field– default value is False.
50
+ # Possible values: True/False
51
+ # @return [TrueClass | FalseClass]
52
+ attr_accessor :include_purchase_categories
53
+
54
+ # A mapping from model property names to API property names.
55
+ def self.names
56
+ @_hash = {} if @_hash.nil?
57
+ @_hash['col_co_id'] = 'ColCoId'
58
+ @_hash['col_co_code'] = 'ColCoCode'
59
+ @_hash['payer_id'] = 'PayerId'
60
+ @_hash['payer_number'] = 'PayerNumber'
61
+ @_hash['account_id'] = 'AccountId'
62
+ @_hash['account_number'] = 'AccountNumber'
63
+ @_hash['include_usage_restrictions'] = 'IncludeUsageRestrictions'
64
+ @_hash['include_purchase_categories'] = 'IncludePurchaseCategories'
65
+ @_hash
66
+ end
67
+
68
+ # An array for optional fields
69
+ def self.optionals
70
+ %w[
71
+ col_co_id
72
+ col_co_code
73
+ payer_id
74
+ payer_number
75
+ account_id
76
+ account_number
77
+ include_usage_restrictions
78
+ include_purchase_categories
79
+ ]
80
+ end
81
+
82
+ # An array for nullable fields
83
+ def self.nullables
84
+ %w[
85
+ col_co_id
86
+ col_co_code
87
+ payer_id
88
+ payer_number
89
+ account_id
90
+ account_number
91
+ ]
92
+ end
93
+
94
+ def initialize(col_co_id = SKIP,
95
+ col_co_code = SKIP,
96
+ payer_id = SKIP,
97
+ payer_number = SKIP,
98
+ account_id = SKIP,
99
+ account_number = SKIP,
100
+ include_usage_restrictions = SKIP,
101
+ include_purchase_categories = SKIP)
102
+ @col_co_id = col_co_id unless col_co_id == SKIP
103
+ @col_co_code = col_co_code unless col_co_code == SKIP
104
+ @payer_id = payer_id unless payer_id == SKIP
105
+ @payer_number = payer_number unless payer_number == SKIP
106
+ @account_id = account_id unless account_id == SKIP
107
+ @account_number = account_number unless account_number == SKIP
108
+ unless include_usage_restrictions == SKIP
109
+ @include_usage_restrictions =
110
+ include_usage_restrictions
111
+ end
112
+ unless include_purchase_categories == SKIP
113
+ @include_purchase_categories =
114
+ include_purchase_categories
115
+ end
116
+ end
117
+
118
+ # Creates an instance of the object from a hash.
119
+ def self.from_hash(hash)
120
+ return nil unless hash
121
+
122
+ # Extract variables from the hash.
123
+ col_co_id = hash.key?('ColCoId') ? hash['ColCoId'] : SKIP
124
+ col_co_code = hash.key?('ColCoCode') ? hash['ColCoCode'] : SKIP
125
+ payer_id = hash.key?('PayerId') ? hash['PayerId'] : SKIP
126
+ payer_number = hash.key?('PayerNumber') ? hash['PayerNumber'] : SKIP
127
+ account_id = hash.key?('AccountId') ? hash['AccountId'] : SKIP
128
+ account_number = hash.key?('AccountNumber') ? hash['AccountNumber'] : SKIP
129
+ include_usage_restrictions =
130
+ hash.key?('IncludeUsageRestrictions') ? hash['IncludeUsageRestrictions'] : SKIP
131
+ include_purchase_categories =
132
+ hash.key?('IncludePurchaseCategories') ? hash['IncludePurchaseCategories'] : SKIP
133
+
134
+ # Create object from extracted values.
135
+ CardTypeRequest.new(col_co_id,
136
+ col_co_code,
137
+ payer_id,
138
+ payer_number,
139
+ account_id,
140
+ account_number,
141
+ include_usage_restrictions,
142
+ include_purchase_categories)
143
+ end
144
+ end
145
+ end
@@ -0,0 +1,79 @@
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
+ # CardTypeResponse Model.
8
+ class CardTypeResponse < BaseModel
9
+ SKIP = Object.new
10
+ private_constant :SKIP
11
+
12
+ # TODO: Write general description for this method
13
+ # @return [Array[CardTypeResponseCustomerCardTypesItems]]
14
+ attr_accessor :customer_card_types
15
+
16
+ # TODO: Write general description for this method
17
+ # @return [CardTypeResponseError]
18
+ attr_accessor :error
19
+
20
+ # API Request Id
21
+ # @return [String]
22
+ attr_accessor :request_id
23
+
24
+ # A mapping from model property names to API property names.
25
+ def self.names
26
+ @_hash = {} if @_hash.nil?
27
+ @_hash['customer_card_types'] = 'CustomerCardTypes'
28
+ @_hash['error'] = 'Error'
29
+ @_hash['request_id'] = 'RequestId'
30
+ @_hash
31
+ end
32
+
33
+ # An array for optional fields
34
+ def self.optionals
35
+ %w[
36
+ customer_card_types
37
+ error
38
+ request_id
39
+ ]
40
+ end
41
+
42
+ # An array for nullable fields
43
+ def self.nullables
44
+ []
45
+ end
46
+
47
+ def initialize(customer_card_types = SKIP,
48
+ error = SKIP,
49
+ request_id = SKIP)
50
+ @customer_card_types = customer_card_types unless customer_card_types == SKIP
51
+ @error = error unless error == SKIP
52
+ @request_id = request_id unless request_id == SKIP
53
+ end
54
+
55
+ # Creates an instance of the object from a hash.
56
+ def self.from_hash(hash)
57
+ return nil unless hash
58
+
59
+ # Extract variables from the hash.
60
+ # Parameter is an array, so we need to iterate through it
61
+ customer_card_types = nil
62
+ unless hash['CustomerCardTypes'].nil?
63
+ customer_card_types = []
64
+ hash['CustomerCardTypes'].each do |structure|
65
+ customer_card_types << (CardTypeResponseCustomerCardTypesItems.from_hash(structure) if structure)
66
+ end
67
+ end
68
+
69
+ customer_card_types = SKIP unless hash.key?('CustomerCardTypes')
70
+ error = CardTypeResponseError.from_hash(hash['Error']) if hash['Error']
71
+ request_id = hash.key?('RequestId') ? hash['RequestId'] : SKIP
72
+
73
+ # Create object from extracted values.
74
+ CardTypeResponse.new(customer_card_types,
75
+ error,
76
+ request_id)
77
+ end
78
+ end
79
+ end