checkout_sdk 1.1.1 → 1.1.3

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: 0b0cbb27631e24299c7ede3691d5f5a4e6b3e1de9c44a77f2bedb1fedd90d892
4
- data.tar.gz: d992578ab186e20d5500a50cb6f62da4b6c34f324d249a1ade01e983314a0c20
3
+ metadata.gz: fe4967d92854672d3668f97b925b4d66e4ceb1bf08374ce054766596fe2b0181
4
+ data.tar.gz: 9ba27b9aea9e2eda47755455da5770383b3fa7ec9892c49dc68b81d8b680ff34
5
5
  SHA512:
6
- metadata.gz: da7647b821d5754b94200c47589994f77baaae74acb1e29c4430f6e3fe8aece291e5425c98708d69a02b7aa7af59cbe140b37d03d6227503e936e8972dce7ff6
7
- data.tar.gz: a8dbbf80e9af1323674f2bd2270f26888281e0d038c918e9bf50b6ba7f35ff23bd64e4f1e58761dfe3c9a5cf4c9c7ff68d2ed6c5307a0a5f74d4325bfb888f15
6
+ metadata.gz: 82e3fbe3f10193ee8655553b58596fd6821d1b52dc1789e895daedb9f818c43b28a27a5db5c245703046ac24a402a3d5b8ec36efcd2019e02ea0ff3174394038
7
+ data.tar.gz: ba39851f661ef0885e35f8b2cd94025d358ce4ecaad015c8e14f43bbe97f04c9a62004f0620b1e2523744cb3b2117748563e3d2f717d0de4c1ba98886fbdd7a4
@@ -31,6 +31,8 @@ require 'checkout_sdk/accounts/schedule_frequency_monthly'
31
31
  require 'checkout_sdk/accounts/instrument_details'
32
32
  require 'checkout_sdk/accounts/instrument_details_faster_payments'
33
33
  require 'checkout_sdk/accounts/instrument_details_sepa'
34
+ require 'checkout_sdk/accounts/instrument_details_card_token'
34
35
  require 'checkout_sdk/accounts/payment_instrument_request'
35
36
  require 'checkout_sdk/accounts/payment_instruments_query'
37
+ require 'checkout_sdk/accounts/headers'
36
38
  require 'checkout_sdk/accounts/update_payment_instrument_request'
@@ -0,0 +1,11 @@
1
+ # frozen_string_literal: true
2
+
3
+ module CheckoutSdk
4
+ module Accounts
5
+ # @!attribute if_match
6
+ # @return [String]
7
+ class Headers
8
+ attr_accessor :if_match
9
+ end
10
+ end
11
+ end
@@ -0,0 +1,11 @@
1
+ # frozen_string_literal: true
2
+
3
+ module CheckoutSdk
4
+ module Accounts
5
+ # @!attribute token
6
+ # @return [String]
7
+ class InstrumentDetailsCardToken < InstrumentDetails
8
+ attr_accessor :token
9
+ end
10
+ end
11
+ end
@@ -24,10 +24,6 @@ module CheckoutSdk
24
24
  :default,
25
25
  :document,
26
26
  :instrument_details
27
-
28
- def initialize
29
- @type = CheckoutSdk::Common::InstrumentType::BANK_ACCOUNT
30
- end
31
27
  end
32
28
  end
33
29
  end
@@ -6,9 +6,12 @@ module CheckoutSdk
6
6
  # @return [String]
7
7
  # @!attribute default
8
8
  # @return [TrueClass, FalseClass]
9
+ # @!attribute headers
10
+ # @return [Headers]
9
11
  class UpdatePaymentInstrumentRequest
10
12
  attr_accessor :label,
11
- :default
13
+ :default,
14
+ :headers
12
15
  end
13
16
  end
14
17
  end
@@ -6,6 +6,7 @@ module CheckoutSdk
6
6
  BANK_ACCOUNT = 'bank_account'
7
7
  TOKEN = 'token'
8
8
  CARD = 'card'
9
+ CARD_TOKEN = 'card_token'
9
10
  end
10
11
  end
11
12
  end
@@ -6,6 +6,8 @@ module CheckoutSdk
6
6
  # @return [String]
7
7
  # @!attribute action_id
8
8
  # @return [String]
9
+ # @!attribute reference
10
+ # @return [String]
9
11
  # @!attribute limit
10
12
  # @return [Integer]
11
13
  # @!attribute pagination_token
@@ -13,6 +15,7 @@ module CheckoutSdk
13
15
  class FinancialActionsQuery
14
16
  attr_accessor :payment_id,
15
17
  :action_id,
18
+ :reference,
16
19
  :limit,
17
20
  :pagination_token
18
21
  end
@@ -1,4 +1,6 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  require 'checkout_sdk/forex/quote_request'
4
+ require 'checkout_sdk/forex/forex_source'
5
+ require 'checkout_sdk/forex/rates_query_filter'
4
6
  require 'checkout_sdk/forex/forex_client'
@@ -3,8 +3,10 @@
3
3
  module CheckoutSdk
4
4
  module Forex
5
5
  class ForexClient < Client
6
- FOREX = 'forex/quotes'
7
- private_constant :FOREX
6
+ FOREX = 'forex'
7
+ QUOTES = 'quotes'
8
+ RATES = 'rates'
9
+ private_constant :FOREX, :QUOTES, :RATES
8
10
 
9
11
  # @param [ApiClient] api_client
10
12
  # @param [CheckoutConfiguration] configuration
@@ -14,7 +16,12 @@ module CheckoutSdk
14
16
 
15
17
  # @param [Hash, QuoteRequest] quote_request
16
18
  def request_quote(quote_request)
17
- api_client.invoke_post(FOREX, sdk_authorization, quote_request)
19
+ api_client.invoke_post(build_path(FOREX, QUOTES), sdk_authorization, quote_request)
20
+ end
21
+
22
+ # @param [Hash, RatesQueryFilter] rates_query_filter
23
+ def get_rates(rates_query_filter)
24
+ api_client.invoke_get(build_path(FOREX, RATES), sdk_authorization, rates_query_filter)
18
25
  end
19
26
  end
20
27
  end
@@ -0,0 +1,10 @@
1
+ # frozen_string_literal: true
2
+
3
+ module CheckoutSdk
4
+ module Forex
5
+ module ForexSource
6
+ VISA = 'visa'
7
+ MASTERCARD = 'mastercard'
8
+ end
9
+ end
10
+ end
@@ -0,0 +1,20 @@
1
+ # frozen_string_literal: true
2
+
3
+ module CheckoutSdk
4
+ module Forex
5
+ # @!attribute product
6
+ # @return [String]
7
+ # @!attribute source
8
+ # @return [String] {ForexSource}
9
+ # @!attribute currency_pairs
10
+ # @return [String]
11
+ # @!attribute process_channel_id
12
+ # @return [String]
13
+ class RatesQueryFilter
14
+ attr_accessor :product,
15
+ :source,
16
+ :currency_pairs,
17
+ :process_channel_id
18
+ end
19
+ end
20
+ end
@@ -5,7 +5,8 @@ module CheckoutSdk
5
5
  KEYS_TRANSFORMATIONS = { three_ds: '3ds',
6
6
  account_holder_type: 'account-holder-type',
7
7
  payment_network: 'payment-network',
8
- from_: 'from' }.freeze
8
+ from_: 'from',
9
+ if_match: 'if-match' }.freeze
9
10
 
10
11
  def self.to_custom_hash(object)
11
12
  hash = {}
@@ -50,9 +50,6 @@ module CheckoutSdk
50
50
  # @return [Time]
51
51
  # @!attribute processing_channel_id
52
52
  # @return [String] - Not available on Previous.
53
- # @!attribute marketplace
54
- # @deprecated Please use {#amount_allocations} instead
55
- # @return [CheckoutSdk::Common::MarketplaceData] - Not available on Previous.
56
53
  # @!attribute amount_allocations
57
54
  # @return [Array(CheckoutSdk::Common::AmountAllocations)] - Not available on Previous.
58
55
  class HostedPaymentsSession
@@ -80,7 +77,6 @@ module CheckoutSdk
80
77
  :capture,
81
78
  :capture_on,
82
79
  :processing_channel_id,
83
- :marketplace,
84
80
  :amount_allocations
85
81
  end
86
82
  end
@@ -18,9 +18,6 @@ module CheckoutSdk
18
18
  # @return [String]
19
19
  # @!attribute processing_channel_id
20
20
  # @return [String] - Not available on Previous.
21
- # @!attribute marketplace
22
- # @deprecated Please use {#amount_allocations} instead
23
- # @return [CheckoutSdk::Common::MarketplaceData] - Not available on Previous.
24
21
  # @!attribute amount_allocations
25
22
  # @return [Array(CheckoutSdk::Common::AmountAllocations)] - Not available on Previous.
26
23
  # @!attribute expires_in
@@ -62,7 +59,6 @@ module CheckoutSdk
62
59
  :reference,
63
60
  :description,
64
61
  :processing_channel_id,
65
- :marketplace,
66
62
  :amount_allocations,
67
63
  :expires_in,
68
64
  :customer,
@@ -8,6 +8,8 @@ module CheckoutSdk
8
8
  # @return [String]
9
9
  # @!attribute java_enabled
10
10
  # @return [TrueClass, FalseClass]
11
+ # @!attribute javascript_enabled
12
+ # @return [TrueClass, FalseClass]
11
13
  # @!attribute language
12
14
  # @return [String]
13
15
  # @!attribute color_depth
@@ -26,6 +28,7 @@ module CheckoutSdk
26
28
  attr_accessor :three_ds_method_completion,
27
29
  :accept_header,
28
30
  :java_enabled,
31
+ :javascript_enabled,
29
32
  :language,
30
33
  :color_depth,
31
34
  :screen_height,
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module CheckoutSdk
4
- VERSION = '1.1.1'
4
+ VERSION = '1.1.3'
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: checkout_sdk
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.1.1
4
+ version: 1.1.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Checkout
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2023-03-15 00:00:00.000000000 Z
11
+ date: 2023-04-21 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rake
@@ -140,9 +140,11 @@ files:
140
140
  - lib/checkout_sdk/accounts/entity_financial_details.rb
141
141
  - lib/checkout_sdk/accounts/entity_financial_documents.rb
142
142
  - lib/checkout_sdk/accounts/file_request.rb
143
+ - lib/checkout_sdk/accounts/headers.rb
143
144
  - lib/checkout_sdk/accounts/identification.rb
144
145
  - lib/checkout_sdk/accounts/individual.rb
145
146
  - lib/checkout_sdk/accounts/instrument_details.rb
147
+ - lib/checkout_sdk/accounts/instrument_details_card_token.rb
146
148
  - lib/checkout_sdk/accounts/instrument_details_faster_payments.rb
147
149
  - lib/checkout_sdk/accounts/instrument_details_sepa.rb
148
150
  - lib/checkout_sdk/accounts/instrument_document.rb
@@ -222,7 +224,9 @@ files:
222
224
  - lib/checkout_sdk/financial/financial_client.rb
223
225
  - lib/checkout_sdk/forex/forex.rb
224
226
  - lib/checkout_sdk/forex/forex_client.rb
227
+ - lib/checkout_sdk/forex/forex_source.rb
225
228
  - lib/checkout_sdk/forex/quote_request.rb
229
+ - lib/checkout_sdk/forex/rates_query_filter.rb
226
230
  - lib/checkout_sdk/http_metadata.rb
227
231
  - lib/checkout_sdk/instruments/base_instruments_client.rb
228
232
  - lib/checkout_sdk/instruments/create/instrument.rb