onlinepayments-sdk-ruby 6.4.0 → 7.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/README.md +1 -1
- data/lib/onlinepayments/sdk/client.rb +1 -1
- data/lib/onlinepayments/sdk/communication/metadata_provider.rb +1 -1
- data/lib/onlinepayments/sdk/domain/card_payment_method_specific_input.rb +9 -0
- data/lib/onlinepayments/sdk/domain/card_payment_method_specific_input_base.rb +9 -0
- data/lib/onlinepayments/sdk/domain/card_payment_method_specific_input_for_hosted_checkout.rb +7 -0
- data/lib/onlinepayments/sdk/domain/create_payment_link_request.rb +7 -0
- data/lib/onlinepayments/sdk/domain/created_token_response.rb +9 -0
- data/lib/onlinepayments/sdk/domain/credit_card_specific_input_hosted_tokenization.rb +3 -3
- data/lib/onlinepayments/sdk/domain/{credit_card_validation_rules_hosted_tokenization.rb → credit_card_validation_rules.rb} +1 -1
- data/lib/onlinepayments/sdk/domain/crm_token.rb +37 -0
- data/lib/onlinepayments/sdk/domain/g_pay_three_d_secure.rb +7 -0
- data/lib/onlinepayments/sdk/domain/hosted_checkout_specific_input.rb +9 -0
- data/lib/onlinepayments/sdk/domain/market_place.rb +37 -0
- data/lib/onlinepayments/sdk/domain/omnichannel_payout_specific_input.rb +7 -0
- data/lib/onlinepayments/sdk/domain/omnichannel_subsequent_specific_input.rb +30 -0
- data/lib/onlinepayments/sdk/domain/payment_link_response.rb +7 -0
- data/lib/onlinepayments/sdk/domain/payment_product840_specific_output.rb +15 -0
- data/lib/onlinepayments/sdk/domain/payment_response.rb +9 -0
- data/lib/onlinepayments/sdk/domain/redirect_payment_method_specific_input.rb +18 -0
- data/lib/onlinepayments/sdk/domain/redirect_payment_product11_specific_input.rb +32 -0
- data/lib/onlinepayments/sdk/domain/redirect_payment_product3307_specific_input.rb +13 -0
- data/lib/onlinepayments/sdk/domain/redirect_payment_product5300_specific_input.rb +7 -0
- data/lib/onlinepayments/sdk/domain/refund_redirect_payment_method_specific_input.rb +32 -0
- data/lib/onlinepayments/sdk/domain/refund_redirect_payment_product900_specific_input.rb +30 -0
- data/lib/onlinepayments/sdk/domain/refund_request.rb +9 -0
- data/lib/onlinepayments/sdk/domain/session_details.rb +37 -0
- data/lib/onlinepayments/sdk/domain/split_payment_product_filter.rb +34 -0
- data/lib/onlinepayments/sdk/domain/split_payment_product_filters_hosted_checkout.rb +40 -0
- data/lib/onlinepayments/sdk/domain/subsequent_card_payment_method_specific_input.rb +9 -0
- data/lib/onlinepayments/sdk/domain/subsequent_payment_request.rb +9 -0
- data/lib/onlinepayments/sdk/domain/token_response.rb +9 -0
- data/lib/onlinepayments/sdk/merchant/merchant_client.rb +2 -2
- data/lib/onlinepayments/sdk/merchant/paymentlinks/payment_links_client.rb +0 -29
- data/lib/onlinepayments/sdk/merchant/payouts/payouts_client.rb +19 -19
- data/lib/onlinepayments/sdk/merchant/productgroups/get_product_group_params.rb +6 -6
- data/lib/onlinepayments/sdk/merchant/productgroups/get_product_groups_params.rb +6 -6
- data/lib/onlinepayments/sdk/merchant/products/get_payment_product_networks_params.rb +4 -4
- data/lib/onlinepayments/sdk/merchant/products/get_payment_product_params.rb +6 -6
- data/lib/onlinepayments/sdk/merchant/products/get_payment_products_params.rb +6 -6
- data/lib/onlinepayments/sdk/merchant/products/get_product_directory_params.rb +2 -2
- data/lib/onlinepayments/sdk/merchant/tokens/tokens_client.rb +24 -24
- data/onlinepayments-sdk-ruby.gemspec +1 -1
- metadata +13 -4
- data/lib/onlinepayments/sdk/merchant/paymentlinks/get_payment_links_in_bulk_params.rb +0 -28
|
@@ -2,10 +2,12 @@
|
|
|
2
2
|
# This file was automatically generated.
|
|
3
3
|
#
|
|
4
4
|
require 'onlinepayments/sdk/domain/data_object'
|
|
5
|
+
require 'onlinepayments/sdk/domain/redirect_payment_product11_specific_input'
|
|
5
6
|
require 'onlinepayments/sdk/domain/redirect_payment_product3203_specific_input'
|
|
6
7
|
require 'onlinepayments/sdk/domain/redirect_payment_product3204_specific_input'
|
|
7
8
|
require 'onlinepayments/sdk/domain/redirect_payment_product3302_specific_input'
|
|
8
9
|
require 'onlinepayments/sdk/domain/redirect_payment_product3306_specific_input'
|
|
10
|
+
require 'onlinepayments/sdk/domain/redirect_payment_product3307_specific_input'
|
|
9
11
|
require 'onlinepayments/sdk/domain/redirect_payment_product5001_specific_input'
|
|
10
12
|
require 'onlinepayments/sdk/domain/redirect_payment_product5300_specific_input'
|
|
11
13
|
require 'onlinepayments/sdk/domain/redirect_payment_product5402_specific_input'
|
|
@@ -22,10 +24,12 @@ module OnlinePayments
|
|
|
22
24
|
module SDK
|
|
23
25
|
module Domain
|
|
24
26
|
# @attr [String] payment_option
|
|
27
|
+
# @attr [OnlinePayments::SDK::Domain::RedirectPaymentProduct11SpecificInput] payment_product11_specific_input
|
|
25
28
|
# @attr [OnlinePayments::SDK::Domain::RedirectPaymentProduct3203SpecificInput] payment_product3203_specific_input
|
|
26
29
|
# @attr [OnlinePayments::SDK::Domain::RedirectPaymentProduct3204SpecificInput] payment_product3204_specific_input
|
|
27
30
|
# @attr [OnlinePayments::SDK::Domain::RedirectPaymentProduct3302SpecificInput] payment_product3302_specific_input
|
|
28
31
|
# @attr [OnlinePayments::SDK::Domain::RedirectPaymentProduct3306SpecificInput] payment_product3306_specific_input
|
|
32
|
+
# @attr [OnlinePayments::SDK::Domain::RedirectPaymentProduct3307SpecificInput] payment_product3307_specific_input
|
|
29
33
|
# @attr [OnlinePayments::SDK::Domain::RedirectPaymentProduct5001SpecificInput] payment_product5001_specific_input
|
|
30
34
|
# @attr [OnlinePayments::SDK::Domain::RedirectPaymentProduct5300SpecificInput] payment_product5300_specific_input
|
|
31
35
|
# @attr [OnlinePayments::SDK::Domain::RedirectPaymentProduct5402SpecificInput] payment_product5402_specific_input
|
|
@@ -45,6 +49,8 @@ module OnlinePayments
|
|
|
45
49
|
|
|
46
50
|
attr_accessor :payment_option
|
|
47
51
|
|
|
52
|
+
attr_accessor :payment_product11_specific_input
|
|
53
|
+
|
|
48
54
|
attr_accessor :payment_product3203_specific_input
|
|
49
55
|
|
|
50
56
|
attr_accessor :payment_product3204_specific_input
|
|
@@ -53,6 +59,8 @@ module OnlinePayments
|
|
|
53
59
|
|
|
54
60
|
attr_accessor :payment_product3306_specific_input
|
|
55
61
|
|
|
62
|
+
attr_accessor :payment_product3307_specific_input
|
|
63
|
+
|
|
56
64
|
attr_accessor :payment_product5001_specific_input
|
|
57
65
|
|
|
58
66
|
attr_accessor :payment_product5300_specific_input
|
|
@@ -87,10 +95,12 @@ module OnlinePayments
|
|
|
87
95
|
def to_h
|
|
88
96
|
hash = super
|
|
89
97
|
hash['paymentOption'] = @payment_option unless @payment_option.nil?
|
|
98
|
+
hash['paymentProduct11SpecificInput'] = @payment_product11_specific_input.to_h unless @payment_product11_specific_input.nil?
|
|
90
99
|
hash['paymentProduct3203SpecificInput'] = @payment_product3203_specific_input.to_h unless @payment_product3203_specific_input.nil?
|
|
91
100
|
hash['paymentProduct3204SpecificInput'] = @payment_product3204_specific_input.to_h unless @payment_product3204_specific_input.nil?
|
|
92
101
|
hash['paymentProduct3302SpecificInput'] = @payment_product3302_specific_input.to_h unless @payment_product3302_specific_input.nil?
|
|
93
102
|
hash['paymentProduct3306SpecificInput'] = @payment_product3306_specific_input.to_h unless @payment_product3306_specific_input.nil?
|
|
103
|
+
hash['paymentProduct3307SpecificInput'] = @payment_product3307_specific_input.to_h unless @payment_product3307_specific_input.nil?
|
|
94
104
|
hash['paymentProduct5001SpecificInput'] = @payment_product5001_specific_input.to_h unless @payment_product5001_specific_input.nil?
|
|
95
105
|
hash['paymentProduct5300SpecificInput'] = @payment_product5300_specific_input.to_h unless @payment_product5300_specific_input.nil?
|
|
96
106
|
hash['paymentProduct5402SpecificInput'] = @payment_product5402_specific_input.to_h unless @payment_product5402_specific_input.nil?
|
|
@@ -114,6 +124,10 @@ module OnlinePayments
|
|
|
114
124
|
if hash.has_key? 'paymentOption'
|
|
115
125
|
@payment_option = hash['paymentOption']
|
|
116
126
|
end
|
|
127
|
+
if hash.has_key? 'paymentProduct11SpecificInput'
|
|
128
|
+
raise TypeError, "value '%s' is not a Hash" % [hash['paymentProduct11SpecificInput']] unless hash['paymentProduct11SpecificInput'].is_a? Hash
|
|
129
|
+
@payment_product11_specific_input = OnlinePayments::SDK::Domain::RedirectPaymentProduct11SpecificInput.new_from_hash(hash['paymentProduct11SpecificInput'])
|
|
130
|
+
end
|
|
117
131
|
if hash.has_key? 'paymentProduct3203SpecificInput'
|
|
118
132
|
raise TypeError, "value '%s' is not a Hash" % [hash['paymentProduct3203SpecificInput']] unless hash['paymentProduct3203SpecificInput'].is_a? Hash
|
|
119
133
|
@payment_product3203_specific_input = OnlinePayments::SDK::Domain::RedirectPaymentProduct3203SpecificInput.new_from_hash(hash['paymentProduct3203SpecificInput'])
|
|
@@ -130,6 +144,10 @@ module OnlinePayments
|
|
|
130
144
|
raise TypeError, "value '%s' is not a Hash" % [hash['paymentProduct3306SpecificInput']] unless hash['paymentProduct3306SpecificInput'].is_a? Hash
|
|
131
145
|
@payment_product3306_specific_input = OnlinePayments::SDK::Domain::RedirectPaymentProduct3306SpecificInput.new_from_hash(hash['paymentProduct3306SpecificInput'])
|
|
132
146
|
end
|
|
147
|
+
if hash.has_key? 'paymentProduct3307SpecificInput'
|
|
148
|
+
raise TypeError, "value '%s' is not a Hash" % [hash['paymentProduct3307SpecificInput']] unless hash['paymentProduct3307SpecificInput'].is_a? Hash
|
|
149
|
+
@payment_product3307_specific_input = OnlinePayments::SDK::Domain::RedirectPaymentProduct3307SpecificInput.new_from_hash(hash['paymentProduct3307SpecificInput'])
|
|
150
|
+
end
|
|
133
151
|
if hash.has_key? 'paymentProduct5001SpecificInput'
|
|
134
152
|
raise TypeError, "value '%s' is not a Hash" % [hash['paymentProduct5001SpecificInput']] unless hash['paymentProduct5001SpecificInput'].is_a? Hash
|
|
135
153
|
@payment_product5001_specific_input = OnlinePayments::SDK::Domain::RedirectPaymentProduct5001SpecificInput.new_from_hash(hash['paymentProduct5001SpecificInput'])
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
#
|
|
2
|
+
# This file was automatically generated.
|
|
3
|
+
#
|
|
4
|
+
require 'date'
|
|
5
|
+
|
|
6
|
+
require 'onlinepayments/sdk/domain/data_object'
|
|
7
|
+
|
|
8
|
+
module OnlinePayments
|
|
9
|
+
module SDK
|
|
10
|
+
module Domain
|
|
11
|
+
# @attr [Date] first_installment_payment_date
|
|
12
|
+
class RedirectPaymentProduct11SpecificInput < OnlinePayments::SDK::Domain::DataObject
|
|
13
|
+
|
|
14
|
+
attr_accessor :first_installment_payment_date
|
|
15
|
+
|
|
16
|
+
# @return (Hash)
|
|
17
|
+
def to_h
|
|
18
|
+
hash = super
|
|
19
|
+
hash['firstInstallmentPaymentDate'] = @first_installment_payment_date.iso8601 unless @first_installment_payment_date.nil?
|
|
20
|
+
hash
|
|
21
|
+
end
|
|
22
|
+
|
|
23
|
+
def from_hash(hash)
|
|
24
|
+
super
|
|
25
|
+
if hash.has_key? 'firstInstallmentPaymentDate'
|
|
26
|
+
@first_installment_payment_date = Date.parse(hash['firstInstallmentPaymentDate'])
|
|
27
|
+
end
|
|
28
|
+
end
|
|
29
|
+
end
|
|
30
|
+
end
|
|
31
|
+
end
|
|
32
|
+
end
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
#
|
|
2
|
+
# This file was automatically generated.
|
|
3
|
+
#
|
|
4
|
+
require 'onlinepayments/sdk/domain/data_object'
|
|
5
|
+
|
|
6
|
+
module OnlinePayments
|
|
7
|
+
module SDK
|
|
8
|
+
module Domain
|
|
9
|
+
class RedirectPaymentProduct3307SpecificInput < OnlinePayments::SDK::Domain::DataObject
|
|
10
|
+
end
|
|
11
|
+
end
|
|
12
|
+
end
|
|
13
|
+
end
|
|
@@ -13,6 +13,7 @@ module OnlinePayments
|
|
|
13
13
|
# @attr [String] loyalty_card_number
|
|
14
14
|
# @attr [String] second_installment_payment_date
|
|
15
15
|
# @attr [Integer] session_duration
|
|
16
|
+
# @attr [String] title
|
|
16
17
|
class RedirectPaymentProduct5300SpecificInput < OnlinePayments::SDK::Domain::DataObject
|
|
17
18
|
|
|
18
19
|
attr_accessor :birth_city
|
|
@@ -29,6 +30,8 @@ module OnlinePayments
|
|
|
29
30
|
|
|
30
31
|
attr_accessor :session_duration
|
|
31
32
|
|
|
33
|
+
attr_accessor :title
|
|
34
|
+
|
|
32
35
|
# @return (Hash)
|
|
33
36
|
def to_h
|
|
34
37
|
hash = super
|
|
@@ -39,6 +42,7 @@ module OnlinePayments
|
|
|
39
42
|
hash['loyaltyCardNumber'] = @loyalty_card_number unless @loyalty_card_number.nil?
|
|
40
43
|
hash['secondInstallmentPaymentDate'] = @second_installment_payment_date unless @second_installment_payment_date.nil?
|
|
41
44
|
hash['sessionDuration'] = @session_duration unless @session_duration.nil?
|
|
45
|
+
hash['title'] = @title unless @title.nil?
|
|
42
46
|
hash
|
|
43
47
|
end
|
|
44
48
|
|
|
@@ -65,6 +69,9 @@ module OnlinePayments
|
|
|
65
69
|
if hash.has_key? 'sessionDuration'
|
|
66
70
|
@session_duration = hash['sessionDuration']
|
|
67
71
|
end
|
|
72
|
+
if hash.has_key? 'title'
|
|
73
|
+
@title = hash['title']
|
|
74
|
+
end
|
|
68
75
|
end
|
|
69
76
|
end
|
|
70
77
|
end
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
#
|
|
2
|
+
# This file was automatically generated.
|
|
3
|
+
#
|
|
4
|
+
require 'onlinepayments/sdk/domain/data_object'
|
|
5
|
+
require 'onlinepayments/sdk/domain/refund_redirect_payment_product900_specific_input'
|
|
6
|
+
|
|
7
|
+
module OnlinePayments
|
|
8
|
+
module SDK
|
|
9
|
+
module Domain
|
|
10
|
+
# @attr [OnlinePayments::SDK::Domain::RefundRedirectPaymentProduct900SpecificInput] refund_redirect_payment_product900_specific_input
|
|
11
|
+
class RefundRedirectPaymentMethodSpecificInput < OnlinePayments::SDK::Domain::DataObject
|
|
12
|
+
|
|
13
|
+
attr_accessor :refund_redirect_payment_product900_specific_input
|
|
14
|
+
|
|
15
|
+
# @return (Hash)
|
|
16
|
+
def to_h
|
|
17
|
+
hash = super
|
|
18
|
+
hash['refundRedirectPaymentProduct900SpecificInput'] = @refund_redirect_payment_product900_specific_input.to_h unless @refund_redirect_payment_product900_specific_input.nil?
|
|
19
|
+
hash
|
|
20
|
+
end
|
|
21
|
+
|
|
22
|
+
def from_hash(hash)
|
|
23
|
+
super
|
|
24
|
+
if hash.has_key? 'refundRedirectPaymentProduct900SpecificInput'
|
|
25
|
+
raise TypeError, "value '%s' is not a Hash" % [hash['refundRedirectPaymentProduct900SpecificInput']] unless hash['refundRedirectPaymentProduct900SpecificInput'].is_a? Hash
|
|
26
|
+
@refund_redirect_payment_product900_specific_input = OnlinePayments::SDK::Domain::RefundRedirectPaymentProduct900SpecificInput.new_from_hash(hash['refundRedirectPaymentProduct900SpecificInput'])
|
|
27
|
+
end
|
|
28
|
+
end
|
|
29
|
+
end
|
|
30
|
+
end
|
|
31
|
+
end
|
|
32
|
+
end
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
#
|
|
2
|
+
# This file was automatically generated.
|
|
3
|
+
#
|
|
4
|
+
require 'onlinepayments/sdk/domain/data_object'
|
|
5
|
+
|
|
6
|
+
module OnlinePayments
|
|
7
|
+
module SDK
|
|
8
|
+
module Domain
|
|
9
|
+
# @attr [String] refund_reason
|
|
10
|
+
class RefundRedirectPaymentProduct900SpecificInput < OnlinePayments::SDK::Domain::DataObject
|
|
11
|
+
|
|
12
|
+
attr_accessor :refund_reason
|
|
13
|
+
|
|
14
|
+
# @return (Hash)
|
|
15
|
+
def to_h
|
|
16
|
+
hash = super
|
|
17
|
+
hash['refundReason'] = @refund_reason unless @refund_reason.nil?
|
|
18
|
+
hash
|
|
19
|
+
end
|
|
20
|
+
|
|
21
|
+
def from_hash(hash)
|
|
22
|
+
super
|
|
23
|
+
if hash.has_key? 'refundReason'
|
|
24
|
+
@refund_reason = hash['refundReason']
|
|
25
|
+
end
|
|
26
|
+
end
|
|
27
|
+
end
|
|
28
|
+
end
|
|
29
|
+
end
|
|
30
|
+
end
|
|
@@ -6,6 +6,7 @@ require 'onlinepayments/sdk/domain/data_object'
|
|
|
6
6
|
require 'onlinepayments/sdk/domain/omnichannel_refund_specific_input'
|
|
7
7
|
require 'onlinepayments/sdk/domain/operation_payment_references'
|
|
8
8
|
require 'onlinepayments/sdk/domain/payment_references'
|
|
9
|
+
require 'onlinepayments/sdk/domain/refund_redirect_payment_method_specific_input'
|
|
9
10
|
|
|
10
11
|
module OnlinePayments
|
|
11
12
|
module SDK
|
|
@@ -16,6 +17,7 @@ module OnlinePayments
|
|
|
16
17
|
# @attr [OnlinePayments::SDK::Domain::OperationPaymentReferences] operation_references
|
|
17
18
|
# @attr [String] reason
|
|
18
19
|
# @attr [OnlinePayments::SDK::Domain::PaymentReferences] references
|
|
20
|
+
# @attr [OnlinePayments::SDK::Domain::RefundRedirectPaymentMethodSpecificInput] refund_redirect_payment_method_specific_input
|
|
19
21
|
class RefundRequest < OnlinePayments::SDK::Domain::DataObject
|
|
20
22
|
|
|
21
23
|
attr_accessor :amount_of_money
|
|
@@ -30,6 +32,8 @@ module OnlinePayments
|
|
|
30
32
|
|
|
31
33
|
attr_accessor :references
|
|
32
34
|
|
|
35
|
+
attr_accessor :refund_redirect_payment_method_specific_input
|
|
36
|
+
|
|
33
37
|
# @return (Hash)
|
|
34
38
|
def to_h
|
|
35
39
|
hash = super
|
|
@@ -39,6 +43,7 @@ module OnlinePayments
|
|
|
39
43
|
hash['operationReferences'] = @operation_references.to_h unless @operation_references.nil?
|
|
40
44
|
hash['reason'] = @reason unless @reason.nil?
|
|
41
45
|
hash['references'] = @references.to_h unless @references.nil?
|
|
46
|
+
hash['refundRedirectPaymentMethodSpecificInput'] = @refund_redirect_payment_method_specific_input.to_h unless @refund_redirect_payment_method_specific_input.nil?
|
|
42
47
|
hash
|
|
43
48
|
end
|
|
44
49
|
|
|
@@ -66,6 +71,10 @@ module OnlinePayments
|
|
|
66
71
|
raise TypeError, "value '%s' is not a Hash" % [hash['references']] unless hash['references'].is_a? Hash
|
|
67
72
|
@references = OnlinePayments::SDK::Domain::PaymentReferences.new_from_hash(hash['references'])
|
|
68
73
|
end
|
|
74
|
+
if hash.has_key? 'refundRedirectPaymentMethodSpecificInput'
|
|
75
|
+
raise TypeError, "value '%s' is not a Hash" % [hash['refundRedirectPaymentMethodSpecificInput']] unless hash['refundRedirectPaymentMethodSpecificInput'].is_a? Hash
|
|
76
|
+
@refund_redirect_payment_method_specific_input = OnlinePayments::SDK::Domain::RefundRedirectPaymentMethodSpecificInput.new_from_hash(hash['refundRedirectPaymentMethodSpecificInput'])
|
|
77
|
+
end
|
|
69
78
|
end
|
|
70
79
|
end
|
|
71
80
|
end
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
#
|
|
2
|
+
# This file was automatically generated.
|
|
3
|
+
#
|
|
4
|
+
require 'onlinepayments/sdk/domain/data_object'
|
|
5
|
+
|
|
6
|
+
module OnlinePayments
|
|
7
|
+
module SDK
|
|
8
|
+
module Domain
|
|
9
|
+
# @attr [String] id
|
|
10
|
+
# @attr [String] type
|
|
11
|
+
class SessionDetails < OnlinePayments::SDK::Domain::DataObject
|
|
12
|
+
|
|
13
|
+
attr_accessor :id
|
|
14
|
+
|
|
15
|
+
attr_accessor :type
|
|
16
|
+
|
|
17
|
+
# @return (Hash)
|
|
18
|
+
def to_h
|
|
19
|
+
hash = super
|
|
20
|
+
hash['id'] = @id unless @id.nil?
|
|
21
|
+
hash['type'] = @type unless @type.nil?
|
|
22
|
+
hash
|
|
23
|
+
end
|
|
24
|
+
|
|
25
|
+
def from_hash(hash)
|
|
26
|
+
super
|
|
27
|
+
if hash.has_key? 'id'
|
|
28
|
+
@id = hash['id']
|
|
29
|
+
end
|
|
30
|
+
if hash.has_key? 'type'
|
|
31
|
+
@type = hash['type']
|
|
32
|
+
end
|
|
33
|
+
end
|
|
34
|
+
end
|
|
35
|
+
end
|
|
36
|
+
end
|
|
37
|
+
end
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
#
|
|
2
|
+
# This file was automatically generated.
|
|
3
|
+
#
|
|
4
|
+
require 'onlinepayments/sdk/domain/data_object'
|
|
5
|
+
|
|
6
|
+
module OnlinePayments
|
|
7
|
+
module SDK
|
|
8
|
+
module Domain
|
|
9
|
+
# @attr [Array<Integer>] products
|
|
10
|
+
class SplitPaymentProductFilter < OnlinePayments::SDK::Domain::DataObject
|
|
11
|
+
|
|
12
|
+
attr_accessor :products
|
|
13
|
+
|
|
14
|
+
# @return (Hash)
|
|
15
|
+
def to_h
|
|
16
|
+
hash = super
|
|
17
|
+
hash['products'] = @products unless @products.nil?
|
|
18
|
+
hash
|
|
19
|
+
end
|
|
20
|
+
|
|
21
|
+
def from_hash(hash)
|
|
22
|
+
super
|
|
23
|
+
if hash.has_key? 'products'
|
|
24
|
+
raise TypeError, "value '%s' is not an Array" % [hash['products']] unless hash['products'].is_a? Array
|
|
25
|
+
@products = []
|
|
26
|
+
hash['products'].each do |e|
|
|
27
|
+
@products << e
|
|
28
|
+
end
|
|
29
|
+
end
|
|
30
|
+
end
|
|
31
|
+
end
|
|
32
|
+
end
|
|
33
|
+
end
|
|
34
|
+
end
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
#
|
|
2
|
+
# This file was automatically generated.
|
|
3
|
+
#
|
|
4
|
+
require 'onlinepayments/sdk/domain/data_object'
|
|
5
|
+
require 'onlinepayments/sdk/domain/split_payment_product_filter'
|
|
6
|
+
|
|
7
|
+
module OnlinePayments
|
|
8
|
+
module SDK
|
|
9
|
+
module Domain
|
|
10
|
+
# @attr [OnlinePayments::SDK::Domain::SplitPaymentProductFilter] exclude
|
|
11
|
+
# @attr [OnlinePayments::SDK::Domain::SplitPaymentProductFilter] restrict_to
|
|
12
|
+
class SplitPaymentProductFiltersHostedCheckout < OnlinePayments::SDK::Domain::DataObject
|
|
13
|
+
|
|
14
|
+
attr_accessor :exclude
|
|
15
|
+
|
|
16
|
+
attr_accessor :restrict_to
|
|
17
|
+
|
|
18
|
+
# @return (Hash)
|
|
19
|
+
def to_h
|
|
20
|
+
hash = super
|
|
21
|
+
hash['exclude'] = @exclude.to_h unless @exclude.nil?
|
|
22
|
+
hash['restrictTo'] = @restrict_to.to_h unless @restrict_to.nil?
|
|
23
|
+
hash
|
|
24
|
+
end
|
|
25
|
+
|
|
26
|
+
def from_hash(hash)
|
|
27
|
+
super
|
|
28
|
+
if hash.has_key? 'exclude'
|
|
29
|
+
raise TypeError, "value '%s' is not a Hash" % [hash['exclude']] unless hash['exclude'].is_a? Hash
|
|
30
|
+
@exclude = OnlinePayments::SDK::Domain::SplitPaymentProductFilter.new_from_hash(hash['exclude'])
|
|
31
|
+
end
|
|
32
|
+
if hash.has_key? 'restrictTo'
|
|
33
|
+
raise TypeError, "value '%s' is not a Hash" % [hash['restrictTo']] unless hash['restrictTo'].is_a? Hash
|
|
34
|
+
@restrict_to = OnlinePayments::SDK::Domain::SplitPaymentProductFilter.new_from_hash(hash['restrictTo'])
|
|
35
|
+
end
|
|
36
|
+
end
|
|
37
|
+
end
|
|
38
|
+
end
|
|
39
|
+
end
|
|
40
|
+
end
|
|
@@ -2,11 +2,13 @@
|
|
|
2
2
|
# This file was automatically generated.
|
|
3
3
|
#
|
|
4
4
|
require 'onlinepayments/sdk/domain/data_object'
|
|
5
|
+
require 'onlinepayments/sdk/domain/market_place'
|
|
5
6
|
|
|
6
7
|
module OnlinePayments
|
|
7
8
|
module SDK
|
|
8
9
|
module Domain
|
|
9
10
|
# @attr [String] authorization_mode
|
|
11
|
+
# @attr [OnlinePayments::SDK::Domain::MarketPlace] market_place
|
|
10
12
|
# @attr [Integer] payment_number
|
|
11
13
|
# @attr [String] scheme_reference_data
|
|
12
14
|
# @attr [String] subsequent_type
|
|
@@ -16,6 +18,8 @@ module OnlinePayments
|
|
|
16
18
|
|
|
17
19
|
attr_accessor :authorization_mode
|
|
18
20
|
|
|
21
|
+
attr_accessor :market_place
|
|
22
|
+
|
|
19
23
|
attr_accessor :payment_number
|
|
20
24
|
|
|
21
25
|
# @deprecated Deprecated
|
|
@@ -32,6 +36,7 @@ module OnlinePayments
|
|
|
32
36
|
def to_h
|
|
33
37
|
hash = super
|
|
34
38
|
hash['authorizationMode'] = @authorization_mode unless @authorization_mode.nil?
|
|
39
|
+
hash['marketPlace'] = @market_place.to_h unless @market_place.nil?
|
|
35
40
|
hash['paymentNumber'] = @payment_number unless @payment_number.nil?
|
|
36
41
|
hash['schemeReferenceData'] = @scheme_reference_data unless @scheme_reference_data.nil?
|
|
37
42
|
hash['subsequentType'] = @subsequent_type unless @subsequent_type.nil?
|
|
@@ -45,6 +50,10 @@ module OnlinePayments
|
|
|
45
50
|
if hash.has_key? 'authorizationMode'
|
|
46
51
|
@authorization_mode = hash['authorizationMode']
|
|
47
52
|
end
|
|
53
|
+
if hash.has_key? 'marketPlace'
|
|
54
|
+
raise TypeError, "value '%s' is not a Hash" % [hash['marketPlace']] unless hash['marketPlace'].is_a? Hash
|
|
55
|
+
@market_place = OnlinePayments::SDK::Domain::MarketPlace.new_from_hash(hash['marketPlace'])
|
|
56
|
+
end
|
|
48
57
|
if hash.has_key? 'paymentNumber'
|
|
49
58
|
@payment_number = hash['paymentNumber']
|
|
50
59
|
end
|
|
@@ -2,6 +2,7 @@
|
|
|
2
2
|
# This file was automatically generated.
|
|
3
3
|
#
|
|
4
4
|
require 'onlinepayments/sdk/domain/data_object'
|
|
5
|
+
require 'onlinepayments/sdk/domain/omnichannel_subsequent_specific_input'
|
|
5
6
|
require 'onlinepayments/sdk/domain/order'
|
|
6
7
|
require 'onlinepayments/sdk/domain/subsequent_card_payment_method_specific_input'
|
|
7
8
|
require 'onlinepayments/sdk/domain/subsequent_payment_product5001_specific_input'
|
|
@@ -9,11 +10,14 @@ require 'onlinepayments/sdk/domain/subsequent_payment_product5001_specific_input
|
|
|
9
10
|
module OnlinePayments
|
|
10
11
|
module SDK
|
|
11
12
|
module Domain
|
|
13
|
+
# @attr [OnlinePayments::SDK::Domain::OmnichannelSubsequentSpecificInput] omnichannel_subsequent_specific_input
|
|
12
14
|
# @attr [OnlinePayments::SDK::Domain::Order] order
|
|
13
15
|
# @attr [OnlinePayments::SDK::Domain::SubsequentPaymentProduct5001SpecificInput] subsequent_payment_product5001_specific_input
|
|
14
16
|
# @attr [OnlinePayments::SDK::Domain::SubsequentCardPaymentMethodSpecificInput] subsequentcard_payment_method_specific_input
|
|
15
17
|
class SubsequentPaymentRequest < OnlinePayments::SDK::Domain::DataObject
|
|
16
18
|
|
|
19
|
+
attr_accessor :omnichannel_subsequent_specific_input
|
|
20
|
+
|
|
17
21
|
attr_accessor :order
|
|
18
22
|
|
|
19
23
|
attr_accessor :subsequent_payment_product5001_specific_input
|
|
@@ -23,6 +27,7 @@ module OnlinePayments
|
|
|
23
27
|
# @return (Hash)
|
|
24
28
|
def to_h
|
|
25
29
|
hash = super
|
|
30
|
+
hash['omnichannelSubsequentSpecificInput'] = @omnichannel_subsequent_specific_input.to_h unless @omnichannel_subsequent_specific_input.nil?
|
|
26
31
|
hash['order'] = @order.to_h unless @order.nil?
|
|
27
32
|
hash['subsequentPaymentProduct5001SpecificInput'] = @subsequent_payment_product5001_specific_input.to_h unless @subsequent_payment_product5001_specific_input.nil?
|
|
28
33
|
hash['subsequentcardPaymentMethodSpecificInput'] = @subsequentcard_payment_method_specific_input.to_h unless @subsequentcard_payment_method_specific_input.nil?
|
|
@@ -31,6 +36,10 @@ module OnlinePayments
|
|
|
31
36
|
|
|
32
37
|
def from_hash(hash)
|
|
33
38
|
super
|
|
39
|
+
if hash.has_key? 'omnichannelSubsequentSpecificInput'
|
|
40
|
+
raise TypeError, "value '%s' is not a Hash" % [hash['omnichannelSubsequentSpecificInput']] unless hash['omnichannelSubsequentSpecificInput'].is_a? Hash
|
|
41
|
+
@omnichannel_subsequent_specific_input = OnlinePayments::SDK::Domain::OmnichannelSubsequentSpecificInput.new_from_hash(hash['omnichannelSubsequentSpecificInput'])
|
|
42
|
+
end
|
|
34
43
|
if hash.has_key? 'order'
|
|
35
44
|
raise TypeError, "value '%s' is not a Hash" % [hash['order']] unless hash['order'].is_a? Hash
|
|
36
45
|
@order = OnlinePayments::SDK::Domain::Order.new_from_hash(hash['order'])
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
#
|
|
2
2
|
# This file was automatically generated.
|
|
3
3
|
#
|
|
4
|
+
require 'onlinepayments/sdk/domain/crm_token'
|
|
4
5
|
require 'onlinepayments/sdk/domain/data_object'
|
|
5
6
|
require 'onlinepayments/sdk/domain/external_token_linked'
|
|
6
7
|
require 'onlinepayments/sdk/domain/network_token_linked'
|
|
@@ -11,6 +12,7 @@ module OnlinePayments
|
|
|
11
12
|
module SDK
|
|
12
13
|
module Domain
|
|
13
14
|
# @attr [OnlinePayments::SDK::Domain::TokenCard] card
|
|
15
|
+
# @attr [OnlinePayments::SDK::Domain::CrmToken] crm_token
|
|
14
16
|
# @attr [OnlinePayments::SDK::Domain::TokenEWallet] e_wallet
|
|
15
17
|
# @attr [OnlinePayments::SDK::Domain::ExternalTokenLinked] external_token_linked
|
|
16
18
|
# @attr [String] id
|
|
@@ -21,6 +23,8 @@ module OnlinePayments
|
|
|
21
23
|
|
|
22
24
|
attr_accessor :card
|
|
23
25
|
|
|
26
|
+
attr_accessor :crm_token
|
|
27
|
+
|
|
24
28
|
attr_accessor :e_wallet
|
|
25
29
|
|
|
26
30
|
attr_accessor :external_token_linked
|
|
@@ -37,6 +41,7 @@ module OnlinePayments
|
|
|
37
41
|
def to_h
|
|
38
42
|
hash = super
|
|
39
43
|
hash['card'] = @card.to_h unless @card.nil?
|
|
44
|
+
hash['crmToken'] = @crm_token.to_h unless @crm_token.nil?
|
|
40
45
|
hash['eWallet'] = @e_wallet.to_h unless @e_wallet.nil?
|
|
41
46
|
hash['externalTokenLinked'] = @external_token_linked.to_h unless @external_token_linked.nil?
|
|
42
47
|
hash['id'] = @id unless @id.nil?
|
|
@@ -52,6 +57,10 @@ module OnlinePayments
|
|
|
52
57
|
raise TypeError, "value '%s' is not a Hash" % [hash['card']] unless hash['card'].is_a? Hash
|
|
53
58
|
@card = OnlinePayments::SDK::Domain::TokenCard.new_from_hash(hash['card'])
|
|
54
59
|
end
|
|
60
|
+
if hash.has_key? 'crmToken'
|
|
61
|
+
raise TypeError, "value '%s' is not a Hash" % [hash['crmToken']] unless hash['crmToken'].is_a? Hash
|
|
62
|
+
@crm_token = OnlinePayments::SDK::Domain::CrmToken.new_from_hash(hash['crmToken'])
|
|
63
|
+
end
|
|
55
64
|
if hash.has_key? 'eWallet'
|
|
56
65
|
raise TypeError, "value '%s' is not a Hash" % [hash['eWallet']] unless hash['eWallet'].is_a? Hash
|
|
57
66
|
@e_wallet = OnlinePayments::SDK::Domain::TokenEWallet.new_from_hash(hash['eWallet'])
|
|
@@ -116,14 +116,14 @@ module OnlinePayments
|
|
|
116
116
|
OnlinePayments::SDK::Merchant::Sessions::SessionsClient.new(self, nil)
|
|
117
117
|
end
|
|
118
118
|
|
|
119
|
-
# Resource /v2/{merchantId}/tokens
|
|
119
|
+
# Resource /v2/{merchantId}/tokens
|
|
120
120
|
#
|
|
121
121
|
# @return [OnlinePayments::SDK::Merchant::Tokens::TokensClient]
|
|
122
122
|
def tokens
|
|
123
123
|
OnlinePayments::SDK::Merchant::Tokens::TokensClient.new(self, nil)
|
|
124
124
|
end
|
|
125
125
|
|
|
126
|
-
# Resource /v2/{merchantId}/payouts
|
|
126
|
+
# Resource /v2/{merchantId}/payouts
|
|
127
127
|
#
|
|
128
128
|
# @return [OnlinePayments::SDK::Merchant::Payouts::PayoutsClient]
|
|
129
129
|
def payouts
|
|
@@ -6,7 +6,6 @@ require 'onlinepayments/sdk/exception_factory'
|
|
|
6
6
|
require 'onlinepayments/sdk/communication/response_exception'
|
|
7
7
|
require 'onlinepayments/sdk/domain/error_response'
|
|
8
8
|
require 'onlinepayments/sdk/domain/payment_link_response'
|
|
9
|
-
require 'onlinepayments/sdk/domain/payment_links_response'
|
|
10
9
|
|
|
11
10
|
module OnlinePayments
|
|
12
11
|
module SDK
|
|
@@ -21,34 +20,6 @@ module OnlinePayments
|
|
|
21
20
|
super(parent: parent, path_context: path_context)
|
|
22
21
|
end
|
|
23
22
|
|
|
24
|
-
# Resource /v2/!{merchantId}/paymentlinks - Get payment links
|
|
25
|
-
#
|
|
26
|
-
# @param query [OnlinePayments::SDK::Merchant::PaymentLinks::GetPaymentLinksInBulkParams]
|
|
27
|
-
# @param context [OnlinePayments::SDK::CallContext, nil]
|
|
28
|
-
# @return [OnlinePayments::SDK::Domain::PaymentLinksResponse]
|
|
29
|
-
# @raise [OnlinePayments::SDK::IdempotenceException] if an idempotent request caused a conflict (HTTP status code 409)
|
|
30
|
-
# @raise [OnlinePayments::SDK::ValidationException] if the request was not correct and couldn't be processed (HTTP status code 400)
|
|
31
|
-
# @raise [OnlinePayments::SDK::AuthorizationException] if the request was not allowed (HTTP status code 403)
|
|
32
|
-
# @raise [OnlinePayments::SDK::ReferenceException] if an object was attempted to be referenced that doesn't exist or has been removed,
|
|
33
|
-
# or there was a conflict (HTTP status code 404, 409 or 410)
|
|
34
|
-
# @raise [OnlinePayments::SDK::PlatformException] if something went wrong at the payment platform,
|
|
35
|
-
# the payment platform was unable to process a message from a downstream partner/acquirer,
|
|
36
|
-
# or the service that you're trying to reach is temporary unavailable (HTTP status code 500, 502 or 503)
|
|
37
|
-
# @raise [OnlinePayments::SDK::ApiException] if the payment platform returned any other error
|
|
38
|
-
def get_payment_links_in_bulk(query, context = nil)
|
|
39
|
-
uri = instantiate_uri('/v2/{merchantId}/paymentlinks', nil)
|
|
40
|
-
@communicator.get(
|
|
41
|
-
uri,
|
|
42
|
-
client_headers,
|
|
43
|
-
query,
|
|
44
|
-
OnlinePayments::SDK::Domain::PaymentLinksResponse,
|
|
45
|
-
context)
|
|
46
|
-
rescue OnlinePayments::SDK::Communication::ResponseException => e
|
|
47
|
-
error_type = OnlinePayments::SDK::Domain::ErrorResponse
|
|
48
|
-
error_object = @communicator.marshaller.unmarshal(e.body, error_type)
|
|
49
|
-
raise OnlinePayments::SDK.create_exception(e.status_code, e.body, error_object, context)
|
|
50
|
-
end
|
|
51
|
-
|
|
52
23
|
# Resource /v2/!{merchantId}/paymentlinks - Create payment link
|
|
53
24
|
#
|
|
54
25
|
# @param body [OnlinePayments::SDK::Domain::CreatePaymentLinkRequest]
|
|
@@ -21,11 +21,12 @@ module OnlinePayments
|
|
|
21
21
|
super(parent: parent, path_context: path_context)
|
|
22
22
|
end
|
|
23
23
|
|
|
24
|
-
# Resource /v2/!{merchantId}/payouts
|
|
24
|
+
# Resource /v2/!{merchantId}/payouts - Create payout
|
|
25
25
|
#
|
|
26
|
-
# @param
|
|
27
|
-
# @param context
|
|
26
|
+
# @param body [OnlinePayments::SDK::Domain::CreatePayoutRequest]
|
|
27
|
+
# @param context [OnlinePayments::SDK::CallContext, nil]
|
|
28
28
|
# @return [OnlinePayments::SDK::Domain::PayoutResponse]
|
|
29
|
+
# @raise [OnlinePayments::SDK::DeclinedPayoutException] if the payment platform declined / rejected the payout. The payout result will be available from the exception.
|
|
29
30
|
# @raise [OnlinePayments::SDK::IdempotenceException] if an idempotent request caused a conflict (HTTP status code 409)
|
|
30
31
|
# @raise [OnlinePayments::SDK::ValidationException] if the request was not correct and couldn't be processed (HTTP status code 400)
|
|
31
32
|
# @raise [OnlinePayments::SDK::AuthorizationException] if the request was not allowed (HTTP status code 403)
|
|
@@ -35,29 +36,26 @@ module OnlinePayments
|
|
|
35
36
|
# the payment platform was unable to process a message from a downstream partner/acquirer,
|
|
36
37
|
# or the service that you're trying to reach is temporary unavailable (HTTP status code 500, 502 or 503)
|
|
37
38
|
# @raise [OnlinePayments::SDK::ApiException] if the payment platform returned any other error
|
|
38
|
-
def
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
}
|
|
42
|
-
uri = instantiate_uri('/v2/{merchantId}/payouts/{payoutId}', path_context)
|
|
43
|
-
@communicator.get(
|
|
39
|
+
def create_payout(body, context = nil)
|
|
40
|
+
uri = instantiate_uri('/v2/{merchantId}/payouts', nil)
|
|
41
|
+
@communicator.post(
|
|
44
42
|
uri,
|
|
45
43
|
client_headers,
|
|
46
44
|
nil,
|
|
45
|
+
body,
|
|
47
46
|
OnlinePayments::SDK::Domain::PayoutResponse,
|
|
48
47
|
context)
|
|
49
48
|
rescue OnlinePayments::SDK::Communication::ResponseException => e
|
|
50
|
-
error_type = OnlinePayments::SDK::Domain::
|
|
49
|
+
error_type = OnlinePayments::SDK::Domain::PayoutErrorResponse
|
|
51
50
|
error_object = @communicator.marshaller.unmarshal(e.body, error_type)
|
|
52
51
|
raise OnlinePayments::SDK.create_exception(e.status_code, e.body, error_object, context)
|
|
53
52
|
end
|
|
54
53
|
|
|
55
|
-
# Resource /v2/!{merchantId}/payouts -
|
|
54
|
+
# Resource /v2/!{merchantId}/payouts/!{payoutId} - Get payout
|
|
56
55
|
#
|
|
57
|
-
# @param
|
|
58
|
-
# @param context
|
|
56
|
+
# @param payout_id [String]
|
|
57
|
+
# @param context [OnlinePayments::SDK::CallContext, nil]
|
|
59
58
|
# @return [OnlinePayments::SDK::Domain::PayoutResponse]
|
|
60
|
-
# @raise [OnlinePayments::SDK::DeclinedPayoutException] if the payment platform declined / rejected the payout. The payout result will be available from the exception.
|
|
61
59
|
# @raise [OnlinePayments::SDK::IdempotenceException] if an idempotent request caused a conflict (HTTP status code 409)
|
|
62
60
|
# @raise [OnlinePayments::SDK::ValidationException] if the request was not correct and couldn't be processed (HTTP status code 400)
|
|
63
61
|
# @raise [OnlinePayments::SDK::AuthorizationException] if the request was not allowed (HTTP status code 403)
|
|
@@ -67,17 +65,19 @@ module OnlinePayments
|
|
|
67
65
|
# the payment platform was unable to process a message from a downstream partner/acquirer,
|
|
68
66
|
# or the service that you're trying to reach is temporary unavailable (HTTP status code 500, 502 or 503)
|
|
69
67
|
# @raise [OnlinePayments::SDK::ApiException] if the payment platform returned any other error
|
|
70
|
-
def
|
|
71
|
-
|
|
72
|
-
|
|
68
|
+
def get_payout(payout_id, context = nil)
|
|
69
|
+
path_context = {
|
|
70
|
+
'payoutId'.freeze => payout_id,
|
|
71
|
+
}
|
|
72
|
+
uri = instantiate_uri('/v2/{merchantId}/payouts/{payoutId}', path_context)
|
|
73
|
+
@communicator.get(
|
|
73
74
|
uri,
|
|
74
75
|
client_headers,
|
|
75
76
|
nil,
|
|
76
|
-
body,
|
|
77
77
|
OnlinePayments::SDK::Domain::PayoutResponse,
|
|
78
78
|
context)
|
|
79
79
|
rescue OnlinePayments::SDK::Communication::ResponseException => e
|
|
80
|
-
error_type = OnlinePayments::SDK::Domain::
|
|
80
|
+
error_type = OnlinePayments::SDK::Domain::ErrorResponse
|
|
81
81
|
error_object = @communicator.marshaller.unmarshal(e.body, error_type)
|
|
82
82
|
raise OnlinePayments::SDK.create_exception(e.status_code, e.body, error_object, context)
|
|
83
83
|
end
|