checkout_sdk 1.2.0 → 1.2.2

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: 14e68356d1de167bcf9ba9c5370aaf6ac81804e1b844474f6c2c573cdc41e96b
4
- data.tar.gz: 8061066149def7f8b6288c94cbc6d2362ac4528b2741759dca3d1ad254160637
3
+ metadata.gz: e8a5d0baf6cbae6fdd117f4d506da563edd5a4b0c34b3d3998502cd44173f06a
4
+ data.tar.gz: a692c66bed6a04a4c01e33b0e358814ffbc678bb358047fc427fbc53c7398c9a
5
5
  SHA512:
6
- metadata.gz: 33cad8c67ad6c941526a6edd897800d975a431da83ca6c0c661181b80943cd63bb417242ee581c523fc1225ae635cc8a0644521c0dfb5f9bc95b3ad78479a9bf
7
- data.tar.gz: e707e11a320e4db4c3612643120a283b8b58de2ddc13b54999cf6ce7d155fc8441d6f584bb03e23f699801f14e413c292c6bc7af62fb542a0809349f4e673d68
6
+ metadata.gz: a78beb178c7ecfc877df410cee8a1090a02bde9883a706d3a47a11a26fb49ca4cbd4a8821074530d3a81bc07a9d3fa8cab32d383e6db9668ee5c0b8fe4e7929a
7
+ data.tar.gz: ce1b9b18e3132c57d9a2e2c520b11c45610e2a5749d53a961f2f41f722396ea6fc2c578ee31ba5f8cfd47b86df397ea97ed04a04fb466985510eaaaa31d70484
@@ -29,8 +29,7 @@ module CheckoutSdk
29
29
  api_url = environment.base_uri
30
30
  new_environment = api_url
31
31
 
32
- # Regex to match a subdomain consisting of 8 to 11 lowercase alphanumeric characters
33
- if subdomain =~ /^[0-9a-z]{8,11}$/
32
+ if subdomain =~ /^[0-9a-z]+$/
34
33
  url_parts = URI.parse(api_url)
35
34
  new_host = "#{subdomain}.#{url_parts.host}"
36
35
 
@@ -0,0 +1,17 @@
1
+ # frozen_string_literal: true
2
+
3
+ module CheckoutSdk
4
+ module Payments
5
+ # @!attribute display_name
6
+ # @return [String]
7
+ # @!attribute type
8
+ # @return [String]
9
+ # @!attribute network
10
+ # @return [String]
11
+ class PaymentMethodDetails
12
+ attr_accessor :display_name,
13
+ :type,
14
+ :network
15
+ end
16
+ end
17
+ end
@@ -14,6 +14,7 @@ require 'checkout_sdk/payments/payer'
14
14
  require 'checkout_sdk/payments/authorization_type'
15
15
  require 'checkout_sdk/payments/os_type'
16
16
  require 'checkout_sdk/payments/payment_instruction'
17
+ require 'checkout_sdk/payments/payment_method_details'
17
18
  require 'checkout_sdk/payments/refund_request'
18
19
  require 'checkout_sdk/payments/product'
19
20
  require 'checkout_sdk/payments/capture_type'
@@ -19,6 +19,12 @@ module CheckoutSdk
19
19
  # @return [String]
20
20
  # @!attribute ptlf
21
21
  # @return [String]
22
+ # @!attribute token_type
23
+ # @return [String]
24
+ # @!attribute token_data
25
+ # @return [ApplePayTokenData]
26
+ # @!attribute payment_method_details
27
+ # @return [PaymentMethodDetails]
22
28
  class KnetSource < PaymentSource
23
29
  attr_accessor :language,
24
30
  :user_defined_field1,
@@ -27,7 +33,10 @@ module CheckoutSdk
27
33
  :user_defined_field4,
28
34
  :user_defined_field5,
29
35
  :card_token,
30
- :ptlf
36
+ :ptlf,
37
+ :token_type,
38
+ :token_data,
39
+ :payment_method_details
31
40
 
32
41
  def initialize
33
42
  super CheckoutSdk::Common::PaymentSourceType::KNET
@@ -18,6 +18,12 @@ module CheckoutSdk
18
18
  # @return [String]
19
19
  # @!attribute ptlf
20
20
  # @return [String]
21
+ # @!attribute token_type
22
+ # @return [String]
23
+ # @!attribute token_data
24
+ # @return [ApplePayTokenData]
25
+ # @!attribute payment_method_details
26
+ # @return [PaymentMethodDetails]
21
27
  class KnetSource < PaymentSource
22
28
  attr_accessor :language,
23
29
  :user_defined_field1,
@@ -26,7 +32,10 @@ module CheckoutSdk
26
32
  :user_defined_field4,
27
33
  :user_defined_field5,
28
34
  :card_token,
29
- :ptlf
35
+ :ptlf,
36
+ :token_type,
37
+ :token_data,
38
+ :payment_method_details
30
39
 
31
40
  def initialize
32
41
  super CheckoutSdk::Common::PaymentSourceType::KNET
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module CheckoutSdk
4
- VERSION = '1.2.0'
4
+ VERSION = '1.2.2'
5
5
  end
@@ -6,9 +6,15 @@ module CheckoutSdk
6
6
  # @return [String]
7
7
  # @!attribute active
8
8
  # @return [TrueClass, FalseClass]
9
+ # @!attribute conditions
10
+ # @return [Array(WorkflowCondition)]
11
+ # @!attribute actions
12
+ # @return [Array(WorkflowAction)]
9
13
  class PatchWorkflow
10
14
  attr_accessor :name,
11
- :active
15
+ :active,
16
+ :conditions,
17
+ :actions
12
18
  end
13
19
  end
14
20
  end
@@ -12,8 +12,9 @@ module CheckoutSdk
12
12
  REFLOW = 'reflow'
13
13
  SUBJECT = 'subject'
14
14
  WORKFLOW_ID = 'workflowId'
15
+ TEST = 'test'
15
16
  private_constant :WORKFLOWS, :WORKFLOW, :ACTIONS, :CONDITIONS, :EVENT_TYPES, :EVENTS, :REFLOW,
16
- :SUBJECT, :WORKFLOW_ID
17
+ :SUBJECT, :WORKFLOW_ID, :TEST
17
18
 
18
19
  # @param [ApiClient] api_client
19
20
  # @param [CheckoutConfiguration] configuration
@@ -86,6 +87,12 @@ module CheckoutSdk
86
87
  api_client.invoke_delete(build_path(WORKFLOWS, workflow_id, CONDITIONS, condition_id), sdk_authorization)
87
88
  end
88
89
 
90
+ # @param [String] workflow_id
91
+ # @param [Hash] event_types_request
92
+ def test_workflow(workflow_id, event_types_request)
93
+ api_client.invoke_post(build_path(WORKFLOWS, workflow_id, TEST), sdk_authorization, event_types_request)
94
+ end
95
+
89
96
  def retrieve_event_types
90
97
  api_client.invoke_get(build_path(WORKFLOWS, EVENT_TYPES), sdk_authorization)
91
98
  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.2.0
4
+ version: 1.2.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Checkout
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2024-08-28 00:00:00.000000000 Z
11
+ date: 2024-09-26 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rake
@@ -301,6 +301,7 @@ files:
301
301
  - lib/checkout_sdk/payments/passenger_name.rb
302
302
  - lib/checkout_sdk/payments/payer.rb
303
303
  - lib/checkout_sdk/payments/payment_instruction.rb
304
+ - lib/checkout_sdk/payments/payment_method_details.rb
304
305
  - lib/checkout_sdk/payments/payment_recipient.rb
305
306
  - lib/checkout_sdk/payments/payment_request.rb
306
307
  - lib/checkout_sdk/payments/payment_retry_request.rb