direct-sdk-ruby 1.5.0 → 1.6.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 594e388fe35c2f7bce9555afebbdcfb98592d38cdc1e8e222c67f6e317b93a39
4
- data.tar.gz: 9f8c21041bc2d15544d78ea1b1854800ef2e41844d279aecc64eebb98ab66cc6
3
+ metadata.gz: cb17a610c0fb3905e0e3d7dd8e6db33920a263eaeeddd2d78d40e3ffa598f6c2
4
+ data.tar.gz: e154fca29cce669b3334129151efc2d89210c43531c46d7d61474b2f7309e9f3
5
5
  SHA512:
6
- metadata.gz: 23d335ce41710fd0f5a9fefb482a13267faf1a032e637ad4208b9240cb6af79bb2c59db91712c416aa51717088a0086c753c48d52eb8aba992ee3b727cb5fa21
7
- data.tar.gz: ed450311f7a896048342b4dd705e9537162ab46541bc7435db27d369362fdb9e429693299ee4aa3de66247cbee6af0d6bd9b1bdbf3a435613a693268587c1685
6
+ metadata.gz: d828e4c95a47a72161750b7886a0458c8bffe03f4d80d65c0518ff23b34718f8a1bed63a247e76d6b99f5fa87a2b07a9c585bdf45e6e3c235ea9a04d9e570f2e
7
+ data.tar.gz: 90f994b1b9f1f47064355a963cc02570910dbf35789e77d3b71bcb49ed63d194e60971104a57077d6f9c4febcc2da19939c911c2e65d3f252fcdac3cabee49fe
@@ -1,6 +1,6 @@
1
1
  Gem::Specification.new do |spec|
2
2
  spec.name = 'direct-sdk-ruby'
3
- spec.version = '1.5.0'
3
+ spec.version = '1.6.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}
@@ -5,13 +5,16 @@
5
5
  require 'ingenico/direct/sdk/data_object'
6
6
  require 'ingenico/direct/sdk/domain/card_essentials'
7
7
  require 'ingenico/direct/sdk/domain/card_fraud_results'
8
+ require 'ingenico/direct/sdk/domain/external_token_linked'
8
9
  require 'ingenico/direct/sdk/domain/three_d_secure_results'
9
10
 
10
11
  module Ingenico::Direct::SDK
11
12
  module Domain
12
13
 
14
+ # @attr [Long] authenticated_amount
13
15
  # @attr [String] authorisation_code
14
16
  # @attr [Ingenico::Direct::SDK::Domain::CardEssentials] card
17
+ # @attr [Ingenico::Direct::SDK::Domain::ExternalTokenLinked] external_token_linked
15
18
  # @attr [Ingenico::Direct::SDK::Domain::CardFraudResults] fraud_results
16
19
  # @attr [String] initial_scheme_transaction_id
17
20
  # @attr [String] payment_option
@@ -19,8 +22,10 @@ module Ingenico::Direct::SDK
19
22
  # @attr [Ingenico::Direct::SDK::Domain::ThreeDSecureResults] three_d_secure_results
20
23
  # @attr [String] token
21
24
  class CardPaymentMethodSpecificOutput < Ingenico::Direct::SDK::DataObject
25
+ attr_accessor :authenticated_amount
22
26
  attr_accessor :authorisation_code
23
27
  attr_accessor :card
28
+ attr_accessor :external_token_linked
24
29
  attr_accessor :fraud_results
25
30
  attr_accessor :initial_scheme_transaction_id
26
31
  attr_accessor :payment_option
@@ -31,8 +36,10 @@ module Ingenico::Direct::SDK
31
36
  # @return (Hash)
32
37
  def to_h
33
38
  hash = super
39
+ hash['authenticatedAmount'] = @authenticated_amount unless @authenticated_amount.nil?
34
40
  hash['authorisationCode'] = @authorisation_code unless @authorisation_code.nil?
35
41
  hash['card'] = @card.to_h if @card
42
+ hash['externalTokenLinked'] = @external_token_linked.to_h if @external_token_linked
36
43
  hash['fraudResults'] = @fraud_results.to_h if @fraud_results
37
44
  hash['initialSchemeTransactionId'] = @initial_scheme_transaction_id unless @initial_scheme_transaction_id.nil?
38
45
  hash['paymentOption'] = @payment_option unless @payment_option.nil?
@@ -44,11 +51,16 @@ module Ingenico::Direct::SDK
44
51
 
45
52
  def from_hash(hash)
46
53
  super
54
+ @authenticated_amount = hash['authenticatedAmount'] if hash.key? 'authenticatedAmount'
47
55
  @authorisation_code = hash['authorisationCode'] if hash.key? 'authorisationCode'
48
56
  if hash.key? 'card'
49
57
  raise TypeError, "value '%s' is not a Hash" % [hash['card']] unless hash['card'].is_a? Hash
50
58
  @card = Ingenico::Direct::SDK::Domain::CardEssentials.new_from_hash(hash['card'])
51
59
  end
60
+ if hash.key? 'externalTokenLinked'
61
+ raise TypeError, "value '%s' is not a Hash" % [hash['externalTokenLinked']] unless hash['externalTokenLinked'].is_a? Hash
62
+ @external_token_linked = Ingenico::Direct::SDK::Domain::ExternalTokenLinked.new_from_hash(hash['externalTokenLinked'])
63
+ end
52
64
  if hash.key? 'fraudResults'
53
65
  raise TypeError, "value '%s' is not a Hash" % [hash['fraudResults']] unless hash['fraudResults'].is_a? Hash
54
66
  @fraud_results = Ingenico::Direct::SDK::Domain::CardFraudResults.new_from_hash(hash['fraudResults'])
@@ -7,20 +7,28 @@ require 'ingenico/direct/sdk/data_object'
7
7
  module Ingenico::Direct::SDK
8
8
  module Domain
9
9
 
10
+ # @attr [String] computed_token
10
11
  # @attr [String] gts_computed_token
12
+ # @attr [String] generated_token
11
13
  class ExternalTokenLinked < Ingenico::Direct::SDK::DataObject
14
+ attr_accessor :computed_token
12
15
  attr_accessor :gts_computed_token
16
+ attr_accessor :generated_token
13
17
 
14
18
  # @return (Hash)
15
19
  def to_h
16
20
  hash = super
21
+ hash['ComputedToken'] = @computed_token unless @computed_token.nil?
17
22
  hash['GTSComputedToken'] = @gts_computed_token unless @gts_computed_token.nil?
23
+ hash['GeneratedToken'] = @generated_token unless @generated_token.nil?
18
24
  hash
19
25
  end
20
26
 
21
27
  def from_hash(hash)
22
28
  super
29
+ @computed_token = hash['ComputedToken'] if hash.key? 'ComputedToken'
23
30
  @gts_computed_token = hash['GTSComputedToken'] if hash.key? 'GTSComputedToken'
31
+ @generated_token = hash['GeneratedToken'] if hash.key? 'GeneratedToken'
24
32
  end
25
33
  end
26
34
  end
@@ -10,6 +10,7 @@ require 'ingenico/direct/sdk/domain/three_d_secure_data'
10
10
  module Ingenico::Direct::SDK
11
11
  module Domain
12
12
 
13
+ # @attr [Long] authentication_amount
13
14
  # @attr [String] challenge_canvas_size
14
15
  # @attr [String] challenge_indicator
15
16
  # @attr [String] exemption_request
@@ -21,6 +22,7 @@ module Ingenico::Direct::SDK
21
22
  # @attr [true/false] skip_authentication
22
23
  # @attr [true/false] skip_soft_decline
23
24
  class ThreeDSecure < Ingenico::Direct::SDK::DataObject
25
+ attr_accessor :authentication_amount
24
26
  attr_accessor :challenge_canvas_size
25
27
  attr_accessor :challenge_indicator
26
28
  attr_accessor :exemption_request
@@ -35,6 +37,7 @@ module Ingenico::Direct::SDK
35
37
  # @return (Hash)
36
38
  def to_h
37
39
  hash = super
40
+ hash['authenticationAmount'] = @authentication_amount unless @authentication_amount.nil?
38
41
  hash['challengeCanvasSize'] = @challenge_canvas_size unless @challenge_canvas_size.nil?
39
42
  hash['challengeIndicator'] = @challenge_indicator unless @challenge_indicator.nil?
40
43
  hash['exemptionRequest'] = @exemption_request unless @exemption_request.nil?
@@ -50,6 +53,7 @@ module Ingenico::Direct::SDK
50
53
 
51
54
  def from_hash(hash)
52
55
  super
56
+ @authentication_amount = hash['authenticationAmount'] if hash.key? 'authenticationAmount'
53
57
  @challenge_canvas_size = hash['challengeCanvasSize'] if hash.key? 'challengeCanvasSize'
54
58
  @challenge_indicator = hash['challengeIndicator'] if hash.key? 'challengeIndicator'
55
59
  @exemption_request = hash['exemptionRequest'] if hash.key? 'exemptionRequest'
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.5.0
4
+ version: 1.6.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-09-09 00:00:00.000000000 Z
11
+ date: 2021-10-01 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: httpclient