acquiring-sdk-ruby 0.1.0 → 1.1.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (35) hide show
  1. checksums.yaml +4 -4
  2. data/acquiring-sdk-ruby.gemspec +1 -1
  3. data/lib/worldline/acquiring/sdk/authentication/oauth2_authenticator.rb +1 -1
  4. data/lib/worldline/acquiring/sdk/communication/metadata_provider.rb +1 -1
  5. data/lib/worldline/acquiring/sdk/v1/acquirer/merchant/balanceinquiries/balance_inquiries_client.rb +60 -0
  6. data/lib/worldline/acquiring/sdk/v1/acquirer/merchant/balanceinquiries.rb +4 -0
  7. data/lib/worldline/acquiring/sdk/v1/acquirer/merchant/merchant_client.rb +8 -0
  8. data/lib/worldline/acquiring/sdk/v1/acquirer/merchant/refunds/refunds_client.rb +1 -1
  9. data/lib/worldline/acquiring/sdk/v1/domain/api_account_verification_request.rb +9 -0
  10. data/lib/worldline/acquiring/sdk/v1/domain/api_balance_inquiry_request.rb +79 -0
  11. data/lib/worldline/acquiring/sdk/v1/domain/api_balance_inquiry_response.rb +87 -0
  12. data/lib/worldline/acquiring/sdk/v1/domain/api_capture_request.rb +18 -0
  13. data/lib/worldline/acquiring/sdk/v1/domain/api_capture_request_for_refund.rb +18 -0
  14. data/lib/worldline/acquiring/sdk/v1/domain/api_increment_request.rb +9 -0
  15. data/lib/worldline/acquiring/sdk/v1/domain/api_payment_refund_request.rb +9 -0
  16. data/lib/worldline/acquiring/sdk/v1/domain/api_payment_request.rb +9 -0
  17. data/lib/worldline/acquiring/sdk/v1/domain/api_payment_response.rb +12 -0
  18. data/lib/worldline/acquiring/sdk/v1/domain/api_payment_reversal_request.rb +9 -0
  19. data/lib/worldline/acquiring/sdk/v1/domain/api_refund_request.rb +9 -0
  20. data/lib/worldline/acquiring/sdk/v1/domain/api_refund_response.rb +12 -0
  21. data/lib/worldline/acquiring/sdk/v1/domain/api_refund_reversal_request.rb +52 -0
  22. data/lib/worldline/acquiring/sdk/v1/domain/api_technical_reversal_request.rb +9 -0
  23. data/lib/worldline/acquiring/sdk/v1/domain/card_data_for_dcc.rb +7 -0
  24. data/lib/worldline/acquiring/sdk/v1/domain/card_payment_data.rb +7 -0
  25. data/lib/worldline/acquiring/sdk/v1/domain/card_payment_data_for_balance_inquiry.rb +89 -0
  26. data/lib/worldline/acquiring/sdk/v1/domain/card_payment_data_for_refund.rb +14 -0
  27. data/lib/worldline/acquiring/sdk/v1/domain/card_payment_data_for_resource.rb +0 -9
  28. data/lib/worldline/acquiring/sdk/v1/domain/card_payment_data_for_response.rb +3 -3
  29. data/lib/worldline/acquiring/sdk/v1/domain/card_payment_data_for_verification.rb +16 -0
  30. data/lib/worldline/acquiring/sdk/v1/domain/emv_data_item.rb +41 -0
  31. data/lib/worldline/acquiring/sdk/v1/domain/payment_references.rb +0 -7
  32. data/lib/worldline/acquiring/sdk/v1/domain/point_of_sale_data.rb +45 -5
  33. data/lib/worldline/acquiring/sdk/v1/domain/point_of_sale_data_for_response.rb +41 -0
  34. data/lib/worldline/acquiring/sdk/v1/domain/terminal_data.rb +80 -0
  35. metadata +14 -5
@@ -6,6 +6,7 @@ require 'date'
6
6
  require 'worldline/acquiring/sdk/domain/data_object'
7
7
  require 'worldline/acquiring/sdk/v1/domain/amount_data'
8
8
  require 'worldline/acquiring/sdk/v1/domain/dcc_data'
9
+ require 'worldline/acquiring/sdk/v1/domain/terminal_data'
9
10
 
10
11
  module Worldline
11
12
  module Acquiring
@@ -15,6 +16,7 @@ module Worldline
15
16
  # @attr [Worldline::Acquiring::SDK::V1::Domain::DccData] dynamic_currency_conversion
16
17
  # @attr [String] operation_id
17
18
  # @attr [Worldline::Acquiring::SDK::V1::Domain::AmountData] reversal_amount
19
+ # @attr [Worldline::Acquiring::SDK::V1::Domain::TerminalData] terminal_data
18
20
  # @attr [DateTime] transaction_timestamp
19
21
  class ApiPaymentReversalRequest < Worldline::Acquiring::SDK::Domain::DataObject
20
22
 
@@ -24,6 +26,8 @@ module Worldline
24
26
 
25
27
  attr_accessor :reversal_amount
26
28
 
29
+ attr_accessor :terminal_data
30
+
27
31
  attr_accessor :transaction_timestamp
28
32
 
29
33
  # @return (Hash)
@@ -32,6 +36,7 @@ module Worldline
32
36
  hash['dynamicCurrencyConversion'] = @dynamic_currency_conversion.to_h unless @dynamic_currency_conversion.nil?
33
37
  hash['operationId'] = @operation_id unless @operation_id.nil?
34
38
  hash['reversalAmount'] = @reversal_amount.to_h unless @reversal_amount.nil?
39
+ hash['terminalData'] = @terminal_data.to_h unless @terminal_data.nil?
35
40
  hash['transactionTimestamp'] = @transaction_timestamp.iso8601(3) unless @transaction_timestamp.nil?
36
41
  hash
37
42
  end
@@ -49,6 +54,10 @@ module Worldline
49
54
  raise TypeError, "value '%s' is not a Hash" % [hash['reversalAmount']] unless hash['reversalAmount'].is_a? Hash
50
55
  @reversal_amount = Worldline::Acquiring::SDK::V1::Domain::AmountData.new_from_hash(hash['reversalAmount'])
51
56
  end
57
+ if hash.has_key? 'terminalData'
58
+ raise TypeError, "value '%s' is not a Hash" % [hash['terminalData']] unless hash['terminalData'].is_a? Hash
59
+ @terminal_data = Worldline::Acquiring::SDK::V1::Domain::TerminalData.new_from_hash(hash['terminalData'])
60
+ end
52
61
  if hash.has_key? 'transactionTimestamp'
53
62
  @transaction_timestamp = DateTime.parse(hash['transactionTimestamp'])
54
63
  end
@@ -9,6 +9,7 @@ require 'worldline/acquiring/sdk/v1/domain/card_payment_data_for_refund'
9
9
  require 'worldline/acquiring/sdk/v1/domain/dcc_data'
10
10
  require 'worldline/acquiring/sdk/v1/domain/merchant_data'
11
11
  require 'worldline/acquiring/sdk/v1/domain/payment_references'
12
+ require 'worldline/acquiring/sdk/v1/domain/terminal_data'
12
13
 
13
14
  module Worldline
14
15
  module Acquiring
@@ -21,6 +22,7 @@ module Worldline
21
22
  # @attr [Worldline::Acquiring::SDK::V1::Domain::MerchantData] merchant
22
23
  # @attr [String] operation_id
23
24
  # @attr [Worldline::Acquiring::SDK::V1::Domain::PaymentReferences] references
25
+ # @attr [Worldline::Acquiring::SDK::V1::Domain::TerminalData] terminal_data
24
26
  # @attr [DateTime] transaction_timestamp
25
27
  class ApiRefundRequest < Worldline::Acquiring::SDK::Domain::DataObject
26
28
 
@@ -36,6 +38,8 @@ module Worldline
36
38
 
37
39
  attr_accessor :references
38
40
 
41
+ attr_accessor :terminal_data
42
+
39
43
  attr_accessor :transaction_timestamp
40
44
 
41
45
  # @return (Hash)
@@ -47,6 +51,7 @@ module Worldline
47
51
  hash['merchant'] = @merchant.to_h unless @merchant.nil?
48
52
  hash['operationId'] = @operation_id unless @operation_id.nil?
49
53
  hash['references'] = @references.to_h unless @references.nil?
54
+ hash['terminalData'] = @terminal_data.to_h unless @terminal_data.nil?
50
55
  hash['transactionTimestamp'] = @transaction_timestamp.iso8601(3) unless @transaction_timestamp.nil?
51
56
  hash
52
57
  end
@@ -76,6 +81,10 @@ module Worldline
76
81
  raise TypeError, "value '%s' is not a Hash" % [hash['references']] unless hash['references'].is_a? Hash
77
82
  @references = Worldline::Acquiring::SDK::V1::Domain::PaymentReferences.new_from_hash(hash['references'])
78
83
  end
84
+ if hash.has_key? 'terminalData'
85
+ raise TypeError, "value '%s' is not a Hash" % [hash['terminalData']] unless hash['terminalData'].is_a? Hash
86
+ @terminal_data = Worldline::Acquiring::SDK::V1::Domain::TerminalData.new_from_hash(hash['terminalData'])
87
+ end
79
88
  if hash.has_key? 'transactionTimestamp'
80
89
  @transaction_timestamp = DateTime.parse(hash['transactionTimestamp'])
81
90
  end
@@ -7,6 +7,7 @@ require 'worldline/acquiring/sdk/domain/data_object'
7
7
  require 'worldline/acquiring/sdk/v1/domain/amount_data'
8
8
  require 'worldline/acquiring/sdk/v1/domain/api_references_for_responses'
9
9
  require 'worldline/acquiring/sdk/v1/domain/card_payment_data_for_resource'
10
+ require 'worldline/acquiring/sdk/v1/domain/emv_data_item'
10
11
 
11
12
  module Worldline
12
13
  module Acquiring
@@ -15,6 +16,7 @@ module Worldline
15
16
  module Domain
16
17
  # @attr [String] authorization_code
17
18
  # @attr [Worldline::Acquiring::SDK::V1::Domain::CardPaymentDataForResource] card_payment_data
19
+ # @attr [Array<Worldline::Acquiring::SDK::V1::Domain::EmvDataItem>] emv_data
18
20
  # @attr [String] operation_id
19
21
  # @attr [String] referenced_payment_id
20
22
  # @attr [Worldline::Acquiring::SDK::V1::Domain::ApiReferencesForResponses] references
@@ -33,6 +35,8 @@ module Worldline
33
35
 
34
36
  attr_accessor :card_payment_data
35
37
 
38
+ attr_accessor :emv_data
39
+
36
40
  attr_accessor :operation_id
37
41
 
38
42
  attr_accessor :referenced_payment_id
@@ -62,6 +66,7 @@ module Worldline
62
66
  hash = super
63
67
  hash['authorizationCode'] = @authorization_code unless @authorization_code.nil?
64
68
  hash['cardPaymentData'] = @card_payment_data.to_h unless @card_payment_data.nil?
69
+ hash['emvData'] = @emv_data.collect{|val| val.to_h} unless @emv_data.nil?
65
70
  hash['operationId'] = @operation_id unless @operation_id.nil?
66
71
  hash['referencedPaymentId'] = @referenced_payment_id unless @referenced_payment_id.nil?
67
72
  hash['references'] = @references.to_h unless @references.nil?
@@ -86,6 +91,13 @@ module Worldline
86
91
  raise TypeError, "value '%s' is not a Hash" % [hash['cardPaymentData']] unless hash['cardPaymentData'].is_a? Hash
87
92
  @card_payment_data = Worldline::Acquiring::SDK::V1::Domain::CardPaymentDataForResource.new_from_hash(hash['cardPaymentData'])
88
93
  end
94
+ if hash.has_key? 'emvData'
95
+ raise TypeError, "value '%s' is not an Array" % [hash['emvData']] unless hash['emvData'].is_a? Array
96
+ @emv_data = []
97
+ hash['emvData'].each do |e|
98
+ @emv_data << Worldline::Acquiring::SDK::V1::Domain::EmvDataItem.new_from_hash(e)
99
+ end
100
+ end
89
101
  if hash.has_key? 'operationId'
90
102
  @operation_id = hash['operationId']
91
103
  end
@@ -0,0 +1,52 @@
1
+ #
2
+ # This file was automatically generated.
3
+ #
4
+ require 'date'
5
+
6
+ require 'worldline/acquiring/sdk/domain/data_object'
7
+ require 'worldline/acquiring/sdk/v1/domain/terminal_data'
8
+
9
+ module Worldline
10
+ module Acquiring
11
+ module SDK
12
+ module V1
13
+ module Domain
14
+ # @attr [String] operation_id
15
+ # @attr [Worldline::Acquiring::SDK::V1::Domain::TerminalData] terminal_data
16
+ # @attr [DateTime] transaction_timestamp
17
+ class ApiRefundReversalRequest < Worldline::Acquiring::SDK::Domain::DataObject
18
+
19
+ attr_accessor :operation_id
20
+
21
+ attr_accessor :terminal_data
22
+
23
+ attr_accessor :transaction_timestamp
24
+
25
+ # @return (Hash)
26
+ def to_h
27
+ hash = super
28
+ hash['operationId'] = @operation_id unless @operation_id.nil?
29
+ hash['terminalData'] = @terminal_data.to_h unless @terminal_data.nil?
30
+ hash['transactionTimestamp'] = @transaction_timestamp.iso8601(3) unless @transaction_timestamp.nil?
31
+ hash
32
+ end
33
+
34
+ def from_hash(hash)
35
+ super
36
+ if hash.has_key? 'operationId'
37
+ @operation_id = hash['operationId']
38
+ end
39
+ if hash.has_key? 'terminalData'
40
+ raise TypeError, "value '%s' is not a Hash" % [hash['terminalData']] unless hash['terminalData'].is_a? Hash
41
+ @terminal_data = Worldline::Acquiring::SDK::V1::Domain::TerminalData.new_from_hash(hash['terminalData'])
42
+ end
43
+ if hash.has_key? 'transactionTimestamp'
44
+ @transaction_timestamp = DateTime.parse(hash['transactionTimestamp'])
45
+ end
46
+ end
47
+ end
48
+ end
49
+ end
50
+ end
51
+ end
52
+ end
@@ -4,6 +4,7 @@
4
4
  require 'date'
5
5
 
6
6
  require 'worldline/acquiring/sdk/domain/data_object'
7
+ require 'worldline/acquiring/sdk/v1/domain/terminal_data'
7
8
 
8
9
  module Worldline
9
10
  module Acquiring
@@ -12,6 +13,7 @@ module Worldline
12
13
  module Domain
13
14
  # @attr [String] operation_id
14
15
  # @attr [String] reason
16
+ # @attr [Worldline::Acquiring::SDK::V1::Domain::TerminalData] terminal_data
15
17
  # @attr [DateTime] transaction_timestamp
16
18
  class ApiTechnicalReversalRequest < Worldline::Acquiring::SDK::Domain::DataObject
17
19
 
@@ -19,6 +21,8 @@ module Worldline
19
21
 
20
22
  attr_accessor :reason
21
23
 
24
+ attr_accessor :terminal_data
25
+
22
26
  attr_accessor :transaction_timestamp
23
27
 
24
28
  # @return (Hash)
@@ -26,6 +30,7 @@ module Worldline
26
30
  hash = super
27
31
  hash['operationId'] = @operation_id unless @operation_id.nil?
28
32
  hash['reason'] = @reason unless @reason.nil?
33
+ hash['terminalData'] = @terminal_data.to_h unless @terminal_data.nil?
29
34
  hash['transactionTimestamp'] = @transaction_timestamp.iso8601(3) unless @transaction_timestamp.nil?
30
35
  hash
31
36
  end
@@ -38,6 +43,10 @@ module Worldline
38
43
  if hash.has_key? 'reason'
39
44
  @reason = hash['reason']
40
45
  end
46
+ if hash.has_key? 'terminalData'
47
+ raise TypeError, "value '%s' is not a Hash" % [hash['terminalData']] unless hash['terminalData'].is_a? Hash
48
+ @terminal_data = Worldline::Acquiring::SDK::V1::Domain::TerminalData.new_from_hash(hash['terminalData'])
49
+ end
41
50
  if hash.has_key? 'transactionTimestamp'
42
51
  @transaction_timestamp = DateTime.parse(hash['transactionTimestamp'])
43
52
  end
@@ -11,6 +11,7 @@ module Worldline
11
11
  # @attr [String] bin
12
12
  # @attr [String] brand
13
13
  # @attr [String] card_country_code
14
+ # @attr [String] card_entry_mode
14
15
  class CardDataForDcc < Worldline::Acquiring::SDK::Domain::DataObject
15
16
 
16
17
  attr_accessor :bin
@@ -19,12 +20,15 @@ module Worldline
19
20
 
20
21
  attr_accessor :card_country_code
21
22
 
23
+ attr_accessor :card_entry_mode
24
+
22
25
  # @return (Hash)
23
26
  def to_h
24
27
  hash = super
25
28
  hash['bin'] = @bin unless @bin.nil?
26
29
  hash['brand'] = @brand unless @brand.nil?
27
30
  hash['cardCountryCode'] = @card_country_code unless @card_country_code.nil?
31
+ hash['cardEntryMode'] = @card_entry_mode unless @card_entry_mode.nil?
28
32
  hash
29
33
  end
30
34
 
@@ -39,6 +43,9 @@ module Worldline
39
43
  if hash.has_key? 'cardCountryCode'
40
44
  @card_country_code = hash['cardCountryCode']
41
45
  end
46
+ if hash.has_key? 'cardEntryMode'
47
+ @card_entry_mode = hash['cardEntryMode']
48
+ end
42
49
  end
43
50
  end
44
51
  end
@@ -15,6 +15,7 @@ module Worldline
15
15
  module Domain
16
16
  # @attr [true/false] allow_partial_approval
17
17
  # @attr [String] brand
18
+ # @attr [String] brand_selector
18
19
  # @attr [true/false] capture_immediately
19
20
  # @attr [Worldline::Acquiring::SDK::V1::Domain::PlainCardData] card_data
20
21
  # @attr [String] card_entry_mode
@@ -30,6 +31,8 @@ module Worldline
30
31
 
31
32
  attr_accessor :brand
32
33
 
34
+ attr_accessor :brand_selector
35
+
33
36
  attr_accessor :capture_immediately
34
37
 
35
38
  attr_accessor :card_data
@@ -53,6 +56,7 @@ module Worldline
53
56
  hash = super
54
57
  hash['allowPartialApproval'] = @allow_partial_approval unless @allow_partial_approval.nil?
55
58
  hash['brand'] = @brand unless @brand.nil?
59
+ hash['brandSelector'] = @brand_selector unless @brand_selector.nil?
56
60
  hash['captureImmediately'] = @capture_immediately unless @capture_immediately.nil?
57
61
  hash['cardData'] = @card_data.to_h unless @card_data.nil?
58
62
  hash['cardEntryMode'] = @card_entry_mode unless @card_entry_mode.nil?
@@ -73,6 +77,9 @@ module Worldline
73
77
  if hash.has_key? 'brand'
74
78
  @brand = hash['brand']
75
79
  end
80
+ if hash.has_key? 'brandSelector'
81
+ @brand_selector = hash['brandSelector']
82
+ end
76
83
  if hash.has_key? 'captureImmediately'
77
84
  @capture_immediately = hash['captureImmediately']
78
85
  end
@@ -0,0 +1,89 @@
1
+ #
2
+ # This file was automatically generated.
3
+ #
4
+ require 'worldline/acquiring/sdk/domain/data_object'
5
+ require 'worldline/acquiring/sdk/v1/domain/e_commerce_data'
6
+ require 'worldline/acquiring/sdk/v1/domain/plain_card_data'
7
+ require 'worldline/acquiring/sdk/v1/domain/point_of_sale_data'
8
+
9
+ module Worldline
10
+ module Acquiring
11
+ module SDK
12
+ module V1
13
+ module Domain
14
+ # @attr [String] brand
15
+ # @attr [String] brand_selector
16
+ # @attr [Worldline::Acquiring::SDK::V1::Domain::PlainCardData] card_data
17
+ # @attr [String] card_entry_mode
18
+ # @attr [String] cardholder_verification_method
19
+ # @attr [Worldline::Acquiring::SDK::V1::Domain::ECommerceData] ecommerce_data
20
+ # @attr [Worldline::Acquiring::SDK::V1::Domain::PointOfSaleData] point_of_sale_data
21
+ # @attr [String] wallet_id
22
+ class CardPaymentDataForBalanceInquiry < Worldline::Acquiring::SDK::Domain::DataObject
23
+
24
+ attr_accessor :brand
25
+
26
+ attr_accessor :brand_selector
27
+
28
+ attr_accessor :card_data
29
+
30
+ attr_accessor :card_entry_mode
31
+
32
+ attr_accessor :cardholder_verification_method
33
+
34
+ attr_accessor :ecommerce_data
35
+
36
+ attr_accessor :point_of_sale_data
37
+
38
+ attr_accessor :wallet_id
39
+
40
+ # @return (Hash)
41
+ def to_h
42
+ hash = super
43
+ hash['brand'] = @brand unless @brand.nil?
44
+ hash['brandSelector'] = @brand_selector unless @brand_selector.nil?
45
+ hash['cardData'] = @card_data.to_h unless @card_data.nil?
46
+ hash['cardEntryMode'] = @card_entry_mode unless @card_entry_mode.nil?
47
+ hash['cardholderVerificationMethod'] = @cardholder_verification_method unless @cardholder_verification_method.nil?
48
+ hash['ecommerceData'] = @ecommerce_data.to_h unless @ecommerce_data.nil?
49
+ hash['pointOfSaleData'] = @point_of_sale_data.to_h unless @point_of_sale_data.nil?
50
+ hash['walletId'] = @wallet_id unless @wallet_id.nil?
51
+ hash
52
+ end
53
+
54
+ def from_hash(hash)
55
+ super
56
+ if hash.has_key? 'brand'
57
+ @brand = hash['brand']
58
+ end
59
+ if hash.has_key? 'brandSelector'
60
+ @brand_selector = hash['brandSelector']
61
+ end
62
+ if hash.has_key? 'cardData'
63
+ raise TypeError, "value '%s' is not a Hash" % [hash['cardData']] unless hash['cardData'].is_a? Hash
64
+ @card_data = Worldline::Acquiring::SDK::V1::Domain::PlainCardData.new_from_hash(hash['cardData'])
65
+ end
66
+ if hash.has_key? 'cardEntryMode'
67
+ @card_entry_mode = hash['cardEntryMode']
68
+ end
69
+ if hash.has_key? 'cardholderVerificationMethod'
70
+ @cardholder_verification_method = hash['cardholderVerificationMethod']
71
+ end
72
+ if hash.has_key? 'ecommerceData'
73
+ raise TypeError, "value '%s' is not a Hash" % [hash['ecommerceData']] unless hash['ecommerceData'].is_a? Hash
74
+ @ecommerce_data = Worldline::Acquiring::SDK::V1::Domain::ECommerceData.new_from_hash(hash['ecommerceData'])
75
+ end
76
+ if hash.has_key? 'pointOfSaleData'
77
+ raise TypeError, "value '%s' is not a Hash" % [hash['pointOfSaleData']] unless hash['pointOfSaleData'].is_a? Hash
78
+ @point_of_sale_data = Worldline::Acquiring::SDK::V1::Domain::PointOfSaleData.new_from_hash(hash['pointOfSaleData'])
79
+ end
80
+ if hash.has_key? 'walletId'
81
+ @wallet_id = hash['walletId']
82
+ end
83
+ end
84
+ end
85
+ end
86
+ end
87
+ end
88
+ end
89
+ end
@@ -12,9 +12,11 @@ module Worldline
12
12
  module V1
13
13
  module Domain
14
14
  # @attr [String] brand
15
+ # @attr [String] brand_selector
15
16
  # @attr [true/false] capture_immediately
16
17
  # @attr [Worldline::Acquiring::SDK::V1::Domain::PlainCardData] card_data
17
18
  # @attr [String] card_entry_mode
19
+ # @attr [String] cardholder_verification_method
18
20
  # @attr [Worldline::Acquiring::SDK::V1::Domain::NetworkTokenData] network_token_data
19
21
  # @attr [Worldline::Acquiring::SDK::V1::Domain::PointOfSaleData] point_of_sale_data
20
22
  # @attr [String] wallet_id
@@ -22,12 +24,16 @@ module Worldline
22
24
 
23
25
  attr_accessor :brand
24
26
 
27
+ attr_accessor :brand_selector
28
+
25
29
  attr_accessor :capture_immediately
26
30
 
27
31
  attr_accessor :card_data
28
32
 
29
33
  attr_accessor :card_entry_mode
30
34
 
35
+ attr_accessor :cardholder_verification_method
36
+
31
37
  attr_accessor :network_token_data
32
38
 
33
39
  attr_accessor :point_of_sale_data
@@ -38,9 +44,11 @@ module Worldline
38
44
  def to_h
39
45
  hash = super
40
46
  hash['brand'] = @brand unless @brand.nil?
47
+ hash['brandSelector'] = @brand_selector unless @brand_selector.nil?
41
48
  hash['captureImmediately'] = @capture_immediately unless @capture_immediately.nil?
42
49
  hash['cardData'] = @card_data.to_h unless @card_data.nil?
43
50
  hash['cardEntryMode'] = @card_entry_mode unless @card_entry_mode.nil?
51
+ hash['cardholderVerificationMethod'] = @cardholder_verification_method unless @cardholder_verification_method.nil?
44
52
  hash['networkTokenData'] = @network_token_data.to_h unless @network_token_data.nil?
45
53
  hash['pointOfSaleData'] = @point_of_sale_data.to_h unless @point_of_sale_data.nil?
46
54
  hash['walletId'] = @wallet_id unless @wallet_id.nil?
@@ -52,6 +60,9 @@ module Worldline
52
60
  if hash.has_key? 'brand'
53
61
  @brand = hash['brand']
54
62
  end
63
+ if hash.has_key? 'brandSelector'
64
+ @brand_selector = hash['brandSelector']
65
+ end
55
66
  if hash.has_key? 'captureImmediately'
56
67
  @capture_immediately = hash['captureImmediately']
57
68
  end
@@ -62,6 +73,9 @@ module Worldline
62
73
  if hash.has_key? 'cardEntryMode'
63
74
  @card_entry_mode = hash['cardEntryMode']
64
75
  end
76
+ if hash.has_key? 'cardholderVerificationMethod'
77
+ @cardholder_verification_method = hash['cardholderVerificationMethod']
78
+ end
65
79
  if hash.has_key? 'networkTokenData'
66
80
  raise TypeError, "value '%s' is not a Hash" % [hash['networkTokenData']] unless hash['networkTokenData'].is_a? Hash
67
81
  @network_token_data = Worldline::Acquiring::SDK::V1::Domain::NetworkTokenData.new_from_hash(hash['networkTokenData'])
@@ -2,7 +2,6 @@
2
2
  # This file was automatically generated.
3
3
  #
4
4
  require 'worldline/acquiring/sdk/domain/data_object'
5
- require 'worldline/acquiring/sdk/v1/domain/point_of_sale_data'
6
5
 
7
6
  module Worldline
8
7
  module Acquiring
@@ -10,18 +9,14 @@ module Worldline
10
9
  module V1
11
10
  module Domain
12
11
  # @attr [String] brand
13
- # @attr [Worldline::Acquiring::SDK::V1::Domain::PointOfSaleData] point_of_sale_data
14
12
  class CardPaymentDataForResource < Worldline::Acquiring::SDK::Domain::DataObject
15
13
 
16
14
  attr_accessor :brand
17
15
 
18
- attr_accessor :point_of_sale_data
19
-
20
16
  # @return (Hash)
21
17
  def to_h
22
18
  hash = super
23
19
  hash['brand'] = @brand unless @brand.nil?
24
- hash['pointOfSaleData'] = @point_of_sale_data.to_h unless @point_of_sale_data.nil?
25
20
  hash
26
21
  end
27
22
 
@@ -30,10 +25,6 @@ module Worldline
30
25
  if hash.has_key? 'brand'
31
26
  @brand = hash['brand']
32
27
  end
33
- if hash.has_key? 'pointOfSaleData'
34
- raise TypeError, "value '%s' is not a Hash" % [hash['pointOfSaleData']] unless hash['pointOfSaleData'].is_a? Hash
35
- @point_of_sale_data = Worldline::Acquiring::SDK::V1::Domain::PointOfSaleData.new_from_hash(hash['pointOfSaleData'])
36
- end
37
28
  end
38
29
  end
39
30
  end
@@ -3,7 +3,7 @@
3
3
  #
4
4
  require 'worldline/acquiring/sdk/domain/data_object'
5
5
  require 'worldline/acquiring/sdk/v1/domain/e_commerce_data_for_response'
6
- require 'worldline/acquiring/sdk/v1/domain/point_of_sale_data'
6
+ require 'worldline/acquiring/sdk/v1/domain/point_of_sale_data_for_response'
7
7
 
8
8
  module Worldline
9
9
  module Acquiring
@@ -12,7 +12,7 @@ module Worldline
12
12
  module Domain
13
13
  # @attr [String] brand
14
14
  # @attr [Worldline::Acquiring::SDK::V1::Domain::ECommerceDataForResponse] ecommerce_data
15
- # @attr [Worldline::Acquiring::SDK::V1::Domain::PointOfSaleData] point_of_sale_data
15
+ # @attr [Worldline::Acquiring::SDK::V1::Domain::PointOfSaleDataForResponse] point_of_sale_data
16
16
  class CardPaymentDataForResponse < Worldline::Acquiring::SDK::Domain::DataObject
17
17
 
18
18
  attr_accessor :brand
@@ -41,7 +41,7 @@ module Worldline
41
41
  end
42
42
  if hash.has_key? 'pointOfSaleData'
43
43
  raise TypeError, "value '%s' is not a Hash" % [hash['pointOfSaleData']] unless hash['pointOfSaleData'].is_a? Hash
44
- @point_of_sale_data = Worldline::Acquiring::SDK::V1::Domain::PointOfSaleData.new_from_hash(hash['pointOfSaleData'])
44
+ @point_of_sale_data = Worldline::Acquiring::SDK::V1::Domain::PointOfSaleDataForResponse.new_from_hash(hash['pointOfSaleData'])
45
45
  end
46
46
  end
47
47
  end
@@ -6,6 +6,7 @@ require 'worldline/acquiring/sdk/v1/domain/card_on_file_data'
6
6
  require 'worldline/acquiring/sdk/v1/domain/e_commerce_data_for_account_verification'
7
7
  require 'worldline/acquiring/sdk/v1/domain/network_token_data'
8
8
  require 'worldline/acquiring/sdk/v1/domain/plain_card_data'
9
+ require 'worldline/acquiring/sdk/v1/domain/point_of_sale_data'
9
10
 
10
11
  module Worldline
11
12
  module Acquiring
@@ -13,17 +14,21 @@ module Worldline
13
14
  module V1
14
15
  module Domain
15
16
  # @attr [String] brand
17
+ # @attr [String] brand_selector
16
18
  # @attr [Worldline::Acquiring::SDK::V1::Domain::PlainCardData] card_data
17
19
  # @attr [String] card_entry_mode
18
20
  # @attr [Worldline::Acquiring::SDK::V1::Domain::CardOnFileData] card_on_file_data
19
21
  # @attr [String] cardholder_verification_method
20
22
  # @attr [Worldline::Acquiring::SDK::V1::Domain::ECommerceDataForAccountVerification] ecommerce_data
21
23
  # @attr [Worldline::Acquiring::SDK::V1::Domain::NetworkTokenData] network_token_data
24
+ # @attr [Worldline::Acquiring::SDK::V1::Domain::PointOfSaleData] point_of_sale_data
22
25
  # @attr [String] wallet_id
23
26
  class CardPaymentDataForVerification < Worldline::Acquiring::SDK::Domain::DataObject
24
27
 
25
28
  attr_accessor :brand
26
29
 
30
+ attr_accessor :brand_selector
31
+
27
32
  attr_accessor :card_data
28
33
 
29
34
  attr_accessor :card_entry_mode
@@ -36,18 +41,22 @@ module Worldline
36
41
 
37
42
  attr_accessor :network_token_data
38
43
 
44
+ attr_accessor :point_of_sale_data
45
+
39
46
  attr_accessor :wallet_id
40
47
 
41
48
  # @return (Hash)
42
49
  def to_h
43
50
  hash = super
44
51
  hash['brand'] = @brand unless @brand.nil?
52
+ hash['brandSelector'] = @brand_selector unless @brand_selector.nil?
45
53
  hash['cardData'] = @card_data.to_h unless @card_data.nil?
46
54
  hash['cardEntryMode'] = @card_entry_mode unless @card_entry_mode.nil?
47
55
  hash['cardOnFileData'] = @card_on_file_data.to_h unless @card_on_file_data.nil?
48
56
  hash['cardholderVerificationMethod'] = @cardholder_verification_method unless @cardholder_verification_method.nil?
49
57
  hash['ecommerceData'] = @ecommerce_data.to_h unless @ecommerce_data.nil?
50
58
  hash['networkTokenData'] = @network_token_data.to_h unless @network_token_data.nil?
59
+ hash['pointOfSaleData'] = @point_of_sale_data.to_h unless @point_of_sale_data.nil?
51
60
  hash['walletId'] = @wallet_id unless @wallet_id.nil?
52
61
  hash
53
62
  end
@@ -57,6 +66,9 @@ module Worldline
57
66
  if hash.has_key? 'brand'
58
67
  @brand = hash['brand']
59
68
  end
69
+ if hash.has_key? 'brandSelector'
70
+ @brand_selector = hash['brandSelector']
71
+ end
60
72
  if hash.has_key? 'cardData'
61
73
  raise TypeError, "value '%s' is not a Hash" % [hash['cardData']] unless hash['cardData'].is_a? Hash
62
74
  @card_data = Worldline::Acquiring::SDK::V1::Domain::PlainCardData.new_from_hash(hash['cardData'])
@@ -79,6 +91,10 @@ module Worldline
79
91
  raise TypeError, "value '%s' is not a Hash" % [hash['networkTokenData']] unless hash['networkTokenData'].is_a? Hash
80
92
  @network_token_data = Worldline::Acquiring::SDK::V1::Domain::NetworkTokenData.new_from_hash(hash['networkTokenData'])
81
93
  end
94
+ if hash.has_key? 'pointOfSaleData'
95
+ raise TypeError, "value '%s' is not a Hash" % [hash['pointOfSaleData']] unless hash['pointOfSaleData'].is_a? Hash
96
+ @point_of_sale_data = Worldline::Acquiring::SDK::V1::Domain::PointOfSaleData.new_from_hash(hash['pointOfSaleData'])
97
+ end
82
98
  if hash.has_key? 'walletId'
83
99
  @wallet_id = hash['walletId']
84
100
  end
@@ -0,0 +1,41 @@
1
+ #
2
+ # This file was automatically generated.
3
+ #
4
+ require 'worldline/acquiring/sdk/domain/data_object'
5
+
6
+ module Worldline
7
+ module Acquiring
8
+ module SDK
9
+ module V1
10
+ module Domain
11
+ # @attr [String] tag
12
+ # @attr [String] value
13
+ class EmvDataItem < Worldline::Acquiring::SDK::Domain::DataObject
14
+
15
+ attr_accessor :tag
16
+
17
+ attr_accessor :value
18
+
19
+ # @return (Hash)
20
+ def to_h
21
+ hash = super
22
+ hash['tag'] = @tag unless @tag.nil?
23
+ hash['value'] = @value unless @value.nil?
24
+ hash
25
+ end
26
+
27
+ def from_hash(hash)
28
+ super
29
+ if hash.has_key? 'tag'
30
+ @tag = hash['tag']
31
+ end
32
+ if hash.has_key? 'value'
33
+ @value = hash['value']
34
+ end
35
+ end
36
+ end
37
+ end
38
+ end
39
+ end
40
+ end
41
+ end
@@ -10,21 +10,17 @@ module Worldline
10
10
  module Domain
11
11
  # @attr [String] dynamic_descriptor
12
12
  # @attr [String] merchant_reference
13
- # @attr [String] retrieval_reference_number
14
13
  class PaymentReferences < Worldline::Acquiring::SDK::Domain::DataObject
15
14
 
16
15
  attr_accessor :dynamic_descriptor
17
16
 
18
17
  attr_accessor :merchant_reference
19
18
 
20
- attr_accessor :retrieval_reference_number
21
-
22
19
  # @return (Hash)
23
20
  def to_h
24
21
  hash = super
25
22
  hash['dynamicDescriptor'] = @dynamic_descriptor unless @dynamic_descriptor.nil?
26
23
  hash['merchantReference'] = @merchant_reference unless @merchant_reference.nil?
27
- hash['retrievalReferenceNumber'] = @retrieval_reference_number unless @retrieval_reference_number.nil?
28
24
  hash
29
25
  end
30
26
 
@@ -36,9 +32,6 @@ module Worldline
36
32
  if hash.has_key? 'merchantReference'
37
33
  @merchant_reference = hash['merchantReference']
38
34
  end
39
- if hash.has_key? 'retrievalReferenceNumber'
40
- @retrieval_reference_number = hash['retrievalReferenceNumber']
41
- end
42
35
  end
43
36
  end
44
37
  end