checkout_sdk 1.0.3 → 1.0.4

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: 86b3e418596eba84f9d21cc8149e4030dd1fbae085ca44db519ab6ad11ce4121
4
- data.tar.gz: d9d48a22ac629a07434d15da2299a8574d7e1a1571baaacb250ca14b3fb1bc75
3
+ metadata.gz: 5d8a69f79c7de8025019e0da19b68333ddf501e1bd4c22ca0adda365206a9149
4
+ data.tar.gz: 438f2c9ec07de8bfe6a30d5bd8a3920b5a47e1fbaa372139e51c2999b5eb6cbe
5
5
  SHA512:
6
- metadata.gz: 8cf7820ae7f37afa4630e1bebd9671b7d9d8eecd1cb3c736881e6bbd264cb4fafb043288fae10c57c66b544279b6b420510659c0414be1706d1c2c7aa283b52b
7
- data.tar.gz: 1123a2c14c3ce44b66ef3943b11ba704de9fccf71971115899eff68643d81c89eda6efa1b2265ae8cf67110e502e7796d96ff115e80657a85ec895a739f70a55
6
+ metadata.gz: '03069e417c9a830dcac196879d39d41f4893921792e32122da92f3d85085e6cfd74e7b26c88055dbf9db01c783d3999b2f848434c02af1502918486fa1adc702'
7
+ data.tar.gz: b9199a8b6c20cfacae6520ac169ef840a4148eb97b415625f27f2fe34a07f301ec840a9fd8621af54154b25149f0797a81f88524ff9282be3f8dfd29bd958b96
@@ -30,6 +30,7 @@ module CheckoutSdk
30
30
 
31
31
  def with_logger(logger)
32
32
  @logger = logger
33
+ self
33
34
  end
34
35
 
35
36
  def build
@@ -35,6 +35,8 @@ module CheckoutSdk
35
35
  # @return [CheckoutSdk::Transfers::TransfersClient]
36
36
  # @!attribute metadata
37
37
  # @return [CheckoutSdk::Metadata::MetadataClient]
38
+ # @!attribute financial
39
+ # @return [CheckoutSdk::Financial::FinancialClient]
38
40
  class CheckoutApi
39
41
  attr_reader :customers,
40
42
  :disputes,
@@ -52,7 +54,8 @@ module CheckoutSdk
52
54
  :risk,
53
55
  :balances,
54
56
  :transfers,
55
- :metadata
57
+ :metadata,
58
+ :financial
56
59
 
57
60
  # @param [CheckoutConfiguration] configuration
58
61
  def initialize(configuration)
@@ -74,6 +77,7 @@ module CheckoutSdk
74
77
  @balances = CheckoutSdk::Balances::BalancesClient.new(balances_client(configuration), configuration)
75
78
  @transfers = CheckoutSdk::Transfers::TransfersClient.new(transfers_client(configuration), configuration)
76
79
  @metadata = CheckoutSdk::Metadata::MetadataClient.new api_client, configuration
80
+ @financial = CheckoutSdk::Financial::FinancialClient.new api_client, configuration
77
81
  end
78
82
 
79
83
  private
@@ -51,6 +51,7 @@ module CheckoutSdk
51
51
  CV_CONNECT = 'cvconnect'
52
52
  TRUSTLY = 'trustly'
53
53
  ILLICADO = 'illicado'
54
+ SEPA = 'sepa'
54
55
  end
55
56
  end
56
57
  end
@@ -0,0 +1,4 @@
1
+ # frozen_string_literal: true
2
+
3
+ require 'checkout_sdk/financial/financial_client'
4
+ require 'checkout_sdk/financial/financial_actions_query'
@@ -0,0 +1,20 @@
1
+ # frozen_string_literal: true
2
+
3
+ module CheckoutSdk
4
+ module Financial
5
+ # @!attribute payment_id
6
+ # @return [String]
7
+ # @!attribute action_id
8
+ # @return [String]
9
+ # @!attribute limit
10
+ # @return [Integer]
11
+ # @!attribute pagination_token
12
+ # @return [String]
13
+ class FinancialActionsQuery
14
+ attr_accessor :payment_id,
15
+ :action_id,
16
+ :limit,
17
+ :pagination_token
18
+ end
19
+ end
20
+ end
@@ -0,0 +1,21 @@
1
+ # frozen_string_literal: true
2
+
3
+ module CheckoutSdk
4
+ module Financial
5
+ class FinancialClient < Client
6
+ FINANCIAL_ACTIONS = 'financial-actions'
7
+ private_constant :FINANCIAL_ACTIONS
8
+
9
+ # @param [ApiClient] api_client
10
+ # @param [CheckoutConfiguration] configuration
11
+ def initialize(api_client, configuration)
12
+ super api_client, configuration, CheckoutSdk::AuthorizationType::SECRET_KEY_OR_OAUTH
13
+ end
14
+
15
+ # @param [FinancialActionsQuery] query_filter
16
+ def query(query_filter)
17
+ api_client.invoke_get(FINANCIAL_ACTIONS, sdk_authorization, query_filter)
18
+ end
19
+ end
20
+ end
21
+ end
@@ -41,5 +41,7 @@ module CheckoutSdk
41
41
  REPORTS = 'reports'
42
42
  REPORTS_VIEW = 'reports:view'
43
43
  CARD_METADATA = 'vault:card-metadata'
44
+ FINANCIAL_ACTIONS = 'financial-actions'
45
+ FINANCIAL_ACTIONS_VIEW = 'financial-actions:view'
44
46
  end
45
47
  end
@@ -80,6 +80,7 @@ require 'checkout_sdk/payments/source/apm/klarna_source'
80
80
  require 'checkout_sdk/payments/source/apm/cv_connect_source'
81
81
  require 'checkout_sdk/payments/source/apm/trustly_source'
82
82
  require 'checkout_sdk/payments/source/apm/illicado_source'
83
+ require 'checkout_sdk/payments/source/apm/sepa_source'
83
84
 
84
85
  # Sender
85
86
  require 'checkout_sdk/payments/sender/sender'
@@ -0,0 +1,33 @@
1
+ # frozen_string_literal: true
2
+
3
+ module CheckoutSdk
4
+ module Payments
5
+ # @!attribute country
6
+ # @return [CheckoutSdk::Common::Country]
7
+ # @!attribute account_number
8
+ # @return [String]
9
+ # @!attribute bank_code
10
+ # @return [String]
11
+ # @!attribute currency
12
+ # @return [CheckoutSdk::Common::Currency]
13
+ # @!attribute mandate_id
14
+ # @return [String]
15
+ # @!attribute date_of_signature
16
+ # @return [String]
17
+ # @!attribute account_holder
18
+ # @return [CheckoutSdk::Common::AccountHolder]
19
+ class SepaSource < PaymentSource
20
+ attr_accessor :country,
21
+ :account_number,
22
+ :bank_code,
23
+ :currency,
24
+ :mandate_id,
25
+ :date_of_signature,
26
+ :account_holder
27
+
28
+ def initialize
29
+ super CheckoutSdk::Common::PaymentSourceType::SEPA
30
+ end
31
+ end
32
+ end
33
+ end
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module CheckoutSdk
4
- VERSION = '1.0.3'
4
+ VERSION = '1.0.4'
5
5
  end
data/lib/checkout_sdk.rb CHANGED
@@ -63,6 +63,7 @@ require 'checkout_sdk/risk/risk'
63
63
  require 'checkout_sdk/balances/balances'
64
64
  require 'checkout_sdk/transfers/transfers'
65
65
  require 'checkout_sdk/metadata/metadata'
66
+ require 'checkout_sdk/financial/financial'
66
67
 
67
68
  # Checkout modules (previous)
68
69
  require 'checkout_sdk/sources/sources'
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.0.3
4
+ version: 1.0.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - Checkout
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2023-02-02 00:00:00.000000000 Z
11
+ date: 2023-02-24 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rake
@@ -217,6 +217,9 @@ files:
217
217
  - lib/checkout_sdk/events/events.rb
218
218
  - lib/checkout_sdk/events/events_client.rb
219
219
  - lib/checkout_sdk/events/events_query_filter.rb
220
+ - lib/checkout_sdk/financial/financial.rb
221
+ - lib/checkout_sdk/financial/financial_actions_query.rb
222
+ - lib/checkout_sdk/financial/financial_client.rb
220
223
  - lib/checkout_sdk/forex/forex.rb
221
224
  - lib/checkout_sdk/forex/forex_client.rb
222
225
  - lib/checkout_sdk/forex/quote_request.rb
@@ -365,6 +368,7 @@ files:
365
368
  - lib/checkout_sdk/payments/source/apm/paypal_source.rb
366
369
  - lib/checkout_sdk/payments/source/apm/post_finance_source.rb
367
370
  - lib/checkout_sdk/payments/source/apm/qpay_source.rb
371
+ - lib/checkout_sdk/payments/source/apm/sepa_source.rb
368
372
  - lib/checkout_sdk/payments/source/apm/sofort_source.rb
369
373
  - lib/checkout_sdk/payments/source/apm/stcpay_source.rb
370
374
  - lib/checkout_sdk/payments/source/apm/tamara_source.rb