checkout_sdk 1.5.0 → 1.6.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: 70605c20e50863e9e8fb6d63165387290f09d7ee9df7085aab98773308c9a791
4
- data.tar.gz: 423b97c81d8fd1c881f9e78e6ca36ae567cf11f0e2bfcced3820df4e67e00cd2
3
+ metadata.gz: 15763373d8272d4c62a34f948cf8d690c2099f94b6beff90a23e089c0c7447d7
4
+ data.tar.gz: d36ca68c28f34e2bdd35f9e392ee4e10340bb1938bb7708bf6fdbb234ae967d8
5
5
  SHA512:
6
- metadata.gz: 06b37ee645dd3c8a5290efba79bb812594579749e9f4c35a66a46dbec902c9bf7154aa8cf91639fd6d874951b42f8b72af7a7597ffd8bf4ebaab9e91b92158d1
7
- data.tar.gz: fbe86b60e6b66c4b3ba56b3728fe9ae02ea3f861a00a7688488864e59d473a15bd094ba9cf672eb5019a0078c5fef1ab32568b9e815c7cb863f74a62c55441be
6
+ metadata.gz: 93e25cfc9efe4d1712347f26b1362f743f0b89a24bf2f65ef2fdd03622f9dc01bec9b5afa94536f66232ec6c97935c6b6c018c2a572d238c4e3ffd64edeefd2d
7
+ data.tar.gz: 945b400a544cd10c594c51def6da98fc74ee82c01b1eeeb33395d2b3fe58d0ff90af6afe11117e9a29fb7b63fb5f8cc4195607c2830684d18e47bb154c4e7ec2
@@ -45,6 +45,8 @@ module CheckoutSdk
45
45
  # @return [CheckoutSdk::Payments::PaymentSessionsClient]
46
46
  # @!attribute payments_setups
47
47
  # @return [CheckoutSdk::Payments::PaymentSetupsClient]
48
+ # @!attribute flow
49
+ # @return [CheckoutSdk::Payments::FlowClient]
48
50
  # @!attribute forward
49
51
  # @return [CheckoutSdk::Forward::ForwardClient]
50
52
  class CheckoutApi
@@ -56,6 +58,7 @@ module CheckoutSdk
56
58
  :links,
57
59
  :payments,
58
60
  :payments_setups,
61
+ :flow,
59
62
  :reports,
60
63
  :sessions,
61
64
  :tokens,
@@ -97,6 +100,7 @@ module CheckoutSdk
97
100
  @contexts = CheckoutSdk::Payments::PaymentContextsClient.new api_client, configuration
98
101
  @payment_sessions = CheckoutSdk::Payments::PaymentSessionsClient.new api_client, configuration
99
102
  @payments_setups = CheckoutSdk::Payments::PaymentSetupsClient.new api_client, configuration
103
+ @flow = CheckoutSdk::Payments::FlowClient.new api_client, configuration
100
104
  @forward = CheckoutSdk::Forward::ForwardClient.new(api_client, configuration)
101
105
  end
102
106
 
@@ -0,0 +1,59 @@
1
+ # frozen_string_literal: true
2
+
3
+ module CheckoutSdk
4
+ module Payments
5
+ # Client for Payment Flow API operations
6
+ # [Beta]
7
+ class FlowClient < Client
8
+ PAYMENT_SESSIONS_PATH = 'payment-sessions'
9
+ SUBMIT_PATH = 'submit'
10
+ COMPLETE_PATH = 'complete'
11
+
12
+ # @param [ApiClient] api_client
13
+ # @param [CheckoutConfiguration] configuration
14
+ def initialize(api_client, configuration)
15
+ super(api_client, configuration, CheckoutSdk::AuthorizationType::SECRET_KEY_OR_OAUTH)
16
+ end
17
+
18
+ # Creates a Payment Session.
19
+ # Use this endpoint to set up a payment session before collecting payment details from your customer.
20
+ # [Beta]
21
+ #
22
+ # @param [Hash] request_payment_session_request
23
+ def request_payment_session(request_payment_session_request)
24
+ api_client.invoke_post(
25
+ build_path(PAYMENT_SESSIONS_PATH),
26
+ sdk_authorization,
27
+ request_payment_session_request
28
+ )
29
+ end
30
+
31
+ # Submits a Payment Session.
32
+ # Use this endpoint to submit payment details and process the payment for an existing session.
33
+ # [Beta]
34
+ #
35
+ # @param [String] id - The unique identifier of the Payment Session
36
+ # @param [Hash] submit_payment_session_request
37
+ def submit_payment_session(id, submit_payment_session_request)
38
+ api_client.invoke_post(
39
+ build_path(PAYMENT_SESSIONS_PATH, id, SUBMIT_PATH),
40
+ sdk_authorization,
41
+ submit_payment_session_request
42
+ )
43
+ end
44
+
45
+ # Creates and submits a Payment Session in a single request.
46
+ # Use this endpoint to create a payment session and immediately process the payment.
47
+ # [Beta]
48
+ #
49
+ # @param [Hash] request_payment_session_with_payment_request
50
+ def request_payment_session_with_payment(request_payment_session_with_payment_request)
51
+ api_client.invoke_post(
52
+ build_path(PAYMENT_SESSIONS_PATH, COMPLETE_PATH),
53
+ sdk_authorization,
54
+ request_payment_session_with_payment_request
55
+ )
56
+ end
57
+ end
58
+ end
59
+ end
@@ -180,3 +180,6 @@ require 'checkout_sdk/payments/sessions/store_payment_details_type'
180
180
 
181
181
  # Payment Setups
182
182
  require 'checkout_sdk/payments/setups/payment_setups_client'
183
+
184
+ # Payment Flow
185
+ require 'checkout_sdk/payments/flow/flow_client'
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module CheckoutSdk
4
- VERSION = '1.5.0'
4
+ VERSION = '1.6.0'
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.5.0
4
+ version: 1.6.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Checkout
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2026-01-28 00:00:00.000000000 Z
11
+ date: 2026-01-29 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rake
@@ -333,6 +333,7 @@ files:
333
333
  - lib/checkout_sdk/payments/destination/token_destination.rb
334
334
  - lib/checkout_sdk/payments/exemption.rb
335
335
  - lib/checkout_sdk/payments/flight_leg_details.rb
336
+ - lib/checkout_sdk/payments/flow/flow_client.rb
336
337
  - lib/checkout_sdk/payments/googlepay.rb
337
338
  - lib/checkout_sdk/payments/hosted/hosted_payment_instruction.rb
338
339
  - lib/checkout_sdk/payments/hosted/hosted_payments_client.rb