adyen-ruby-api-library 4.3.0 → 6.0.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.
Files changed (76) hide show
  1. checksums.yaml +4 -4
  2. data/.github/CODEOWNERS +1 -1
  3. data/.github/workflows/ruby.yml +20 -0
  4. data/.gitignore +4 -0
  5. data/README.md +73 -124
  6. data/docs/marketpay.html +2 -0
  7. data/lib/adyen/client.rb +43 -24
  8. data/lib/adyen/services/{checkout_utility.rb → bin_lookup.rb} +6 -4
  9. data/lib/adyen/services/checkout.rb +89 -8
  10. data/lib/adyen/services/dispute.rb +20 -0
  11. data/lib/adyen/services/marketpay.rb +10 -7
  12. data/lib/adyen/services/payments.rb +14 -5
  13. data/lib/adyen/services/payouts.rb +3 -2
  14. data/lib/adyen/services/recurring.rb +3 -2
  15. data/lib/adyen/services/service.rb +2 -2
  16. data/lib/adyen/version.rb +1 -1
  17. data/lib/adyen-ruby-api-library.rb +2 -1
  18. data/spec/account_spec.rb +4 -1
  19. data/spec/bin_lookup_spec.rb +15 -0
  20. data/spec/checkout_spec.rb +275 -5
  21. data/spec/dispute_spec.rb +17 -0
  22. data/spec/fund_spec.rb +2 -1
  23. data/spec/mocks/requests/Account/check_account_holder.json +5 -0
  24. data/spec/mocks/requests/Account/delete_payout_methods.json +6 -0
  25. data/spec/mocks/requests/Account/delete_signatories.json +6 -0
  26. data/spec/mocks/requests/BinLookup/get_3ds_availability.json +4 -0
  27. data/spec/mocks/requests/BinLookup/get_cost_estimate.json +8 -0
  28. data/spec/mocks/requests/Checkout/orders.json +6 -0
  29. data/spec/mocks/requests/Checkout/orders_cancel.json +7 -0
  30. data/spec/mocks/requests/Checkout/origin_keys.json +3 -0
  31. data/spec/mocks/requests/Checkout/payment_methods_balance.json +9 -0
  32. data/spec/mocks/requests/Checkout/sessions.json +10 -0
  33. data/spec/mocks/requests/DisputeService/defend_dispute.json +5 -0
  34. data/spec/mocks/requests/DisputeService/delete_dispute_defense_document.json +5 -0
  35. data/spec/mocks/requests/DisputeService/retrieve_applicable_defense_reasons.json +4 -0
  36. data/spec/mocks/requests/DisputeService/supply_defense_document.json +11 -0
  37. data/spec/mocks/requests/Fund/refund_funds_transfer.json +7 -0
  38. data/spec/mocks/requests/Payment/get_authentication_result.json +4 -0
  39. data/spec/mocks/requests/Payment/retrieve_3ds2_result.json +4 -0
  40. data/spec/mocks/requests/Payment/technical_cancel.json +4 -0
  41. data/spec/mocks/requests/Payment/void_pending_refund.json +4 -0
  42. data/spec/mocks/requests/Payout/payout.json +8 -0
  43. data/spec/mocks/requests/Recurring/schedule_account_updater.json +12 -0
  44. data/spec/mocks/responses/Account/check_account_holder.json +3 -0
  45. data/spec/mocks/responses/Account/delete_payout_methods.json +3 -0
  46. data/spec/mocks/responses/Account/delete_signatories.json +3 -0
  47. data/spec/mocks/responses/BinLookup/get_3ds_availability.json +8 -0
  48. data/spec/mocks/responses/BinLookup/get_cost_estimate.json +8 -0
  49. data/spec/mocks/responses/Checkout/get-payment-link.json +11 -0
  50. data/spec/mocks/responses/Checkout/orders.json +8 -0
  51. data/spec/mocks/responses/Checkout/orders_cancel.json +4 -0
  52. data/spec/mocks/responses/Checkout/origin_keys.json +5 -0
  53. data/spec/mocks/responses/Checkout/payment_methods_balance.json +3 -0
  54. data/spec/mocks/responses/Checkout/sessions-success.json +11 -0
  55. data/spec/mocks/responses/Checkout/update-payment-link.json +11 -0
  56. data/spec/mocks/responses/DisputeService/defend_dispute.json +5 -0
  57. data/spec/mocks/responses/DisputeService/delete_dispute_defense_document.json +5 -0
  58. data/spec/mocks/responses/DisputeService/retrieve_applicable_defense_reasons.json +28 -0
  59. data/spec/mocks/responses/DisputeService/supply_defense_document.json +5 -0
  60. data/spec/mocks/responses/Fund/refund_funds_transfer.json +5 -0
  61. data/spec/mocks/responses/Payment/get_authentication_result.json +5 -0
  62. data/spec/mocks/responses/Payment/retrieve_3ds2_result.json +5 -0
  63. data/spec/mocks/responses/Payment/technical_cancel.json +3 -0
  64. data/spec/mocks/responses/Payment/void_pending_refund.json +3 -0
  65. data/spec/mocks/responses/Payout/payout.json +3 -0
  66. data/spec/mocks/responses/Recurring/schedule_account_updater.json +4 -0
  67. data/spec/payments_spec.rb +5 -1
  68. data/spec/payouts_spec.rb +2 -1
  69. data/spec/recurring_spec.rb +2 -1
  70. data/spec/service_spec.rb +1 -0
  71. data/spec/spec_helper.rb +18 -12
  72. metadata +52 -8
  73. data/.travis.yml +0 -14
  74. data/spec/checkout_utility_spec.rb +0 -29
  75. data/spec/mocks/requests/CheckoutUtility/origin_keys.json +0 -7
  76. data/spec/mocks/responses/CheckoutUtility/origin_keys.json +0 -7
@@ -0,0 +1,8 @@
1
+ {
2
+ "binDetails": {
3
+ "issuerCountry": "NL"
4
+ },
5
+ "threeDS1Supported": true,
6
+ "threeDS2CardRangeDetails": [],
7
+ "threeDS2supported": false
8
+ }
@@ -0,0 +1,8 @@
1
+ {
2
+ "costEstimateAmount": {
3
+ "currency": "EUR",
4
+ "value": 1000
5
+ },
6
+ "resultCode": "Success",
7
+ "surchargeType": "PASSTHROUGH"
8
+ }
@@ -0,0 +1,11 @@
1
+ {
2
+ "amount": {
3
+ "currency": "USD",
4
+ "value": 1000
5
+ },
6
+ "id": "MockId",
7
+ "merchantAccount": "TestMerchant",
8
+ "reference": "Merchant Reference",
9
+ "status": "active",
10
+ "url": "https://adyen.com"
11
+ }
@@ -0,0 +1,8 @@
1
+ {
2
+ "expiresAt": "1970-01-01",
3
+ "orderData": "mockedOrderData",
4
+ "remainingAmount": {
5
+ "currency": "USD",
6
+ "value": 100
7
+ }
8
+ }
@@ -0,0 +1,4 @@
1
+ {
2
+ "pspReference": "mocked_psp_ref",
3
+ "resultCode": "cancelled"
4
+ }
@@ -0,0 +1,5 @@
1
+ {
2
+ "originKeys": {
3
+ "https://adyen.com": "mocked_origin_key"
4
+ }
5
+ }
@@ -0,0 +1,3 @@
1
+ {
2
+ "balance": "100"
3
+ }
@@ -0,0 +1,11 @@
1
+ {
2
+ "id": "session-test-id",
3
+ "amount": {
4
+ "currency": "EUR",
5
+ "value": 1000
6
+ },
7
+ "reference": "TestReference",
8
+ "returnUrl": "http://test-url.com",
9
+ "expiresAt": "2021-09-30T06:45:06Z",
10
+ "merchantAccount": "YourMerchantAccount"
11
+ }
@@ -0,0 +1,11 @@
1
+ {
2
+ "amount": {
3
+ "currency": "USD",
4
+ "value": 1000
5
+ },
6
+ "id": "MockId",
7
+ "merchantAccount": "TestMerchant",
8
+ "reference": "Merchant Reference",
9
+ "status": "expired",
10
+ "url": "https://adyen.com"
11
+ }
@@ -0,0 +1,5 @@
1
+ {
2
+ "disputeServiceResult": {
3
+ "success": true
4
+ }
5
+ }
@@ -0,0 +1,5 @@
1
+ {
2
+ "disputeServiceResult": {
3
+ "success": true
4
+ }
5
+ }
@@ -0,0 +1,28 @@
1
+ {
2
+ "defenseReasons": [
3
+ {
4
+ "defenseDocumentTypes": [
5
+ {
6
+ "available": false,
7
+ "defenseDocumentTypeCode": "TIDorInvoice",
8
+ "requirementLevel": "Optional"
9
+ },
10
+ {
11
+ "available": false,
12
+ "defenseDocumentTypeCode": "DefenseMaterial",
13
+ "requirementLevel": "Required"
14
+ },
15
+ {
16
+ "available": false,
17
+ "defenseDocumentTypeCode": "AlternativeDefenseMaterial",
18
+ "requirementLevel": "AlternativeRequired"
19
+ }
20
+ ],
21
+ "defenseReasonCode": "SupplyDefenseMaterial",
22
+ "satisfied": false
23
+ }
24
+ ],
25
+ "disputeServiceResult": {
26
+ "success": true
27
+ }
28
+ }
@@ -0,0 +1,5 @@
1
+ {
2
+ "disputeServiceResult": {
3
+ "success": true
4
+ }
5
+ }
@@ -0,0 +1,5 @@
1
+ {
2
+ "pspReference": "9915090893984580",
3
+ "merchantReference": "MerchantReference",
4
+ "resultCode": "Received"
5
+ }
@@ -0,0 +1,5 @@
1
+ {
2
+ "threeDS2Result": {
3
+ "transStatus": "Y"
4
+ }
5
+ }
@@ -0,0 +1,5 @@
1
+ {
2
+ "threeDS2Result": {
3
+ "transStatus": "Y"
4
+ }
5
+ }
@@ -0,0 +1,3 @@
1
+ {
2
+ "originalReference": "9914694372990637"
3
+ }
@@ -0,0 +1,3 @@
1
+ {
2
+ "pspReference": "9914694372990637"
3
+ }
@@ -0,0 +1,3 @@
1
+ {
2
+ "resultCode": "Success"
3
+ }
@@ -0,0 +1,4 @@
1
+ {
2
+ "pspReference": "8815260599791117",
3
+ "result": "Success"
4
+ }
@@ -15,7 +15,11 @@ RSpec.describe Adyen::Payments, service: "payments service" do
15
15
  ["cancel_or_refund", "response", "[cancelOrRefund-received]"],
16
16
  ["capture", "response", "[capture-received]"],
17
17
  ["refund", "response", "[refund-received]"],
18
- ["donate", "response", "[donation-received]"]
18
+ ["donate", "response", "[donation-received]"],
19
+ ["get_authentication_result", "threeDS2Result", {"transStatus" => "Y"}],
20
+ ["retrieve_3ds2_result", "threeDS2Result", {"transStatus" => "Y"}],
21
+ ["technical_cancel", "originalReference", "9914694372990637"],
22
+ ["void_pending_refund", "pspReference", "9914694372990637"]
19
23
  ]
20
24
 
21
25
  generate_tests(client, "Payment", test_sets, client.payments)
data/spec/payouts_spec.rb CHANGED
@@ -11,7 +11,8 @@ RSpec.describe Adyen::Payments, service: "payouts service" do
11
11
  ["store_detail_and_submit_third_party", "resultCode", "[payout-submit-received]"],
12
12
  ["submit_third_party", "resultCode", "[payout-submit-received]"],
13
13
  ["confirm_third_party", "response", "[payout-confirm-received]"],
14
- ["decline_third_party", "response", "[payout-decline-received]"]
14
+ ["decline_third_party", "response", "[payout-decline-received]"],
15
+ ["payout", "resultCode", "Success"]
15
16
  ]
16
17
 
17
18
  generate_tests(client, "Payout", test_sets, client.payouts)
@@ -10,7 +10,8 @@ RSpec.describe Adyen::Payments, service: "recurring service" do
10
10
  test_sets = [
11
11
  ["list_recurring_details", "creationDate", "2017-03-01T11:53:11+01:00"],
12
12
  ["disable", "response", "[detail-successfully-disabled]"],
13
- ["store_token", "result", "Success"]
13
+ ["store_token", "result", "Success"],
14
+ ["schedule_account_updater", "result", "Success"]
14
15
  ]
15
16
 
16
17
  generate_tests(client, "Recurring", test_sets, client.recurring)
data/spec/service_spec.rb CHANGED
@@ -18,6 +18,7 @@ RSpec.describe Adyen::Service do
18
18
  expect(described_class.action_for_method_name(:decline_third_party)).to eq 'declineThirdParty'
19
19
  expect(described_class.action_for_method_name(:delete_bank_accounts)).to eq 'deleteBankAccounts'
20
20
  expect(described_class.action_for_method_name(:delete_shareholders)).to eq 'deleteShareholders'
21
+ expect(described_class.action_for_method_name(:delete_signatories)).to eq 'deleteSignatories'
21
22
  expect(described_class.action_for_method_name(:disable)).to eq 'disable'
22
23
  expect(described_class.action_for_method_name(:donate)).to eq 'donate'
23
24
  expect(described_class.action_for_method_name(:get_account_holder)).to eq 'getAccountHolder'
data/spec/spec_helper.rb CHANGED
@@ -18,20 +18,26 @@ def create_test(client, service, method_name, parent_object)
18
18
  request_body = JSON.parse(json_from_file("mocks/requests/#{service}/#{method_name}.json"))
19
19
  response_body = json_from_file("mocks/responses/#{service}/#{method_name}.json")
20
20
 
21
-
22
- if service == 'Checkout' || service == 'CheckoutUtility'
21
+ with_application_info = [
22
+ "authorise",
23
+ "authorise3d",
24
+ "authorise3ds2",
25
+ "payments",
26
+ "payment_session",
27
+ ]
28
+ if with_application_info.include?(method_name)
23
29
  client.add_application_info(request_body)
24
30
  end
25
31
 
26
32
  # client-generated headers
27
33
  headers = {
28
- 'Content-Type'.to_sym => 'application/json'
34
+ "Content-Type".to_sym => "application/json",
29
35
  }
30
36
 
31
37
  # authentication headers
32
- if not client.api_key.nil? then
38
+ if not client.api_key.nil?
33
39
  headers["x-api-key"] = client.api_key
34
- elsif not client.ws_user.nil? and not client.ws_password.nil? then
40
+ elsif not client.ws_user.nil? and not client.ws_password.nil?
35
41
  auth_header = "Basic " + Base64::encode64("#{client.ws_user}:#{client.ws_password}")
36
42
  headers["Authorization"] = auth_header.strip
37
43
  else
@@ -43,12 +49,12 @@ def create_test(client, service, method_name, parent_object)
43
49
  url = client.service_url(service, action, parent_object.version)
44
50
  WebMock.stub_request(:post, url).
45
51
  with(
46
- body: request_body,
47
- headers: headers
48
- ).
52
+ body: request_body,
53
+ headers: headers,
54
+ ).
49
55
  to_return(
50
- body: response_body
51
- )
56
+ body: response_body,
57
+ )
52
58
  result = parent_object.public_send(method_name, request_body)
53
59
 
54
60
  # result.response is already a Ruby object (Adyen::HashWithAccessors) (rather than an unparsed JSON string)
@@ -86,10 +92,10 @@ def create_client(auth_type)
86
92
  client = Adyen::Client.new
87
93
  client.env = :mock
88
94
 
89
- if auth_type == :basic then
95
+ if auth_type == :basic
90
96
  client.ws_user = "user"
91
97
  client.ws_password = "password"
92
- elsif auth_type == :api_key then
98
+ elsif auth_type == :api_key
93
99
  client.api_key = "api_key"
94
100
  else
95
101
  raise ArgumentError "Invalid auth type for test client"
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: adyen-ruby-api-library
3
3
  version: !ruby/object:Gem::Version
4
- version: 4.3.0
4
+ version: 6.0.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Adyen
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2020-07-13 00:00:00.000000000 Z
11
+ date: 2021-10-21 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: faraday
@@ -81,8 +81,8 @@ files:
81
81
  - ".github/ISSUE_TEMPLATE/feature_request.md"
82
82
  - ".github/PULL_REQUEST_TEMPLATE.md"
83
83
  - ".github/dependabot.yml"
84
+ - ".github/workflows/ruby.yml"
84
85
  - ".gitignore"
85
- - ".travis.yml"
86
86
  - CODE_OF_CONDUCT.md
87
87
  - CONTRIBUTING.md
88
88
  - Gemfile
@@ -111,9 +111,10 @@ files:
111
111
  - lib/adyen/errors.rb
112
112
  - lib/adyen/hash_with_accessors.rb
113
113
  - lib/adyen/result.rb
114
+ - lib/adyen/services/bin_lookup.rb
114
115
  - lib/adyen/services/checkout.rb
115
- - lib/adyen/services/checkout_utility.rb
116
116
  - lib/adyen/services/data_protection.rb
117
+ - lib/adyen/services/dispute.rb
117
118
  - lib/adyen/services/marketpay.rb
118
119
  - lib/adyen/services/payments.rb
119
120
  - lib/adyen/services/payouts.rb
@@ -124,20 +125,24 @@ files:
124
125
  - lib/adyen/version.rb
125
126
  - renovate.json
126
127
  - spec/account_spec.rb
128
+ - spec/bin_lookup_spec.rb
127
129
  - spec/checkout_spec.rb
128
- - spec/checkout_utility_spec.rb
129
130
  - spec/client_spec.rb
130
131
  - spec/data_protection_spec.rb
132
+ - spec/dispute_spec.rb
131
133
  - spec/errors_spec.rb
132
134
  - spec/fund_spec.rb
133
135
  - spec/hash_with_accessors_spec.rb
134
136
  - spec/hop_spec.rb
137
+ - spec/mocks/requests/Account/check_account_holder.json
135
138
  - spec/mocks/requests/Account/close_account.json
136
139
  - spec/mocks/requests/Account/close_account_holder.json
137
140
  - spec/mocks/requests/Account/create_account.json
138
141
  - spec/mocks/requests/Account/create_account_holder.json
139
142
  - spec/mocks/requests/Account/delete_bank_accounts.json
143
+ - spec/mocks/requests/Account/delete_payout_methods.json
140
144
  - spec/mocks/requests/Account/delete_shareholders.json
145
+ - spec/mocks/requests/Account/delete_signatories.json
141
146
  - spec/mocks/requests/Account/get_account_holder.json
142
147
  - spec/mocks/requests/Account/get_uploaded_documents.json
143
148
  - spec/mocks/requests/Account/suspend_account_holder.json
@@ -146,18 +151,29 @@ files:
146
151
  - spec/mocks/requests/Account/update_account_holder.json
147
152
  - spec/mocks/requests/Account/update_account_holder_state.json
148
153
  - spec/mocks/requests/Account/upload_document.json
154
+ - spec/mocks/requests/BinLookup/get_3ds_availability.json
155
+ - spec/mocks/requests/BinLookup/get_cost_estimate.json
156
+ - spec/mocks/requests/Checkout/orders.json
157
+ - spec/mocks/requests/Checkout/orders_cancel.json
158
+ - spec/mocks/requests/Checkout/origin_keys.json
149
159
  - spec/mocks/requests/Checkout/payment-details.json
150
160
  - spec/mocks/requests/Checkout/payment-result.json
151
161
  - spec/mocks/requests/Checkout/payment_links.json
152
162
  - spec/mocks/requests/Checkout/payment_methods.json
163
+ - spec/mocks/requests/Checkout/payment_methods_balance.json
153
164
  - spec/mocks/requests/Checkout/payment_session.json
154
165
  - spec/mocks/requests/Checkout/payments.json
166
+ - spec/mocks/requests/Checkout/sessions.json
155
167
  - spec/mocks/requests/Checkout/verify.json
156
- - spec/mocks/requests/CheckoutUtility/origin_keys.json
157
168
  - spec/mocks/requests/DataProtectionService/request_subject_erasure.json
169
+ - spec/mocks/requests/DisputeService/defend_dispute.json
170
+ - spec/mocks/requests/DisputeService/delete_dispute_defense_document.json
171
+ - spec/mocks/requests/DisputeService/retrieve_applicable_defense_reasons.json
172
+ - spec/mocks/requests/DisputeService/supply_defense_document.json
158
173
  - spec/mocks/requests/Fund/account_holder_balance.json
159
174
  - spec/mocks/requests/Fund/account_holder_transaction_list.json
160
175
  - spec/mocks/requests/Fund/payout_account_holder.json
176
+ - spec/mocks/requests/Fund/refund_funds_transfer.json
161
177
  - spec/mocks/requests/Fund/refund_not_paid_out_transfers.json
162
178
  - spec/mocks/requests/Fund/setup_beneficiary.json
163
179
  - spec/mocks/requests/Fund/transfer_funds.json
@@ -176,24 +192,33 @@ files:
176
192
  - spec/mocks/requests/Payment/cancel_or_refund.json
177
193
  - spec/mocks/requests/Payment/capture.json
178
194
  - spec/mocks/requests/Payment/donate.json
195
+ - spec/mocks/requests/Payment/get_authentication_result.json
179
196
  - spec/mocks/requests/Payment/refund.json
197
+ - spec/mocks/requests/Payment/retrieve_3ds2_result.json
198
+ - spec/mocks/requests/Payment/technical_cancel.json
199
+ - spec/mocks/requests/Payment/void_pending_refund.json
180
200
  - spec/mocks/requests/Payout/confirm_third_party.json
181
201
  - spec/mocks/requests/Payout/decline_third_party.json
202
+ - spec/mocks/requests/Payout/payout.json
182
203
  - spec/mocks/requests/Payout/store_detail.json
183
204
  - spec/mocks/requests/Payout/store_detail_and_submit_third_party.json
184
205
  - spec/mocks/requests/Payout/submit_third_party.json
185
206
  - spec/mocks/requests/Recurring/disable.json
186
207
  - spec/mocks/requests/Recurring/list_recurring_details.json
208
+ - spec/mocks/requests/Recurring/schedule_account_updater.json
187
209
  - spec/mocks/requests/Recurring/store_token.json
188
210
  - spec/mocks/requests/Terminal/assign_terminals.json
189
211
  - spec/mocks/requests/Terminal/find_terminal.json
190
212
  - spec/mocks/requests/Terminal/get_terminals_under_account.json
213
+ - spec/mocks/responses/Account/check_account_holder.json
191
214
  - spec/mocks/responses/Account/close_account.json
192
215
  - spec/mocks/responses/Account/close_account_holder.json
193
216
  - spec/mocks/responses/Account/create_account.json
194
217
  - spec/mocks/responses/Account/create_account_holder.json
195
218
  - spec/mocks/responses/Account/delete_bank_accounts.json
219
+ - spec/mocks/responses/Account/delete_payout_methods.json
196
220
  - spec/mocks/responses/Account/delete_shareholders.json
221
+ - spec/mocks/responses/Account/delete_signatories.json
197
222
  - spec/mocks/responses/Account/get_account_holder.json
198
223
  - spec/mocks/responses/Account/get_uploaded_documents.json
199
224
  - spec/mocks/responses/Account/suspend_account_holder.json
@@ -202,18 +227,31 @@ files:
202
227
  - spec/mocks/responses/Account/update_account_holder.json
203
228
  - spec/mocks/responses/Account/update_account_holder_state.json
204
229
  - spec/mocks/responses/Account/upload_document.json
230
+ - spec/mocks/responses/BinLookup/get_3ds_availability.json
231
+ - spec/mocks/responses/BinLookup/get_cost_estimate.json
232
+ - spec/mocks/responses/Checkout/get-payment-link.json
233
+ - spec/mocks/responses/Checkout/orders.json
234
+ - spec/mocks/responses/Checkout/orders_cancel.json
235
+ - spec/mocks/responses/Checkout/origin_keys.json
205
236
  - spec/mocks/responses/Checkout/payment-details.json
206
237
  - spec/mocks/responses/Checkout/payment-result.json
207
238
  - spec/mocks/responses/Checkout/payment_links.json
208
239
  - spec/mocks/responses/Checkout/payment_methods.json
240
+ - spec/mocks/responses/Checkout/payment_methods_balance.json
209
241
  - spec/mocks/responses/Checkout/payment_session.json
210
242
  - spec/mocks/responses/Checkout/payments.json
243
+ - spec/mocks/responses/Checkout/sessions-success.json
244
+ - spec/mocks/responses/Checkout/update-payment-link.json
211
245
  - spec/mocks/responses/Checkout/verify.json
212
- - spec/mocks/responses/CheckoutUtility/origin_keys.json
213
246
  - spec/mocks/responses/DataProtectionService/request_subject_erasure.json
247
+ - spec/mocks/responses/DisputeService/defend_dispute.json
248
+ - spec/mocks/responses/DisputeService/delete_dispute_defense_document.json
249
+ - spec/mocks/responses/DisputeService/retrieve_applicable_defense_reasons.json
250
+ - spec/mocks/responses/DisputeService/supply_defense_document.json
214
251
  - spec/mocks/responses/Fund/account_holder_balance.json
215
252
  - spec/mocks/responses/Fund/account_holder_transaction_list.json
216
253
  - spec/mocks/responses/Fund/payout_account_holder.json
254
+ - spec/mocks/responses/Fund/refund_funds_transfer.json
217
255
  - spec/mocks/responses/Fund/refund_not_paid_out_transfers.json
218
256
  - spec/mocks/responses/Fund/setup_beneficiary.json
219
257
  - spec/mocks/responses/Fund/transfer_funds.json
@@ -232,14 +270,20 @@ files:
232
270
  - spec/mocks/responses/Payment/cancel_or_refund.json
233
271
  - spec/mocks/responses/Payment/capture.json
234
272
  - spec/mocks/responses/Payment/donate.json
273
+ - spec/mocks/responses/Payment/get_authentication_result.json
235
274
  - spec/mocks/responses/Payment/refund.json
275
+ - spec/mocks/responses/Payment/retrieve_3ds2_result.json
276
+ - spec/mocks/responses/Payment/technical_cancel.json
277
+ - spec/mocks/responses/Payment/void_pending_refund.json
236
278
  - spec/mocks/responses/Payout/confirm_third_party.json
237
279
  - spec/mocks/responses/Payout/decline_third_party.json
280
+ - spec/mocks/responses/Payout/payout.json
238
281
  - spec/mocks/responses/Payout/store_detail.json
239
282
  - spec/mocks/responses/Payout/store_detail_and_submit_third_party.json
240
283
  - spec/mocks/responses/Payout/submit_third_party.json
241
284
  - spec/mocks/responses/Recurring/disable.json
242
285
  - spec/mocks/responses/Recurring/list_recurring_details.json
286
+ - spec/mocks/responses/Recurring/schedule_account_updater.json
243
287
  - spec/mocks/responses/Recurring/store_token.json
244
288
  - spec/mocks/responses/Terminal/assign_terminals.json
245
289
  - spec/mocks/responses/Terminal/find_terminal.json
@@ -274,7 +318,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
274
318
  - !ruby/object:Gem::Version
275
319
  version: '0'
276
320
  requirements: []
277
- rubygems_version: 3.1.2
321
+ rubygems_version: 3.2.3
278
322
  signing_key:
279
323
  specification_version: 4
280
324
  summary: Official Adyen Ruby API Library
data/.travis.yml DELETED
@@ -1,14 +0,0 @@
1
- sudo: false
2
- language: ruby
3
-
4
- rvm:
5
- - 2.5
6
- - 2.4
7
- - 2.3
8
- - 2.2
9
- - 2.1
10
-
11
- notifications:
12
- email: false
13
-
14
- script: bundle exec rspec
@@ -1,29 +0,0 @@
1
- require "spec_helper"
2
- require "json"
3
-
4
- # rubocop:disable Metrics/BlockLength
5
-
6
- RSpec.describe Adyen::CheckoutUtility, service: "checkout utility" do
7
- before(:all) do
8
- @shared_values = {
9
- client: create_client(:api_key),
10
- service: "CheckoutUtility",
11
- }
12
- end
13
-
14
- it "sets the correct service URL base" do
15
- client = Adyen::Client.new(env: :test)
16
- expect(client.service_url_base(@shared_values[:service])).to eq("https://checkout-test.adyen.com/checkout")
17
- end
18
-
19
- # must be created manually because every field in the response is an array
20
- it "makes an origin_keys call" do
21
- parsed_body = create_test(@shared_values[:client], @shared_values[:service], "origin_keys", @shared_values[:client].checkout_utility)
22
- expect(parsed_body["originKeys"]).
23
- to be_a Adyen::HashWithAccessors
24
- expect(parsed_body["originKeys"]).
25
- to be_a_kind_of Hash
26
- end
27
- end
28
-
29
- # rubocop:enable Metrics/BlockLength
@@ -1,7 +0,0 @@
1
- {
2
- "originDomains": [
3
- "https://www.your-domain1.com",
4
- "https://www.your-domain2.com",
5
- "https://www.your-domain3.com"
6
- ]
7
- }
@@ -1,7 +0,0 @@
1
- {
2
- "originKeys": {
3
- "https://www.your-domain1.com": "pub.v2.7814286629520534.aHR0cHM6Ly93d3cueW91ci1kb21haW4xLmNvbQ.UEwIBmW9-c_uXo5wSEr2w8Hz8hVIpujXPHjpcEse3xI",
4
- "https://www.your-domain3.com": "pub.v2.7814286629520534.aHR0cHM6Ly93d3cueW91ci1kb21haW4zLmNvbQ.fUvflu-YIdZSsLEH8Qqmr7ksE4ag_NYiiMXK0s6aq_4",
5
- "https://www.your-domain2.com": "pub.v2.7814286629520534.aHR0cHM6Ly93d3cueW91ci1kb21haW4yLmNvbQ.EP6eXBJKk0t7-QIUl6e_b1qMuMHGepxG_SlUqxAYrfY"
6
- }
7
- }