data-and-reporting-sdk 1.0.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/LICENSE +28 -0
- data/README.md +104 -0
- data/lib/shell_data_reporting_ap_is/api_helper.rb +10 -0
- data/lib/shell_data_reporting_ap_is/client.rb +84 -0
- data/lib/shell_data_reporting_ap_is/configuration.rb +110 -0
- data/lib/shell_data_reporting_ap_is/controllers/base_controller.rb +66 -0
- data/lib/shell_data_reporting_ap_is/controllers/customer_controller.rb +478 -0
- data/lib/shell_data_reporting_ap_is/controllers/invoice_controller.rb +470 -0
- data/lib/shell_data_reporting_ap_is/controllers/o_auth_authorization_controller.rb +42 -0
- data/lib/shell_data_reporting_ap_is/controllers/transaction_controller.rb +878 -0
- data/lib/shell_data_reporting_ap_is/exceptions/api_exception.rb +10 -0
- data/lib/shell_data_reporting_ap_is/exceptions/default_error_exception.rb +32 -0
- data/lib/shell_data_reporting_ap_is/exceptions/error_object_exception.rb +54 -0
- data/lib/shell_data_reporting_ap_is/exceptions/error_user_access_error1_exception.rb +32 -0
- data/lib/shell_data_reporting_ap_is/exceptions/o_auth_provider_exception.rb +48 -0
- data/lib/shell_data_reporting_ap_is/http/auth/basic_auth.rb +50 -0
- data/lib/shell_data_reporting_ap_is/http/auth/bearer_token.rb +89 -0
- data/lib/shell_data_reporting_ap_is/http/http_call_back.rb +10 -0
- data/lib/shell_data_reporting_ap_is/http/http_method_enum.rb +10 -0
- data/lib/shell_data_reporting_ap_is/http/http_request.rb +10 -0
- data/lib/shell_data_reporting_ap_is/http/http_response.rb +10 -0
- data/lib/shell_data_reporting_ap_is/models/account_access.rb +128 -0
- data/lib/shell_data_reporting_ap_is/models/account_request.rb +252 -0
- data/lib/shell_data_reporting_ap_is/models/account_response.rb +111 -0
- data/lib/shell_data_reporting_ap_is/models/account_response_accounts_items.rb +750 -0
- data/lib/shell_data_reporting_ap_is/models/accounts.rb +65 -0
- data/lib/shell_data_reporting_ap_is/models/address.rb +174 -0
- data/lib/shell_data_reporting_ap_is/models/associated_account.rb +98 -0
- data/lib/shell_data_reporting_ap_is/models/audit_request.rb +256 -0
- data/lib/shell_data_reporting_ap_is/models/audit_response.rb +111 -0
- data/lib/shell_data_reporting_ap_is/models/audit_response_audits_items.rb +450 -0
- data/lib/shell_data_reporting_ap_is/models/bank_account.rb +192 -0
- data/lib/shell_data_reporting_ap_is/models/base_model.rb +62 -0
- data/lib/shell_data_reporting_ap_is/models/bonus_configuration.rb +419 -0
- data/lib/shell_data_reporting_ap_is/models/bonus_history.rb +444 -0
- data/lib/shell_data_reporting_ap_is/models/card_day_time_restrictions.rb +159 -0
- data/lib/shell_data_reporting_ap_is/models/card_exceptions.rb +268 -0
- data/lib/shell_data_reporting_ap_is/models/card_group_request.rb +178 -0
- data/lib/shell_data_reporting_ap_is/models/card_group_response.rb +109 -0
- data/lib/shell_data_reporting_ap_is/models/card_group_response_card_groups_items.rb +301 -0
- data/lib/shell_data_reporting_ap_is/models/card_type_request.rb +145 -0
- data/lib/shell_data_reporting_ap_is/models/card_type_response.rb +79 -0
- data/lib/shell_data_reporting_ap_is/models/card_type_response_customer_card_types_items.rb +470 -0
- data/lib/shell_data_reporting_ap_is/models/card_type_response_error.rb +60 -0
- data/lib/shell_data_reporting_ap_is/models/card_usage_restrictions.rb +281 -0
- data/lib/shell_data_reporting_ap_is/models/card_usage_summary_request.rb +159 -0
- data/lib/shell_data_reporting_ap_is/models/card_usage_summary_response.rb +79 -0
- data/lib/shell_data_reporting_ap_is/models/col_co_access.rb +88 -0
- data/lib/shell_data_reporting_ap_is/models/current_volume.rb +99 -0
- data/lib/shell_data_reporting_ap_is/models/customer_contract.rb +63 -0
- data/lib/shell_data_reporting_ap_is/models/customer_detail_request.rb +123 -0
- data/lib/shell_data_reporting_ap_is/models/customer_detail_response.rb +437 -0
- data/lib/shell_data_reporting_ap_is/models/customer_price_list_request.rb +200 -0
- data/lib/shell_data_reporting_ap_is/models/customer_price_list_response.rb +82 -0
- data/lib/shell_data_reporting_ap_is/models/default_error_fault.rb +60 -0
- data/lib/shell_data_reporting_ap_is/models/default_error_fault_detail.rb +50 -0
- data/lib/shell_data_reporting_ap_is/models/delivery_addresses.rb +258 -0
- data/lib/shell_data_reporting_ap_is/models/eid_access.rb +75 -0
- data/lib/shell_data_reporting_ap_is/models/eid_document.rb +166 -0
- data/lib/shell_data_reporting_ap_is/models/eid_document_response.rb +140 -0
- data/lib/shell_data_reporting_ap_is/models/eid_download_req.rb +86 -0
- data/lib/shell_data_reporting_ap_is/models/eid_download_request.rb +50 -0
- data/lib/shell_data_reporting_ap_is/models/eid_search_req.rb +160 -0
- data/lib/shell_data_reporting_ap_is/models/eid_search_request.rb +70 -0
- data/lib/shell_data_reporting_ap_is/models/error_details.rb +81 -0
- data/lib/shell_data_reporting_ap_is/models/error_status.rb +60 -0
- data/lib/shell_data_reporting_ap_is/models/error_user_access.rb +50 -0
- data/lib/shell_data_reporting_ap_is/models/error_user_access_error.rb +60 -0
- data/lib/shell_data_reporting_ap_is/models/exception_product.rb +65 -0
- data/lib/shell_data_reporting_ap_is/models/exception_site_location.rb +63 -0
- data/lib/shell_data_reporting_ap_is/models/fee_item.rb +977 -0
- data/lib/shell_data_reporting_ap_is/models/fee_item_summary_all_of0.rb +194 -0
- data/lib/shell_data_reporting_ap_is/models/fee_rule_location.rb +153 -0
- data/lib/shell_data_reporting_ap_is/models/fee_rule_product.rb +98 -0
- data/lib/shell_data_reporting_ap_is/models/fee_rule_tier.rb +74 -0
- data/lib/shell_data_reporting_ap_is/models/fee_summary_response.rb +85 -0
- data/lib/shell_data_reporting_ap_is/models/fees_fee_rule_tiers.rb +124 -0
- data/lib/shell_data_reporting_ap_is/models/finance_currency.rb +98 -0
- data/lib/shell_data_reporting_ap_is/models/fuel_consumption_card.rb +73 -0
- data/lib/shell_data_reporting_ap_is/models/fuel_consumption_data.rb +267 -0
- data/lib/shell_data_reporting_ap_is/models/fuel_consumption_request.rb +197 -0
- data/lib/shell_data_reporting_ap_is/models/fuel_consumption_response.rb +79 -0
- data/lib/shell_data_reporting_ap_is/models/invoice_dates_data.rb +62 -0
- data/lib/shell_data_reporting_ap_is/models/invoice_dates_request.rb +50 -0
- data/lib/shell_data_reporting_ap_is/models/invoice_dates_request_filters.rb +146 -0
- data/lib/shell_data_reporting_ap_is/models/invoice_dates_response_data.rb +80 -0
- data/lib/shell_data_reporting_ap_is/models/invoice_distribution_method.rb +99 -0
- data/lib/shell_data_reporting_ap_is/models/invoice_download_req.rb +99 -0
- data/lib/shell_data_reporting_ap_is/models/invoice_download_request.rb +50 -0
- data/lib/shell_data_reporting_ap_is/models/invoice_search_additional_document.rb +80 -0
- data/lib/shell_data_reporting_ap_is/models/invoice_search_details.rb +913 -0
- data/lib/shell_data_reporting_ap_is/models/invoice_search_request.rb +91 -0
- data/lib/shell_data_reporting_ap_is/models/invoice_search_request_filters.rb +344 -0
- data/lib/shell_data_reporting_ap_is/models/invoice_search_response.rb +127 -0
- data/lib/shell_data_reporting_ap_is/models/invoice_summary_details.rb +129 -0
- data/lib/shell_data_reporting_ap_is/models/invoice_summary_request.rb +50 -0
- data/lib/shell_data_reporting_ap_is/models/invoice_summary_request_filters.rb +345 -0
- data/lib/shell_data_reporting_ap_is/models/invoice_summary_response.rb +79 -0
- data/lib/shell_data_reporting_ap_is/models/invoices_summaries.rb +221 -0
- data/lib/shell_data_reporting_ap_is/models/last_statement_of_account.rb +421 -0
- data/lib/shell_data_reporting_ap_is/models/logged_in_user_request.rb +107 -0
- data/lib/shell_data_reporting_ap_is/models/logged_in_user_response.rb +394 -0
- data/lib/shell_data_reporting_ap_is/models/monthly_invoice_trend.rb +112 -0
- data/lib/shell_data_reporting_ap_is/models/multi_priced_transaction_request.rb +360 -0
- data/lib/shell_data_reporting_ap_is/models/multi_priced_transaction_request_accounts_items.rb +84 -0
- data/lib/shell_data_reporting_ap_is/models/multi_priced_transaction_response.rb +110 -0
- data/lib/shell_data_reporting_ap_is/models/multi_priced_transaction_response_transactions_items.rb +1724 -0
- data/lib/shell_data_reporting_ap_is/models/o_auth_provider_error_enum.rb +45 -0
- data/lib/shell_data_reporting_ap_is/models/o_auth_token.rb +100 -0
- data/lib/shell_data_reporting_ap_is/models/past_statement_of_accounts.rb +502 -0
- data/lib/shell_data_reporting_ap_is/models/payer_access.rb +147 -0
- data/lib/shell_data_reporting_ap_is/models/payer_details.rb +1412 -0
- data/lib/shell_data_reporting_ap_is/models/payer_request.rb +126 -0
- data/lib/shell_data_reporting_ap_is/models/payer_response.rb +115 -0
- data/lib/shell_data_reporting_ap_is/models/payers.rb +109 -0
- data/lib/shell_data_reporting_ap_is/models/payments_since_last_soa.rb +322 -0
- data/lib/shell_data_reporting_ap_is/models/pin_advice_types.rb +80 -0
- data/lib/shell_data_reporting_ap_is/models/price_list.rb +485 -0
- data/lib/shell_data_reporting_ap_is/models/price_trans_summary_request.rb +477 -0
- data/lib/shell_data_reporting_ap_is/models/price_transaction_request.rb +572 -0
- data/lib/shell_data_reporting_ap_is/models/priced_request_data.rb +485 -0
- data/lib/shell_data_reporting_ap_is/models/priced_response_data.rb +2132 -0
- data/lib/shell_data_reporting_ap_is/models/priced_trans_summary_response.rb +79 -0
- data/lib/shell_data_reporting_ap_is/models/priced_trans_summary_response_transactions_summary_items.rb +242 -0
- data/lib/shell_data_reporting_ap_is/models/priced_transaction_items_location_items.rb +67 -0
- data/lib/shell_data_reporting_ap_is/models/priced_transaction_req_v2_invoice_status_enum.rb +27 -0
- data/lib/shell_data_reporting_ap_is/models/priced_transaction_req_v2_period_enum.rb +27 -0
- data/lib/shell_data_reporting_ap_is/models/priced_transaction_req_v2_sort_order_enum.rb +37 -0
- data/lib/shell_data_reporting_ap_is/models/priced_transaction_request_v2.rb +72 -0
- data/lib/shell_data_reporting_ap_is/models/priced_transaction_resp_v2_refund_flag_enum.rb +23 -0
- data/lib/shell_data_reporting_ap_is/models/priced_transaction_response.rb +59 -0
- data/lib/shell_data_reporting_ap_is/models/priced_transaction_response_transactions_items.rb +1719 -0
- data/lib/shell_data_reporting_ap_is/models/priced_transaction_response_v2.rb +110 -0
- data/lib/shell_data_reporting_ap_is/models/pricing_current_volume.rb +115 -0
- data/lib/shell_data_reporting_ap_is/models/pricing_history.rb +105 -0
- data/lib/shell_data_reporting_ap_is/models/purchase_categories.rb +114 -0
- data/lib/shell_data_reporting_ap_is/models/recent_transaction_req.rb +217 -0
- data/lib/shell_data_reporting_ap_is/models/recent_transaction_request.rb +66 -0
- data/lib/shell_data_reporting_ap_is/models/recent_transactions.rb +918 -0
- data/lib/shell_data_reporting_ap_is/models/recent_transactions_response.rb +110 -0
- data/lib/shell_data_reporting_ap_is/models/role.rb +102 -0
- data/lib/shell_data_reporting_ap_is/models/search_doc_req.rb +269 -0
- data/lib/shell_data_reporting_ap_is/models/search_documents_invoice.rb +204 -0
- data/lib/shell_data_reporting_ap_is/models/search_documents_request.rb +70 -0
- data/lib/shell_data_reporting_ap_is/models/search_documents_response.rb +122 -0
- data/lib/shell_data_reporting_ap_is/models/search_soa_req.rb +197 -0
- data/lib/shell_data_reporting_ap_is/models/search_statement_of_account.rb +220 -0
- data/lib/shell_data_reporting_ap_is/models/search_statement_of_account_request.rb +70 -0
- data/lib/shell_data_reporting_ap_is/models/search_statement_of_account_response.rb +120 -0
- data/lib/shell_data_reporting_ap_is/models/site_location.rb +67 -0
- data/lib/shell_data_reporting_ap_is/models/statement_of_account_request.rb +50 -0
- data/lib/shell_data_reporting_ap_is/models/statement_of_account_request_filters.rb +197 -0
- data/lib/shell_data_reporting_ap_is/models/statement_of_account_resp.rb +138 -0
- data/lib/shell_data_reporting_ap_is/models/statement_of_account_response.rb +80 -0
- data/lib/shell_data_reporting_ap_is/models/tier.rb +167 -0
- data/lib/shell_data_reporting_ap_is/models/transaction_exceptions.rb +1267 -0
- data/lib/shell_data_reporting_ap_is/models/transaction_exceptions_request.rb +267 -0
- data/lib/shell_data_reporting_ap_is/models/transaction_exceptions_response.rb +100 -0
- data/lib/shell_data_reporting_ap_is/models/transaction_fees_request.rb +348 -0
- data/lib/shell_data_reporting_ap_is/models/transaction_fees_response.rb +111 -0
- data/lib/shell_data_reporting_ap_is/models/update_odometer.rb +62 -0
- data/lib/shell_data_reporting_ap_is/models/update_odometer_reference.rb +67 -0
- data/lib/shell_data_reporting_ap_is/models/update_odometer_request.rb +146 -0
- data/lib/shell_data_reporting_ap_is/models/update_odometer_response.rb +93 -0
- data/lib/shell_data_reporting_ap_is/models/usage_summary.rb +202 -0
- data/lib/shell_data_reporting_ap_is/models/volume_based_bonus_request.rb +118 -0
- data/lib/shell_data_reporting_ap_is/models/volume_based_bonus_response.rb +120 -0
- data/lib/shell_data_reporting_ap_is/models/volume_based_pricing_request.rb +103 -0
- data/lib/shell_data_reporting_ap_is/models/volume_based_pricing_response.rb +120 -0
- data/lib/shell_data_reporting_ap_is/utilities/date_time_helper.rb +11 -0
- data/lib/shell_data_reporting_ap_is/utilities/file_wrapper.rb +16 -0
- data/lib/shell_data_reporting_ap_is.rb +229 -0
- data/test/controllers/controller_test_base.rb +34 -0
- data/test/controllers/test_invoice_controller.rb +398 -0
- data/test/controllers/test_transaction_controller.rb +235 -0
- data/test/http_response_catcher.rb +19 -0
- metadata +302 -0
@@ -0,0 +1,99 @@
|
|
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
|
+
# CurrentVolume Model.
|
8
|
+
class CurrentVolume < BaseModel
|
9
|
+
SKIP = Object.new
|
10
|
+
private_constant :SKIP
|
11
|
+
|
12
|
+
# Bonus or association bonus configuration identifier that is associated to
|
13
|
+
# the payer
|
14
|
+
# @return [Integer]
|
15
|
+
attr_accessor :fee_rule_id
|
16
|
+
|
17
|
+
# Bonus or association bonus configuration description that is associated to
|
18
|
+
# the payer.
|
19
|
+
# @return [String]
|
20
|
+
attr_accessor :fee_rule_description
|
21
|
+
|
22
|
+
# Consumption(Volume) of the month.
|
23
|
+
# @return [Integer]
|
24
|
+
attr_accessor :month
|
25
|
+
|
26
|
+
# Consumption (Volume) of the year.
|
27
|
+
# @return [String]
|
28
|
+
attr_accessor :year
|
29
|
+
|
30
|
+
# Total volume consumption for the month/year above.
|
31
|
+
# @return [Float]
|
32
|
+
attr_accessor :total_volume
|
33
|
+
|
34
|
+
# A mapping from model property names to API property names.
|
35
|
+
def self.names
|
36
|
+
@_hash = {} if @_hash.nil?
|
37
|
+
@_hash['fee_rule_id'] = 'FeeRuleId'
|
38
|
+
@_hash['fee_rule_description'] = 'FeeRuleDescription'
|
39
|
+
@_hash['month'] = 'Month'
|
40
|
+
@_hash['year'] = 'Year'
|
41
|
+
@_hash['total_volume'] = 'TotalVolume'
|
42
|
+
@_hash
|
43
|
+
end
|
44
|
+
|
45
|
+
# An array for optional fields
|
46
|
+
def self.optionals
|
47
|
+
%w[
|
48
|
+
fee_rule_id
|
49
|
+
fee_rule_description
|
50
|
+
month
|
51
|
+
year
|
52
|
+
total_volume
|
53
|
+
]
|
54
|
+
end
|
55
|
+
|
56
|
+
# An array for nullable fields
|
57
|
+
def self.nullables
|
58
|
+
%w[
|
59
|
+
fee_rule_id
|
60
|
+
fee_rule_description
|
61
|
+
month
|
62
|
+
year
|
63
|
+
total_volume
|
64
|
+
]
|
65
|
+
end
|
66
|
+
|
67
|
+
def initialize(fee_rule_id = SKIP,
|
68
|
+
fee_rule_description = SKIP,
|
69
|
+
month = SKIP,
|
70
|
+
year = SKIP,
|
71
|
+
total_volume = SKIP)
|
72
|
+
@fee_rule_id = fee_rule_id unless fee_rule_id == SKIP
|
73
|
+
@fee_rule_description = fee_rule_description unless fee_rule_description == SKIP
|
74
|
+
@month = month unless month == SKIP
|
75
|
+
@year = year unless year == SKIP
|
76
|
+
@total_volume = total_volume unless total_volume == SKIP
|
77
|
+
end
|
78
|
+
|
79
|
+
# Creates an instance of the object from a hash.
|
80
|
+
def self.from_hash(hash)
|
81
|
+
return nil unless hash
|
82
|
+
|
83
|
+
# Extract variables from the hash.
|
84
|
+
fee_rule_id = hash.key?('FeeRuleId') ? hash['FeeRuleId'] : SKIP
|
85
|
+
fee_rule_description =
|
86
|
+
hash.key?('FeeRuleDescription') ? hash['FeeRuleDescription'] : SKIP
|
87
|
+
month = hash.key?('Month') ? hash['Month'] : SKIP
|
88
|
+
year = hash.key?('Year') ? hash['Year'] : SKIP
|
89
|
+
total_volume = hash.key?('TotalVolume') ? hash['TotalVolume'] : SKIP
|
90
|
+
|
91
|
+
# Create object from extracted values.
|
92
|
+
CurrentVolume.new(fee_rule_id,
|
93
|
+
fee_rule_description,
|
94
|
+
month,
|
95
|
+
year,
|
96
|
+
total_volume)
|
97
|
+
end
|
98
|
+
end
|
99
|
+
end
|
@@ -0,0 +1,63 @@
|
|
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
|
+
# CustomerContract Model.
|
8
|
+
class CustomerContract < BaseModel
|
9
|
+
SKIP = Object.new
|
10
|
+
private_constant :SKIP
|
11
|
+
|
12
|
+
# Partner Id in e-TM system
|
13
|
+
# @return [String]
|
14
|
+
attr_accessor :partner_id
|
15
|
+
|
16
|
+
# Partner Name in e-TM system
|
17
|
+
# @return [String]
|
18
|
+
attr_accessor :partner_name
|
19
|
+
|
20
|
+
# A mapping from model property names to API property names.
|
21
|
+
def self.names
|
22
|
+
@_hash = {} if @_hash.nil?
|
23
|
+
@_hash['partner_id'] = 'PartnerId'
|
24
|
+
@_hash['partner_name'] = 'PartnerName'
|
25
|
+
@_hash
|
26
|
+
end
|
27
|
+
|
28
|
+
# An array for optional fields
|
29
|
+
def self.optionals
|
30
|
+
%w[
|
31
|
+
partner_id
|
32
|
+
partner_name
|
33
|
+
]
|
34
|
+
end
|
35
|
+
|
36
|
+
# An array for nullable fields
|
37
|
+
def self.nullables
|
38
|
+
%w[
|
39
|
+
partner_id
|
40
|
+
partner_name
|
41
|
+
]
|
42
|
+
end
|
43
|
+
|
44
|
+
def initialize(partner_id = SKIP,
|
45
|
+
partner_name = SKIP)
|
46
|
+
@partner_id = partner_id unless partner_id == SKIP
|
47
|
+
@partner_name = partner_name unless partner_name == SKIP
|
48
|
+
end
|
49
|
+
|
50
|
+
# Creates an instance of the object from a hash.
|
51
|
+
def self.from_hash(hash)
|
52
|
+
return nil unless hash
|
53
|
+
|
54
|
+
# Extract variables from the hash.
|
55
|
+
partner_id = hash.key?('PartnerId') ? hash['PartnerId'] : SKIP
|
56
|
+
partner_name = hash.key?('PartnerName') ? hash['PartnerName'] : SKIP
|
57
|
+
|
58
|
+
# Create object from extracted values.
|
59
|
+
CustomerContract.new(partner_id,
|
60
|
+
partner_name)
|
61
|
+
end
|
62
|
+
end
|
63
|
+
end
|
@@ -0,0 +1,123 @@
|
|
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
|
+
# CustomerDetailRequest Model.
|
8
|
+
class CustomerDetailRequest < BaseModel
|
9
|
+
SKIP = Object.new
|
10
|
+
private_constant :SKIP
|
11
|
+
|
12
|
+
# Collecting Company Id (in GFN) of the selected payer.
|
13
|
+
# Optional if ColCoCode is passed else Mandatory.
|
14
|
+
# Example:
|
15
|
+
# 1-Philippines
|
16
|
+
# 5-UK
|
17
|
+
# @return [Integer]
|
18
|
+
attr_accessor :col_co_id
|
19
|
+
|
20
|
+
# Collecting Company Code (Shell Code) of the selected payer.
|
21
|
+
# Mandatory for serviced OUs such as Romania, Latvia, Lithuania, Estonia,
|
22
|
+
# Ukraine etc. It is optional for other countries if ColCoID is provided.
|
23
|
+
# Example:
|
24
|
+
# 86-Philippines
|
25
|
+
# 5-UK
|
26
|
+
# @return [Integer]
|
27
|
+
attr_accessor :col_co_code
|
28
|
+
|
29
|
+
# Payer Id (i.e., Customer Id of the Payment Customer in H3 Cards Platform)
|
30
|
+
# of the selected payer.
|
31
|
+
# Optional if PayerNumber is passed else Mandatory
|
32
|
+
# Example: 123456
|
33
|
+
# @return [Integer]
|
34
|
+
attr_accessor :payer_id
|
35
|
+
|
36
|
+
# Payer Number of the selected payer.
|
37
|
+
# Optional if PayerId is passed else Mandatory
|
38
|
+
# Example: GB000000123
|
39
|
+
# @return [String]
|
40
|
+
attr_accessor :payer_number
|
41
|
+
|
42
|
+
# Account ID of the customer.
|
43
|
+
# Optional if AccountNumber is passed else Mandatory.
|
44
|
+
# @return [Integer]
|
45
|
+
attr_accessor :account_id
|
46
|
+
|
47
|
+
# Account Number of the customer.
|
48
|
+
# Optional if AccountId is passed else Mandatory.
|
49
|
+
# @return [String]
|
50
|
+
attr_accessor :account_number
|
51
|
+
|
52
|
+
# A mapping from model property names to API property names.
|
53
|
+
def self.names
|
54
|
+
@_hash = {} if @_hash.nil?
|
55
|
+
@_hash['col_co_id'] = 'ColCoId'
|
56
|
+
@_hash['col_co_code'] = 'ColCoCode'
|
57
|
+
@_hash['payer_id'] = 'PayerId'
|
58
|
+
@_hash['payer_number'] = 'PayerNumber'
|
59
|
+
@_hash['account_id'] = 'AccountId'
|
60
|
+
@_hash['account_number'] = 'AccountNumber'
|
61
|
+
@_hash
|
62
|
+
end
|
63
|
+
|
64
|
+
# An array for optional fields
|
65
|
+
def self.optionals
|
66
|
+
%w[
|
67
|
+
col_co_id
|
68
|
+
col_co_code
|
69
|
+
payer_id
|
70
|
+
payer_number
|
71
|
+
account_id
|
72
|
+
account_number
|
73
|
+
]
|
74
|
+
end
|
75
|
+
|
76
|
+
# An array for nullable fields
|
77
|
+
def self.nullables
|
78
|
+
%w[
|
79
|
+
col_co_id
|
80
|
+
col_co_code
|
81
|
+
payer_id
|
82
|
+
payer_number
|
83
|
+
account_id
|
84
|
+
account_number
|
85
|
+
]
|
86
|
+
end
|
87
|
+
|
88
|
+
def initialize(col_co_id = SKIP,
|
89
|
+
col_co_code = SKIP,
|
90
|
+
payer_id = SKIP,
|
91
|
+
payer_number = SKIP,
|
92
|
+
account_id = SKIP,
|
93
|
+
account_number = SKIP)
|
94
|
+
@col_co_id = col_co_id unless col_co_id == SKIP
|
95
|
+
@col_co_code = col_co_code unless col_co_code == SKIP
|
96
|
+
@payer_id = payer_id unless payer_id == SKIP
|
97
|
+
@payer_number = payer_number unless payer_number == SKIP
|
98
|
+
@account_id = account_id unless account_id == SKIP
|
99
|
+
@account_number = account_number unless account_number == SKIP
|
100
|
+
end
|
101
|
+
|
102
|
+
# Creates an instance of the object from a hash.
|
103
|
+
def self.from_hash(hash)
|
104
|
+
return nil unless hash
|
105
|
+
|
106
|
+
# Extract variables from the hash.
|
107
|
+
col_co_id = hash.key?('ColCoId') ? hash['ColCoId'] : SKIP
|
108
|
+
col_co_code = hash.key?('ColCoCode') ? hash['ColCoCode'] : SKIP
|
109
|
+
payer_id = hash.key?('PayerId') ? hash['PayerId'] : SKIP
|
110
|
+
payer_number = hash.key?('PayerNumber') ? hash['PayerNumber'] : SKIP
|
111
|
+
account_id = hash.key?('AccountId') ? hash['AccountId'] : SKIP
|
112
|
+
account_number = hash.key?('AccountNumber') ? hash['AccountNumber'] : SKIP
|
113
|
+
|
114
|
+
# Create object from extracted values.
|
115
|
+
CustomerDetailRequest.new(col_co_id,
|
116
|
+
col_co_code,
|
117
|
+
payer_id,
|
118
|
+
payer_number,
|
119
|
+
account_id,
|
120
|
+
account_number)
|
121
|
+
end
|
122
|
+
end
|
123
|
+
end
|