adyen-ruby-api-library 10.2.0 → 10.3.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 +4 -4
- data/.github/workflows/stale.yml +1 -0
- data/VERSION +1 -1
- data/lib/adyen/client.rb +2 -0
- data/lib/adyen/services/balancePlatform/balances_api.rb +66 -0
- data/lib/adyen/services/balancePlatform.rb +5 -0
- data/lib/adyen/services/sessionAuthentication/session_authentication_api.rb +26 -0
- data/lib/adyen/services/sessionAuthentication.rb +24 -0
- data/lib/adyen/version.rb +1 -1
- data/spec/client_spec.rb +6 -0
- metadata +6 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 5c9dcac3a9a17688cad88c6466c0e9bf555c2fb68f6f17fe1a81145ee39769d9
|
4
|
+
data.tar.gz: 7ac74b1fd3abce0e78d9a9e27a80128f196f13fe351e16893162de54afde1f8a
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: dfd9dd3890fedccfa1a74dfd9417475bf9cf4346a45afa35690f199df0af3a6ece03f777f1900c27e71cd40cd1ff641cb96655ad916cb5e6bf3d0395dc2509cb
|
7
|
+
data.tar.gz: 6ebd1db6b15dc8f3d21325555fde69df8d003141eeccac68db1e99b5cdbc29e8b43d592f68039ade223717334548ca23daef054a91c1f76b69fe0490ec34c7f8
|
data/.github/workflows/stale.yml
CHANGED
data/VERSION
CHANGED
@@ -1,2 +1,2 @@
|
|
1
|
-
10.
|
1
|
+
10.3.0
|
2
2
|
|
data/lib/adyen/client.rb
CHANGED
@@ -53,6 +53,8 @@ module Adyen
|
|
53
53
|
|
54
54
|
# base URL for API given service and @env
|
55
55
|
def service_url_base(service)
|
56
|
+
# maps 'Disputes' to expected service name 'DisputesService' for URL matching
|
57
|
+
service = 'DisputesService' if service == 'Disputes'
|
56
58
|
if @env == :mock
|
57
59
|
@mock_service_url_base
|
58
60
|
else
|
@@ -0,0 +1,66 @@
|
|
1
|
+
require_relative '../service'
|
2
|
+
module Adyen
|
3
|
+
|
4
|
+
# NOTE: This class is auto generated by OpenAPI Generator
|
5
|
+
# Ref: https://openapi-generator.tech
|
6
|
+
#
|
7
|
+
# Do not edit the class manually.
|
8
|
+
class BalancesApi < Service
|
9
|
+
attr_accessor :service, :version
|
10
|
+
|
11
|
+
def initialize(client, version = DEFAULT_VERSION)
|
12
|
+
super(client, version, 'BalancePlatform')
|
13
|
+
end
|
14
|
+
|
15
|
+
# Create a balance webhook setting
|
16
|
+
def create_webhook_setting(request, balance_platform_id, webhook_id, balance_webhook_setting_info, headers: {})
|
17
|
+
endpoint = '/balancePlatforms/{balancePlatformId}/webhooks/{webhookId}/settings'.gsub(/{.+?}/, '%s')
|
18
|
+
endpoint = endpoint.gsub(%r{^/}, '')
|
19
|
+
endpoint = format(endpoint, balance_platform_id, webhook_id)
|
20
|
+
|
21
|
+
action = { method: 'post', url: endpoint }
|
22
|
+
@client.call_adyen_api(@service, action, request, headers, @version)
|
23
|
+
end
|
24
|
+
|
25
|
+
# Delete a balance webhook setting by id
|
26
|
+
def delete_webhook_setting(balance_platform_id, webhook_id, setting_id, headers: {})
|
27
|
+
endpoint = '/balancePlatforms/{balancePlatformId}/webhooks/{webhookId}/settings/{settingId}'.gsub(/{.+?}/, '%s')
|
28
|
+
endpoint = endpoint.gsub(%r{^/}, '')
|
29
|
+
endpoint = format(endpoint, balance_platform_id, webhook_id, setting_id)
|
30
|
+
|
31
|
+
action = { method: 'delete', url: endpoint }
|
32
|
+
@client.call_adyen_api(@service, action, {}, headers, @version)
|
33
|
+
end
|
34
|
+
|
35
|
+
# Get all balance webhook settings
|
36
|
+
def get_all_webhook_settings(balance_platform_id, webhook_id, headers: {})
|
37
|
+
endpoint = '/balancePlatforms/{balancePlatformId}/webhooks/{webhookId}/settings'.gsub(/{.+?}/, '%s')
|
38
|
+
endpoint = endpoint.gsub(%r{^/}, '')
|
39
|
+
endpoint = format(endpoint, balance_platform_id, webhook_id)
|
40
|
+
|
41
|
+
action = { method: 'get', url: endpoint }
|
42
|
+
@client.call_adyen_api(@service, action, {}, headers, @version)
|
43
|
+
end
|
44
|
+
|
45
|
+
# Get a balance webhook setting by id
|
46
|
+
def get_webhook_setting(balance_platform_id, webhook_id, setting_id, headers: {})
|
47
|
+
endpoint = '/balancePlatforms/{balancePlatformId}/webhooks/{webhookId}/settings/{settingId}'.gsub(/{.+?}/, '%s')
|
48
|
+
endpoint = endpoint.gsub(%r{^/}, '')
|
49
|
+
endpoint = format(endpoint, balance_platform_id, webhook_id, setting_id)
|
50
|
+
|
51
|
+
action = { method: 'get', url: endpoint }
|
52
|
+
@client.call_adyen_api(@service, action, {}, headers, @version)
|
53
|
+
end
|
54
|
+
|
55
|
+
# Update a balance webhook setting by id
|
56
|
+
def update_webhook_setting(request, balance_platform_id, webhook_id, setting_id, balance_webhook_setting_info_update, headers: {})
|
57
|
+
endpoint = '/balancePlatforms/{balancePlatformId}/webhooks/{webhookId}/settings/{settingId}'.gsub(/{.+?}/, '%s')
|
58
|
+
endpoint = endpoint.gsub(%r{^/}, '')
|
59
|
+
endpoint = format(endpoint, balance_platform_id, webhook_id, setting_id)
|
60
|
+
|
61
|
+
action = { method: 'patch', url: endpoint }
|
62
|
+
@client.call_adyen_api(@service, action, request, headers, @version)
|
63
|
+
end
|
64
|
+
|
65
|
+
end
|
66
|
+
end
|
@@ -1,5 +1,6 @@
|
|
1
1
|
require_relative 'balancePlatform/account_holders_api'
|
2
2
|
require_relative 'balancePlatform/balance_accounts_api'
|
3
|
+
require_relative 'balancePlatform/balances_api'
|
3
4
|
require_relative 'balancePlatform/bank_account_validation_api'
|
4
5
|
require_relative 'balancePlatform/card_orders_api'
|
5
6
|
require_relative 'balancePlatform/grant_accounts_api'
|
@@ -37,6 +38,10 @@ module Adyen
|
|
37
38
|
@balance_accounts_api ||= Adyen::BalanceAccountsApi.new(@client, @version)
|
38
39
|
end
|
39
40
|
|
41
|
+
def balances_api
|
42
|
+
@balances_api ||= Adyen::BalancesApi.new(@client, @version)
|
43
|
+
end
|
44
|
+
|
40
45
|
def bank_account_validation_api
|
41
46
|
@bank_account_validation_api ||= Adyen::BankAccountValidationApi.new(@client, @version)
|
42
47
|
end
|
@@ -0,0 +1,26 @@
|
|
1
|
+
require_relative '../service'
|
2
|
+
module Adyen
|
3
|
+
|
4
|
+
# NOTE: This class is auto generated by OpenAPI Generator
|
5
|
+
# Ref: https://openapi-generator.tech
|
6
|
+
#
|
7
|
+
# Do not edit the class manually.
|
8
|
+
class SessionAuthenticationApi < Service
|
9
|
+
attr_accessor :service, :version
|
10
|
+
|
11
|
+
def initialize(client, version = DEFAULT_VERSION)
|
12
|
+
super(client, version, 'SessionAuthentication')
|
13
|
+
end
|
14
|
+
|
15
|
+
# Create a session token
|
16
|
+
def create_authentication_session(request, authentication_session_request, headers: {})
|
17
|
+
endpoint = '/sessions'.gsub(/{.+?}/, '%s')
|
18
|
+
endpoint = endpoint.gsub(%r{^/}, '')
|
19
|
+
endpoint = format(endpoint)
|
20
|
+
|
21
|
+
action = { method: 'post', url: endpoint }
|
22
|
+
@client.call_adyen_api(@service, action, request, headers, @version)
|
23
|
+
end
|
24
|
+
|
25
|
+
end
|
26
|
+
end
|
@@ -0,0 +1,24 @@
|
|
1
|
+
require_relative 'sessionAuthentication/session_authentication_api'
|
2
|
+
|
3
|
+
module Adyen
|
4
|
+
|
5
|
+
# NOTE: This class is auto generated by OpenAPI Generator
|
6
|
+
# Ref: https://openapi-generator.tech
|
7
|
+
#
|
8
|
+
# Do not edit the class manually.
|
9
|
+
class SessionAuthentication
|
10
|
+
attr_accessor :service, :version
|
11
|
+
|
12
|
+
DEFAULT_VERSION = 1
|
13
|
+
def initialize(client, version = DEFAULT_VERSION)
|
14
|
+
@service = 'SessionAuthentication'
|
15
|
+
@client = client
|
16
|
+
@version = version
|
17
|
+
end
|
18
|
+
|
19
|
+
def session_authentication_api
|
20
|
+
@session_authentication_api ||= Adyen::SessionAuthenticationApi.new(@client, @version)
|
21
|
+
end
|
22
|
+
|
23
|
+
end
|
24
|
+
end
|
data/lib/adyen/version.rb
CHANGED
data/spec/client_spec.rb
CHANGED
@@ -278,4 +278,10 @@ RSpec.describe Adyen do
|
|
278
278
|
expect(client.service_url('PosMobile', 'sessions', nil))
|
279
279
|
.to eq('https://checkout-test.adyen.com/checkout/possdk/sessions')
|
280
280
|
end
|
281
|
+
|
282
|
+
it 'correctly maps Disputes to DisputesService and generates valid URL' do
|
283
|
+
client = Adyen::Client.new(env: :test)
|
284
|
+
expect(client.service_url_base('Disputes'))
|
285
|
+
.to eq('https://ca-test.adyen.com/ca/services/DisputesService')
|
286
|
+
end
|
281
287
|
end
|
metadata
CHANGED
@@ -1,13 +1,13 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: adyen-ruby-api-library
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 10.
|
4
|
+
version: 10.3.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Adyen
|
8
8
|
bindir: bin
|
9
9
|
cert_chain: []
|
10
|
-
date:
|
10
|
+
date: 1980-01-02 00:00:00.000000000 Z
|
11
11
|
dependencies:
|
12
12
|
- !ruby/object:Gem::Dependency
|
13
13
|
name: faraday
|
@@ -110,6 +110,7 @@ files:
|
|
110
110
|
- lib/adyen/services/balancePlatform.rb
|
111
111
|
- lib/adyen/services/balancePlatform/account_holders_api.rb
|
112
112
|
- lib/adyen/services/balancePlatform/balance_accounts_api.rb
|
113
|
+
- lib/adyen/services/balancePlatform/balances_api.rb
|
113
114
|
- lib/adyen/services/balancePlatform/bank_account_validation_api.rb
|
114
115
|
- lib/adyen/services/balancePlatform/card_orders_api.rb
|
115
116
|
- lib/adyen/services/balancePlatform/grant_accounts_api.rb
|
@@ -183,6 +184,8 @@ files:
|
|
183
184
|
- lib/adyen/services/posTerminalManagement.rb
|
184
185
|
- lib/adyen/services/recurring.rb
|
185
186
|
- lib/adyen/services/service.rb
|
187
|
+
- lib/adyen/services/sessionAuthentication.rb
|
188
|
+
- lib/adyen/services/sessionAuthentication/session_authentication_api.rb
|
186
189
|
- lib/adyen/services/storedValue.rb
|
187
190
|
- lib/adyen/services/terminalCloudAPI.rb
|
188
191
|
- lib/adyen/services/transfers.rb
|
@@ -433,7 +436,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
433
436
|
- !ruby/object:Gem::Version
|
434
437
|
version: '0'
|
435
438
|
requirements: []
|
436
|
-
rubygems_version: 3.6.
|
439
|
+
rubygems_version: 3.6.7
|
437
440
|
specification_version: 4
|
438
441
|
summary: Official Adyen Ruby API Library
|
439
442
|
test_files: []
|