connect-sdk-ruby 1.15.0 → 1.16.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: 60d2b09edea200a56f2c7f531df2fbb1cba07b99c652e6bf175df68a42d4190d
4
- data.tar.gz: 1548c437ca4f0af5a03dfb83b75b10f2120fe8e12e364e86703a7f178bef7be1
3
+ metadata.gz: ef1b29b7c2c9cd260773a4aff6e82cda43bfdf5709b699552caeb9e1f34384d8
4
+ data.tar.gz: 11fc21a923b380b6d5e7ddc045212afd26d2bf5b87d7c7820d57355e59046e6b
5
5
  SHA512:
6
- metadata.gz: 3fc58cb465cf11c3efde6b7dfb9659dd57e9c6aa811570423a311913d5cea6d12e501954f333719d42ec841545ad3fa82c3d4b230f0b150ab187e44566158b55
7
- data.tar.gz: 7a6ca83a0dbed0ddaeea333bd1eaad2ad07100a69dbab5a1aa5fa115efb266a69ca5fb8ae553fb27802b56bd37e7c320ccddf0be85f0c5103692931fd64a4467
6
+ metadata.gz: a48cfe0ea406e8982eaa2d207353108cb4ebfaf06c73d1195c591adb2e8f7d67df8c44071b17dec66b8d4d893f625a66e6a0d137520638dc6e79ae85428a53df
7
+ data.tar.gz: f8aa4f3359ecf4c5db2298643650aaf49c204a1039855ce5ca598a468bfd11154d48f7a325b750f02c02c2321cf20d62fc8d3e507f6daa11e390da68f8270993
@@ -1,6 +1,6 @@
1
1
  Gem::Specification.new do |spec|
2
2
  spec.name = 'connect-sdk-ruby'
3
- spec.version = '1.15.0'
3
+ spec.version = '1.16.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}
@@ -4,6 +4,7 @@
4
4
  #
5
5
  require 'ingenico/connect/sdk/data_object'
6
6
  require 'ingenico/connect/sdk/domain/definitions/airline_flight_leg'
7
+ require 'ingenico/connect/sdk/domain/definitions/airline_passenger'
7
8
 
8
9
  module Ingenico::Connect::SDK
9
10
  module Domain
@@ -50,6 +51,9 @@ module Ingenico::Connect::SDK
50
51
  # String
51
52
  attr_accessor :passenger_name
52
53
 
54
+ # Array of {Ingenico::Connect::SDK::Domain::Definitions::AirlinePassenger}
55
+ attr_accessor :passengers
56
+
53
57
  # String
54
58
  attr_accessor :place_of_issue
55
59
 
@@ -83,6 +87,7 @@ module Ingenico::Connect::SDK
83
87
  add_to_hash(hash, 'merchantCustomerId', @merchant_customer_id)
84
88
  add_to_hash(hash, 'name', @name)
85
89
  add_to_hash(hash, 'passengerName', @passenger_name)
90
+ add_to_hash(hash, 'passengers', @passengers)
86
91
  add_to_hash(hash, 'placeOfIssue', @place_of_issue)
87
92
  add_to_hash(hash, 'pnr', @pnr)
88
93
  add_to_hash(hash, 'pointOfSale', @point_of_sale)
@@ -139,6 +144,15 @@ module Ingenico::Connect::SDK
139
144
  if hash.has_key?('passengerName')
140
145
  @passenger_name = hash['passengerName']
141
146
  end
147
+ if hash.has_key?('passengers')
148
+ if !(hash['passengers'].is_a? Array)
149
+ raise TypeError, "value '%s' is not an Array" % [hash['passengers']]
150
+ end
151
+ @passengers = []
152
+ hash['passengers'].each do |e|
153
+ @passengers << Ingenico::Connect::SDK::Domain::Definitions::AirlinePassenger.new_from_hash(e)
154
+ end
155
+ end
142
156
  if hash.has_key?('placeOfIssue')
143
157
  @place_of_issue = hash['placeOfIssue']
144
158
  end
@@ -40,6 +40,9 @@ module Ingenico::Connect::SDK
40
40
  # String
41
41
  attr_accessor :origin_airport
42
42
 
43
+ # String
44
+ attr_accessor :service_class
45
+
43
46
  # String
44
47
  attr_accessor :stopover_code
45
48
 
@@ -55,6 +58,7 @@ module Ingenico::Connect::SDK
55
58
  add_to_hash(hash, 'flightNumber', @flight_number)
56
59
  add_to_hash(hash, 'number', @number)
57
60
  add_to_hash(hash, 'originAirport', @origin_airport)
61
+ add_to_hash(hash, 'serviceClass', @service_class)
58
62
  add_to_hash(hash, 'stopoverCode', @stopover_code)
59
63
  hash
60
64
  end
@@ -91,6 +95,9 @@ module Ingenico::Connect::SDK
91
95
  if hash.has_key?('originAirport')
92
96
  @origin_airport = hash['originAirport']
93
97
  end
98
+ if hash.has_key?('serviceClass')
99
+ @service_class = hash['serviceClass']
100
+ end
94
101
  if hash.has_key?('stopoverCode')
95
102
  @stopover_code = hash['stopoverCode']
96
103
  end
@@ -0,0 +1,52 @@
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 Definitions
10
+
11
+ class AirlinePassenger < Ingenico::Connect::SDK::DataObject
12
+
13
+ # String
14
+ attr_accessor :first_name
15
+
16
+ # String
17
+ attr_accessor :surname
18
+
19
+ # String
20
+ attr_accessor :surname_prefix
21
+
22
+ # String
23
+ attr_accessor :title
24
+
25
+ def to_h
26
+ hash = super
27
+ add_to_hash(hash, 'firstName', @first_name)
28
+ add_to_hash(hash, 'surname', @surname)
29
+ add_to_hash(hash, 'surnamePrefix', @surname_prefix)
30
+ add_to_hash(hash, 'title', @title)
31
+ hash
32
+ end
33
+
34
+ def from_hash(hash)
35
+ super
36
+ if hash.has_key?('firstName')
37
+ @first_name = hash['firstName']
38
+ end
39
+ if hash.has_key?('surname')
40
+ @surname = hash['surname']
41
+ end
42
+ if hash.has_key?('surnamePrefix')
43
+ @surname_prefix = hash['surnamePrefix']
44
+ end
45
+ if hash.has_key?('title')
46
+ @title = hash['title']
47
+ end
48
+ end
49
+ end
50
+ end
51
+ end
52
+ end
@@ -11,6 +11,9 @@ module Ingenico::Connect::SDK
11
11
 
12
12
  class CreateMandateBase < Ingenico::Connect::SDK::DataObject
13
13
 
14
+ # String
15
+ attr_accessor :alias
16
+
14
17
  # {Ingenico::Connect::SDK::Domain::Mandates::MandateCustomer}
15
18
  attr_accessor :customer
16
19
 
@@ -28,6 +31,7 @@ module Ingenico::Connect::SDK
28
31
 
29
32
  def to_h
30
33
  hash = super
34
+ add_to_hash(hash, 'alias', @alias)
31
35
  add_to_hash(hash, 'customer', @customer)
32
36
  add_to_hash(hash, 'customerReference', @customer_reference)
33
37
  add_to_hash(hash, 'language', @language)
@@ -38,6 +42,9 @@ module Ingenico::Connect::SDK
38
42
 
39
43
  def from_hash(hash)
40
44
  super
45
+ if hash.has_key?('alias')
46
+ @alias = hash['alias']
47
+ end
41
48
  if hash.has_key?('customer')
42
49
  if !(hash['customer'].is_a? Hash)
43
50
  raise TypeError, "value '%s' is not a Hash" % [hash['customer']]
@@ -11,6 +11,9 @@ module Ingenico::Connect::SDK
11
11
 
12
12
  class MandateResponse < Ingenico::Connect::SDK::DataObject
13
13
 
14
+ # String
15
+ attr_accessor :alias
16
+
14
17
  # {Ingenico::Connect::SDK::Domain::Mandates::MandateCustomer}
15
18
  attr_accessor :customer
16
19
 
@@ -28,6 +31,7 @@ module Ingenico::Connect::SDK
28
31
 
29
32
  def to_h
30
33
  hash = super
34
+ add_to_hash(hash, 'alias', @alias)
31
35
  add_to_hash(hash, 'customer', @customer)
32
36
  add_to_hash(hash, 'customerReference', @customer_reference)
33
37
  add_to_hash(hash, 'recurrenceType', @recurrence_type)
@@ -38,6 +42,9 @@ module Ingenico::Connect::SDK
38
42
 
39
43
  def from_hash(hash)
40
44
  super
45
+ if hash.has_key?('alias')
46
+ @alias = hash['alias']
47
+ end
41
48
  if hash.has_key?('customer')
42
49
  if !(hash['customer'].is_a? Hash)
43
50
  raise TypeError, "value '%s' is not a Hash" % [hash['customer']]
@@ -0,0 +1,38 @@
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
+ class HostedCheckoutSpecificOutput < Ingenico::Connect::SDK::DataObject
12
+
13
+ # String
14
+ attr_accessor :hosted_checkout_id
15
+
16
+ # String
17
+ attr_accessor :variant
18
+
19
+ def to_h
20
+ hash = super
21
+ add_to_hash(hash, 'hostedCheckoutId', @hosted_checkout_id)
22
+ add_to_hash(hash, 'variant', @variant)
23
+ hash
24
+ end
25
+
26
+ def from_hash(hash)
27
+ super
28
+ if hash.has_key?('hostedCheckoutId')
29
+ @hosted_checkout_id = hash['hostedCheckoutId']
30
+ end
31
+ if hash.has_key?('variant')
32
+ @variant = hash['variant']
33
+ end
34
+ end
35
+ end
36
+ end
37
+ end
38
+ end
@@ -3,6 +3,7 @@
3
3
  # https://epayments-api.developer-ingenico.com/s2sapi/v1/
4
4
  #
5
5
  require 'ingenico/connect/sdk/domain/definitions/abstract_order_status'
6
+ require 'ingenico/connect/sdk/domain/payment/hosted_checkout_specific_output'
6
7
  require 'ingenico/connect/sdk/domain/payment/payment_output'
7
8
  require 'ingenico/connect/sdk/domain/payment/payment_status_output'
8
9
 
@@ -12,6 +13,9 @@ module Ingenico::Connect::SDK
12
13
 
13
14
  class Payment < Ingenico::Connect::SDK::Domain::Definitions::AbstractOrderStatus
14
15
 
16
+ # {Ingenico::Connect::SDK::Domain::Payment::HostedCheckoutSpecificOutput}
17
+ attr_accessor :hosted_checkout_specific_output
18
+
15
19
  # {Ingenico::Connect::SDK::Domain::Payment::PaymentOutput}
16
20
  attr_accessor :payment_output
17
21
 
@@ -23,6 +27,7 @@ module Ingenico::Connect::SDK
23
27
 
24
28
  def to_h
25
29
  hash = super
30
+ add_to_hash(hash, 'hostedCheckoutSpecificOutput', @hosted_checkout_specific_output)
26
31
  add_to_hash(hash, 'paymentOutput', @payment_output)
27
32
  add_to_hash(hash, 'status', @status)
28
33
  add_to_hash(hash, 'statusOutput', @status_output)
@@ -31,6 +36,12 @@ module Ingenico::Connect::SDK
31
36
 
32
37
  def from_hash(hash)
33
38
  super
39
+ if hash.has_key?('hostedCheckoutSpecificOutput')
40
+ if !(hash['hostedCheckoutSpecificOutput'].is_a? Hash)
41
+ raise TypeError, "value '%s' is not a Hash" % [hash['hostedCheckoutSpecificOutput']]
42
+ end
43
+ @hosted_checkout_specific_output = Ingenico::Connect::SDK::Domain::Payment::HostedCheckoutSpecificOutput.new_from_hash(hash['hostedCheckoutSpecificOutput'])
44
+ end
34
45
  if hash.has_key?('paymentOutput')
35
46
  if !(hash['paymentOutput'].is_a? Hash)
36
47
  raise TypeError, "value '%s' is not a Hash" % [hash['paymentOutput']]
@@ -3,6 +3,7 @@
3
3
  # https://epayments-api.developer-ingenico.com/s2sapi/v1/
4
4
  #
5
5
  require 'ingenico/connect/sdk/domain/definitions/bank_account_iban'
6
+ require 'ingenico/connect/sdk/domain/definitions/fraud_results'
6
7
  require 'ingenico/connect/sdk/domain/payment/abstract_payment_method_specific_output'
7
8
  require 'ingenico/connect/sdk/domain/payment/payment_product836_specific_output'
8
9
  require 'ingenico/connect/sdk/domain/payment/payment_product840_specific_output'
@@ -16,6 +17,9 @@ module Ingenico::Connect::SDK
16
17
  # {Ingenico::Connect::SDK::Domain::Definitions::BankAccountIban}
17
18
  attr_accessor :bank_account_iban
18
19
 
20
+ # {Ingenico::Connect::SDK::Domain::Definitions::FraudResults}
21
+ attr_accessor :fraud_results
22
+
19
23
  # {Ingenico::Connect::SDK::Domain::Payment::PaymentProduct836SpecificOutput}
20
24
  attr_accessor :payment_product836_specific_output
21
25
 
@@ -25,6 +29,7 @@ module Ingenico::Connect::SDK
25
29
  def to_h
26
30
  hash = super
27
31
  add_to_hash(hash, 'bankAccountIban', @bank_account_iban)
32
+ add_to_hash(hash, 'fraudResults', @fraud_results)
28
33
  add_to_hash(hash, 'paymentProduct836SpecificOutput', @payment_product836_specific_output)
29
34
  add_to_hash(hash, 'paymentProduct840SpecificOutput', @payment_product840_specific_output)
30
35
  hash
@@ -38,6 +43,12 @@ module Ingenico::Connect::SDK
38
43
  end
39
44
  @bank_account_iban = Ingenico::Connect::SDK::Domain::Definitions::BankAccountIban.new_from_hash(hash['bankAccountIban'])
40
45
  end
46
+ if hash.has_key?('fraudResults')
47
+ if !(hash['fraudResults'].is_a? Hash)
48
+ raise TypeError, "value '%s' is not a Hash" % [hash['fraudResults']]
49
+ end
50
+ @fraud_results = Ingenico::Connect::SDK::Domain::Definitions::FraudResults.new_from_hash(hash['fraudResults'])
51
+ end
41
52
  if hash.has_key?('paymentProduct836SpecificOutput')
42
53
  if !(hash['paymentProduct836SpecificOutput'].is_a? Hash)
43
54
  raise TypeError, "value '%s' is not a Hash" % [hash['paymentProduct836SpecificOutput']]
@@ -10,6 +10,12 @@ module Ingenico::Connect::SDK
10
10
 
11
11
  class SessionResponse < Ingenico::Connect::SDK::DataObject
12
12
 
13
+ # String
14
+ attr_accessor :asset_url
15
+
16
+ # String
17
+ attr_accessor :client_api_url
18
+
13
19
  # String
14
20
  attr_accessor :client_session_id
15
21
 
@@ -24,6 +30,8 @@ module Ingenico::Connect::SDK
24
30
 
25
31
  def to_h
26
32
  hash = super
33
+ add_to_hash(hash, 'assetUrl', @asset_url)
34
+ add_to_hash(hash, 'clientApiUrl', @client_api_url)
27
35
  add_to_hash(hash, 'clientSessionId', @client_session_id)
28
36
  add_to_hash(hash, 'customerId', @customer_id)
29
37
  add_to_hash(hash, 'invalidTokens', @invalid_tokens)
@@ -33,6 +41,12 @@ module Ingenico::Connect::SDK
33
41
 
34
42
  def from_hash(hash)
35
43
  super
44
+ if hash.has_key?('assetUrl')
45
+ @asset_url = hash['assetUrl']
46
+ end
47
+ if hash.has_key?('clientApiUrl')
48
+ @client_api_url = hash['clientApiUrl']
49
+ end
36
50
  if hash.has_key?('clientSessionId')
37
51
  @client_session_id = hash['clientSessionId']
38
52
  end
@@ -5,7 +5,7 @@ module Ingenico::Connect::SDK
5
5
 
6
6
  # Manages metadata about the server using the SDK
7
7
  class MetaDataProvider
8
- @@SDK_VERSION = '1.15.0'
8
+ @@SDK_VERSION = '1.16.0'
9
9
  @@SERVER_META_INFO_HEADER = 'X-GCS-ServerMetaInfo'
10
10
  @@PROHIBITED_HEADERS = [@@SERVER_META_INFO_HEADER, 'X-GCS-Idempotence-Key',
11
11
  '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: 1.15.0
4
+ version: 1.16.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: 2017-12-06 00:00:00.000000000 Z
11
+ date: 2017-12-18 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: httpclient
@@ -206,6 +206,7 @@ files:
206
206
  - lib/ingenico/connect/sdk/domain/definitions/address.rb
207
207
  - lib/ingenico/connect/sdk/domain/definitions/airline_data.rb
208
208
  - lib/ingenico/connect/sdk/domain/definitions/airline_flight_leg.rb
209
+ - lib/ingenico/connect/sdk/domain/definitions/airline_passenger.rb
209
210
  - lib/ingenico/connect/sdk/domain/definitions/amount_of_money.rb
210
211
  - lib/ingenico/connect/sdk/domain/definitions/bank_account.rb
211
212
  - lib/ingenico/connect/sdk/domain/definitions/bank_account_bban.rb
@@ -298,6 +299,7 @@ files:
298
299
  - lib/ingenico/connect/sdk/domain/payment/e_invoice_payment_product9000_specific_output.rb
299
300
  - lib/ingenico/connect/sdk/domain/payment/external_cardholder_authentication_data.rb
300
301
  - lib/ingenico/connect/sdk/domain/payment/find_payments_response.rb
302
+ - lib/ingenico/connect/sdk/domain/payment/hosted_checkout_specific_output.rb
301
303
  - lib/ingenico/connect/sdk/domain/payment/invoice_payment_method_specific_input.rb
302
304
  - lib/ingenico/connect/sdk/domain/payment/invoice_payment_method_specific_output.rb
303
305
  - lib/ingenico/connect/sdk/domain/payment/level3_summary_data.rb