direct-sdk-ruby 1.0.0 → 1.4.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/direct-sdk-ruby.gemspec +1 -1
- data/lib/ingenico/direct/sdk/domain/airline_flight_leg.rb +4 -0
- data/lib/ingenico/direct/sdk/domain/browser_data.rb +4 -0
- data/lib/ingenico/direct/sdk/domain/card_essentials.rb +4 -0
- data/lib/ingenico/direct/sdk/domain/card_payment_method_specific_input.rb +8 -4
- data/lib/ingenico/direct/sdk/domain/card_payment_method_specific_input_base.rb +8 -0
- data/lib/ingenico/direct/sdk/domain/create_hosted_checkout_request.rb +8 -0
- data/lib/ingenico/direct/sdk/domain/get_iin_details_request.rb +35 -0
- data/lib/ingenico/direct/sdk/domain/get_iin_details_response.rb +46 -0
- data/lib/ingenico/direct/sdk/domain/hosted_checkout_specific_input.rb +4 -0
- data/lib/ingenico/direct/sdk/domain/iin_detail.rb +31 -0
- data/lib/ingenico/direct/sdk/domain/mobile_payment_method_hosted_checkout_specific_input.rb +31 -0
- data/lib/ingenico/direct/sdk/domain/payment_context.rb +39 -0
- data/lib/ingenico/direct/sdk/domain/payment_product.rb +16 -0
- data/lib/ingenico/direct/sdk/domain/payment_product130_specific_input.rb +31 -0
- data/lib/ingenico/direct/sdk/domain/payment_product130_specific_three_d_secure.rb +39 -0
- data/lib/ingenico/direct/sdk/domain/payment_product302_specific_data.rb +33 -0
- data/lib/ingenico/direct/sdk/domain/payment_product320_specific_data.rb +37 -0
- data/lib/ingenico/direct/sdk/domain/shipping.rb +8 -0
- data/lib/ingenico/direct/sdk/domain/three_d_secure.rb +12 -0
- data/lib/ingenico/direct/sdk/domain/three_d_secure_base.rb +12 -0
- data/lib/ingenico/direct/sdk/domain/token_response.rb +4 -0
- data/lib/ingenico/direct/sdk/merchant/merchant_client.rb +1 -1
- data/lib/ingenico/direct/sdk/merchant/services/services_client.rb +31 -0
- metadata +11 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: c933150f36817b801e1ca95cfbd4e2f55ebecde7b843e10b3f18590fe4bd65f5
|
4
|
+
data.tar.gz: accf2bc8adb754003c10e72f74849a94c79d40527f48e7f308c0e7711a254739
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 203b8b5feaeac54348d64f5d010a49ec0f21d54f3094445e2a46c6625e1ea6712e551271d15901f8bab88c92e7dd483dbdb059e7692b2d1ce3501a909376150c
|
7
|
+
data.tar.gz: 90361436cf6fb2dd8f6a6c219a6538587524e8412dabbf7364d6798ac1a65bcd39cc4255497bdfeb060ad57bf527a0f6b798f360313f4369e560334c7eb4ec2c
|
data/direct-sdk-ruby.gemspec
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
Gem::Specification.new do |spec|
|
2
2
|
spec.name = 'direct-sdk-ruby'
|
3
|
-
spec.version = '1.
|
3
|
+
spec.version = '1.4.0'
|
4
4
|
spec.authors = ['Ingenico ePayments']
|
5
5
|
spec.email = ['60233882+ingenico-dev-team@users.noreply.github.com']
|
6
6
|
spec.summary = %q{SDK to communicate with the Ingenico ePayments platform using the Ingenico Direct Server API}
|
@@ -21,6 +21,7 @@ module Ingenico::Direct::SDK
|
|
21
21
|
# @attr [String] fare_basis
|
22
22
|
# @attr [Integer] fee
|
23
23
|
# @attr [String] flight_number
|
24
|
+
# @attr [Integer] leg_fare
|
24
25
|
# @attr [Integer] number
|
25
26
|
# @attr [String] origin_airport
|
26
27
|
# @attr [String] passenger_class
|
@@ -41,6 +42,7 @@ module Ingenico::Direct::SDK
|
|
41
42
|
attr_accessor :fare_basis
|
42
43
|
attr_accessor :fee
|
43
44
|
attr_accessor :flight_number
|
45
|
+
attr_accessor :leg_fare
|
44
46
|
attr_accessor :number
|
45
47
|
attr_accessor :origin_airport
|
46
48
|
attr_accessor :passenger_class
|
@@ -64,6 +66,7 @@ module Ingenico::Direct::SDK
|
|
64
66
|
hash['fareBasis'] = @fare_basis unless @fare_basis.nil?
|
65
67
|
hash['fee'] = @fee unless @fee.nil?
|
66
68
|
hash['flightNumber'] = @flight_number unless @flight_number.nil?
|
69
|
+
hash['legFare'] = @leg_fare unless @leg_fare.nil?
|
67
70
|
hash['number'] = @number unless @number.nil?
|
68
71
|
hash['originAirport'] = @origin_airport unless @origin_airport.nil?
|
69
72
|
hash['passengerClass'] = @passenger_class unless @passenger_class.nil?
|
@@ -88,6 +91,7 @@ module Ingenico::Direct::SDK
|
|
88
91
|
@fare_basis = hash['fareBasis'] if hash.key? 'fareBasis'
|
89
92
|
@fee = hash['fee'] if hash.key? 'fee'
|
90
93
|
@flight_number = hash['flightNumber'] if hash.key? 'flightNumber'
|
94
|
+
@leg_fare = hash['legFare'] if hash.key? 'legFare'
|
91
95
|
@number = hash['number'] if hash.key? 'number'
|
92
96
|
@origin_airport = hash['originAirport'] if hash.key? 'originAirport'
|
93
97
|
@passenger_class = hash['passengerClass'] if hash.key? 'passengerClass'
|
@@ -9,11 +9,13 @@ module Ingenico::Direct::SDK
|
|
9
9
|
|
10
10
|
# @attr [Integer] color_depth
|
11
11
|
# @attr [true/false] java_enabled
|
12
|
+
# @attr [true/false] java_script_enabled
|
12
13
|
# @attr [String] screen_height
|
13
14
|
# @attr [String] screen_width
|
14
15
|
class BrowserData < Ingenico::Direct::SDK::DataObject
|
15
16
|
attr_accessor :color_depth
|
16
17
|
attr_accessor :java_enabled
|
18
|
+
attr_accessor :java_script_enabled
|
17
19
|
attr_accessor :screen_height
|
18
20
|
attr_accessor :screen_width
|
19
21
|
|
@@ -22,6 +24,7 @@ module Ingenico::Direct::SDK
|
|
22
24
|
hash = super
|
23
25
|
hash['colorDepth'] = @color_depth unless @color_depth.nil?
|
24
26
|
hash['javaEnabled'] = @java_enabled unless @java_enabled.nil?
|
27
|
+
hash['javaScriptEnabled'] = @java_script_enabled unless @java_script_enabled.nil?
|
25
28
|
hash['screenHeight'] = @screen_height unless @screen_height.nil?
|
26
29
|
hash['screenWidth'] = @screen_width unless @screen_width.nil?
|
27
30
|
hash
|
@@ -31,6 +34,7 @@ module Ingenico::Direct::SDK
|
|
31
34
|
super
|
32
35
|
@color_depth = hash['colorDepth'] if hash.key? 'colorDepth'
|
33
36
|
@java_enabled = hash['javaEnabled'] if hash.key? 'javaEnabled'
|
37
|
+
@java_script_enabled = hash['javaScriptEnabled'] if hash.key? 'javaScriptEnabled'
|
34
38
|
@screen_height = hash['screenHeight'] if hash.key? 'screenHeight'
|
35
39
|
@screen_width = hash['screenWidth'] if hash.key? 'screenWidth'
|
36
40
|
end
|
@@ -7,15 +7,18 @@ require 'ingenico/direct/sdk/data_object'
|
|
7
7
|
module Ingenico::Direct::SDK
|
8
8
|
module Domain
|
9
9
|
|
10
|
+
# @attr [String] bin
|
10
11
|
# @attr [String] card_number
|
11
12
|
# @attr [String] expiry_date
|
12
13
|
class CardEssentials < Ingenico::Direct::SDK::DataObject
|
14
|
+
attr_accessor :bin
|
13
15
|
attr_accessor :card_number
|
14
16
|
attr_accessor :expiry_date
|
15
17
|
|
16
18
|
# @return (Hash)
|
17
19
|
def to_h
|
18
20
|
hash = super
|
21
|
+
hash['bin'] = @bin unless @bin.nil?
|
19
22
|
hash['cardNumber'] = @card_number unless @card_number.nil?
|
20
23
|
hash['expiryDate'] = @expiry_date unless @expiry_date.nil?
|
21
24
|
hash
|
@@ -23,6 +26,7 @@ module Ingenico::Direct::SDK
|
|
23
26
|
|
24
27
|
def from_hash(hash)
|
25
28
|
super
|
29
|
+
@bin = hash['bin'] if hash.key? 'bin'
|
26
30
|
@card_number = hash['cardNumber'] if hash.key? 'cardNumber'
|
27
31
|
@expiry_date = hash['expiryDate'] if hash.key? 'expiryDate'
|
28
32
|
end
|
@@ -5,6 +5,7 @@
|
|
5
5
|
require 'ingenico/direct/sdk/data_object'
|
6
6
|
require 'ingenico/direct/sdk/domain/card'
|
7
7
|
require 'ingenico/direct/sdk/domain/card_recurrence_details'
|
8
|
+
require 'ingenico/direct/sdk/domain/payment_product130_specific_input'
|
8
9
|
require 'ingenico/direct/sdk/domain/three_d_secure'
|
9
10
|
|
10
11
|
module Ingenico::Direct::SDK
|
@@ -14,11 +15,11 @@ module Ingenico::Direct::SDK
|
|
14
15
|
# @attr [Ingenico::Direct::SDK::Domain::Card] card
|
15
16
|
# @attr [String] initial_scheme_transaction_id
|
16
17
|
# @attr [true/false] is_recurring
|
18
|
+
# @attr [Ingenico::Direct::SDK::Domain::PaymentProduct130SpecificInput] payment_product130_specific_input
|
17
19
|
# @attr [Integer] payment_product_id
|
18
20
|
# @attr [Ingenico::Direct::SDK::Domain::CardRecurrenceDetails] recurring
|
19
21
|
# @attr [String] return_url
|
20
22
|
# @attr [true/false] skip_authentication
|
21
|
-
# @attr [true/false] skip_soft_decline
|
22
23
|
# @attr [Ingenico::Direct::SDK::Domain::ThreeDSecure] three_d_secure
|
23
24
|
# @attr [String] token
|
24
25
|
# @attr [true/false] tokenize
|
@@ -30,11 +31,11 @@ module Ingenico::Direct::SDK
|
|
30
31
|
attr_accessor :card
|
31
32
|
attr_accessor :initial_scheme_transaction_id
|
32
33
|
attr_accessor :is_recurring
|
34
|
+
attr_accessor :payment_product130_specific_input
|
33
35
|
attr_accessor :payment_product_id
|
34
36
|
attr_accessor :recurring
|
35
37
|
attr_accessor :return_url
|
36
38
|
attr_accessor :skip_authentication
|
37
|
-
attr_accessor :skip_soft_decline
|
38
39
|
attr_accessor :three_d_secure
|
39
40
|
attr_accessor :token
|
40
41
|
attr_accessor :tokenize
|
@@ -49,11 +50,11 @@ module Ingenico::Direct::SDK
|
|
49
50
|
hash['card'] = @card.to_h if @card
|
50
51
|
hash['initialSchemeTransactionId'] = @initial_scheme_transaction_id unless @initial_scheme_transaction_id.nil?
|
51
52
|
hash['isRecurring'] = @is_recurring unless @is_recurring.nil?
|
53
|
+
hash['paymentProduct130SpecificInput'] = @payment_product130_specific_input.to_h if @payment_product130_specific_input
|
52
54
|
hash['paymentProductId'] = @payment_product_id unless @payment_product_id.nil?
|
53
55
|
hash['recurring'] = @recurring.to_h if @recurring
|
54
56
|
hash['returnUrl'] = @return_url unless @return_url.nil?
|
55
57
|
hash['skipAuthentication'] = @skip_authentication unless @skip_authentication.nil?
|
56
|
-
hash['skipSoftDecline'] = @skip_soft_decline unless @skip_soft_decline.nil?
|
57
58
|
hash['threeDSecure'] = @three_d_secure.to_h if @three_d_secure
|
58
59
|
hash['token'] = @token unless @token.nil?
|
59
60
|
hash['tokenize'] = @tokenize unless @tokenize.nil?
|
@@ -72,6 +73,10 @@ module Ingenico::Direct::SDK
|
|
72
73
|
end
|
73
74
|
@initial_scheme_transaction_id = hash['initialSchemeTransactionId'] if hash.key? 'initialSchemeTransactionId'
|
74
75
|
@is_recurring = hash['isRecurring'] if hash.key? 'isRecurring'
|
76
|
+
if hash.key? 'paymentProduct130SpecificInput'
|
77
|
+
raise TypeError, "value '%s' is not a Hash" % [hash['paymentProduct130SpecificInput']] unless hash['paymentProduct130SpecificInput'].is_a? Hash
|
78
|
+
@payment_product130_specific_input = Ingenico::Direct::SDK::Domain::PaymentProduct130SpecificInput.new_from_hash(hash['paymentProduct130SpecificInput'])
|
79
|
+
end
|
75
80
|
@payment_product_id = hash['paymentProductId'] if hash.key? 'paymentProductId'
|
76
81
|
if hash.key? 'recurring'
|
77
82
|
raise TypeError, "value '%s' is not a Hash" % [hash['recurring']] unless hash['recurring'].is_a? Hash
|
@@ -79,7 +84,6 @@ module Ingenico::Direct::SDK
|
|
79
84
|
end
|
80
85
|
@return_url = hash['returnUrl'] if hash.key? 'returnUrl'
|
81
86
|
@skip_authentication = hash['skipAuthentication'] if hash.key? 'skipAuthentication'
|
82
|
-
@skip_soft_decline = hash['skipSoftDecline'] if hash.key? 'skipSoftDecline'
|
83
87
|
if hash.key? 'threeDSecure'
|
84
88
|
raise TypeError, "value '%s' is not a Hash" % [hash['threeDSecure']] unless hash['threeDSecure'].is_a? Hash
|
85
89
|
@three_d_secure = Ingenico::Direct::SDK::Domain::ThreeDSecure.new_from_hash(hash['threeDSecure'])
|
@@ -4,6 +4,7 @@
|
|
4
4
|
#
|
5
5
|
require 'ingenico/direct/sdk/data_object'
|
6
6
|
require 'ingenico/direct/sdk/domain/card_recurrence_details'
|
7
|
+
require 'ingenico/direct/sdk/domain/payment_product130_specific_input'
|
7
8
|
require 'ingenico/direct/sdk/domain/payment_product5100_specific_input'
|
8
9
|
require 'ingenico/direct/sdk/domain/three_d_secure_base'
|
9
10
|
|
@@ -12,6 +13,7 @@ module Ingenico::Direct::SDK
|
|
12
13
|
|
13
14
|
# @attr [String] authorization_mode
|
14
15
|
# @attr [String] initial_scheme_transaction_id
|
16
|
+
# @attr [Ingenico::Direct::SDK::Domain::PaymentProduct130SpecificInput] payment_product130_specific_input
|
15
17
|
# @attr [Ingenico::Direct::SDK::Domain::PaymentProduct5100SpecificInput] payment_product5100_specific_input
|
16
18
|
# @attr [Integer] payment_product_id
|
17
19
|
# @attr [Ingenico::Direct::SDK::Domain::CardRecurrenceDetails] recurring
|
@@ -24,6 +26,7 @@ module Ingenico::Direct::SDK
|
|
24
26
|
class CardPaymentMethodSpecificInputBase < Ingenico::Direct::SDK::DataObject
|
25
27
|
attr_accessor :authorization_mode
|
26
28
|
attr_accessor :initial_scheme_transaction_id
|
29
|
+
attr_accessor :payment_product130_specific_input
|
27
30
|
attr_accessor :payment_product5100_specific_input
|
28
31
|
attr_accessor :payment_product_id
|
29
32
|
attr_accessor :recurring
|
@@ -39,6 +42,7 @@ module Ingenico::Direct::SDK
|
|
39
42
|
hash = super
|
40
43
|
hash['authorizationMode'] = @authorization_mode unless @authorization_mode.nil?
|
41
44
|
hash['initialSchemeTransactionId'] = @initial_scheme_transaction_id unless @initial_scheme_transaction_id.nil?
|
45
|
+
hash['paymentProduct130SpecificInput'] = @payment_product130_specific_input.to_h if @payment_product130_specific_input
|
42
46
|
hash['paymentProduct5100SpecificInput'] = @payment_product5100_specific_input.to_h if @payment_product5100_specific_input
|
43
47
|
hash['paymentProductId'] = @payment_product_id unless @payment_product_id.nil?
|
44
48
|
hash['recurring'] = @recurring.to_h if @recurring
|
@@ -55,6 +59,10 @@ module Ingenico::Direct::SDK
|
|
55
59
|
super
|
56
60
|
@authorization_mode = hash['authorizationMode'] if hash.key? 'authorizationMode'
|
57
61
|
@initial_scheme_transaction_id = hash['initialSchemeTransactionId'] if hash.key? 'initialSchemeTransactionId'
|
62
|
+
if hash.key? 'paymentProduct130SpecificInput'
|
63
|
+
raise TypeError, "value '%s' is not a Hash" % [hash['paymentProduct130SpecificInput']] unless hash['paymentProduct130SpecificInput'].is_a? Hash
|
64
|
+
@payment_product130_specific_input = Ingenico::Direct::SDK::Domain::PaymentProduct130SpecificInput.new_from_hash(hash['paymentProduct130SpecificInput'])
|
65
|
+
end
|
58
66
|
if hash.key? 'paymentProduct5100SpecificInput'
|
59
67
|
raise TypeError, "value '%s' is not a Hash" % [hash['paymentProduct5100SpecificInput']] unless hash['paymentProduct5100SpecificInput'].is_a? Hash
|
60
68
|
@payment_product5100_specific_input = Ingenico::Direct::SDK::Domain::PaymentProduct5100SpecificInput.new_from_hash(hash['paymentProduct5100SpecificInput'])
|
@@ -6,6 +6,7 @@ require 'ingenico/direct/sdk/data_object'
|
|
6
6
|
require 'ingenico/direct/sdk/domain/card_payment_method_specific_input_base'
|
7
7
|
require 'ingenico/direct/sdk/domain/fraud_fields'
|
8
8
|
require 'ingenico/direct/sdk/domain/hosted_checkout_specific_input'
|
9
|
+
require 'ingenico/direct/sdk/domain/mobile_payment_method_hosted_checkout_specific_input'
|
9
10
|
require 'ingenico/direct/sdk/domain/order'
|
10
11
|
require 'ingenico/direct/sdk/domain/redirect_payment_method_specific_input'
|
11
12
|
|
@@ -15,12 +16,14 @@ module Ingenico::Direct::SDK
|
|
15
16
|
# @attr [Ingenico::Direct::SDK::Domain::CardPaymentMethodSpecificInputBase] card_payment_method_specific_input
|
16
17
|
# @attr [Ingenico::Direct::SDK::Domain::FraudFields] fraud_fields
|
17
18
|
# @attr [Ingenico::Direct::SDK::Domain::HostedCheckoutSpecificInput] hosted_checkout_specific_input
|
19
|
+
# @attr [Ingenico::Direct::SDK::Domain::MobilePaymentMethodHostedCheckoutSpecificInput] mobile_payment_method_specific_input
|
18
20
|
# @attr [Ingenico::Direct::SDK::Domain::Order] order
|
19
21
|
# @attr [Ingenico::Direct::SDK::Domain::RedirectPaymentMethodSpecificInput] redirect_payment_method_specific_input
|
20
22
|
class CreateHostedCheckoutRequest < Ingenico::Direct::SDK::DataObject
|
21
23
|
attr_accessor :card_payment_method_specific_input
|
22
24
|
attr_accessor :fraud_fields
|
23
25
|
attr_accessor :hosted_checkout_specific_input
|
26
|
+
attr_accessor :mobile_payment_method_specific_input
|
24
27
|
attr_accessor :order
|
25
28
|
attr_accessor :redirect_payment_method_specific_input
|
26
29
|
|
@@ -30,6 +33,7 @@ module Ingenico::Direct::SDK
|
|
30
33
|
hash['cardPaymentMethodSpecificInput'] = @card_payment_method_specific_input.to_h if @card_payment_method_specific_input
|
31
34
|
hash['fraudFields'] = @fraud_fields.to_h if @fraud_fields
|
32
35
|
hash['hostedCheckoutSpecificInput'] = @hosted_checkout_specific_input.to_h if @hosted_checkout_specific_input
|
36
|
+
hash['mobilePaymentMethodSpecificInput'] = @mobile_payment_method_specific_input.to_h if @mobile_payment_method_specific_input
|
33
37
|
hash['order'] = @order.to_h if @order
|
34
38
|
hash['redirectPaymentMethodSpecificInput'] = @redirect_payment_method_specific_input.to_h if @redirect_payment_method_specific_input
|
35
39
|
hash
|
@@ -49,6 +53,10 @@ module Ingenico::Direct::SDK
|
|
49
53
|
raise TypeError, "value '%s' is not a Hash" % [hash['hostedCheckoutSpecificInput']] unless hash['hostedCheckoutSpecificInput'].is_a? Hash
|
50
54
|
@hosted_checkout_specific_input = Ingenico::Direct::SDK::Domain::HostedCheckoutSpecificInput.new_from_hash(hash['hostedCheckoutSpecificInput'])
|
51
55
|
end
|
56
|
+
if hash.key? 'mobilePaymentMethodSpecificInput'
|
57
|
+
raise TypeError, "value '%s' is not a Hash" % [hash['mobilePaymentMethodSpecificInput']] unless hash['mobilePaymentMethodSpecificInput'].is_a? Hash
|
58
|
+
@mobile_payment_method_specific_input = Ingenico::Direct::SDK::Domain::MobilePaymentMethodHostedCheckoutSpecificInput.new_from_hash(hash['mobilePaymentMethodSpecificInput'])
|
59
|
+
end
|
52
60
|
if hash.key? 'order'
|
53
61
|
raise TypeError, "value '%s' is not a Hash" % [hash['order']] unless hash['order'].is_a? Hash
|
54
62
|
@order = Ingenico::Direct::SDK::Domain::Order.new_from_hash(hash['order'])
|
@@ -0,0 +1,35 @@
|
|
1
|
+
#
|
2
|
+
# This class was auto-generated from the API references found at
|
3
|
+
# https://support.direct.ingenico.com/documentation/api/reference/
|
4
|
+
#
|
5
|
+
require 'ingenico/direct/sdk/data_object'
|
6
|
+
require 'ingenico/direct/sdk/domain/payment_context'
|
7
|
+
|
8
|
+
module Ingenico::Direct::SDK
|
9
|
+
module Domain
|
10
|
+
|
11
|
+
# @attr [String] bin
|
12
|
+
# @attr [Ingenico::Direct::SDK::Domain::PaymentContext] payment_context
|
13
|
+
class GetIINDetailsRequest < Ingenico::Direct::SDK::DataObject
|
14
|
+
attr_accessor :bin
|
15
|
+
attr_accessor :payment_context
|
16
|
+
|
17
|
+
# @return (Hash)
|
18
|
+
def to_h
|
19
|
+
hash = super
|
20
|
+
hash['bin'] = @bin unless @bin.nil?
|
21
|
+
hash['paymentContext'] = @payment_context.to_h if @payment_context
|
22
|
+
hash
|
23
|
+
end
|
24
|
+
|
25
|
+
def from_hash(hash)
|
26
|
+
super
|
27
|
+
@bin = hash['bin'] if hash.key? 'bin'
|
28
|
+
if hash.key? 'paymentContext'
|
29
|
+
raise TypeError, "value '%s' is not a Hash" % [hash['paymentContext']] unless hash['paymentContext'].is_a? Hash
|
30
|
+
@payment_context = Ingenico::Direct::SDK::Domain::PaymentContext.new_from_hash(hash['paymentContext'])
|
31
|
+
end
|
32
|
+
end
|
33
|
+
end
|
34
|
+
end
|
35
|
+
end
|
@@ -0,0 +1,46 @@
|
|
1
|
+
#
|
2
|
+
# This class was auto-generated from the API references found at
|
3
|
+
# https://support.direct.ingenico.com/documentation/api/reference/
|
4
|
+
#
|
5
|
+
require 'ingenico/direct/sdk/data_object'
|
6
|
+
require 'ingenico/direct/sdk/domain/iin_detail'
|
7
|
+
|
8
|
+
module Ingenico::Direct::SDK
|
9
|
+
module Domain
|
10
|
+
|
11
|
+
# @attr [Array<Ingenico::Direct::SDK::Domain::IINDetail>] co_brands
|
12
|
+
# @attr [String] country_code
|
13
|
+
# @attr [true/false] is_allowed_in_context
|
14
|
+
# @attr [Integer] payment_product_id
|
15
|
+
class GetIINDetailsResponse < Ingenico::Direct::SDK::DataObject
|
16
|
+
attr_accessor :co_brands
|
17
|
+
attr_accessor :country_code
|
18
|
+
attr_accessor :is_allowed_in_context
|
19
|
+
attr_accessor :payment_product_id
|
20
|
+
|
21
|
+
# @return (Hash)
|
22
|
+
def to_h
|
23
|
+
hash = super
|
24
|
+
hash['coBrands'] = @co_brands.collect(&:to_h) if @co_brands
|
25
|
+
hash['countryCode'] = @country_code unless @country_code.nil?
|
26
|
+
hash['isAllowedInContext'] = @is_allowed_in_context unless @is_allowed_in_context.nil?
|
27
|
+
hash['paymentProductId'] = @payment_product_id unless @payment_product_id.nil?
|
28
|
+
hash
|
29
|
+
end
|
30
|
+
|
31
|
+
def from_hash(hash)
|
32
|
+
super
|
33
|
+
if hash.key? 'coBrands'
|
34
|
+
raise TypeError, "value '%s' is not an Array" % [hash['coBrands']] unless hash['coBrands'].is_a? Array
|
35
|
+
@co_brands = []
|
36
|
+
hash['coBrands'].each do |e|
|
37
|
+
@co_brands << Ingenico::Direct::SDK::Domain::IINDetail.new_from_hash(e)
|
38
|
+
end
|
39
|
+
end
|
40
|
+
@country_code = hash['countryCode'] if hash.key? 'countryCode'
|
41
|
+
@is_allowed_in_context = hash['isAllowedInContext'] if hash.key? 'isAllowedInContext'
|
42
|
+
@payment_product_id = hash['paymentProductId'] if hash.key? 'paymentProductId'
|
43
|
+
end
|
44
|
+
end
|
45
|
+
end
|
46
|
+
end
|
@@ -12,6 +12,7 @@ module Ingenico::Direct::SDK
|
|
12
12
|
# @attr [String] locale
|
13
13
|
# @attr [Ingenico::Direct::SDK::Domain::PaymentProductFiltersHostedCheckout] payment_product_filters
|
14
14
|
# @attr [String] return_url
|
15
|
+
# @attr [Integer] session_timeout
|
15
16
|
# @attr [true/false] show_result_page
|
16
17
|
# @attr [String] tokens
|
17
18
|
# @attr [String] variant
|
@@ -20,6 +21,7 @@ module Ingenico::Direct::SDK
|
|
20
21
|
attr_accessor :locale
|
21
22
|
attr_accessor :payment_product_filters
|
22
23
|
attr_accessor :return_url
|
24
|
+
attr_accessor :session_timeout
|
23
25
|
attr_accessor :show_result_page
|
24
26
|
attr_accessor :tokens
|
25
27
|
attr_accessor :variant
|
@@ -31,6 +33,7 @@ module Ingenico::Direct::SDK
|
|
31
33
|
hash['locale'] = @locale unless @locale.nil?
|
32
34
|
hash['paymentProductFilters'] = @payment_product_filters.to_h if @payment_product_filters
|
33
35
|
hash['returnUrl'] = @return_url unless @return_url.nil?
|
36
|
+
hash['sessionTimeout'] = @session_timeout unless @session_timeout.nil?
|
34
37
|
hash['showResultPage'] = @show_result_page unless @show_result_page.nil?
|
35
38
|
hash['tokens'] = @tokens unless @tokens.nil?
|
36
39
|
hash['variant'] = @variant unless @variant.nil?
|
@@ -46,6 +49,7 @@ module Ingenico::Direct::SDK
|
|
46
49
|
@payment_product_filters = Ingenico::Direct::SDK::Domain::PaymentProductFiltersHostedCheckout.new_from_hash(hash['paymentProductFilters'])
|
47
50
|
end
|
48
51
|
@return_url = hash['returnUrl'] if hash.key? 'returnUrl'
|
52
|
+
@session_timeout = hash['sessionTimeout'] if hash.key? 'sessionTimeout'
|
49
53
|
@show_result_page = hash['showResultPage'] if hash.key? 'showResultPage'
|
50
54
|
@tokens = hash['tokens'] if hash.key? 'tokens'
|
51
55
|
@variant = hash['variant'] if hash.key? 'variant'
|
@@ -0,0 +1,31 @@
|
|
1
|
+
#
|
2
|
+
# This class was auto-generated from the API references found at
|
3
|
+
# https://support.direct.ingenico.com/documentation/api/reference/
|
4
|
+
#
|
5
|
+
require 'ingenico/direct/sdk/data_object'
|
6
|
+
|
7
|
+
module Ingenico::Direct::SDK
|
8
|
+
module Domain
|
9
|
+
|
10
|
+
# @attr [true/false] is_allowed_in_context
|
11
|
+
# @attr [Integer] payment_product_id
|
12
|
+
class IINDetail < Ingenico::Direct::SDK::DataObject
|
13
|
+
attr_accessor :is_allowed_in_context
|
14
|
+
attr_accessor :payment_product_id
|
15
|
+
|
16
|
+
# @return (Hash)
|
17
|
+
def to_h
|
18
|
+
hash = super
|
19
|
+
hash['isAllowedInContext'] = @is_allowed_in_context unless @is_allowed_in_context.nil?
|
20
|
+
hash['paymentProductId'] = @payment_product_id unless @payment_product_id.nil?
|
21
|
+
hash
|
22
|
+
end
|
23
|
+
|
24
|
+
def from_hash(hash)
|
25
|
+
super
|
26
|
+
@is_allowed_in_context = hash['isAllowedInContext'] if hash.key? 'isAllowedInContext'
|
27
|
+
@payment_product_id = hash['paymentProductId'] if hash.key? 'paymentProductId'
|
28
|
+
end
|
29
|
+
end
|
30
|
+
end
|
31
|
+
end
|
@@ -0,0 +1,31 @@
|
|
1
|
+
#
|
2
|
+
# This class was auto-generated from the API references found at
|
3
|
+
# https://support.direct.ingenico.com/documentation/api/reference/
|
4
|
+
#
|
5
|
+
require 'ingenico/direct/sdk/data_object'
|
6
|
+
|
7
|
+
module Ingenico::Direct::SDK
|
8
|
+
module Domain
|
9
|
+
|
10
|
+
# @attr [String] authorization_mode
|
11
|
+
# @attr [Integer] payment_product_id
|
12
|
+
class MobilePaymentMethodHostedCheckoutSpecificInput < Ingenico::Direct::SDK::DataObject
|
13
|
+
attr_accessor :authorization_mode
|
14
|
+
attr_accessor :payment_product_id
|
15
|
+
|
16
|
+
# @return (Hash)
|
17
|
+
def to_h
|
18
|
+
hash = super
|
19
|
+
hash['authorizationMode'] = @authorization_mode unless @authorization_mode.nil?
|
20
|
+
hash['paymentProductId'] = @payment_product_id unless @payment_product_id.nil?
|
21
|
+
hash
|
22
|
+
end
|
23
|
+
|
24
|
+
def from_hash(hash)
|
25
|
+
super
|
26
|
+
@authorization_mode = hash['authorizationMode'] if hash.key? 'authorizationMode'
|
27
|
+
@payment_product_id = hash['paymentProductId'] if hash.key? 'paymentProductId'
|
28
|
+
end
|
29
|
+
end
|
30
|
+
end
|
31
|
+
end
|
@@ -0,0 +1,39 @@
|
|
1
|
+
#
|
2
|
+
# This class was auto-generated from the API references found at
|
3
|
+
# https://support.direct.ingenico.com/documentation/api/reference/
|
4
|
+
#
|
5
|
+
require 'ingenico/direct/sdk/data_object'
|
6
|
+
require 'ingenico/direct/sdk/domain/amount_of_money'
|
7
|
+
|
8
|
+
module Ingenico::Direct::SDK
|
9
|
+
module Domain
|
10
|
+
|
11
|
+
# @attr [Ingenico::Direct::SDK::Domain::AmountOfMoney] amount_of_money
|
12
|
+
# @attr [String] country_code
|
13
|
+
# @attr [true/false] is_recurring
|
14
|
+
class PaymentContext < Ingenico::Direct::SDK::DataObject
|
15
|
+
attr_accessor :amount_of_money
|
16
|
+
attr_accessor :country_code
|
17
|
+
attr_accessor :is_recurring
|
18
|
+
|
19
|
+
# @return (Hash)
|
20
|
+
def to_h
|
21
|
+
hash = super
|
22
|
+
hash['amountOfMoney'] = @amount_of_money.to_h if @amount_of_money
|
23
|
+
hash['countryCode'] = @country_code unless @country_code.nil?
|
24
|
+
hash['isRecurring'] = @is_recurring unless @is_recurring.nil?
|
25
|
+
hash
|
26
|
+
end
|
27
|
+
|
28
|
+
def from_hash(hash)
|
29
|
+
super
|
30
|
+
if hash.key? 'amountOfMoney'
|
31
|
+
raise TypeError, "value '%s' is not a Hash" % [hash['amountOfMoney']] unless hash['amountOfMoney'].is_a? Hash
|
32
|
+
@amount_of_money = Ingenico::Direct::SDK::Domain::AmountOfMoney.new_from_hash(hash['amountOfMoney'])
|
33
|
+
end
|
34
|
+
@country_code = hash['countryCode'] if hash.key? 'countryCode'
|
35
|
+
@is_recurring = hash['isRecurring'] if hash.key? 'isRecurring'
|
36
|
+
end
|
37
|
+
end
|
38
|
+
end
|
39
|
+
end
|
@@ -4,6 +4,8 @@
|
|
4
4
|
#
|
5
5
|
require 'ingenico/direct/sdk/data_object'
|
6
6
|
require 'ingenico/direct/sdk/domain/account_on_file'
|
7
|
+
require 'ingenico/direct/sdk/domain/payment_product302_specific_data'
|
8
|
+
require 'ingenico/direct/sdk/domain/payment_product320_specific_data'
|
7
9
|
require 'ingenico/direct/sdk/domain/payment_product_display_hints'
|
8
10
|
require 'ingenico/direct/sdk/domain/payment_product_field'
|
9
11
|
|
@@ -17,6 +19,8 @@ module Ingenico::Direct::SDK
|
|
17
19
|
# @attr [Array<Ingenico::Direct::SDK::Domain::PaymentProductField>] fields
|
18
20
|
# @attr [Integer] id
|
19
21
|
# @attr [String] payment_method
|
22
|
+
# @attr [Ingenico::Direct::SDK::Domain::PaymentProduct302SpecificData] payment_product302_specific_data
|
23
|
+
# @attr [Ingenico::Direct::SDK::Domain::PaymentProduct320SpecificData] payment_product320_specific_data
|
20
24
|
# @attr [String] payment_product_group
|
21
25
|
# @attr [true/false] uses_redirection_to3rd_party
|
22
26
|
class PaymentProduct < Ingenico::Direct::SDK::DataObject
|
@@ -27,6 +31,8 @@ module Ingenico::Direct::SDK
|
|
27
31
|
attr_accessor :fields
|
28
32
|
attr_accessor :id
|
29
33
|
attr_accessor :payment_method
|
34
|
+
attr_accessor :payment_product302_specific_data
|
35
|
+
attr_accessor :payment_product320_specific_data
|
30
36
|
attr_accessor :payment_product_group
|
31
37
|
attr_accessor :uses_redirection_to3rd_party
|
32
38
|
|
@@ -40,6 +46,8 @@ module Ingenico::Direct::SDK
|
|
40
46
|
hash['fields'] = @fields.collect(&:to_h) if @fields
|
41
47
|
hash['id'] = @id unless @id.nil?
|
42
48
|
hash['paymentMethod'] = @payment_method unless @payment_method.nil?
|
49
|
+
hash['paymentProduct302SpecificData'] = @payment_product302_specific_data.to_h if @payment_product302_specific_data
|
50
|
+
hash['paymentProduct320SpecificData'] = @payment_product320_specific_data.to_h if @payment_product320_specific_data
|
43
51
|
hash['paymentProductGroup'] = @payment_product_group unless @payment_product_group.nil?
|
44
52
|
hash['usesRedirectionTo3rdParty'] = @uses_redirection_to3rd_party unless @uses_redirection_to3rd_party.nil?
|
45
53
|
hash
|
@@ -69,6 +77,14 @@ module Ingenico::Direct::SDK
|
|
69
77
|
end
|
70
78
|
@id = hash['id'] if hash.key? 'id'
|
71
79
|
@payment_method = hash['paymentMethod'] if hash.key? 'paymentMethod'
|
80
|
+
if hash.key? 'paymentProduct302SpecificData'
|
81
|
+
raise TypeError, "value '%s' is not a Hash" % [hash['paymentProduct302SpecificData']] unless hash['paymentProduct302SpecificData'].is_a? Hash
|
82
|
+
@payment_product302_specific_data = Ingenico::Direct::SDK::Domain::PaymentProduct302SpecificData.new_from_hash(hash['paymentProduct302SpecificData'])
|
83
|
+
end
|
84
|
+
if hash.key? 'paymentProduct320SpecificData'
|
85
|
+
raise TypeError, "value '%s' is not a Hash" % [hash['paymentProduct320SpecificData']] unless hash['paymentProduct320SpecificData'].is_a? Hash
|
86
|
+
@payment_product320_specific_data = Ingenico::Direct::SDK::Domain::PaymentProduct320SpecificData.new_from_hash(hash['paymentProduct320SpecificData'])
|
87
|
+
end
|
72
88
|
@payment_product_group = hash['paymentProductGroup'] if hash.key? 'paymentProductGroup'
|
73
89
|
@uses_redirection_to3rd_party = hash['usesRedirectionTo3rdParty'] if hash.key? 'usesRedirectionTo3rdParty'
|
74
90
|
end
|
@@ -0,0 +1,31 @@
|
|
1
|
+
#
|
2
|
+
# This class was auto-generated from the API references found at
|
3
|
+
# https://support.direct.ingenico.com/documentation/api/reference/
|
4
|
+
#
|
5
|
+
require 'ingenico/direct/sdk/data_object'
|
6
|
+
require 'ingenico/direct/sdk/domain/payment_product130_specific_three_d_secure'
|
7
|
+
|
8
|
+
module Ingenico::Direct::SDK
|
9
|
+
module Domain
|
10
|
+
|
11
|
+
# @attr [Ingenico::Direct::SDK::Domain::PaymentProduct130SpecificThreeDSecure] three_d_secure
|
12
|
+
class PaymentProduct130SpecificInput < Ingenico::Direct::SDK::DataObject
|
13
|
+
attr_accessor :three_d_secure
|
14
|
+
|
15
|
+
# @return (Hash)
|
16
|
+
def to_h
|
17
|
+
hash = super
|
18
|
+
hash['threeDSecure'] = @three_d_secure.to_h if @three_d_secure
|
19
|
+
hash
|
20
|
+
end
|
21
|
+
|
22
|
+
def from_hash(hash)
|
23
|
+
super
|
24
|
+
if hash.key? 'threeDSecure'
|
25
|
+
raise TypeError, "value '%s' is not a Hash" % [hash['threeDSecure']] unless hash['threeDSecure'].is_a? Hash
|
26
|
+
@three_d_secure = Ingenico::Direct::SDK::Domain::PaymentProduct130SpecificThreeDSecure.new_from_hash(hash['threeDSecure'])
|
27
|
+
end
|
28
|
+
end
|
29
|
+
end
|
30
|
+
end
|
31
|
+
end
|
@@ -0,0 +1,39 @@
|
|
1
|
+
#
|
2
|
+
# This class was auto-generated from the API references found at
|
3
|
+
# https://support.direct.ingenico.com/documentation/api/reference/
|
4
|
+
#
|
5
|
+
require 'ingenico/direct/sdk/data_object'
|
6
|
+
|
7
|
+
module Ingenico::Direct::SDK
|
8
|
+
module Domain
|
9
|
+
|
10
|
+
# @attr [true/false] acquirer_exemption
|
11
|
+
# @attr [String] merchant_score
|
12
|
+
# @attr [Integer] number_of_items
|
13
|
+
# @attr [String] usecase
|
14
|
+
class PaymentProduct130SpecificThreeDSecure < Ingenico::Direct::SDK::DataObject
|
15
|
+
attr_accessor :acquirer_exemption
|
16
|
+
attr_accessor :merchant_score
|
17
|
+
attr_accessor :number_of_items
|
18
|
+
attr_accessor :usecase
|
19
|
+
|
20
|
+
# @return (Hash)
|
21
|
+
def to_h
|
22
|
+
hash = super
|
23
|
+
hash['acquirerExemption'] = @acquirer_exemption unless @acquirer_exemption.nil?
|
24
|
+
hash['merchantScore'] = @merchant_score unless @merchant_score.nil?
|
25
|
+
hash['numberOfItems'] = @number_of_items unless @number_of_items.nil?
|
26
|
+
hash['usecase'] = @usecase unless @usecase.nil?
|
27
|
+
hash
|
28
|
+
end
|
29
|
+
|
30
|
+
def from_hash(hash)
|
31
|
+
super
|
32
|
+
@acquirer_exemption = hash['acquirerExemption'] if hash.key? 'acquirerExemption'
|
33
|
+
@merchant_score = hash['merchantScore'] if hash.key? 'merchantScore'
|
34
|
+
@number_of_items = hash['numberOfItems'] if hash.key? 'numberOfItems'
|
35
|
+
@usecase = hash['usecase'] if hash.key? 'usecase'
|
36
|
+
end
|
37
|
+
end
|
38
|
+
end
|
39
|
+
end
|
@@ -0,0 +1,33 @@
|
|
1
|
+
#
|
2
|
+
# This class was auto-generated from the API references found at
|
3
|
+
# https://support.direct.ingenico.com/documentation/api/reference/
|
4
|
+
#
|
5
|
+
require 'ingenico/direct/sdk/data_object'
|
6
|
+
|
7
|
+
module Ingenico::Direct::SDK
|
8
|
+
module Domain
|
9
|
+
|
10
|
+
# @attr [Array<String>] networks
|
11
|
+
class PaymentProduct302SpecificData < Ingenico::Direct::SDK::DataObject
|
12
|
+
attr_accessor :networks
|
13
|
+
|
14
|
+
# @return (Hash)
|
15
|
+
def to_h
|
16
|
+
hash = super
|
17
|
+
hash['networks'] = @networks unless @networks.nil?
|
18
|
+
hash
|
19
|
+
end
|
20
|
+
|
21
|
+
def from_hash(hash)
|
22
|
+
super
|
23
|
+
if hash.key? 'networks'
|
24
|
+
raise TypeError, "value '%s' is not an Array" % [hash['networks']] unless hash['networks'].is_a? Array
|
25
|
+
@networks = []
|
26
|
+
hash['networks'].each do |e|
|
27
|
+
@networks << e
|
28
|
+
end
|
29
|
+
end
|
30
|
+
end
|
31
|
+
end
|
32
|
+
end
|
33
|
+
end
|
@@ -0,0 +1,37 @@
|
|
1
|
+
#
|
2
|
+
# This class was auto-generated from the API references found at
|
3
|
+
# https://support.direct.ingenico.com/documentation/api/reference/
|
4
|
+
#
|
5
|
+
require 'ingenico/direct/sdk/data_object'
|
6
|
+
|
7
|
+
module Ingenico::Direct::SDK
|
8
|
+
module Domain
|
9
|
+
|
10
|
+
# @attr [String] gateway
|
11
|
+
# @attr [Array<String>] networks
|
12
|
+
class PaymentProduct320SpecificData < Ingenico::Direct::SDK::DataObject
|
13
|
+
attr_accessor :gateway
|
14
|
+
attr_accessor :networks
|
15
|
+
|
16
|
+
# @return (Hash)
|
17
|
+
def to_h
|
18
|
+
hash = super
|
19
|
+
hash['gateway'] = @gateway unless @gateway.nil?
|
20
|
+
hash['networks'] = @networks unless @networks.nil?
|
21
|
+
hash
|
22
|
+
end
|
23
|
+
|
24
|
+
def from_hash(hash)
|
25
|
+
super
|
26
|
+
@gateway = hash['gateway'] if hash.key? 'gateway'
|
27
|
+
if hash.key? 'networks'
|
28
|
+
raise TypeError, "value '%s' is not an Array" % [hash['networks']] unless hash['networks'].is_a? Array
|
29
|
+
@networks = []
|
30
|
+
hash['networks'].each do |e|
|
31
|
+
@networks << e
|
32
|
+
end
|
33
|
+
end
|
34
|
+
end
|
35
|
+
end
|
36
|
+
end
|
37
|
+
end
|
@@ -13,6 +13,8 @@ module Ingenico::Direct::SDK
|
|
13
13
|
# @attr [String] email_address
|
14
14
|
# @attr [String] first_usage_date
|
15
15
|
# @attr [true/false] is_first_usage
|
16
|
+
# @attr [Long] shipping_cost
|
17
|
+
# @attr [Long] shipping_cost_tax
|
16
18
|
# @attr [String] type
|
17
19
|
class Shipping < Ingenico::Direct::SDK::DataObject
|
18
20
|
attr_accessor :address
|
@@ -20,6 +22,8 @@ module Ingenico::Direct::SDK
|
|
20
22
|
attr_accessor :email_address
|
21
23
|
attr_accessor :first_usage_date
|
22
24
|
attr_accessor :is_first_usage
|
25
|
+
attr_accessor :shipping_cost
|
26
|
+
attr_accessor :shipping_cost_tax
|
23
27
|
attr_accessor :type
|
24
28
|
|
25
29
|
# @return (Hash)
|
@@ -30,6 +34,8 @@ module Ingenico::Direct::SDK
|
|
30
34
|
hash['emailAddress'] = @email_address unless @email_address.nil?
|
31
35
|
hash['firstUsageDate'] = @first_usage_date unless @first_usage_date.nil?
|
32
36
|
hash['isFirstUsage'] = @is_first_usage unless @is_first_usage.nil?
|
37
|
+
hash['shippingCost'] = @shipping_cost unless @shipping_cost.nil?
|
38
|
+
hash['shippingCostTax'] = @shipping_cost_tax unless @shipping_cost_tax.nil?
|
33
39
|
hash['type'] = @type unless @type.nil?
|
34
40
|
hash
|
35
41
|
end
|
@@ -44,6 +50,8 @@ module Ingenico::Direct::SDK
|
|
44
50
|
@email_address = hash['emailAddress'] if hash.key? 'emailAddress'
|
45
51
|
@first_usage_date = hash['firstUsageDate'] if hash.key? 'firstUsageDate'
|
46
52
|
@is_first_usage = hash['isFirstUsage'] if hash.key? 'isFirstUsage'
|
53
|
+
@shipping_cost = hash['shippingCost'] if hash.key? 'shippingCost'
|
54
|
+
@shipping_cost_tax = hash['shippingCostTax'] if hash.key? 'shippingCostTax'
|
47
55
|
@type = hash['type'] if hash.key? 'type'
|
48
56
|
end
|
49
57
|
end
|
@@ -14,17 +14,23 @@ module Ingenico::Direct::SDK
|
|
14
14
|
# @attr [String] challenge_indicator
|
15
15
|
# @attr [String] exemption_request
|
16
16
|
# @attr [Ingenico::Direct::SDK::Domain::ExternalCardholderAuthenticationData] external_cardholder_authentication_data
|
17
|
+
# @attr [Integer] merchant_fraud_rate
|
17
18
|
# @attr [Ingenico::Direct::SDK::Domain::ThreeDSecureData] prior_three_d_secure_data
|
18
19
|
# @attr [Ingenico::Direct::SDK::Domain::RedirectionData] redirection_data
|
20
|
+
# @attr [true/false] secure_corporate_payment
|
19
21
|
# @attr [true/false] skip_authentication
|
22
|
+
# @attr [true/false] skip_soft_decline
|
20
23
|
class ThreeDSecure < Ingenico::Direct::SDK::DataObject
|
21
24
|
attr_accessor :challenge_canvas_size
|
22
25
|
attr_accessor :challenge_indicator
|
23
26
|
attr_accessor :exemption_request
|
24
27
|
attr_accessor :external_cardholder_authentication_data
|
28
|
+
attr_accessor :merchant_fraud_rate
|
25
29
|
attr_accessor :prior_three_d_secure_data
|
26
30
|
attr_accessor :redirection_data
|
31
|
+
attr_accessor :secure_corporate_payment
|
27
32
|
attr_accessor :skip_authentication
|
33
|
+
attr_accessor :skip_soft_decline
|
28
34
|
|
29
35
|
# @return (Hash)
|
30
36
|
def to_h
|
@@ -33,9 +39,12 @@ module Ingenico::Direct::SDK
|
|
33
39
|
hash['challengeIndicator'] = @challenge_indicator unless @challenge_indicator.nil?
|
34
40
|
hash['exemptionRequest'] = @exemption_request unless @exemption_request.nil?
|
35
41
|
hash['externalCardholderAuthenticationData'] = @external_cardholder_authentication_data.to_h if @external_cardholder_authentication_data
|
42
|
+
hash['merchantFraudRate'] = @merchant_fraud_rate unless @merchant_fraud_rate.nil?
|
36
43
|
hash['priorThreeDSecureData'] = @prior_three_d_secure_data.to_h if @prior_three_d_secure_data
|
37
44
|
hash['redirectionData'] = @redirection_data.to_h if @redirection_data
|
45
|
+
hash['secureCorporatePayment'] = @secure_corporate_payment unless @secure_corporate_payment.nil?
|
38
46
|
hash['skipAuthentication'] = @skip_authentication unless @skip_authentication.nil?
|
47
|
+
hash['skipSoftDecline'] = @skip_soft_decline unless @skip_soft_decline.nil?
|
39
48
|
hash
|
40
49
|
end
|
41
50
|
|
@@ -48,6 +57,7 @@ module Ingenico::Direct::SDK
|
|
48
57
|
raise TypeError, "value '%s' is not a Hash" % [hash['externalCardholderAuthenticationData']] unless hash['externalCardholderAuthenticationData'].is_a? Hash
|
49
58
|
@external_cardholder_authentication_data = Ingenico::Direct::SDK::Domain::ExternalCardholderAuthenticationData.new_from_hash(hash['externalCardholderAuthenticationData'])
|
50
59
|
end
|
60
|
+
@merchant_fraud_rate = hash['merchantFraudRate'] if hash.key? 'merchantFraudRate'
|
51
61
|
if hash.key? 'priorThreeDSecureData'
|
52
62
|
raise TypeError, "value '%s' is not a Hash" % [hash['priorThreeDSecureData']] unless hash['priorThreeDSecureData'].is_a? Hash
|
53
63
|
@prior_three_d_secure_data = Ingenico::Direct::SDK::Domain::ThreeDSecureData.new_from_hash(hash['priorThreeDSecureData'])
|
@@ -56,7 +66,9 @@ module Ingenico::Direct::SDK
|
|
56
66
|
raise TypeError, "value '%s' is not a Hash" % [hash['redirectionData']] unless hash['redirectionData'].is_a? Hash
|
57
67
|
@redirection_data = Ingenico::Direct::SDK::Domain::RedirectionData.new_from_hash(hash['redirectionData'])
|
58
68
|
end
|
69
|
+
@secure_corporate_payment = hash['secureCorporatePayment'] if hash.key? 'secureCorporatePayment'
|
59
70
|
@skip_authentication = hash['skipAuthentication'] if hash.key? 'skipAuthentication'
|
71
|
+
@skip_soft_decline = hash['skipSoftDecline'] if hash.key? 'skipSoftDecline'
|
60
72
|
end
|
61
73
|
end
|
62
74
|
end
|
@@ -11,14 +11,20 @@ module Ingenico::Direct::SDK
|
|
11
11
|
# @attr [String] challenge_canvas_size
|
12
12
|
# @attr [String] challenge_indicator
|
13
13
|
# @attr [String] exemption_request
|
14
|
+
# @attr [Integer] merchant_fraud_rate
|
14
15
|
# @attr [Ingenico::Direct::SDK::Domain::ThreeDSecureData] prior_three_d_secure_data
|
16
|
+
# @attr [true/false] secure_corporate_payment
|
15
17
|
# @attr [true/false] skip_authentication
|
18
|
+
# @attr [true/false] skip_soft_decline
|
16
19
|
class ThreeDSecureBase < Ingenico::Direct::SDK::DataObject
|
17
20
|
attr_accessor :challenge_canvas_size
|
18
21
|
attr_accessor :challenge_indicator
|
19
22
|
attr_accessor :exemption_request
|
23
|
+
attr_accessor :merchant_fraud_rate
|
20
24
|
attr_accessor :prior_three_d_secure_data
|
25
|
+
attr_accessor :secure_corporate_payment
|
21
26
|
attr_accessor :skip_authentication
|
27
|
+
attr_accessor :skip_soft_decline
|
22
28
|
|
23
29
|
# @return (Hash)
|
24
30
|
def to_h
|
@@ -26,8 +32,11 @@ module Ingenico::Direct::SDK
|
|
26
32
|
hash['challengeCanvasSize'] = @challenge_canvas_size unless @challenge_canvas_size.nil?
|
27
33
|
hash['challengeIndicator'] = @challenge_indicator unless @challenge_indicator.nil?
|
28
34
|
hash['exemptionRequest'] = @exemption_request unless @exemption_request.nil?
|
35
|
+
hash['merchantFraudRate'] = @merchant_fraud_rate unless @merchant_fraud_rate.nil?
|
29
36
|
hash['priorThreeDSecureData'] = @prior_three_d_secure_data.to_h if @prior_three_d_secure_data
|
37
|
+
hash['secureCorporatePayment'] = @secure_corporate_payment unless @secure_corporate_payment.nil?
|
30
38
|
hash['skipAuthentication'] = @skip_authentication unless @skip_authentication.nil?
|
39
|
+
hash['skipSoftDecline'] = @skip_soft_decline unless @skip_soft_decline.nil?
|
31
40
|
hash
|
32
41
|
end
|
33
42
|
|
@@ -36,11 +45,14 @@ module Ingenico::Direct::SDK
|
|
36
45
|
@challenge_canvas_size = hash['challengeCanvasSize'] if hash.key? 'challengeCanvasSize'
|
37
46
|
@challenge_indicator = hash['challengeIndicator'] if hash.key? 'challengeIndicator'
|
38
47
|
@exemption_request = hash['exemptionRequest'] if hash.key? 'exemptionRequest'
|
48
|
+
@merchant_fraud_rate = hash['merchantFraudRate'] if hash.key? 'merchantFraudRate'
|
39
49
|
if hash.key? 'priorThreeDSecureData'
|
40
50
|
raise TypeError, "value '%s' is not a Hash" % [hash['priorThreeDSecureData']] unless hash['priorThreeDSecureData'].is_a? Hash
|
41
51
|
@prior_three_d_secure_data = Ingenico::Direct::SDK::Domain::ThreeDSecureData.new_from_hash(hash['priorThreeDSecureData'])
|
42
52
|
end
|
53
|
+
@secure_corporate_payment = hash['secureCorporatePayment'] if hash.key? 'secureCorporatePayment'
|
43
54
|
@skip_authentication = hash['skipAuthentication'] if hash.key? 'skipAuthentication'
|
55
|
+
@skip_soft_decline = hash['skipSoftDecline'] if hash.key? 'skipSoftDecline'
|
44
56
|
end
|
45
57
|
end
|
46
58
|
end
|
@@ -14,12 +14,14 @@ module Ingenico::Direct::SDK
|
|
14
14
|
# @attr [Ingenico::Direct::SDK::Domain::TokenEWallet] e_wallet
|
15
15
|
# @attr [Ingenico::Direct::SDK::Domain::ExternalTokenLinked] external_token_linked
|
16
16
|
# @attr [String] id
|
17
|
+
# @attr [true/false] is_temporary
|
17
18
|
# @attr [Integer] payment_product_id
|
18
19
|
class TokenResponse < Ingenico::Direct::SDK::DataObject
|
19
20
|
attr_accessor :card
|
20
21
|
attr_accessor :e_wallet
|
21
22
|
attr_accessor :external_token_linked
|
22
23
|
attr_accessor :id
|
24
|
+
attr_accessor :is_temporary
|
23
25
|
attr_accessor :payment_product_id
|
24
26
|
|
25
27
|
# @return (Hash)
|
@@ -29,6 +31,7 @@ module Ingenico::Direct::SDK
|
|
29
31
|
hash['eWallet'] = @e_wallet.to_h if @e_wallet
|
30
32
|
hash['externalTokenLinked'] = @external_token_linked.to_h if @external_token_linked
|
31
33
|
hash['id'] = @id unless @id.nil?
|
34
|
+
hash['isTemporary'] = @is_temporary unless @is_temporary.nil?
|
32
35
|
hash['paymentProductId'] = @payment_product_id unless @payment_product_id.nil?
|
33
36
|
hash
|
34
37
|
end
|
@@ -48,6 +51,7 @@ module Ingenico::Direct::SDK
|
|
48
51
|
@external_token_linked = Ingenico::Direct::SDK::Domain::ExternalTokenLinked.new_from_hash(hash['externalTokenLinked'])
|
49
52
|
end
|
50
53
|
@id = hash['id'] if hash.key? 'id'
|
54
|
+
@is_temporary = hash['isTemporary'] if hash.key? 'isTemporary'
|
51
55
|
@payment_product_id = hash['paymentProductId'] if hash.key? 'paymentProductId'
|
52
56
|
end
|
53
57
|
end
|
@@ -49,7 +49,7 @@ module Ingenico::Direct::SDK
|
|
49
49
|
Ingenico::Direct::SDK::Merchant::Payments::PaymentsClient.new(self, nil)
|
50
50
|
end
|
51
51
|
|
52
|
-
# Resource /v2/!{merchantId}/services
|
52
|
+
# Resource /v2/!{merchantId}/services
|
53
53
|
# @return [Ingenico::Direct::SDK::Merchant::Services::ServicesClient]
|
54
54
|
def services
|
55
55
|
Ingenico::Direct::SDK::Merchant::Services::ServicesClient.new(self, nil)
|
@@ -5,6 +5,8 @@
|
|
5
5
|
require 'ingenico/direct/sdk/api_resource'
|
6
6
|
require 'ingenico/direct/sdk/response_exception'
|
7
7
|
require 'ingenico/direct/sdk/domain/error_response'
|
8
|
+
require 'ingenico/direct/sdk/domain/get_iin_details_request'
|
9
|
+
require 'ingenico/direct/sdk/domain/get_iin_details_response'
|
8
10
|
require 'ingenico/direct/sdk/domain/test_connection'
|
9
11
|
|
10
12
|
module Ingenico::Direct::SDK
|
@@ -46,6 +48,35 @@ module Ingenico::Direct::SDK
|
|
46
48
|
error_object = @communicator.marshaller.unmarshal(e.body, error_type)
|
47
49
|
raise create_exception(e.status_code, e.body, error_object, context)
|
48
50
|
end
|
51
|
+
|
52
|
+
# Resource /v2/!{merchantId}/services/getIINdetails - {https://support.direct.ingenico.com/documentation/api/reference#operation/GetIINDetailsApi Get IIN details}
|
53
|
+
# @param body [Ingenico::Direct::SDK::Domain::GetIINDetailsRequest]
|
54
|
+
# @param context [Ingenico::Direct::SDK::CallContext]
|
55
|
+
# @return [Ingenico::Direct::SDK::Domain::GetIINDetailsResponse]
|
56
|
+
# @raise [Ingenico::Direct::SDK::ValidationException] if the request was not correct and couldn't be processed (HTTP status code 400)
|
57
|
+
# @raise [Ingenico::Direct::SDK::AuthorizationException] if the request was not allowed (HTTP status code 403)
|
58
|
+
# @raise [Ingenico::Direct::SDK::IdempotenceException] if an idempotent request caused a conflict (HTTP status code 409)
|
59
|
+
# @raise [Ingenico::Direct::SDK::ReferenceException] if an object was attempted to be referenced that doesn't exist or has been removed,
|
60
|
+
# or there was a conflict (HTTP status code 404, 409 or 410)
|
61
|
+
# @raise [Ingenico::Direct::SDK::GlobalCollectException] if something went wrong at the Ingenico ePayments platform,
|
62
|
+
# the Ingenico ePayments platform was unable to process a message from a downstream partner/acquirer,
|
63
|
+
# or the service that you're trying to reach is temporary unavailable (HTTP status code 500, 502 or 503)
|
64
|
+
# @raise [Ingenico::Direct::SDK::ApiException]if the Ingenico ePayments platform returned any other error
|
65
|
+
def get_iin_details(body, context = nil)
|
66
|
+
uri = instantiate_uri('/v2/{merchantId}/services/getIINdetails')
|
67
|
+
@communicator.post(
|
68
|
+
uri,
|
69
|
+
client_headers,
|
70
|
+
nil,
|
71
|
+
body,
|
72
|
+
Ingenico::Direct::SDK::Domain::GetIINDetailsResponse,
|
73
|
+
context
|
74
|
+
)
|
75
|
+
rescue ResponseException => e
|
76
|
+
error_type = Ingenico::Direct::SDK::Domain::ErrorResponse
|
77
|
+
error_object = @communicator.marshaller.unmarshal(e.body, error_type)
|
78
|
+
raise create_exception(e.status_code, e.body, error_object, context)
|
79
|
+
end
|
49
80
|
end
|
50
81
|
end
|
51
82
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: direct-sdk-ruby
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.
|
4
|
+
version: 1.4.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Ingenico ePayments
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2021-
|
11
|
+
date: 2021-08-23 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: httpclient
|
@@ -211,11 +211,14 @@ files:
|
|
211
211
|
- lib/ingenico/direct/sdk/domain/g_pay_three_d_secure.rb
|
212
212
|
- lib/ingenico/direct/sdk/domain/get_hosted_checkout_response.rb
|
213
213
|
- lib/ingenico/direct/sdk/domain/get_hosted_tokenization_response.rb
|
214
|
+
- lib/ingenico/direct/sdk/domain/get_iin_details_request.rb
|
215
|
+
- lib/ingenico/direct/sdk/domain/get_iin_details_response.rb
|
214
216
|
- lib/ingenico/direct/sdk/domain/get_payment_product_groups_response.rb
|
215
217
|
- lib/ingenico/direct/sdk/domain/get_payment_products_response.rb
|
216
218
|
- lib/ingenico/direct/sdk/domain/gift_card_purchase.rb
|
217
219
|
- lib/ingenico/direct/sdk/domain/hosted_checkout_specific_input.rb
|
218
220
|
- lib/ingenico/direct/sdk/domain/hosted_checkout_specific_output.rb
|
221
|
+
- lib/ingenico/direct/sdk/domain/iin_detail.rb
|
219
222
|
- lib/ingenico/direct/sdk/domain/label_template_element.rb
|
220
223
|
- lib/ingenico/direct/sdk/domain/length_validator.rb
|
221
224
|
- lib/ingenico/direct/sdk/domain/line_item.rb
|
@@ -223,6 +226,7 @@ files:
|
|
223
226
|
- lib/ingenico/direct/sdk/domain/loan_recipient.rb
|
224
227
|
- lib/ingenico/direct/sdk/domain/merchant_action.rb
|
225
228
|
- lib/ingenico/direct/sdk/domain/mobile_payment_data.rb
|
229
|
+
- lib/ingenico/direct/sdk/domain/mobile_payment_method_hosted_checkout_specific_input.rb
|
226
230
|
- lib/ingenico/direct/sdk/domain/mobile_payment_method_specific_input.rb
|
227
231
|
- lib/ingenico/direct/sdk/domain/mobile_payment_method_specific_output.rb
|
228
232
|
- lib/ingenico/direct/sdk/domain/mobile_payment_product320_specific_input.rb
|
@@ -232,10 +236,15 @@ files:
|
|
232
236
|
- lib/ingenico/direct/sdk/domain/order_status_output.rb
|
233
237
|
- lib/ingenico/direct/sdk/domain/order_type_information.rb
|
234
238
|
- lib/ingenico/direct/sdk/domain/payment_account_on_file.rb
|
239
|
+
- lib/ingenico/direct/sdk/domain/payment_context.rb
|
235
240
|
- lib/ingenico/direct/sdk/domain/payment_creation_output.rb
|
236
241
|
- lib/ingenico/direct/sdk/domain/payment_error_response.rb
|
237
242
|
- lib/ingenico/direct/sdk/domain/payment_output.rb
|
238
243
|
- lib/ingenico/direct/sdk/domain/payment_product.rb
|
244
|
+
- lib/ingenico/direct/sdk/domain/payment_product130_specific_input.rb
|
245
|
+
- lib/ingenico/direct/sdk/domain/payment_product130_specific_three_d_secure.rb
|
246
|
+
- lib/ingenico/direct/sdk/domain/payment_product302_specific_data.rb
|
247
|
+
- lib/ingenico/direct/sdk/domain/payment_product320_specific_data.rb
|
239
248
|
- lib/ingenico/direct/sdk/domain/payment_product5100_specific_input.rb
|
240
249
|
- lib/ingenico/direct/sdk/domain/payment_product5402_specific_output.rb
|
241
250
|
- lib/ingenico/direct/sdk/domain/payment_product5500_specific_output.rb
|