connect-sdk-ruby 2.0.0 → 2.1.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: 5940613b410d1daae1a7b9985eb7611905ba2bf091a5de2c2b7d62be5805b05a
4
- data.tar.gz: fabecd05da645f74cdd5dd4e7a5e7e578a19225c7bb4038cfa075e8c52158cd3
3
+ metadata.gz: 4f4268a4082684a120a81e66f4e9e44574811deac0902eaf521e96ff3207bcc1
4
+ data.tar.gz: 748d2f68aaa10ada9a3458c2e0a96ce1a6c4612148be53085f77cfab3b112695
5
5
  SHA512:
6
- metadata.gz: 97e05f49e4cfa01b4b05ecee08202bd97cfaf976fcb79362da89875aa83dd61fab86908f6c42fbf2b6ae1e27b938cc640a04b3b9d98543ae13be76d722206610
7
- data.tar.gz: f2e42a9c667b29b8bce29ec6bf3e1ab9e7c255dd6fe2808ed501c7cb29a051b48195198c2a94c122f4824fe0f026c92c5a17e5e2c6d6b9eafe4aed7f21255eb8
6
+ metadata.gz: 2028c956fee0b36ddc2ed9cb8a941fd341a17effd11520f5dfa990fc3d5d217596a473d3378ee25f2f8e2e6336a4233df85b24ec8500da37ae2f325821c0a3b4
7
+ data.tar.gz: 65379df87b193cd17bd9bf2a6d7a13626b1ed0fb83eddfef3e03c6c7541e000fd846e8e61096b2f17fb9e2eeeffa725094a3d60faae1704e9f39f774ffb9234a
@@ -1,6 +1,6 @@
1
1
  Gem::Specification.new do |spec|
2
2
  spec.name = 'connect-sdk-ruby'
3
- spec.version = '2.0.0'
3
+ spec.version = '2.1.0'
4
4
  spec.authors = ['Ingenico ePayments']
5
5
  spec.email = ['github@epay.ingenico.com']
6
6
  spec.summary = %q{SDK to communicate with the Ingenico ePayments platform using the Ingenico Connect Server API}
@@ -5,6 +5,7 @@
5
5
  require 'ingenico/connect/sdk/data_object'
6
6
  require 'ingenico/connect/sdk/domain/definitions/airline_data'
7
7
  require 'ingenico/connect/sdk/domain/payment/level3_summary_data'
8
+ require 'ingenico/connect/sdk/domain/payment/loan_recipient'
8
9
  require 'ingenico/connect/sdk/domain/payment/order_type_information'
9
10
 
10
11
  module Ingenico::Connect::SDK
@@ -13,6 +14,7 @@ module Ingenico::Connect::SDK
13
14
 
14
15
  # @attr [Ingenico::Connect::SDK::Domain::Definitions::AirlineData] airline_data
15
16
  # @attr [Ingenico::Connect::SDK::Domain::Payment::Level3SummaryData] level3_summary_data
17
+ # @attr [Ingenico::Connect::SDK::Domain::Payment::LoanRecipient] loan_recipient
16
18
  # @attr [Integer] number_of_installments
17
19
  # @attr [String] order_date
18
20
  # @attr [Ingenico::Connect::SDK::Domain::Payment::OrderTypeInformation] type_information
@@ -24,6 +26,8 @@ module Ingenico::Connect::SDK
24
26
  # @deprecated Use Order.shoppingCart.amountBreakdown instead
25
27
  attr_accessor :level3_summary_data
26
28
 
29
+ attr_accessor :loan_recipient
30
+
27
31
  attr_accessor :number_of_installments
28
32
 
29
33
  attr_accessor :order_date
@@ -35,6 +39,7 @@ module Ingenico::Connect::SDK
35
39
  hash = super
36
40
  hash['airlineData'] = @airline_data.to_h unless @airline_data.nil?
37
41
  hash['level3SummaryData'] = @level3_summary_data.to_h unless @level3_summary_data.nil?
42
+ hash['loanRecipient'] = @loan_recipient.to_h unless @loan_recipient.nil?
38
43
  hash['numberOfInstallments'] = @number_of_installments unless @number_of_installments.nil?
39
44
  hash['orderDate'] = @order_date unless @order_date.nil?
40
45
  hash['typeInformation'] = @type_information.to_h unless @type_information.nil?
@@ -51,6 +56,10 @@ module Ingenico::Connect::SDK
51
56
  raise TypeError, "value '%s' is not a Hash" % [hash['level3SummaryData']] unless hash['level3SummaryData'].is_a? Hash
52
57
  @level3_summary_data = Ingenico::Connect::SDK::Domain::Payment::Level3SummaryData.new_from_hash(hash['level3SummaryData'])
53
58
  end
59
+ if hash.has_key? 'loanRecipient'
60
+ raise TypeError, "value '%s' is not a Hash" % [hash['loanRecipient']] unless hash['loanRecipient'].is_a? Hash
61
+ @loan_recipient = Ingenico::Connect::SDK::Domain::Payment::LoanRecipient.new_from_hash(hash['loanRecipient'])
62
+ end
54
63
  if hash.has_key? 'numberOfInstallments'
55
64
  @number_of_installments = hash['numberOfInstallments']
56
65
  end
@@ -0,0 +1,60 @@
1
+ #
2
+ # This class was auto-generated from the API references found at
3
+ # https://epayments-api.developer-ingenico.com/s2sapi/v1/
4
+ #
5
+ require 'ingenico/connect/sdk/data_object'
6
+
7
+ module Ingenico::Connect::SDK
8
+ module Domain
9
+ module Payment
10
+
11
+ # @attr [String] account_number
12
+ # @attr [String] date_of_birth
13
+ # @attr [String] partial_pan
14
+ # @attr [String] surname
15
+ # @attr [String] zip
16
+ class LoanRecipient < Ingenico::Connect::SDK::DataObject
17
+
18
+ attr_accessor :account_number
19
+
20
+ attr_accessor :date_of_birth
21
+
22
+ attr_accessor :partial_pan
23
+
24
+ attr_accessor :surname
25
+
26
+ attr_accessor :zip
27
+
28
+ # @return (Hash)
29
+ def to_h
30
+ hash = super
31
+ hash['accountNumber'] = @account_number unless @account_number.nil?
32
+ hash['dateOfBirth'] = @date_of_birth unless @date_of_birth.nil?
33
+ hash['partialPan'] = @partial_pan unless @partial_pan.nil?
34
+ hash['surname'] = @surname unless @surname.nil?
35
+ hash['zip'] = @zip unless @zip.nil?
36
+ hash
37
+ end
38
+
39
+ def from_hash(hash)
40
+ super
41
+ if hash.has_key? 'accountNumber'
42
+ @account_number = hash['accountNumber']
43
+ end
44
+ if hash.has_key? 'dateOfBirth'
45
+ @date_of_birth = hash['dateOfBirth']
46
+ end
47
+ if hash.has_key? 'partialPan'
48
+ @partial_pan = hash['partialPan']
49
+ end
50
+ if hash.has_key? 'surname'
51
+ @surname = hash['surname']
52
+ end
53
+ if hash.has_key? 'zip'
54
+ @zip = hash['zip']
55
+ end
56
+ end
57
+ end
58
+ end
59
+ end
60
+ end
@@ -7,7 +7,7 @@ module Ingenico::Connect::SDK
7
7
  #
8
8
  # @attr_reader [Array<Ingenico::Connect::SDK::RequestHeader>] meta_data_headers List of headers that should be used in all requests.
9
9
  class MetaDataProvider
10
- @@SDK_VERSION = '2.0.0'
10
+ @@SDK_VERSION = '2.1.0'
11
11
  @@SERVER_META_INFO_HEADER = 'X-GCS-ServerMetaInfo'
12
12
  @@PROHIBITED_HEADERS = [@@SERVER_META_INFO_HEADER, 'X-GCS-Idempotence-Key',
13
13
  'Date', 'Content-Type', 'Authorization'].sort!.freeze
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: connect-sdk-ruby
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.0.0
4
+ version: 2.1.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: 2019-06-21 00:00:00.000000000 Z
11
+ date: 2019-07-04 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: httpclient
@@ -358,6 +358,7 @@ files:
358
358
  - lib/ingenico/connect/sdk/domain/payment/line_item.rb
359
359
  - lib/ingenico/connect/sdk/domain/payment/line_item_invoice_data.rb
360
360
  - lib/ingenico/connect/sdk/domain/payment/line_item_level3_interchange_information.rb
361
+ - lib/ingenico/connect/sdk/domain/payment/loan_recipient.rb
361
362
  - lib/ingenico/connect/sdk/domain/payment/merchant.rb
362
363
  - lib/ingenico/connect/sdk/domain/payment/merchant_action.rb
363
364
  - lib/ingenico/connect/sdk/domain/payment/mobile_payment_data.rb