adyen-ruby-api-library 8.0.0 → 8.0.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (46) hide show
  1. checksums.yaml +4 -4
  2. data/.github/workflows/codeql.yml +2 -2
  3. data/.github/workflows/rubygems_release.yml +1 -4
  4. data/CONTRIBUTING.md +1 -1
  5. data/README.md +1 -1
  6. data/VERSION +1 -1
  7. data/lib/adyen/services/balancePlatform/account_holders_api.rb +9 -9
  8. data/lib/adyen/services/balancePlatform/balance_accounts_api.rb +32 -32
  9. data/lib/adyen/services/balancePlatform/payment_instrument_groups_api.rb +10 -10
  10. data/lib/adyen/services/balancePlatform/payment_instruments_api.rb +17 -17
  11. data/lib/adyen/services/balancePlatform/platform_api.rb +6 -6
  12. data/lib/adyen/services/balancePlatform/transaction_rules_api.rb +9 -9
  13. data/lib/adyen/services/checkout/modifications_api.rb +9 -9
  14. data/lib/adyen/services/checkout/orders_api.rb +6 -6
  15. data/lib/adyen/services/checkout/payment_links_api.rb +8 -8
  16. data/lib/adyen/services/checkout/payments_api.rb +9 -9
  17. data/lib/adyen/services/dataProtection.rb +1 -1
  18. data/lib/adyen/services/legalEntityManagement/business_lines_api.rb +9 -9
  19. data/lib/adyen/services/legalEntityManagement/hosted_onboarding_api.rb +10 -10
  20. data/lib/adyen/services/legalEntityManagement/legal_entities_api.rb +27 -18
  21. data/lib/adyen/services/legalEntityManagement/pci_questionnaires_api.rb +8 -8
  22. data/lib/adyen/services/legalEntityManagement/terms_of_service_api.rb +18 -18
  23. data/lib/adyen/services/legalEntityManagement/transfer_instruments_api.rb +9 -9
  24. data/lib/adyen/services/management/account_company_level_api.rb +8 -8
  25. data/lib/adyen/services/management/account_merchant_level_api.rb +8 -8
  26. data/lib/adyen/services/management/account_store_level_api.rb +26 -26
  27. data/lib/adyen/services/management/allowed_origins_company_level_api.rb +12 -12
  28. data/lib/adyen/services/management/allowed_origins_merchant_level_api.rb +12 -12
  29. data/lib/adyen/services/management/android_files_company_level_api.rb +8 -8
  30. data/lib/adyen/services/management/api_credentials_company_level_api.rb +13 -13
  31. data/lib/adyen/services/management/api_credentials_merchant_level_api.rb +13 -13
  32. data/lib/adyen/services/management/my_api_credential_api.rb +22 -22
  33. data/lib/adyen/services/management/payment_methods_merchant_level_api.rb +15 -15
  34. data/lib/adyen/services/management/payout_settings_merchant_level_api.rb +15 -15
  35. data/lib/adyen/services/management/split_configuration_merchant_level_api.rb +30 -30
  36. data/lib/adyen/services/management/terminal_actions_company_level_api.rb +8 -8
  37. data/lib/adyen/services/management/terminal_orders_company_level_api.rb +40 -40
  38. data/lib/adyen/services/management/terminal_orders_merchant_level_api.rb +40 -40
  39. data/lib/adyen/services/management/terminal_settings_store_level_api.rb +16 -16
  40. data/lib/adyen/services/management/users_company_level_api.rb +13 -13
  41. data/lib/adyen/services/management/users_merchant_level_api.rb +13 -13
  42. data/lib/adyen/services/management/webhooks_company_level_api.rb +19 -19
  43. data/lib/adyen/services/management/webhooks_merchant_level_api.rb +19 -19
  44. data/lib/adyen/services/transfers/transfers_api.rb +6 -6
  45. data/lib/adyen/version.rb +1 -1
  46. metadata +2 -2
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: a8745b09f8edc40fabb77453e75201e77e3af826be8615bdb439d6bc452ac777
4
- data.tar.gz: 8a507142c9d6b9e82c07c8e4a7deb51a3fab7db40c79577efec3844652ee30d6
3
+ metadata.gz: 270b6ef403bd4388caeb109a653a812cb08a5ebca358f2524ddec2fb66f78133
4
+ data.tar.gz: e6c6eaf7eb56b10d02ba59955b504205f23c6c1793955aae2cb500e715a52aab
5
5
  SHA512:
6
- metadata.gz: 883b6e3ae48c3bc914b7d6434577271c15e67171f7d24bebb021fc89493a6a5eab0373f2041bd944b3075c62c3638db8928958f9cb4f1468c4ac7f2d594fc718
7
- data.tar.gz: 3ed556482fd55fc777a0f62e517bfdb28bda61c5ad4a7b639bb220b73e595f754d37dd0ebd21d8d29ff1df9fff3d2161f304eca07c078f99d0ed7e1f9cfb34be
6
+ metadata.gz: 18302f40daecf83d3fd54a9c56df1906f5682a50b48d75fec756f0fb17a7c79697b9cb4a209d724d4d0a176d2c909b079e8c10f983ac7e2a473bfcbf157a9189
7
+ data.tar.gz: 70edb1785ca54271a9a32c1c1fa35bcee5d3e9cef6b36da96a3f611b9411d12422568ea80f2079ea9826f7666e77036a6ebfceeaa43216a8da492d6062b000c9
@@ -2,9 +2,9 @@ name: "CodeQL"
2
2
 
3
3
  on:
4
4
  push:
5
- branches: [ "develop", "main" ]
5
+ branches: [ "main" ]
6
6
  pull_request:
7
- branches: [ "develop" ]
7
+ branches: [ "main" ]
8
8
  schedule:
9
9
  - cron: "40 12 * * 0"
10
10
 
@@ -10,12 +10,9 @@ jobs:
10
10
 
11
11
  steps:
12
12
  - uses: actions/checkout@v4
13
- - run: |
14
- git config user.name github-actions
15
- git config user.email github-actions@github.com
16
13
  - name: Release Gem on RubyGems
17
14
  if: contains(github.ref, 'refs/tags/v')
18
- uses: cadwallion/publish-rubygems-action@master
15
+ uses: cadwallion/publish-rubygems-action@v1.1.0
19
16
  env:
20
17
  GITHUB_TOKEN: ${{secrets.TOKEN_RUBYGEMS_RELEASES_WITH_EXPIRATION}}
21
18
  RUBYGEMS_API_KEY: ${{secrets.RUBYGEMS_API_KEY}}
data/CONTRIBUTING.md CHANGED
@@ -3,7 +3,7 @@
3
3
  ## How to contribute step-by-step
4
4
 
5
5
  1. Fork the `Adyen/adyen-ruby-api-library` repository.
6
- 2. Create a new branch from `develop` in your fork. This makes it easier for you to keep track of your changes.
6
+ 2. Create a new branch from `main` in your fork. This makes it easier for you to keep track of your changes.
7
7
  3. Make the desired changes to the code.
8
8
  * If you are adding new functionality or fixing a bug, we recommend you add unit tests that cover it.
9
9
  4. Push the changes to your fork.
data/README.md CHANGED
@@ -234,7 +234,7 @@ We value your input! Help us enhance our API Libraries and improve the integrati
234
234
  ## Contributing
235
235
 
236
236
  We encourage you to contribute to this repository, so everyone can benefit from new features, bug fixes, and any other improvements.
237
- Have a look at our [contributing guidelines](https://github.com/Adyen/adyen-ruby-api-library/blob/develop/CONTRIBUTING.md) to find out how to raise a pull request.
237
+ Have a look at our [contributing guidelines](/CONTRIBUTING.md) to find out how to raise a pull request.
238
238
 
239
239
  ## Support
240
240
  If you have a feature request, or spotted a bug or a technical problem, [create an issue here](https://github.com/Adyen/adyen-ruby-api-library/issues/new/choose).
data/VERSION CHANGED
@@ -1,2 +1,2 @@
1
- 8.0.0
1
+ 8.0.1
2
2
 
@@ -7,6 +7,15 @@ module Adyen
7
7
  super(client, version, 'BalancePlatform')
8
8
  end
9
9
 
10
+ def create_account_holder(request, headers: {})
11
+ endpoint = '/accountHolders'.gsub(/{.+?}/, '%s')
12
+ endpoint = endpoint.gsub(%r{^/}, '')
13
+ endpoint = format(endpoint)
14
+
15
+ action = { method: 'post', url: endpoint }
16
+ @client.call_adyen_api(@service, action, request, headers, @version)
17
+ end
18
+
10
19
  def get_account_holder(id, headers: {})
11
20
  endpoint = '/accountHolders/{id}'.gsub(/{.+?}/, '%s')
12
21
  endpoint = endpoint.gsub(%r{^/}, '')
@@ -43,14 +52,5 @@ module Adyen
43
52
  @client.call_adyen_api(@service, action, request, headers, @version)
44
53
  end
45
54
 
46
- def create_account_holder(request, headers: {})
47
- endpoint = '/accountHolders'.gsub(/{.+?}/, '%s')
48
- endpoint = endpoint.gsub(%r{^/}, '')
49
- endpoint = format(endpoint)
50
-
51
- action = { method: 'post', url: endpoint }
52
- @client.call_adyen_api(@service, action, request, headers, @version)
53
- end
54
-
55
55
  end
56
56
  end
@@ -7,6 +7,24 @@ module Adyen
7
7
  super(client, version, 'BalancePlatform')
8
8
  end
9
9
 
10
+ def create_balance_account(request, headers: {})
11
+ endpoint = '/balanceAccounts'.gsub(/{.+?}/, '%s')
12
+ endpoint = endpoint.gsub(%r{^/}, '')
13
+ endpoint = format(endpoint)
14
+
15
+ action = { method: 'post', url: endpoint }
16
+ @client.call_adyen_api(@service, action, request, headers, @version)
17
+ end
18
+
19
+ def create_sweep(request, balance_account_id, headers: {})
20
+ endpoint = '/balanceAccounts/{balanceAccountId}/sweeps'.gsub(/{.+?}/, '%s')
21
+ endpoint = endpoint.gsub(%r{^/}, '')
22
+ endpoint = format(endpoint, balance_account_id)
23
+
24
+ action = { method: 'post', url: endpoint }
25
+ @client.call_adyen_api(@service, action, request, headers, @version)
26
+ end
27
+
10
28
  def delete_sweep(balance_account_id, sweep_id, headers: {})
11
29
  endpoint = '/balanceAccounts/{balanceAccountId}/sweeps/{sweepId}'.gsub(/{.+?}/, '%s')
12
30
  endpoint = endpoint.gsub(%r{^/}, '')
@@ -16,20 +34,20 @@ module Adyen
16
34
  @client.call_adyen_api(@service, action, {}, headers, @version)
17
35
  end
18
36
 
19
- def get_all_sweeps_for_balance_account(balance_account_id, headers: {}, query_params: {})
20
- endpoint = '/balanceAccounts/{balanceAccountId}/sweeps'.gsub(/{.+?}/, '%s')
37
+ def get_all_payment_instruments_for_balance_account(id, headers: {}, query_params: {})
38
+ endpoint = '/balanceAccounts/{id}/paymentInstruments'.gsub(/{.+?}/, '%s')
21
39
  endpoint = endpoint.gsub(%r{^/}, '')
22
- endpoint = format(endpoint, balance_account_id)
40
+ endpoint = format(endpoint, id)
23
41
  endpoint += create_query_string(query_params)
24
42
  action = { method: 'get', url: endpoint }
25
43
  @client.call_adyen_api(@service, action, {}, headers, @version)
26
44
  end
27
45
 
28
- def get_sweep(balance_account_id, sweep_id, headers: {})
29
- endpoint = '/balanceAccounts/{balanceAccountId}/sweeps/{sweepId}'.gsub(/{.+?}/, '%s')
46
+ def get_all_sweeps_for_balance_account(balance_account_id, headers: {}, query_params: {})
47
+ endpoint = '/balanceAccounts/{balanceAccountId}/sweeps'.gsub(/{.+?}/, '%s')
30
48
  endpoint = endpoint.gsub(%r{^/}, '')
31
- endpoint = format(endpoint, balance_account_id, sweep_id)
32
-
49
+ endpoint = format(endpoint, balance_account_id)
50
+ endpoint += create_query_string(query_params)
33
51
  action = { method: 'get', url: endpoint }
34
52
  @client.call_adyen_api(@service, action, {}, headers, @version)
35
53
  end
@@ -43,22 +61,13 @@ module Adyen
43
61
  @client.call_adyen_api(@service, action, {}, headers, @version)
44
62
  end
45
63
 
46
- def get_all_payment_instruments_for_balance_account(id, headers: {}, query_params: {})
47
- endpoint = '/balanceAccounts/{id}/paymentInstruments'.gsub(/{.+?}/, '%s')
48
- endpoint = endpoint.gsub(%r{^/}, '')
49
- endpoint = format(endpoint, id)
50
- endpoint += create_query_string(query_params)
51
- action = { method: 'get', url: endpoint }
52
- @client.call_adyen_api(@service, action, {}, headers, @version)
53
- end
54
-
55
- def update_sweep(request, balance_account_id, sweep_id, headers: {})
64
+ def get_sweep(balance_account_id, sweep_id, headers: {})
56
65
  endpoint = '/balanceAccounts/{balanceAccountId}/sweeps/{sweepId}'.gsub(/{.+?}/, '%s')
57
66
  endpoint = endpoint.gsub(%r{^/}, '')
58
67
  endpoint = format(endpoint, balance_account_id, sweep_id)
59
68
 
60
- action = { method: 'patch', url: endpoint }
61
- @client.call_adyen_api(@service, action, request, headers, @version)
69
+ action = { method: 'get', url: endpoint }
70
+ @client.call_adyen_api(@service, action, {}, headers, @version)
62
71
  end
63
72
 
64
73
  def update_balance_account(request, id, headers: {})
@@ -70,21 +79,12 @@ module Adyen
70
79
  @client.call_adyen_api(@service, action, request, headers, @version)
71
80
  end
72
81
 
73
- def create_balance_account(request, headers: {})
74
- endpoint = '/balanceAccounts'.gsub(/{.+?}/, '%s')
75
- endpoint = endpoint.gsub(%r{^/}, '')
76
- endpoint = format(endpoint)
77
-
78
- action = { method: 'post', url: endpoint }
79
- @client.call_adyen_api(@service, action, request, headers, @version)
80
- end
81
-
82
- def create_sweep(request, balance_account_id, headers: {})
83
- endpoint = '/balanceAccounts/{balanceAccountId}/sweeps'.gsub(/{.+?}/, '%s')
82
+ def update_sweep(request, balance_account_id, sweep_id, headers: {})
83
+ endpoint = '/balanceAccounts/{balanceAccountId}/sweeps/{sweepId}'.gsub(/{.+?}/, '%s')
84
84
  endpoint = endpoint.gsub(%r{^/}, '')
85
- endpoint = format(endpoint, balance_account_id)
85
+ endpoint = format(endpoint, balance_account_id, sweep_id)
86
86
 
87
- action = { method: 'post', url: endpoint }
87
+ action = { method: 'patch', url: endpoint }
88
88
  @client.call_adyen_api(@service, action, request, headers, @version)
89
89
  end
90
90
 
@@ -7,13 +7,13 @@ module Adyen
7
7
  super(client, version, 'BalancePlatform')
8
8
  end
9
9
 
10
- def get_payment_instrument_group(id, headers: {})
11
- endpoint = '/paymentInstrumentGroups/{id}'.gsub(/{.+?}/, '%s')
10
+ def create_payment_instrument_group(request, headers: {})
11
+ endpoint = '/paymentInstrumentGroups'.gsub(/{.+?}/, '%s')
12
12
  endpoint = endpoint.gsub(%r{^/}, '')
13
- endpoint = format(endpoint, id)
13
+ endpoint = format(endpoint)
14
14
 
15
- action = { method: 'get', url: endpoint }
16
- @client.call_adyen_api(@service, action, {}, headers, @version)
15
+ action = { method: 'post', url: endpoint }
16
+ @client.call_adyen_api(@service, action, request, headers, @version)
17
17
  end
18
18
 
19
19
  def get_all_transaction_rules_for_payment_instrument_group(id, headers: {})
@@ -25,13 +25,13 @@ module Adyen
25
25
  @client.call_adyen_api(@service, action, {}, headers, @version)
26
26
  end
27
27
 
28
- def create_payment_instrument_group(request, headers: {})
29
- endpoint = '/paymentInstrumentGroups'.gsub(/{.+?}/, '%s')
28
+ def get_payment_instrument_group(id, headers: {})
29
+ endpoint = '/paymentInstrumentGroups/{id}'.gsub(/{.+?}/, '%s')
30
30
  endpoint = endpoint.gsub(%r{^/}, '')
31
- endpoint = format(endpoint)
31
+ endpoint = format(endpoint, id)
32
32
 
33
- action = { method: 'post', url: endpoint }
34
- @client.call_adyen_api(@service, action, request, headers, @version)
33
+ action = { method: 'get', url: endpoint }
34
+ @client.call_adyen_api(@service, action, {}, headers, @version)
35
35
  end
36
36
 
37
37
  end
@@ -7,17 +7,17 @@ module Adyen
7
7
  super(client, version, 'BalancePlatform')
8
8
  end
9
9
 
10
- def get_payment_instrument(id, headers: {})
11
- endpoint = '/paymentInstruments/{id}'.gsub(/{.+?}/, '%s')
10
+ def create_payment_instrument(request, headers: {})
11
+ endpoint = '/paymentInstruments'.gsub(/{.+?}/, '%s')
12
12
  endpoint = endpoint.gsub(%r{^/}, '')
13
- endpoint = format(endpoint, id)
13
+ endpoint = format(endpoint)
14
14
 
15
- action = { method: 'get', url: endpoint }
16
- @client.call_adyen_api(@service, action, {}, headers, @version)
15
+ action = { method: 'post', url: endpoint }
16
+ @client.call_adyen_api(@service, action, request, headers, @version)
17
17
  end
18
18
 
19
- def list_network_tokens(id, headers: {})
20
- endpoint = '/paymentInstruments/{id}/networkTokens'.gsub(/{.+?}/, '%s')
19
+ def get_all_transaction_rules_for_payment_instrument(id, headers: {})
20
+ endpoint = '/paymentInstruments/{id}/transactionRules'.gsub(/{.+?}/, '%s')
21
21
  endpoint = endpoint.gsub(%r{^/}, '')
22
22
  endpoint = format(endpoint, id)
23
23
 
@@ -34,8 +34,8 @@ module Adyen
34
34
  @client.call_adyen_api(@service, action, {}, headers, @version)
35
35
  end
36
36
 
37
- def get_all_transaction_rules_for_payment_instrument(id, headers: {})
38
- endpoint = '/paymentInstruments/{id}/transactionRules'.gsub(/{.+?}/, '%s')
37
+ def get_payment_instrument(id, headers: {})
38
+ endpoint = '/paymentInstruments/{id}'.gsub(/{.+?}/, '%s')
39
39
  endpoint = endpoint.gsub(%r{^/}, '')
40
40
  endpoint = format(endpoint, id)
41
41
 
@@ -43,21 +43,21 @@ module Adyen
43
43
  @client.call_adyen_api(@service, action, {}, headers, @version)
44
44
  end
45
45
 
46
- def update_payment_instrument(request, id, headers: {})
47
- endpoint = '/paymentInstruments/{id}'.gsub(/{.+?}/, '%s')
46
+ def list_network_tokens(id, headers: {})
47
+ endpoint = '/paymentInstruments/{id}/networkTokens'.gsub(/{.+?}/, '%s')
48
48
  endpoint = endpoint.gsub(%r{^/}, '')
49
49
  endpoint = format(endpoint, id)
50
50
 
51
- action = { method: 'patch', url: endpoint }
52
- @client.call_adyen_api(@service, action, request, headers, @version)
51
+ action = { method: 'get', url: endpoint }
52
+ @client.call_adyen_api(@service, action, {}, headers, @version)
53
53
  end
54
54
 
55
- def create_payment_instrument(request, headers: {})
56
- endpoint = '/paymentInstruments'.gsub(/{.+?}/, '%s')
55
+ def update_payment_instrument(request, id, headers: {})
56
+ endpoint = '/paymentInstruments/{id}'.gsub(/{.+?}/, '%s')
57
57
  endpoint = endpoint.gsub(%r{^/}, '')
58
- endpoint = format(endpoint)
58
+ endpoint = format(endpoint, id)
59
59
 
60
- action = { method: 'post', url: endpoint }
60
+ action = { method: 'patch', url: endpoint }
61
61
  @client.call_adyen_api(@service, action, request, headers, @version)
62
62
  end
63
63
 
@@ -7,20 +7,20 @@ module Adyen
7
7
  super(client, version, 'BalancePlatform')
8
8
  end
9
9
 
10
- def get_balance_platform(id, headers: {})
11
- endpoint = '/balancePlatforms/{id}'.gsub(/{.+?}/, '%s')
10
+ def get_all_account_holders_under_balance_platform(id, headers: {}, query_params: {})
11
+ endpoint = '/balancePlatforms/{id}/accountHolders'.gsub(/{.+?}/, '%s')
12
12
  endpoint = endpoint.gsub(%r{^/}, '')
13
13
  endpoint = format(endpoint, id)
14
-
14
+ endpoint += create_query_string(query_params)
15
15
  action = { method: 'get', url: endpoint }
16
16
  @client.call_adyen_api(@service, action, {}, headers, @version)
17
17
  end
18
18
 
19
- def get_all_account_holders_under_balance_platform(id, headers: {}, query_params: {})
20
- endpoint = '/balancePlatforms/{id}/accountHolders'.gsub(/{.+?}/, '%s')
19
+ def get_balance_platform(id, headers: {})
20
+ endpoint = '/balancePlatforms/{id}'.gsub(/{.+?}/, '%s')
21
21
  endpoint = endpoint.gsub(%r{^/}, '')
22
22
  endpoint = format(endpoint, id)
23
- endpoint += create_query_string(query_params)
23
+
24
24
  action = { method: 'get', url: endpoint }
25
25
  @client.call_adyen_api(@service, action, {}, headers, @version)
26
26
  end
@@ -7,6 +7,15 @@ module Adyen
7
7
  super(client, version, 'BalancePlatform')
8
8
  end
9
9
 
10
+ def create_transaction_rule(request, headers: {})
11
+ endpoint = '/transactionRules'.gsub(/{.+?}/, '%s')
12
+ endpoint = endpoint.gsub(%r{^/}, '')
13
+ endpoint = format(endpoint)
14
+
15
+ action = { method: 'post', url: endpoint }
16
+ @client.call_adyen_api(@service, action, request, headers, @version)
17
+ end
18
+
10
19
  def delete_transaction_rule(transaction_rule_id, headers: {})
11
20
  endpoint = '/transactionRules/{transactionRuleId}'.gsub(/{.+?}/, '%s')
12
21
  endpoint = endpoint.gsub(%r{^/}, '')
@@ -34,14 +43,5 @@ module Adyen
34
43
  @client.call_adyen_api(@service, action, request, headers, @version)
35
44
  end
36
45
 
37
- def create_transaction_rule(request, headers: {})
38
- endpoint = '/transactionRules'.gsub(/{.+?}/, '%s')
39
- endpoint = endpoint.gsub(%r{^/}, '')
40
- endpoint = format(endpoint)
41
-
42
- action = { method: 'post', url: endpoint }
43
- @client.call_adyen_api(@service, action, request, headers, @version)
44
- end
45
-
46
46
  end
47
47
  end
@@ -16,15 +16,6 @@ module Adyen
16
16
  @client.call_adyen_api(@service, action, request, headers, @version)
17
17
  end
18
18
 
19
- def update_authorised_amount(request, payment_psp_reference, headers: {})
20
- endpoint = '/payments/{paymentPspReference}/amountUpdates'.gsub(/{.+?}/, '%s')
21
- endpoint = endpoint.gsub(%r{^/}, '')
22
- endpoint = format(endpoint, payment_psp_reference)
23
-
24
- action = { method: 'post', url: endpoint }
25
- @client.call_adyen_api(@service, action, request, headers, @version)
26
- end
27
-
28
19
  def cancel_authorised_payment_by_psp_reference(request, payment_psp_reference, headers: {})
29
20
  endpoint = '/payments/{paymentPspReference}/cancels'.gsub(/{.+?}/, '%s')
30
21
  endpoint = endpoint.gsub(%r{^/}, '')
@@ -61,5 +52,14 @@ module Adyen
61
52
  @client.call_adyen_api(@service, action, request, headers, @version)
62
53
  end
63
54
 
55
+ def update_authorised_amount(request, payment_psp_reference, headers: {})
56
+ endpoint = '/payments/{paymentPspReference}/amountUpdates'.gsub(/{.+?}/, '%s')
57
+ endpoint = endpoint.gsub(%r{^/}, '')
58
+ endpoint = format(endpoint, payment_psp_reference)
59
+
60
+ action = { method: 'post', url: endpoint }
61
+ @client.call_adyen_api(@service, action, request, headers, @version)
62
+ end
63
+
64
64
  end
65
65
  end
@@ -7,8 +7,8 @@ module Adyen
7
7
  super(client, version, 'Checkout')
8
8
  end
9
9
 
10
- def orders(request, headers: {})
11
- endpoint = '/orders'.gsub(/{.+?}/, '%s')
10
+ def cancel_order(request, headers: {})
11
+ endpoint = '/orders/cancel'.gsub(/{.+?}/, '%s')
12
12
  endpoint = endpoint.gsub(%r{^/}, '')
13
13
  endpoint = format(endpoint)
14
14
 
@@ -16,8 +16,8 @@ module Adyen
16
16
  @client.call_adyen_api(@service, action, request, headers, @version)
17
17
  end
18
18
 
19
- def cancel_order(request, headers: {})
20
- endpoint = '/orders/cancel'.gsub(/{.+?}/, '%s')
19
+ def get_balance_of_gift_card(request, headers: {})
20
+ endpoint = '/paymentMethods/balance'.gsub(/{.+?}/, '%s')
21
21
  endpoint = endpoint.gsub(%r{^/}, '')
22
22
  endpoint = format(endpoint)
23
23
 
@@ -25,8 +25,8 @@ module Adyen
25
25
  @client.call_adyen_api(@service, action, request, headers, @version)
26
26
  end
27
27
 
28
- def get_balance_of_gift_card(request, headers: {})
29
- endpoint = '/paymentMethods/balance'.gsub(/{.+?}/, '%s')
28
+ def orders(request, headers: {})
29
+ endpoint = '/orders'.gsub(/{.+?}/, '%s')
30
30
  endpoint = endpoint.gsub(%r{^/}, '')
31
31
  endpoint = format(endpoint)
32
32
 
@@ -16,21 +16,21 @@ module Adyen
16
16
  @client.call_adyen_api(@service, action, {}, headers, @version)
17
17
  end
18
18
 
19
- def update_payment_link(request, link_id, headers: {})
20
- endpoint = '/paymentLinks/{linkId}'.gsub(/{.+?}/, '%s')
19
+ def payment_links(request, headers: {})
20
+ endpoint = '/paymentLinks'.gsub(/{.+?}/, '%s')
21
21
  endpoint = endpoint.gsub(%r{^/}, '')
22
- endpoint = format(endpoint, link_id)
22
+ endpoint = format(endpoint)
23
23
 
24
- action = { method: 'patch', url: endpoint }
24
+ action = { method: 'post', url: endpoint }
25
25
  @client.call_adyen_api(@service, action, request, headers, @version)
26
26
  end
27
27
 
28
- def payment_links(request, headers: {})
29
- endpoint = '/paymentLinks'.gsub(/{.+?}/, '%s')
28
+ def update_payment_link(request, link_id, headers: {})
29
+ endpoint = '/paymentLinks/{linkId}'.gsub(/{.+?}/, '%s')
30
30
  endpoint = endpoint.gsub(%r{^/}, '')
31
- endpoint = format(endpoint)
31
+ endpoint = format(endpoint, link_id)
32
32
 
33
- action = { method: 'post', url: endpoint }
33
+ action = { method: 'patch', url: endpoint }
34
34
  @client.call_adyen_api(@service, action, request, headers, @version)
35
35
  end
36
36
 
@@ -7,15 +7,6 @@ module Adyen
7
7
  super(client, version, 'Checkout')
8
8
  end
9
9
 
10
- def get_result_of_payment_session(session_id, headers: {}, query_params: {})
11
- endpoint = '/sessions/{sessionId}'.gsub(/{.+?}/, '%s')
12
- endpoint = endpoint.gsub(%r{^/}, '')
13
- endpoint = format(endpoint, session_id)
14
- endpoint += create_query_string(query_params)
15
- action = { method: 'get', url: endpoint }
16
- @client.call_adyen_api(@service, action, {}, headers, @version)
17
- end
18
-
19
10
  def card_details(request, headers: {})
20
11
  endpoint = '/cardDetails'.gsub(/{.+?}/, '%s')
21
12
  endpoint = endpoint.gsub(%r{^/}, '')
@@ -34,6 +25,15 @@ module Adyen
34
25
  @client.call_adyen_api(@service, action, request, headers, @version)
35
26
  end
36
27
 
28
+ def get_result_of_payment_session(session_id, headers: {}, query_params: {})
29
+ endpoint = '/sessions/{sessionId}'.gsub(/{.+?}/, '%s')
30
+ endpoint = endpoint.gsub(%r{^/}, '')
31
+ endpoint = format(endpoint, session_id)
32
+ endpoint += create_query_string(query_params)
33
+ action = { method: 'get', url: endpoint }
34
+ @client.call_adyen_api(@service, action, {}, headers, @version)
35
+ end
36
+
37
37
  def payment_methods(request, headers: {})
38
38
  endpoint = '/paymentMethods'.gsub(/{.+?}/, '%s')
39
39
  endpoint = endpoint.gsub(%r{^/}, '')
@@ -5,7 +5,7 @@ module Adyen
5
5
 
6
6
  DEFAULT_VERSION = 1
7
7
  def initialize(client, version = DEFAULT_VERSION)
8
- super(client, version, 'DataProtection')
8
+ super(client, version, 'DataProtectionService')
9
9
  end
10
10
 
11
11
  def request_subject_erasure(request, headers: {})
@@ -7,6 +7,15 @@ module Adyen
7
7
  super(client, version, 'LegalEntityManagement')
8
8
  end
9
9
 
10
+ def create_business_line(request, headers: {})
11
+ endpoint = '/businessLines'.gsub(/{.+?}/, '%s')
12
+ endpoint = endpoint.gsub(%r{^/}, '')
13
+ endpoint = format(endpoint)
14
+
15
+ action = { method: 'post', url: endpoint }
16
+ @client.call_adyen_api(@service, action, request, headers, @version)
17
+ end
18
+
10
19
  def delete_business_line(id, headers: {})
11
20
  endpoint = '/businessLines/{id}'.gsub(/{.+?}/, '%s')
12
21
  endpoint = endpoint.gsub(%r{^/}, '')
@@ -34,14 +43,5 @@ module Adyen
34
43
  @client.call_adyen_api(@service, action, request, headers, @version)
35
44
  end
36
45
 
37
- def create_business_line(request, headers: {})
38
- endpoint = '/businessLines'.gsub(/{.+?}/, '%s')
39
- endpoint = endpoint.gsub(%r{^/}, '')
40
- endpoint = format(endpoint)
41
-
42
- action = { method: 'post', url: endpoint }
43
- @client.call_adyen_api(@service, action, request, headers, @version)
44
- end
45
-
46
46
  end
47
47
  end
@@ -7,13 +7,13 @@ module Adyen
7
7
  super(client, version, 'LegalEntityManagement')
8
8
  end
9
9
 
10
- def list_hosted_onboarding_page_themes(headers: {})
11
- endpoint = '/themes'.gsub(/{.+?}/, '%s')
10
+ def get_link_to_adyenhosted_onboarding_page(request, id, headers: {})
11
+ endpoint = '/legalEntities/{id}/onboardingLinks'.gsub(/{.+?}/, '%s')
12
12
  endpoint = endpoint.gsub(%r{^/}, '')
13
- endpoint = format(endpoint)
13
+ endpoint = format(endpoint, id)
14
14
 
15
- action = { method: 'get', url: endpoint }
16
- @client.call_adyen_api(@service, action, {}, headers, @version)
15
+ action = { method: 'post', url: endpoint }
16
+ @client.call_adyen_api(@service, action, request, headers, @version)
17
17
  end
18
18
 
19
19
  def get_onboarding_link_theme(id, headers: {})
@@ -25,13 +25,13 @@ module Adyen
25
25
  @client.call_adyen_api(@service, action, {}, headers, @version)
26
26
  end
27
27
 
28
- def get_link_to_adyenhosted_onboarding_page(request, id, headers: {})
29
- endpoint = '/legalEntities/{id}/onboardingLinks'.gsub(/{.+?}/, '%s')
28
+ def list_hosted_onboarding_page_themes(headers: {})
29
+ endpoint = '/themes'.gsub(/{.+?}/, '%s')
30
30
  endpoint = endpoint.gsub(%r{^/}, '')
31
- endpoint = format(endpoint, id)
31
+ endpoint = format(endpoint)
32
32
 
33
- action = { method: 'post', url: endpoint }
34
- @client.call_adyen_api(@service, action, request, headers, @version)
33
+ action = { method: 'get', url: endpoint }
34
+ @client.call_adyen_api(@service, action, {}, headers, @version)
35
35
  end
36
36
 
37
37
  end
@@ -7,33 +7,24 @@ module Adyen
7
7
  super(client, version, 'LegalEntityManagement')
8
8
  end
9
9
 
10
- def get_legal_entity(id, headers: {})
11
- endpoint = '/legalEntities/{id}'.gsub(/{.+?}/, '%s')
10
+ def check_legal_entitys_verification_errors(id, headers: {})
11
+ endpoint = '/legalEntities/{id}/checkVerificationErrors'.gsub(/{.+?}/, '%s')
12
12
  endpoint = endpoint.gsub(%r{^/}, '')
13
13
  endpoint = format(endpoint, id)
14
14
 
15
- action = { method: 'get', url: endpoint }
15
+ action = { method: 'post', url: endpoint }
16
16
  @client.call_adyen_api(@service, action, {}, headers, @version)
17
17
  end
18
18
 
19
- def get_all_business_lines_under_legal_entity(id, headers: {})
20
- endpoint = '/legalEntities/{id}/businessLines'.gsub(/{.+?}/, '%s')
19
+ def confirm_data_review(id, headers: {})
20
+ endpoint = '/legalEntities/{id}/confirmDataReview'.gsub(/{.+?}/, '%s')
21
21
  endpoint = endpoint.gsub(%r{^/}, '')
22
22
  endpoint = format(endpoint, id)
23
23
 
24
- action = { method: 'get', url: endpoint }
24
+ action = { method: 'post', url: endpoint }
25
25
  @client.call_adyen_api(@service, action, {}, headers, @version)
26
26
  end
27
27
 
28
- def update_legal_entity(request, id, headers: {})
29
- endpoint = '/legalEntities/{id}'.gsub(/{.+?}/, '%s')
30
- endpoint = endpoint.gsub(%r{^/}, '')
31
- endpoint = format(endpoint, id)
32
-
33
- action = { method: 'patch', url: endpoint }
34
- @client.call_adyen_api(@service, action, request, headers, @version)
35
- end
36
-
37
28
  def create_legal_entity(request, headers: {})
38
29
  endpoint = '/legalEntities'.gsub(/{.+?}/, '%s')
39
30
  endpoint = endpoint.gsub(%r{^/}, '')
@@ -43,14 +34,32 @@ module Adyen
43
34
  @client.call_adyen_api(@service, action, request, headers, @version)
44
35
  end
45
36
 
46
- def check_legal_entitys_verification_errors(id, headers: {})
47
- endpoint = '/legalEntities/{id}/checkVerificationErrors'.gsub(/{.+?}/, '%s')
37
+ def get_all_business_lines_under_legal_entity(id, headers: {})
38
+ endpoint = '/legalEntities/{id}/businessLines'.gsub(/{.+?}/, '%s')
48
39
  endpoint = endpoint.gsub(%r{^/}, '')
49
40
  endpoint = format(endpoint, id)
50
41
 
51
- action = { method: 'post', url: endpoint }
42
+ action = { method: 'get', url: endpoint }
52
43
  @client.call_adyen_api(@service, action, {}, headers, @version)
53
44
  end
54
45
 
46
+ def get_legal_entity(id, headers: {})
47
+ endpoint = '/legalEntities/{id}'.gsub(/{.+?}/, '%s')
48
+ endpoint = endpoint.gsub(%r{^/}, '')
49
+ endpoint = format(endpoint, id)
50
+
51
+ action = { method: 'get', url: endpoint }
52
+ @client.call_adyen_api(@service, action, {}, headers, @version)
53
+ end
54
+
55
+ def update_legal_entity(request, id, headers: {})
56
+ endpoint = '/legalEntities/{id}'.gsub(/{.+?}/, '%s')
57
+ endpoint = endpoint.gsub(%r{^/}, '')
58
+ endpoint = format(endpoint, id)
59
+
60
+ action = { method: 'patch', url: endpoint }
61
+ @client.call_adyen_api(@service, action, request, headers, @version)
62
+ end
63
+
55
64
  end
56
65
  end