digital-payments-sdk 1.0.0 → 1.1.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.
- checksums.yaml +4 -4
- data/README.md +33 -20
- data/lib/{shell_ev → shell_smart_pay_api}/api_helper.rb +2 -2
- data/lib/{shell_ev → shell_smart_pay_api}/client.rb +4 -4
- data/lib/{shell_ev → shell_smart_pay_api}/configuration.rb +11 -8
- data/lib/{shell_ev → shell_smart_pay_api}/controllers/base_controller.rb +11 -11
- data/lib/shell_smart_pay_api/controllers/digital_payment_enablement_controller.rb +57 -0
- data/lib/{shell_ev → shell_smart_pay_api}/controllers/fueling_controller.rb +50 -49
- data/lib/{shell_ev → shell_smart_pay_api}/controllers/partner_notification_controller.rb +27 -27
- data/lib/{shell_ev → shell_smart_pay_api}/controllers/shell_api_platform_security_authentication_controller.rb +9 -9
- data/lib/{shell_ev → shell_smart_pay_api}/controllers/station_locator_controller.rb +22 -22
- data/lib/{shell_ev → shell_smart_pay_api}/exceptions/access_token_error_exception.rb +28 -16
- data/lib/shell_smart_pay_api/exceptions/api_exception.rb +21 -0
- data/lib/{shell_ev → shell_smart_pay_api}/exceptions/cancel_fueling_error_response_error_exception.rb +31 -17
- data/lib/{shell_ev → shell_smart_pay_api}/exceptions/mpp_acces_token_error_response_exception.rb +31 -17
- data/lib/{shell_ev → shell_smart_pay_api}/exceptions/payment_enablement_error_response_exception.rb +28 -16
- data/lib/{shell_ev → shell_smart_pay_api}/exceptions/station_locator_bad_request_exception.rb +30 -17
- data/lib/{shell_ev → shell_smart_pay_api}/exceptions/station_locator_forbidden_exception.rb +30 -17
- data/lib/{shell_ev → shell_smart_pay_api}/exceptions/station_locator_internal_server_error_exception.rb +30 -17
- data/lib/{shell_ev → shell_smart_pay_api}/exceptions/station_locator_not_found_exception.rb +30 -17
- data/lib/{shell_ev → shell_smart_pay_api}/exceptions/station_locator_unauthorized_exception.rb +30 -17
- data/lib/{shell_ev → shell_smart_pay_api}/http/auth/mpp_token.rb +2 -2
- data/lib/{shell_ev → shell_smart_pay_api}/http/auth/o_auth_token_post.rb +2 -2
- data/lib/{shell_ev → shell_smart_pay_api}/http/http_call_back.rb +2 -2
- data/lib/{shell_ev → shell_smart_pay_api}/http/http_method_enum.rb +2 -2
- data/lib/{shell_ev → shell_smart_pay_api}/http/http_request.rb +2 -2
- data/lib/{shell_ev → shell_smart_pay_api}/http/http_response.rb +2 -2
- data/lib/{shell_ev → shell_smart_pay_api}/models/access_token_response.rb +17 -4
- data/lib/{shell_ev → shell_smart_pay_api}/models/around_location_array.rb +16 -4
- data/lib/shell_smart_pay_api/models/base_model.rb +110 -0
- data/lib/{shell_ev → shell_smart_pay_api}/models/cancel_fueling_error_response.rb +17 -5
- data/lib/{shell_ev → shell_smart_pay_api}/models/cancel_fueling_request.rb +16 -4
- data/lib/{shell_ev → shell_smart_pay_api}/models/collecting_company.rb +14 -2
- data/lib/{shell_ev/models/around_location_array_data_items.rb → shell_smart_pay_api/models/datum.rb} +78 -57
- data/lib/{shell_ev/models/fault_response_fault_detail.rb → shell_smart_pay_api/models/detail.rb} +17 -5
- data/lib/{shell_ev/models/prepare_fueling_request_device_details_items.rb → shell_smart_pay_api/models/device_detail.rb} +23 -11
- data/lib/{shell_ev/models/fault_response_fault.rb → shell_smart_pay_api/models/fault.rb} +21 -10
- data/lib/{shell_ev → shell_smart_pay_api}/models/fault_response.rb +16 -4
- data/lib/{shell_ev → shell_smart_pay_api}/models/finalise_fueling_request.rb +31 -18
- data/lib/{shell_ev/models/around_location_array_data_items_loc.rb → shell_smart_pay_api/models/loc.rb} +25 -15
- data/lib/{shell_ev → shell_smart_pay_api}/models/loyalty_details.rb +16 -4
- data/lib/{shell_ev → shell_smart_pay_api}/models/mobile_payment_registration_request.rb +22 -10
- data/lib/{shell_ev → shell_smart_pay_api}/models/mpp_acces_token_response.rb +18 -6
- data/lib/{shell_ev → shell_smart_pay_api}/models/mpp_error.rb +18 -7
- data/lib/{shell_ev/models/around_location_array_data_items_opening_hours_items.rb → shell_smart_pay_api/models/opening_hour.rb} +40 -24
- data/lib/{shell_ev/models/finalise_fueling_request_payment.rb → shell_smart_pay_api/models/payment.rb} +22 -10
- data/lib/{shell_ev/models/payment_details_items.rb → shell_smart_pay_api/models/payment_details.rb} +22 -9
- data/lib/{shell_ev → shell_smart_pay_api}/models/payment_enablement_response.rb +14 -2
- data/lib/{shell_ev → shell_smart_pay_api}/models/payment_properties.rb +24 -10
- data/lib/{shell_ev → shell_smart_pay_api}/models/prepare_fueling_request.rb +31 -24
- data/lib/{shell_ev → shell_smart_pay_api}/models/prepare_fueling_response.rb +16 -4
- data/lib/{shell_ev/models/finalise_fueling_request_products_items.rb → shell_smart_pay_api/models/product.rb} +22 -10
- data/lib/{shell_ev → shell_smart_pay_api}/utilities/date_time_helper.rb +2 -2
- data/lib/shell_smart_pay_api/utilities/file_wrapper.rb +28 -0
- data/lib/shell_smart_pay_api.rb +89 -0
- data/test/controllers/controller_test_base.rb +3 -3
- data/test/controllers/test_fueling_controller.rb +1 -1
- data/test/controllers/test_partner_notification_controller.rb +1 -1
- data/test/controllers/test_shell_api_platform_security_authentication_controller.rb +1 -1
- data/test/controllers/test_station_locator_controller.rb +1 -1
- data/test/http_response_catcher.rb +2 -2
- metadata +63 -72
- data/lib/shell_ev/controllers/digital_payment_enablement_controller.rb +0 -56
- data/lib/shell_ev/exceptions/api_exception.rb +0 -10
- data/lib/shell_ev/models/base_model.rb +0 -62
- data/lib/shell_ev/models/mpp_token_request_body.rb +0 -73
- data/lib/shell_ev/models/oauth_token_post_request_body.rb +0 -73
- data/lib/shell_ev/models/partner_token_request_body.rb +0 -73
- data/lib/shell_ev/utilities/file_wrapper.rb +0 -16
- data/lib/shell_ev.rb +0 -85
data/lib/{shell_ev/models/payment_details_items.rb → shell_smart_pay_api/models/payment_details.rb}
RENAMED
@@ -1,11 +1,11 @@
|
|
1
|
-
#
|
1
|
+
# shell_smart_pay_api
|
2
2
|
#
|
3
3
|
# This file was automatically generated by APIMATIC v2.0
|
4
4
|
# ( https://apimatic.io ).
|
5
5
|
|
6
|
-
module
|
7
|
-
#
|
8
|
-
class
|
6
|
+
module ShellSmartPayApi
|
7
|
+
# Object containing Payment details
|
8
|
+
class PaymentDetails < BaseModel
|
9
9
|
SKIP = Object.new
|
10
10
|
private_constant :SKIP
|
11
11
|
|
@@ -49,8 +49,7 @@ module ShellEv
|
|
49
49
|
[]
|
50
50
|
end
|
51
51
|
|
52
|
-
def initialize(payment_method_id = nil,
|
53
|
-
payment_properties = nil,
|
52
|
+
def initialize(payment_method_id = nil, payment_properties = nil,
|
54
53
|
payment_category = SKIP)
|
55
54
|
@payment_category = payment_category unless payment_category == SKIP
|
56
55
|
@payment_method_id = payment_method_id
|
@@ -70,9 +69,23 @@ module ShellEv
|
|
70
69
|
hash.key?('paymentCategory') ? hash['paymentCategory'] : SKIP
|
71
70
|
|
72
71
|
# Create object from extracted values.
|
73
|
-
|
74
|
-
|
75
|
-
|
72
|
+
PaymentDetails.new(payment_method_id,
|
73
|
+
payment_properties,
|
74
|
+
payment_category)
|
75
|
+
end
|
76
|
+
|
77
|
+
# Provides a human-readable string representation of the object.
|
78
|
+
def to_s
|
79
|
+
class_name = self.class.name.split('::').last
|
80
|
+
"<#{class_name} payment_category: #{@payment_category}, payment_method_id:"\
|
81
|
+
" #{@payment_method_id}, payment_properties: #{@payment_properties}>"
|
82
|
+
end
|
83
|
+
|
84
|
+
# Provides a debugging-friendly string with detailed object information.
|
85
|
+
def inspect
|
86
|
+
class_name = self.class.name.split('::').last
|
87
|
+
"<#{class_name} payment_category: #{@payment_category.inspect}, payment_method_id:"\
|
88
|
+
" #{@payment_method_id.inspect}, payment_properties: #{@payment_properties.inspect}>"
|
76
89
|
end
|
77
90
|
end
|
78
91
|
end
|
@@ -1,9 +1,9 @@
|
|
1
|
-
#
|
1
|
+
# shell_smart_pay_api
|
2
2
|
#
|
3
3
|
# This file was automatically generated by APIMATIC v2.0
|
4
4
|
# ( https://apimatic.io ).
|
5
5
|
|
6
|
-
module
|
6
|
+
module ShellSmartPayApi
|
7
7
|
# PaymentEnablementResponse Model.
|
8
8
|
class PaymentEnablementResponse < BaseModel
|
9
9
|
SKIP = Object.new
|
@@ -44,5 +44,17 @@ module ShellEv
|
|
44
44
|
# Create object from extracted values.
|
45
45
|
PaymentEnablementResponse.new(dpan_last4)
|
46
46
|
end
|
47
|
+
|
48
|
+
# Provides a human-readable string representation of the object.
|
49
|
+
def to_s
|
50
|
+
class_name = self.class.name.split('::').last
|
51
|
+
"<#{class_name} dpan_last4: #{@dpan_last4}>"
|
52
|
+
end
|
53
|
+
|
54
|
+
# Provides a debugging-friendly string with detailed object information.
|
55
|
+
def inspect
|
56
|
+
class_name = self.class.name.split('::').last
|
57
|
+
"<#{class_name} dpan_last4: #{@dpan_last4.inspect}>"
|
58
|
+
end
|
47
59
|
end
|
48
60
|
end
|
@@ -1,9 +1,9 @@
|
|
1
|
-
#
|
1
|
+
# shell_smart_pay_api
|
2
2
|
#
|
3
3
|
# This file was automatically generated by APIMATIC v2.0
|
4
4
|
# ( https://apimatic.io ).
|
5
5
|
|
6
|
-
module
|
6
|
+
module ShellSmartPayApi
|
7
7
|
# Object containing Payment Property details Please note: All the
|
8
8
|
# attributes are optional as they serve all payment methods (i.e. different
|
9
9
|
# payment methods require different fields to be filled/mandated). As a
|
@@ -116,14 +116,9 @@ module ShellEv
|
|
116
116
|
[]
|
117
117
|
end
|
118
118
|
|
119
|
-
def initialize(card_identifier = nil,
|
120
|
-
|
121
|
-
|
122
|
-
token = SKIP,
|
123
|
-
identifier = SKIP,
|
124
|
-
network = SKIP,
|
125
|
-
odometer = SKIP,
|
126
|
-
fleet_id = SKIP,
|
119
|
+
def initialize(card_identifier = nil, payment_type = SKIP,
|
120
|
+
client_metadata_id = SKIP, token = SKIP, identifier = SKIP,
|
121
|
+
network = SKIP, odometer = SKIP, fleet_id = SKIP,
|
127
122
|
external_ref_id = SKIP)
|
128
123
|
@payment_type = payment_type unless payment_type == SKIP
|
129
124
|
@client_metadata_id = client_metadata_id unless client_metadata_id == SKIP
|
@@ -165,5 +160,24 @@ module ShellEv
|
|
165
160
|
fleet_id,
|
166
161
|
external_ref_id)
|
167
162
|
end
|
163
|
+
|
164
|
+
# Provides a human-readable string representation of the object.
|
165
|
+
def to_s
|
166
|
+
class_name = self.class.name.split('::').last
|
167
|
+
"<#{class_name} payment_type: #{@payment_type}, client_metadata_id: #{@client_metadata_id},"\
|
168
|
+
" token: #{@token}, identifier: #{@identifier}, network: #{@network}, card_identifier:"\
|
169
|
+
" #{@card_identifier}, odometer: #{@odometer}, fleet_id: #{@fleet_id}, external_ref_id:"\
|
170
|
+
" #{@external_ref_id}>"
|
171
|
+
end
|
172
|
+
|
173
|
+
# Provides a debugging-friendly string with detailed object information.
|
174
|
+
def inspect
|
175
|
+
class_name = self.class.name.split('::').last
|
176
|
+
"<#{class_name} payment_type: #{@payment_type.inspect}, client_metadata_id:"\
|
177
|
+
" #{@client_metadata_id.inspect}, token: #{@token.inspect}, identifier:"\
|
178
|
+
" #{@identifier.inspect}, network: #{@network.inspect}, card_identifier:"\
|
179
|
+
" #{@card_identifier.inspect}, odometer: #{@odometer.inspect}, fleet_id:"\
|
180
|
+
" #{@fleet_id.inspect}, external_ref_id: #{@external_ref_id.inspect}>"
|
181
|
+
end
|
168
182
|
end
|
169
183
|
end
|
@@ -1,9 +1,9 @@
|
|
1
|
-
#
|
1
|
+
# shell_smart_pay_api
|
2
2
|
#
|
3
3
|
# This file was automatically generated by APIMATIC v2.0
|
4
4
|
# ( https://apimatic.io ).
|
5
5
|
|
6
|
-
module
|
6
|
+
module ShellSmartPayApi
|
7
7
|
# PrepareFuelingRequest Model.
|
8
8
|
class PrepareFuelingRequest < BaseModel
|
9
9
|
SKIP = Object.new
|
@@ -62,11 +62,11 @@ module ShellEv
|
|
62
62
|
attr_accessor :device_type
|
63
63
|
|
64
64
|
# Object containing Payment details
|
65
|
-
# @return [
|
65
|
+
# @return [PaymentDetails]
|
66
66
|
attr_accessor :payment_details
|
67
67
|
|
68
68
|
# Object containing device details
|
69
|
-
# @return [Array[
|
69
|
+
# @return [Array[DeviceDetail]]
|
70
70
|
attr_accessor :device_details
|
71
71
|
|
72
72
|
# A mapping from model property names to API property names.
|
@@ -100,15 +100,10 @@ module ShellEv
|
|
100
100
|
[]
|
101
101
|
end
|
102
102
|
|
103
|
-
def initialize(latitude = nil,
|
104
|
-
|
105
|
-
|
106
|
-
|
107
|
-
source_application = nil,
|
108
|
-
payment_details = nil,
|
109
|
-
maximum_fueling_amount = SKIP,
|
110
|
-
loyalty_details = SKIP,
|
111
|
-
device_type = SKIP,
|
103
|
+
def initialize(latitude = nil, longitude = nil, station_id = nil,
|
104
|
+
pump_id = nil, source_application = nil,
|
105
|
+
payment_details = nil, maximum_fueling_amount = SKIP,
|
106
|
+
loyalty_details = SKIP, device_type = SKIP,
|
112
107
|
device_details = SKIP)
|
113
108
|
@latitude = latitude
|
114
109
|
@longitude = longitude
|
@@ -133,16 +128,7 @@ module ShellEv
|
|
133
128
|
pump_id = hash.key?('pumpId') ? hash['pumpId'] : nil
|
134
129
|
source_application =
|
135
130
|
hash.key?('sourceApplication') ? hash['sourceApplication'] : nil
|
136
|
-
|
137
|
-
payment_details = nil
|
138
|
-
unless hash['paymentDetails'].nil?
|
139
|
-
payment_details = []
|
140
|
-
hash['paymentDetails'].each do |structure|
|
141
|
-
payment_details << (PaymentDetailsItems.from_hash(structure) if structure)
|
142
|
-
end
|
143
|
-
end
|
144
|
-
|
145
|
-
payment_details = nil unless hash.key?('paymentDetails')
|
131
|
+
payment_details = PaymentDetails.from_hash(hash['paymentDetails']) if hash['paymentDetails']
|
146
132
|
maximum_fueling_amount =
|
147
133
|
hash.key?('maximumFuelingAmount') ? hash['maximumFuelingAmount'] : SKIP
|
148
134
|
# Parameter is an array, so we need to iterate through it
|
@@ -161,7 +147,7 @@ module ShellEv
|
|
161
147
|
unless hash['deviceDetails'].nil?
|
162
148
|
device_details = []
|
163
149
|
hash['deviceDetails'].each do |structure|
|
164
|
-
device_details << (
|
150
|
+
device_details << (DeviceDetail.from_hash(structure) if structure)
|
165
151
|
end
|
166
152
|
end
|
167
153
|
|
@@ -179,5 +165,26 @@ module ShellEv
|
|
179
165
|
device_type,
|
180
166
|
device_details)
|
181
167
|
end
|
168
|
+
|
169
|
+
# Provides a human-readable string representation of the object.
|
170
|
+
def to_s
|
171
|
+
class_name = self.class.name.split('::').last
|
172
|
+
"<#{class_name} latitude: #{@latitude}, longitude: #{@longitude}, maximum_fueling_amount:"\
|
173
|
+
" #{@maximum_fueling_amount}, station_id: #{@station_id}, pump_id: #{@pump_id},"\
|
174
|
+
" loyalty_details: #{@loyalty_details}, source_application: #{@source_application},"\
|
175
|
+
" device_type: #{@device_type}, payment_details: #{@payment_details}, device_details:"\
|
176
|
+
" #{@device_details}>"
|
177
|
+
end
|
178
|
+
|
179
|
+
# Provides a debugging-friendly string with detailed object information.
|
180
|
+
def inspect
|
181
|
+
class_name = self.class.name.split('::').last
|
182
|
+
"<#{class_name} latitude: #{@latitude.inspect}, longitude: #{@longitude.inspect},"\
|
183
|
+
" maximum_fueling_amount: #{@maximum_fueling_amount.inspect}, station_id:"\
|
184
|
+
" #{@station_id.inspect}, pump_id: #{@pump_id.inspect}, loyalty_details:"\
|
185
|
+
" #{@loyalty_details.inspect}, source_application: #{@source_application.inspect},"\
|
186
|
+
" device_type: #{@device_type.inspect}, payment_details: #{@payment_details.inspect},"\
|
187
|
+
" device_details: #{@device_details.inspect}>"
|
188
|
+
end
|
182
189
|
end
|
183
190
|
end
|
@@ -1,9 +1,9 @@
|
|
1
|
-
#
|
1
|
+
# shell_smart_pay_api
|
2
2
|
#
|
3
3
|
# This file was automatically generated by APIMATIC v2.0
|
4
4
|
# ( https://apimatic.io ).
|
5
5
|
|
6
|
-
module
|
6
|
+
module ShellSmartPayApi
|
7
7
|
# The response of prepare fueling returns
|
8
8
|
class PrepareFuelingResponse < BaseModel
|
9
9
|
SKIP = Object.new
|
@@ -43,8 +43,7 @@ module ShellEv
|
|
43
43
|
[]
|
44
44
|
end
|
45
45
|
|
46
|
-
def initialize(mpp_transaction_id = nil,
|
47
|
-
products = SKIP)
|
46
|
+
def initialize(mpp_transaction_id = nil, products = SKIP)
|
48
47
|
@mpp_transaction_id = mpp_transaction_id
|
49
48
|
@products = products unless products == SKIP
|
50
49
|
end
|
@@ -62,5 +61,18 @@ module ShellEv
|
|
62
61
|
PrepareFuelingResponse.new(mpp_transaction_id,
|
63
62
|
products)
|
64
63
|
end
|
64
|
+
|
65
|
+
# Provides a human-readable string representation of the object.
|
66
|
+
def to_s
|
67
|
+
class_name = self.class.name.split('::').last
|
68
|
+
"<#{class_name} mpp_transaction_id: #{@mpp_transaction_id}, products: #{@products}>"
|
69
|
+
end
|
70
|
+
|
71
|
+
# Provides a debugging-friendly string with detailed object information.
|
72
|
+
def inspect
|
73
|
+
class_name = self.class.name.split('::').last
|
74
|
+
"<#{class_name} mpp_transaction_id: #{@mpp_transaction_id.inspect}, products:"\
|
75
|
+
" #{@products.inspect}>"
|
76
|
+
end
|
65
77
|
end
|
66
78
|
end
|
@@ -1,11 +1,11 @@
|
|
1
|
-
#
|
1
|
+
# shell_smart_pay_api
|
2
2
|
#
|
3
3
|
# This file was automatically generated by APIMATIC v2.0
|
4
4
|
# ( https://apimatic.io ).
|
5
5
|
|
6
|
-
module
|
7
|
-
#
|
8
|
-
class
|
6
|
+
module ShellSmartPayApi
|
7
|
+
# Product Model.
|
8
|
+
class Product < BaseModel
|
9
9
|
SKIP = Object.new
|
10
10
|
private_constant :SKIP
|
11
11
|
|
@@ -44,9 +44,7 @@ module ShellEv
|
|
44
44
|
[]
|
45
45
|
end
|
46
46
|
|
47
|
-
def initialize(product_id = SKIP,
|
48
|
-
product_name = SKIP,
|
49
|
-
unit_price = SKIP)
|
47
|
+
def initialize(product_id = SKIP, product_name = SKIP, unit_price = SKIP)
|
50
48
|
@product_id = product_id unless product_id == SKIP
|
51
49
|
@product_name = product_name unless product_name == SKIP
|
52
50
|
@unit_price = unit_price unless unit_price == SKIP
|
@@ -62,9 +60,23 @@ module ShellEv
|
|
62
60
|
unit_price = hash.key?('unitPrice') ? hash['unitPrice'] : SKIP
|
63
61
|
|
64
62
|
# Create object from extracted values.
|
65
|
-
|
66
|
-
|
67
|
-
|
63
|
+
Product.new(product_id,
|
64
|
+
product_name,
|
65
|
+
unit_price)
|
66
|
+
end
|
67
|
+
|
68
|
+
# Provides a human-readable string representation of the object.
|
69
|
+
def to_s
|
70
|
+
class_name = self.class.name.split('::').last
|
71
|
+
"<#{class_name} product_id: #{@product_id}, product_name: #{@product_name}, unit_price:"\
|
72
|
+
" #{@unit_price}>"
|
73
|
+
end
|
74
|
+
|
75
|
+
# Provides a debugging-friendly string with detailed object information.
|
76
|
+
def inspect
|
77
|
+
class_name = self.class.name.split('::').last
|
78
|
+
"<#{class_name} product_id: #{@product_id.inspect}, product_name: #{@product_name.inspect},"\
|
79
|
+
" unit_price: #{@unit_price.inspect}>"
|
68
80
|
end
|
69
81
|
end
|
70
82
|
end
|
@@ -1,10 +1,10 @@
|
|
1
|
-
#
|
1
|
+
# shell_smart_pay_api
|
2
2
|
#
|
3
3
|
# This file was automatically generated by APIMATIC v2.0
|
4
4
|
# ( https://apimatic.io ).
|
5
5
|
|
6
6
|
require 'date'
|
7
|
-
module
|
7
|
+
module ShellSmartPayApi
|
8
8
|
# A utility that supports dateTime conversion to different formats
|
9
9
|
class DateTimeHelper < CoreLibrary::DateTimeHelper
|
10
10
|
end
|
@@ -0,0 +1,28 @@
|
|
1
|
+
# shell_smart_pay_api
|
2
|
+
#
|
3
|
+
# This file was automatically generated by APIMATIC v2.0
|
4
|
+
# ( https://apimatic.io ).
|
5
|
+
|
6
|
+
module ShellSmartPayApi
|
7
|
+
# A utility to allow users to set the content-type for files
|
8
|
+
class FileWrapper < CoreLibrary::FileWrapper
|
9
|
+
# The constructor.
|
10
|
+
# @param [File] file The file to be sent in the request.
|
11
|
+
# @param [string] content_type The content type of the provided file.
|
12
|
+
def initialize(file, content_type: 'application/octet-stream')
|
13
|
+
super
|
14
|
+
end
|
15
|
+
|
16
|
+
# Provides a human-readable string representation of the object.
|
17
|
+
def to_s
|
18
|
+
class_name = self.class.name.split('::').last
|
19
|
+
"<#{class_name} file: #{@file}, content_type: #{@content_type}>"
|
20
|
+
end
|
21
|
+
|
22
|
+
# Provides a debugging-friendly string with detailed object information.
|
23
|
+
def to_inspect
|
24
|
+
class_name = self.class.name.split('::').last
|
25
|
+
"<#{class_name} file: #{@file.inspect}, content_type: #{@content_type.inspect}>"
|
26
|
+
end
|
27
|
+
end
|
28
|
+
end
|
@@ -0,0 +1,89 @@
|
|
1
|
+
# shell_smart_pay_api
|
2
|
+
#
|
3
|
+
# This file was automatically generated by APIMATIC v2.0
|
4
|
+
# ( https://apimatic.io ).
|
5
|
+
|
6
|
+
require 'date'
|
7
|
+
require 'json'
|
8
|
+
|
9
|
+
require 'apimatic_core_interfaces'
|
10
|
+
require 'apimatic_core'
|
11
|
+
require 'apimatic_faraday_client_adapter'
|
12
|
+
|
13
|
+
require_relative 'shell_smart_pay_api/api_helper'
|
14
|
+
require_relative 'shell_smart_pay_api/client'
|
15
|
+
|
16
|
+
# Utilities
|
17
|
+
require_relative 'shell_smart_pay_api/utilities/file_wrapper'
|
18
|
+
require_relative 'shell_smart_pay_api/utilities/date_time_helper'
|
19
|
+
|
20
|
+
# Http
|
21
|
+
require_relative 'shell_smart_pay_api/http/http_call_back'
|
22
|
+
require_relative 'shell_smart_pay_api/http/http_method_enum'
|
23
|
+
require_relative 'shell_smart_pay_api/http/http_request'
|
24
|
+
require_relative 'shell_smart_pay_api/http/http_response'
|
25
|
+
|
26
|
+
# Logger
|
27
|
+
require_relative 'shell_smart_pay_api/http/auth/mpp_token'
|
28
|
+
require_relative 'shell_smart_pay_api/http/auth/o_auth_token_post'
|
29
|
+
|
30
|
+
# Models
|
31
|
+
require_relative 'shell_smart_pay_api/models/base_model'
|
32
|
+
require_relative 'shell_smart_pay_api/models/collecting_company'
|
33
|
+
require_relative 'shell_smart_pay_api/models/' \
|
34
|
+
'mobile_payment_registration_request'
|
35
|
+
require_relative 'shell_smart_pay_api/models/around_location_array'
|
36
|
+
require_relative 'shell_smart_pay_api/models/payment_enablement_response'
|
37
|
+
require_relative 'shell_smart_pay_api/models/access_token_response'
|
38
|
+
require_relative 'shell_smart_pay_api/models/mpp_acces_token_response'
|
39
|
+
require_relative 'shell_smart_pay_api/models/prepare_fueling_request'
|
40
|
+
require_relative 'shell_smart_pay_api/models/loyalty_details'
|
41
|
+
require_relative 'shell_smart_pay_api/models/payment_details'
|
42
|
+
require_relative 'shell_smart_pay_api/models/payment_properties'
|
43
|
+
require_relative 'shell_smart_pay_api/models/prepare_fueling_response'
|
44
|
+
require_relative 'shell_smart_pay_api/models/cancel_fueling_error_response'
|
45
|
+
require_relative 'shell_smart_pay_api/models/mpp_error'
|
46
|
+
require_relative 'shell_smart_pay_api/models/fault_response'
|
47
|
+
require_relative 'shell_smart_pay_api/models/finalise_fueling_request'
|
48
|
+
require_relative 'shell_smart_pay_api/models/cancel_fueling_request'
|
49
|
+
require_relative 'shell_smart_pay_api/models/datum'
|
50
|
+
require_relative 'shell_smart_pay_api/models/detail'
|
51
|
+
require_relative 'shell_smart_pay_api/models/device_detail'
|
52
|
+
require_relative 'shell_smart_pay_api/models/fault'
|
53
|
+
require_relative 'shell_smart_pay_api/models/loc'
|
54
|
+
require_relative 'shell_smart_pay_api/models/opening_hour'
|
55
|
+
require_relative 'shell_smart_pay_api/models/payment'
|
56
|
+
require_relative 'shell_smart_pay_api/models/product'
|
57
|
+
|
58
|
+
# Exceptions
|
59
|
+
require_relative 'shell_smart_pay_api/exceptions/api_exception'
|
60
|
+
require_relative 'shell_smart_pay_api/exceptions/' \
|
61
|
+
'payment_enablement_error_response_exception'
|
62
|
+
require_relative 'shell_smart_pay_api/exceptions/access_token_error_exception'
|
63
|
+
require_relative 'shell_smart_pay_api/exceptions/' \
|
64
|
+
'mpp_acces_token_error_response_exception'
|
65
|
+
require_relative 'shell_smart_pay_api/exceptions/' \
|
66
|
+
'station_locator_unauthorized_exception'
|
67
|
+
require_relative 'shell_smart_pay_api/exceptions/' \
|
68
|
+
'station_locator_bad_request_exception'
|
69
|
+
require_relative 'shell_smart_pay_api/exceptions/' \
|
70
|
+
'station_locator_not_found_exception'
|
71
|
+
require_relative 'shell_smart_pay_api/exceptions/' \
|
72
|
+
'station_locator_forbidden_exception'
|
73
|
+
require_relative 'shell_smart_pay_api/exceptions/' \
|
74
|
+
'station_locator_internal_server_error_exception'
|
75
|
+
require_relative 'shell_smart_pay_api/exceptions/' \
|
76
|
+
'cancel_fueling_error_response_error_exception'
|
77
|
+
|
78
|
+
require_relative 'shell_smart_pay_api/configuration'
|
79
|
+
|
80
|
+
# Controllers
|
81
|
+
require_relative 'shell_smart_pay_api/controllers/base_controller'
|
82
|
+
require_relative 'shell_smart_pay_api/controllers/' \
|
83
|
+
'shell_api_platform_security_authentication_controller'
|
84
|
+
require_relative 'shell_smart_pay_api/controllers/' \
|
85
|
+
'digital_payment_enablement_controller'
|
86
|
+
require_relative 'shell_smart_pay_api/controllers/station_locator_controller'
|
87
|
+
require_relative 'shell_smart_pay_api/controllers/fueling_controller'
|
88
|
+
require_relative 'shell_smart_pay_api/controllers/' \
|
89
|
+
'partner_notification_controller'
|
@@ -1,4 +1,4 @@
|
|
1
|
-
#
|
1
|
+
# shell_smart_pay_api
|
2
2
|
#
|
3
3
|
# This file was automatically generated by APIMATIC v2.0
|
4
4
|
# ( https://apimatic.io ).
|
@@ -8,12 +8,12 @@ require 'minitest/autorun'
|
|
8
8
|
require 'minitest/hell'
|
9
9
|
require 'minitest/pride'
|
10
10
|
require 'minitest/proveit'
|
11
|
-
require '
|
11
|
+
require 'shell_smart_pay_api'
|
12
12
|
require_relative '../http_response_catcher'
|
13
13
|
|
14
14
|
class ControllerTestBase < Minitest::Test
|
15
15
|
parallelize_me!
|
16
|
-
include
|
16
|
+
include ShellSmartPayApi
|
17
17
|
include CoreLibrary
|
18
18
|
|
19
19
|
# Create configuration and set any test parameters
|
@@ -1,9 +1,9 @@
|
|
1
|
-
#
|
1
|
+
# shell_smart_pay_api
|
2
2
|
#
|
3
3
|
# This file was automatically generated by APIMATIC v2.0
|
4
4
|
# ( https://apimatic.io ).
|
5
5
|
|
6
|
-
class HttpResponseCatcher <
|
6
|
+
class HttpResponseCatcher < ShellSmartPayApi::HttpCallBack
|
7
7
|
attr_accessor :response
|
8
8
|
|
9
9
|
def on_before_request(request)
|