onlinepayments-sdk-ruby 3.1.0 → 3.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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 1bb876f081236865f02a3dd20ff6077b31c23849992bb96ea55d6b53d0f54fc1
4
- data.tar.gz: 32b0499d531fec07363427cf5de88d23abe2be615d730952cb5a651faca45b0b
3
+ metadata.gz: 4bbee3c62e917ac2eb7123a6abde69e4c8cef0e91622aafa32e02b33d8a6cbc6
4
+ data.tar.gz: 70338bb82049b04687e59ad9c4492b8a41b99e1a34b742f3cd60ef553cfe179c
5
5
  SHA512:
6
- metadata.gz: f6dc8f05d2503945a27ea6c6ae624ed5cdd0cd4bab2dc95e5725f67e43ff16a230560d1ece763469e34d023142dbdc4e0a6e79a634e025e7cb0aea1c421d2a03
7
- data.tar.gz: 766130f0e2b133f60a8cdb379df46447aef8ce6fe517458a19756705117af71d0c6293b58d6ff1dc430700c39d4d52ea95f9a8339c957f72de7e64ba2bf1ff80
6
+ metadata.gz: 2b9f638eb0d603d884ca0b6cde962389e880cdb090aeb1f075e0db98f0481cc8c57d8b1acc5aa7f283242a1819be7c9f88871e4a3af794e05bb451d73042ceb2
7
+ data.tar.gz: 4f228a1b5210a6d3bb83b80446f086c6c0a34b5ef01d6399e0df4ab9f8734dd46cc31b5ef1ef4dc13ff3b22b016a6c412680d66273c33fb28e3abf659f1f9e90
@@ -8,10 +8,12 @@ module OnlinePayments::SDK
8
8
 
9
9
  # @attr [String] bin
10
10
  # @attr [String] card_number
11
+ # @attr [String] country_code
11
12
  # @attr [String] expiry_date
12
13
  class CardEssentials < OnlinePayments::SDK::DataObject
13
14
  attr_accessor :bin
14
15
  attr_accessor :card_number
16
+ attr_accessor :country_code
15
17
  attr_accessor :expiry_date
16
18
 
17
19
  # @return (Hash)
@@ -19,6 +21,7 @@ module OnlinePayments::SDK
19
21
  hash = super
20
22
  hash['bin'] = @bin unless @bin.nil?
21
23
  hash['cardNumber'] = @card_number unless @card_number.nil?
24
+ hash['countryCode'] = @country_code unless @country_code.nil?
22
25
  hash['expiryDate'] = @expiry_date unless @expiry_date.nil?
23
26
  hash
24
27
  end
@@ -27,6 +30,7 @@ module OnlinePayments::SDK
27
30
  super
28
31
  @bin = hash['bin'] if hash.key? 'bin'
29
32
  @card_number = hash['cardNumber'] if hash.key? 'cardNumber'
33
+ @country_code = hash['countryCode'] if hash.key? 'countryCode'
30
34
  @expiry_date = hash['expiryDate'] if hash.key? 'expiryDate'
31
35
  end
32
36
  end
@@ -15,6 +15,7 @@ module OnlinePayments::SDK
15
15
  # @attr [OnlinePayments::SDK::Domain::CardPaymentMethodSpecificInput] card_payment_method_specific_input
16
16
  # @attr [String] encrypted_customer_input
17
17
  # @attr [OnlinePayments::SDK::Domain::FraudFields] fraud_fields
18
+ # @attr [String] hosted_tokenization_id
18
19
  # @attr [OnlinePayments::SDK::Domain::MobilePaymentMethodSpecificInput] mobile_payment_method_specific_input
19
20
  # @attr [OnlinePayments::SDK::Domain::Order] order
20
21
  # @attr [OnlinePayments::SDK::Domain::RedirectPaymentMethodSpecificInput] redirect_payment_method_specific_input
@@ -23,6 +24,7 @@ module OnlinePayments::SDK
23
24
  attr_accessor :card_payment_method_specific_input
24
25
  attr_accessor :encrypted_customer_input
25
26
  attr_accessor :fraud_fields
27
+ attr_accessor :hosted_tokenization_id
26
28
  attr_accessor :mobile_payment_method_specific_input
27
29
  attr_accessor :order
28
30
  attr_accessor :redirect_payment_method_specific_input
@@ -34,6 +36,7 @@ module OnlinePayments::SDK
34
36
  hash['cardPaymentMethodSpecificInput'] = @card_payment_method_specific_input.to_h if @card_payment_method_specific_input
35
37
  hash['encryptedCustomerInput'] = @encrypted_customer_input unless @encrypted_customer_input.nil?
36
38
  hash['fraudFields'] = @fraud_fields.to_h if @fraud_fields
39
+ hash['hostedTokenizationId'] = @hosted_tokenization_id unless @hosted_tokenization_id.nil?
37
40
  hash['mobilePaymentMethodSpecificInput'] = @mobile_payment_method_specific_input.to_h if @mobile_payment_method_specific_input
38
41
  hash['order'] = @order.to_h if @order
39
42
  hash['redirectPaymentMethodSpecificInput'] = @redirect_payment_method_specific_input.to_h if @redirect_payment_method_specific_input
@@ -52,6 +55,7 @@ module OnlinePayments::SDK
52
55
  raise TypeError, "value '%s' is not a Hash" % [hash['fraudFields']] unless hash['fraudFields'].is_a? Hash
53
56
  @fraud_fields = OnlinePayments::SDK::Domain::FraudFields.new_from_hash(hash['fraudFields'])
54
57
  end
58
+ @hosted_tokenization_id = hash['hostedTokenizationId'] if hash.key? 'hostedTokenizationId'
55
59
  if hash.key? 'mobilePaymentMethodSpecificInput'
56
60
  raise TypeError, "value '%s' is not a Hash" % [hash['mobilePaymentMethodSpecificInput']] unless hash['mobilePaymentMethodSpecificInput'].is_a? Hash
57
61
  @mobile_payment_method_specific_input = OnlinePayments::SDK::Domain::MobilePaymentMethodSpecificInput.new_from_hash(hash['mobilePaymentMethodSpecificInput'])
@@ -0,0 +1,26 @@
1
+ #
2
+ # This class was auto-generated.
3
+ #
4
+ require 'onlinepayments/sdk/data_object'
5
+
6
+ module OnlinePayments::SDK
7
+ module Domain
8
+
9
+ # @attr [String] ip_address_country_code
10
+ class CustomerDeviceOutput < OnlinePayments::SDK::DataObject
11
+ attr_accessor :ip_address_country_code
12
+
13
+ # @return (Hash)
14
+ def to_h
15
+ hash = super
16
+ hash['ipAddressCountryCode'] = @ip_address_country_code unless @ip_address_country_code.nil?
17
+ hash
18
+ end
19
+
20
+ def from_hash(hash)
21
+ super
22
+ @ip_address_country_code = hash['ipAddressCountryCode'] if hash.key? 'ipAddressCountryCode'
23
+ end
24
+ end
25
+ end
26
+ end
@@ -0,0 +1,30 @@
1
+ #
2
+ # This class was auto-generated.
3
+ #
4
+ require 'onlinepayments/sdk/data_object'
5
+ require 'onlinepayments/sdk/domain/customer_device_output'
6
+
7
+ module OnlinePayments::SDK
8
+ module Domain
9
+
10
+ # @attr [OnlinePayments::SDK::Domain::CustomerDeviceOutput] device
11
+ class CustomerOutput < OnlinePayments::SDK::DataObject
12
+ attr_accessor :device
13
+
14
+ # @return (Hash)
15
+ def to_h
16
+ hash = super
17
+ hash['device'] = @device.to_h if @device
18
+ hash
19
+ end
20
+
21
+ def from_hash(hash)
22
+ super
23
+ if hash.key? 'device'
24
+ raise TypeError, "value '%s' is not a Hash" % [hash['device']] unless hash['device'].is_a? Hash
25
+ @device = OnlinePayments::SDK::Domain::CustomerDeviceOutput.new_from_hash(hash['device'])
26
+ end
27
+ end
28
+ end
29
+ end
30
+ end
@@ -4,6 +4,7 @@
4
4
  require 'onlinepayments/sdk/data_object'
5
5
  require 'onlinepayments/sdk/domain/amount_of_money'
6
6
  require 'onlinepayments/sdk/domain/card_payment_method_specific_output'
7
+ require 'onlinepayments/sdk/domain/customer_output'
7
8
  require 'onlinepayments/sdk/domain/mobile_payment_method_specific_output'
8
9
  require 'onlinepayments/sdk/domain/payment_references'
9
10
  require 'onlinepayments/sdk/domain/redirect_payment_method_specific_output'
@@ -15,6 +16,7 @@ module OnlinePayments::SDK
15
16
  # @attr [OnlinePayments::SDK::Domain::AmountOfMoney] amount_of_money
16
17
  # @attr [Long] amount_paid
17
18
  # @attr [OnlinePayments::SDK::Domain::CardPaymentMethodSpecificOutput] card_payment_method_specific_output
19
+ # @attr [OnlinePayments::SDK::Domain::CustomerOutput] customer
18
20
  # @attr [String] merchant_parameters
19
21
  # @attr [OnlinePayments::SDK::Domain::MobilePaymentMethodSpecificOutput] mobile_payment_method_specific_output
20
22
  # @attr [String] payment_method
@@ -25,6 +27,7 @@ module OnlinePayments::SDK
25
27
  attr_accessor :amount_of_money
26
28
  attr_accessor :amount_paid
27
29
  attr_accessor :card_payment_method_specific_output
30
+ attr_accessor :customer
28
31
  attr_accessor :merchant_parameters
29
32
  attr_accessor :mobile_payment_method_specific_output
30
33
  attr_accessor :payment_method
@@ -38,6 +41,7 @@ module OnlinePayments::SDK
38
41
  hash['amountOfMoney'] = @amount_of_money.to_h if @amount_of_money
39
42
  hash['amountPaid'] = @amount_paid unless @amount_paid.nil?
40
43
  hash['cardPaymentMethodSpecificOutput'] = @card_payment_method_specific_output.to_h if @card_payment_method_specific_output
44
+ hash['customer'] = @customer.to_h if @customer
41
45
  hash['merchantParameters'] = @merchant_parameters unless @merchant_parameters.nil?
42
46
  hash['mobilePaymentMethodSpecificOutput'] = @mobile_payment_method_specific_output.to_h if @mobile_payment_method_specific_output
43
47
  hash['paymentMethod'] = @payment_method unless @payment_method.nil?
@@ -58,6 +62,10 @@ module OnlinePayments::SDK
58
62
  raise TypeError, "value '%s' is not a Hash" % [hash['cardPaymentMethodSpecificOutput']] unless hash['cardPaymentMethodSpecificOutput'].is_a? Hash
59
63
  @card_payment_method_specific_output = OnlinePayments::SDK::Domain::CardPaymentMethodSpecificOutput.new_from_hash(hash['cardPaymentMethodSpecificOutput'])
60
64
  end
65
+ if hash.key? 'customer'
66
+ raise TypeError, "value '%s' is not a Hash" % [hash['customer']] unless hash['customer'].is_a? Hash
67
+ @customer = OnlinePayments::SDK::Domain::CustomerOutput.new_from_hash(hash['customer'])
68
+ end
61
69
  @merchant_parameters = hash['merchantParameters'] if hash.key? 'merchantParameters'
62
70
  if hash.key? 'mobilePaymentMethodSpecificOutput'
63
71
  raise TypeError, "value '%s' is not a Hash" % [hash['mobilePaymentMethodSpecificOutput']] unless hash['mobilePaymentMethodSpecificOutput'].is_a? Hash
@@ -6,23 +6,63 @@ require 'onlinepayments/sdk/data_object'
6
6
  module OnlinePayments::SDK
7
7
  module Domain
8
8
 
9
+ # @attr [String] acs_transaction_id
10
+ # @attr [String] applied_exemption
11
+ # @attr [String] authentication_status
12
+ # @attr [String] cavv
13
+ # @attr [String] challenge_indicator
14
+ # @attr [String] ds_transaction_id
9
15
  # @attr [String] eci
16
+ # @attr [String] flow
17
+ # @attr [String] liability
18
+ # @attr [String] scheme_eci
19
+ # @attr [String] version
10
20
  # @attr [String] xid
11
21
  class ThreeDSecureResults < OnlinePayments::SDK::DataObject
22
+ attr_accessor :acs_transaction_id
23
+ attr_accessor :applied_exemption
24
+ attr_accessor :authentication_status
25
+ attr_accessor :cavv
26
+ attr_accessor :challenge_indicator
27
+ attr_accessor :ds_transaction_id
12
28
  attr_accessor :eci
29
+ attr_accessor :flow
30
+ attr_accessor :liability
31
+ attr_accessor :scheme_eci
32
+ attr_accessor :version
13
33
  attr_accessor :xid
14
34
 
15
35
  # @return (Hash)
16
36
  def to_h
17
37
  hash = super
38
+ hash['acsTransactionId'] = @acs_transaction_id unless @acs_transaction_id.nil?
39
+ hash['appliedExemption'] = @applied_exemption unless @applied_exemption.nil?
40
+ hash['authenticationStatus'] = @authentication_status unless @authentication_status.nil?
41
+ hash['cavv'] = @cavv unless @cavv.nil?
42
+ hash['challengeIndicator'] = @challenge_indicator unless @challenge_indicator.nil?
43
+ hash['dsTransactionId'] = @ds_transaction_id unless @ds_transaction_id.nil?
18
44
  hash['eci'] = @eci unless @eci.nil?
45
+ hash['flow'] = @flow unless @flow.nil?
46
+ hash['liability'] = @liability unless @liability.nil?
47
+ hash['schemeEci'] = @scheme_eci unless @scheme_eci.nil?
48
+ hash['version'] = @version unless @version.nil?
19
49
  hash['xid'] = @xid unless @xid.nil?
20
50
  hash
21
51
  end
22
52
 
23
53
  def from_hash(hash)
24
54
  super
55
+ @acs_transaction_id = hash['acsTransactionId'] if hash.key? 'acsTransactionId'
56
+ @applied_exemption = hash['appliedExemption'] if hash.key? 'appliedExemption'
57
+ @authentication_status = hash['authenticationStatus'] if hash.key? 'authenticationStatus'
58
+ @cavv = hash['cavv'] if hash.key? 'cavv'
59
+ @challenge_indicator = hash['challengeIndicator'] if hash.key? 'challengeIndicator'
60
+ @ds_transaction_id = hash['dsTransactionId'] if hash.key? 'dsTransactionId'
25
61
  @eci = hash['eci'] if hash.key? 'eci'
62
+ @flow = hash['flow'] if hash.key? 'flow'
63
+ @liability = hash['liability'] if hash.key? 'liability'
64
+ @scheme_eci = hash['schemeEci'] if hash.key? 'schemeEci'
65
+ @version = hash['version'] if hash.key? 'version'
26
66
  @xid = hash['xid'] if hash.key? 'xid'
27
67
  end
28
68
  end
@@ -1,6 +1,6 @@
1
1
  Gem::Specification.new do |spec|
2
2
  spec.name = 'onlinepayments-sdk-ruby'
3
- spec.version = '3.1.0'
3
+ spec.version = '3.4.0'
4
4
  spec.authors = ['Worldline Direct support team']
5
5
  spec.email = ['82139942+worldline-direct-support-team@users.noreply.github.com']
6
6
  spec.summary = %q{SDK to communicate with the Online Payments platform using the Online Payments Server API}
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: onlinepayments-sdk-ruby
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.1.0
4
+ version: 3.4.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Worldline Direct support team
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2022-03-01 00:00:00.000000000 Z
11
+ date: 2022-05-05 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: httpclient
@@ -200,6 +200,8 @@ files:
200
200
  - lib/onlinepayments/sdk/domain/customer_account.rb
201
201
  - lib/onlinepayments/sdk/domain/customer_account_authentication.rb
202
202
  - lib/onlinepayments/sdk/domain/customer_device.rb
203
+ - lib/onlinepayments/sdk/domain/customer_device_output.rb
204
+ - lib/onlinepayments/sdk/domain/customer_output.rb
203
205
  - lib/onlinepayments/sdk/domain/customer_payment_activity.rb
204
206
  - lib/onlinepayments/sdk/domain/customer_token.rb
205
207
  - lib/onlinepayments/sdk/domain/decrypted_payment_data.rb