univapay-apimatic-sdk 0.0.3 → 0.0.4
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/README.md +48 -48
- data/lib/univapay_client_sdk/{controllers/base_controller.rb → apis/base_api.rb} +3 -3
- data/lib/univapay_client_sdk/{controllers/cancels_controller.rb → apis/cancels_api.rb} +2 -2
- data/lib/univapay_client_sdk/{controllers/charges_controller.rb → apis/charges_api.rb} +2 -2
- data/lib/univapay_client_sdk/{controllers/merchants_controller.rb → apis/merchants_api.rb} +2 -2
- data/lib/univapay_client_sdk/{controllers/refunds_controller.rb → apis/refunds_api.rb} +2 -2
- data/lib/univapay_client_sdk/{controllers/stores_controller.rb → apis/stores_api.rb} +2 -2
- data/lib/univapay_client_sdk/{controllers/subscriptions_controller.rb → apis/subscriptions_api.rb} +2 -2
- data/lib/univapay_client_sdk/{controllers/transaction_tokens_controller.rb → apis/transaction_tokens_api.rb} +2 -2
- data/lib/univapay_client_sdk/{controllers/webhooks_controller.rb → apis/webhooks_api.rb} +2 -2
- data/lib/univapay_client_sdk/client.rb +19 -19
- data/lib/univapay_client_sdk.rb +9 -9
- data/test/{controllers/controller_test_base.rb → apis/api_test_base.rb} +1 -1
- data/test/{controllers/test_cancels_controller.rb → apis/test_cancels_api.rb} +2 -2
- data/test/{controllers/test_charges_controller.rb → apis/test_charges_api.rb} +2 -2
- data/test/{controllers/test_merchants_controller.rb → apis/test_merchants_api.rb} +2 -2
- data/test/{controllers/test_refunds_controller.rb → apis/test_refunds_api.rb} +2 -2
- data/test/{controllers/test_stores_controller.rb → apis/test_stores_api.rb} +2 -2
- data/test/{controllers/test_subscriptions_controller.rb → apis/test_subscriptions_api.rb} +2 -2
- data/test/{controllers/test_transaction_tokens_controller.rb → apis/test_transaction_tokens_api.rb} +2 -2
- data/test/{controllers/test_webhooks_controller.rb → apis/test_webhooks_api.rb} +2 -2
- metadata +19 -19
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 8dff7e69f1e12f970292c1194aa2e9772e79a1077531bdcd3cdc7da549b2b38f
|
|
4
|
+
data.tar.gz: 778166110fb85b9b967297875e69461fa8f81fc1f5f26caeb7b0ade2c47db3a0
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 33b2e5b8e832a065d59ed38db76c157b38731fd51a2d1811a93968c3dc5ed0f515ef17ea993b6d2c06cade89cf4d4be64bdd8f840289024dfbb2258d10670457
|
|
7
|
+
data.tar.gz: fe7b183e072126bdca270349426bb99e1215074b95940d249c2dc04b7d9147d971ccb7ad49b5cf1605e246f38d9b2ceb511cd6c41ec146160153a5c6a0d4503f
|
data/README.md
CHANGED
|
@@ -36,16 +36,16 @@ We will assume that all requests are going to originate from a backend server th
|
|
|
36
36
|
Install the gem from the command line:
|
|
37
37
|
|
|
38
38
|
```bash
|
|
39
|
-
gem install univapay-apimatic-sdk -v 0.0.
|
|
39
|
+
gem install univapay-apimatic-sdk -v 0.0.4
|
|
40
40
|
```
|
|
41
41
|
|
|
42
42
|
Or add the gem to your Gemfile and run `bundle`:
|
|
43
43
|
|
|
44
44
|
```ruby
|
|
45
|
-
gem 'univapay-apimatic-sdk', '0.0.
|
|
45
|
+
gem 'univapay-apimatic-sdk', '0.0.4'
|
|
46
46
|
```
|
|
47
47
|
|
|
48
|
-
For additional gem details, see the [RubyGems page for the univapay-apimatic-sdk gem](https://rubygems.org/gems/univapay-apimatic-sdk/versions/0.0.
|
|
48
|
+
For additional gem details, see the [RubyGems page for the univapay-apimatic-sdk gem](https://rubygems.org/gems/univapay-apimatic-sdk/versions/0.0.4).
|
|
49
49
|
|
|
50
50
|
## IRB Console Usage
|
|
51
51
|
|
|
@@ -92,14 +92,14 @@ rake
|
|
|
92
92
|
|
|
93
93
|
## Initialize the API Client
|
|
94
94
|
|
|
95
|
-
**_Note:_** Documentation for the client can be found [here.](https://www.github.com/sdks-io/univapay-apimatic-ruby-sdk/tree/0.0.
|
|
95
|
+
**_Note:_** Documentation for the client can be found [here.](https://www.github.com/sdks-io/univapay-apimatic-ruby-sdk/tree/0.0.4/doc/client.md)
|
|
96
96
|
|
|
97
97
|
The following parameters are configurable for the API Client:
|
|
98
98
|
|
|
99
99
|
| Parameter | Type | Description |
|
|
100
100
|
| --- | --- | --- |
|
|
101
101
|
| base_url | `String` | Base URL for the API<br>*Default*: `'https://api.univapay.com'` |
|
|
102
|
-
| environment | [`Environment`](https://www.github.com/sdks-io/univapay-apimatic-ruby-sdk/tree/0.0.
|
|
102
|
+
| environment | [`Environment`](https://www.github.com/sdks-io/univapay-apimatic-ruby-sdk/tree/0.0.4/README.md#environments) | The API environment. <br> **Default: `Environment.PRODUCTION`** |
|
|
103
103
|
| connection | `Faraday::Connection` | The Faraday connection object passed by the SDK user for making requests |
|
|
104
104
|
| adapter | `Faraday::Adapter` | The Faraday adapter object passed by the SDK user for performing http requests |
|
|
105
105
|
| timeout | `Float` | The value to use for connection timeout. <br> **Default: 30** |
|
|
@@ -109,9 +109,9 @@ The following parameters are configurable for the API Client:
|
|
|
109
109
|
| retry_statuses | `Array` | A list of HTTP statuses to retry. <br> **Default: [408, 413, 429, 500, 502, 503, 504, 521, 522, 524]** |
|
|
110
110
|
| retry_methods | `Array` | A list of HTTP methods to retry. <br> **Default: %i[get put]** |
|
|
111
111
|
| http_callback | `HttpCallBack` | The Http CallBack allows defining callables for pre and post API calls. |
|
|
112
|
-
| proxy_settings | [`ProxySettings`](https://www.github.com/sdks-io/univapay-apimatic-ruby-sdk/tree/0.0.
|
|
113
|
-
| logging_configuration | [`LoggingConfiguration`](https://www.github.com/sdks-io/univapay-apimatic-ruby-sdk/tree/0.0.
|
|
114
|
-
| bearer_auth_credentials | [`BearerAuthCredentials`](https://www.github.com/sdks-io/univapay-apimatic-ruby-sdk/tree/0.0.
|
|
112
|
+
| proxy_settings | [`ProxySettings`](https://www.github.com/sdks-io/univapay-apimatic-ruby-sdk/tree/0.0.4/doc/proxy-settings.md) | Optional proxy configuration to route HTTP requests through a proxy server. |
|
|
113
|
+
| logging_configuration | [`LoggingConfiguration`](https://www.github.com/sdks-io/univapay-apimatic-ruby-sdk/tree/0.0.4/doc/logging-configuration.md) | The SDK logging configuration for API calls |
|
|
114
|
+
| bearer_auth_credentials | [`BearerAuthCredentials`](https://www.github.com/sdks-io/univapay-apimatic-ruby-sdk/tree/0.0.4/doc/auth/oauth-2-bearer-token.md) | The credential object for OAuth 2 Bearer token |
|
|
115
115
|
|
|
116
116
|
The API client can be initialized as follows:
|
|
117
117
|
|
|
@@ -149,7 +149,7 @@ include UnivapayClientSdk
|
|
|
149
149
|
client = Client.from_env
|
|
150
150
|
```
|
|
151
151
|
|
|
152
|
-
See the [`Environment-Based Client Initialization`](https://www.github.com/sdks-io/univapay-apimatic-ruby-sdk/tree/0.0.
|
|
152
|
+
See the [`Environment-Based Client Initialization`](https://www.github.com/sdks-io/univapay-apimatic-ruby-sdk/tree/0.0.4/doc/environment-based-client-initialization.md) section for details.
|
|
153
153
|
|
|
154
154
|
## Environments
|
|
155
155
|
|
|
@@ -165,60 +165,60 @@ The SDK can be configured to use a different environment for making API calls. A
|
|
|
165
165
|
|
|
166
166
|
This API uses the following authentication schemes.
|
|
167
167
|
|
|
168
|
-
* [`JWT_TOKEN (OAuth 2 Bearer token)`](https://www.github.com/sdks-io/univapay-apimatic-ruby-sdk/tree/0.0.
|
|
168
|
+
* [`JWT_TOKEN (OAuth 2 Bearer token)`](https://www.github.com/sdks-io/univapay-apimatic-ruby-sdk/tree/0.0.4/doc/auth/oauth-2-bearer-token.md)
|
|
169
169
|
|
|
170
170
|
## List of APIs
|
|
171
171
|
|
|
172
|
-
* [Transaction Tokens](https://www.github.com/sdks-io/univapay-apimatic-ruby-sdk/tree/0.0.
|
|
173
|
-
* [Charges](https://www.github.com/sdks-io/univapay-apimatic-ruby-sdk/tree/0.0.
|
|
174
|
-
* [Refunds](https://www.github.com/sdks-io/univapay-apimatic-ruby-sdk/tree/0.0.
|
|
175
|
-
* [Subscriptions](https://www.github.com/sdks-io/univapay-apimatic-ruby-sdk/tree/0.0.
|
|
176
|
-
* [Cancels](https://www.github.com/sdks-io/univapay-apimatic-ruby-sdk/tree/0.0.
|
|
177
|
-
* [Merchants](https://www.github.com/sdks-io/univapay-apimatic-ruby-sdk/tree/0.0.
|
|
178
|
-
* [Stores](https://www.github.com/sdks-io/univapay-apimatic-ruby-sdk/tree/0.0.
|
|
179
|
-
* [Webhooks](https://www.github.com/sdks-io/univapay-apimatic-ruby-sdk/tree/0.0.
|
|
172
|
+
* [Transaction Tokens](https://www.github.com/sdks-io/univapay-apimatic-ruby-sdk/tree/0.0.4/doc/controllers/transaction-tokens.md)
|
|
173
|
+
* [Charges](https://www.github.com/sdks-io/univapay-apimatic-ruby-sdk/tree/0.0.4/doc/controllers/charges.md)
|
|
174
|
+
* [Refunds](https://www.github.com/sdks-io/univapay-apimatic-ruby-sdk/tree/0.0.4/doc/controllers/refunds.md)
|
|
175
|
+
* [Subscriptions](https://www.github.com/sdks-io/univapay-apimatic-ruby-sdk/tree/0.0.4/doc/controllers/subscriptions.md)
|
|
176
|
+
* [Cancels](https://www.github.com/sdks-io/univapay-apimatic-ruby-sdk/tree/0.0.4/doc/controllers/cancels.md)
|
|
177
|
+
* [Merchants](https://www.github.com/sdks-io/univapay-apimatic-ruby-sdk/tree/0.0.4/doc/controllers/merchants.md)
|
|
178
|
+
* [Stores](https://www.github.com/sdks-io/univapay-apimatic-ruby-sdk/tree/0.0.4/doc/controllers/stores.md)
|
|
179
|
+
* [Webhooks](https://www.github.com/sdks-io/univapay-apimatic-ruby-sdk/tree/0.0.4/doc/controllers/webhooks.md)
|
|
180
180
|
|
|
181
181
|
## Webhooks
|
|
182
182
|
|
|
183
|
-
* [Charge Updated](https://www.github.com/sdks-io/univapay-apimatic-ruby-sdk/tree/0.0.
|
|
184
|
-
* [Charge Finished](https://www.github.com/sdks-io/univapay-apimatic-ruby-sdk/tree/0.0.
|
|
185
|
-
* [Token Created](https://www.github.com/sdks-io/univapay-apimatic-ruby-sdk/tree/0.0.
|
|
186
|
-
* [Token Updated](https://www.github.com/sdks-io/univapay-apimatic-ruby-sdk/tree/0.0.
|
|
187
|
-
* [Token Three Ds Updated](https://www.github.com/sdks-io/univapay-apimatic-ruby-sdk/tree/0.0.
|
|
188
|
-
* [Token Cvv Auth Updated](https://www.github.com/sdks-io/univapay-apimatic-ruby-sdk/tree/0.0.
|
|
189
|
-
* [Token Cvv Auth Check Updated](https://www.github.com/sdks-io/univapay-apimatic-ruby-sdk/tree/0.0.
|
|
190
|
-
* [Token Replaced](https://www.github.com/sdks-io/univapay-apimatic-ruby-sdk/tree/0.0.
|
|
191
|
-
* [Recurring Token Deleted](https://www.github.com/sdks-io/univapay-apimatic-ruby-sdk/tree/0.0.
|
|
192
|
-
* [Refund](https://www.github.com/sdks-io/univapay-apimatic-ruby-sdk/tree/0.0.
|
|
193
|
-
* [Cancel](https://www.github.com/sdks-io/univapay-apimatic-ruby-sdk/tree/0.0.
|
|
194
|
-
* [Subscription Created](https://www.github.com/sdks-io/univapay-apimatic-ruby-sdk/tree/0.0.
|
|
195
|
-
* [Subscription Payment](https://www.github.com/sdks-io/univapay-apimatic-ruby-sdk/tree/0.0.
|
|
196
|
-
* [Subscription Completed](https://www.github.com/sdks-io/univapay-apimatic-ruby-sdk/tree/0.0.
|
|
197
|
-
* [Subscription Failure](https://www.github.com/sdks-io/univapay-apimatic-ruby-sdk/tree/0.0.
|
|
198
|
-
* [Subscription Canceled](https://www.github.com/sdks-io/univapay-apimatic-ruby-sdk/tree/0.0.
|
|
199
|
-
* [Subscription Suspended](https://www.github.com/sdks-io/univapay-apimatic-ruby-sdk/tree/0.0.
|
|
200
|
-
* [Bank-Transfer](https://www.github.com/sdks-io/univapay-apimatic-ruby-sdk/tree/0.0.
|
|
201
|
-
* [Customs](https://www.github.com/sdks-io/univapay-apimatic-ruby-sdk/tree/0.0.
|
|
183
|
+
* [Charge Updated](https://www.github.com/sdks-io/univapay-apimatic-ruby-sdk/tree/0.0.4/doc/events/webhooks/charge-updated-handler.md)
|
|
184
|
+
* [Charge Finished](https://www.github.com/sdks-io/univapay-apimatic-ruby-sdk/tree/0.0.4/doc/events/webhooks/charge-finished-handler.md)
|
|
185
|
+
* [Token Created](https://www.github.com/sdks-io/univapay-apimatic-ruby-sdk/tree/0.0.4/doc/events/webhooks/token-created-handler.md)
|
|
186
|
+
* [Token Updated](https://www.github.com/sdks-io/univapay-apimatic-ruby-sdk/tree/0.0.4/doc/events/webhooks/token-updated-handler.md)
|
|
187
|
+
* [Token Three Ds Updated](https://www.github.com/sdks-io/univapay-apimatic-ruby-sdk/tree/0.0.4/doc/events/webhooks/token-three-ds-updated-handler.md)
|
|
188
|
+
* [Token Cvv Auth Updated](https://www.github.com/sdks-io/univapay-apimatic-ruby-sdk/tree/0.0.4/doc/events/webhooks/token-cvv-auth-updated-handler.md)
|
|
189
|
+
* [Token Cvv Auth Check Updated](https://www.github.com/sdks-io/univapay-apimatic-ruby-sdk/tree/0.0.4/doc/events/webhooks/token-cvv-auth-check-updated-handler.md)
|
|
190
|
+
* [Token Replaced](https://www.github.com/sdks-io/univapay-apimatic-ruby-sdk/tree/0.0.4/doc/events/webhooks/token-replaced-handler.md)
|
|
191
|
+
* [Recurring Token Deleted](https://www.github.com/sdks-io/univapay-apimatic-ruby-sdk/tree/0.0.4/doc/events/webhooks/recurring-token-deleted-handler.md)
|
|
192
|
+
* [Refund](https://www.github.com/sdks-io/univapay-apimatic-ruby-sdk/tree/0.0.4/doc/events/webhooks/refund-handler.md)
|
|
193
|
+
* [Cancel](https://www.github.com/sdks-io/univapay-apimatic-ruby-sdk/tree/0.0.4/doc/events/webhooks/cancel-handler.md)
|
|
194
|
+
* [Subscription Created](https://www.github.com/sdks-io/univapay-apimatic-ruby-sdk/tree/0.0.4/doc/events/webhooks/subscription-created-handler.md)
|
|
195
|
+
* [Subscription Payment](https://www.github.com/sdks-io/univapay-apimatic-ruby-sdk/tree/0.0.4/doc/events/webhooks/subscription-payment-handler.md)
|
|
196
|
+
* [Subscription Completed](https://www.github.com/sdks-io/univapay-apimatic-ruby-sdk/tree/0.0.4/doc/events/webhooks/subscription-completed-handler.md)
|
|
197
|
+
* [Subscription Failure](https://www.github.com/sdks-io/univapay-apimatic-ruby-sdk/tree/0.0.4/doc/events/webhooks/subscription-failure-handler.md)
|
|
198
|
+
* [Subscription Canceled](https://www.github.com/sdks-io/univapay-apimatic-ruby-sdk/tree/0.0.4/doc/events/webhooks/subscription-canceled-handler.md)
|
|
199
|
+
* [Subscription Suspended](https://www.github.com/sdks-io/univapay-apimatic-ruby-sdk/tree/0.0.4/doc/events/webhooks/subscription-suspended-handler.md)
|
|
200
|
+
* [Bank-Transfer](https://www.github.com/sdks-io/univapay-apimatic-ruby-sdk/tree/0.0.4/doc/events/webhooks/bank-transfer-handler.md)
|
|
201
|
+
* [Customs](https://www.github.com/sdks-io/univapay-apimatic-ruby-sdk/tree/0.0.4/doc/events/webhooks/customs-handler.md)
|
|
202
202
|
|
|
203
203
|
## SDK Infrastructure
|
|
204
204
|
|
|
205
205
|
### Configuration
|
|
206
206
|
|
|
207
|
-
* [ProxySettings](https://www.github.com/sdks-io/univapay-apimatic-ruby-sdk/tree/0.0.
|
|
208
|
-
* [Environment-Based Client Initialization](https://www.github.com/sdks-io/univapay-apimatic-ruby-sdk/tree/0.0.
|
|
209
|
-
* [AbstractLogger](https://www.github.com/sdks-io/univapay-apimatic-ruby-sdk/tree/0.0.
|
|
210
|
-
* [LoggingConfiguration](https://www.github.com/sdks-io/univapay-apimatic-ruby-sdk/tree/0.0.
|
|
211
|
-
* [RequestLoggingConfiguration](https://www.github.com/sdks-io/univapay-apimatic-ruby-sdk/tree/0.0.
|
|
212
|
-
* [ResponseLoggingConfiguration](https://www.github.com/sdks-io/univapay-apimatic-ruby-sdk/tree/0.0.
|
|
207
|
+
* [ProxySettings](https://www.github.com/sdks-io/univapay-apimatic-ruby-sdk/tree/0.0.4/doc/proxy-settings.md)
|
|
208
|
+
* [Environment-Based Client Initialization](https://www.github.com/sdks-io/univapay-apimatic-ruby-sdk/tree/0.0.4/doc/environment-based-client-initialization.md)
|
|
209
|
+
* [AbstractLogger](https://www.github.com/sdks-io/univapay-apimatic-ruby-sdk/tree/0.0.4/doc/abstract-logger.md)
|
|
210
|
+
* [LoggingConfiguration](https://www.github.com/sdks-io/univapay-apimatic-ruby-sdk/tree/0.0.4/doc/logging-configuration.md)
|
|
211
|
+
* [RequestLoggingConfiguration](https://www.github.com/sdks-io/univapay-apimatic-ruby-sdk/tree/0.0.4/doc/request-logging-configuration.md)
|
|
212
|
+
* [ResponseLoggingConfiguration](https://www.github.com/sdks-io/univapay-apimatic-ruby-sdk/tree/0.0.4/doc/response-logging-configuration.md)
|
|
213
213
|
|
|
214
214
|
### HTTP
|
|
215
215
|
|
|
216
|
-
* [HttpResponse](https://www.github.com/sdks-io/univapay-apimatic-ruby-sdk/tree/0.0.
|
|
217
|
-
* [HttpRequest](https://www.github.com/sdks-io/univapay-apimatic-ruby-sdk/tree/0.0.
|
|
216
|
+
* [HttpResponse](https://www.github.com/sdks-io/univapay-apimatic-ruby-sdk/tree/0.0.4/doc/http-response.md)
|
|
217
|
+
* [HttpRequest](https://www.github.com/sdks-io/univapay-apimatic-ruby-sdk/tree/0.0.4/doc/http-request.md)
|
|
218
218
|
|
|
219
219
|
### Utilities
|
|
220
220
|
|
|
221
|
-
* [ApiResponse](https://www.github.com/sdks-io/univapay-apimatic-ruby-sdk/tree/0.0.
|
|
222
|
-
* [ApiHelper](https://www.github.com/sdks-io/univapay-apimatic-ruby-sdk/tree/0.0.
|
|
223
|
-
* [DateTimeHelper](https://www.github.com/sdks-io/univapay-apimatic-ruby-sdk/tree/0.0.
|
|
221
|
+
* [ApiResponse](https://www.github.com/sdks-io/univapay-apimatic-ruby-sdk/tree/0.0.4/doc/api-response.md)
|
|
222
|
+
* [ApiHelper](https://www.github.com/sdks-io/univapay-apimatic-ruby-sdk/tree/0.0.4/doc/api-helper.md)
|
|
223
|
+
* [DateTimeHelper](https://www.github.com/sdks-io/univapay-apimatic-ruby-sdk/tree/0.0.4/doc/date-time-helper.md)
|
|
224
224
|
|
|
@@ -4,13 +4,13 @@
|
|
|
4
4
|
# by APIMATIC v3.0 ( https://www.apimatic.io ).
|
|
5
5
|
|
|
6
6
|
module UnivapayClientSdk
|
|
7
|
-
#
|
|
8
|
-
class
|
|
7
|
+
# BaseApi.
|
|
8
|
+
class BaseApi
|
|
9
9
|
include CoreLibrary
|
|
10
10
|
attr_accessor :config, :http_call_back
|
|
11
11
|
|
|
12
12
|
def self.user_agent
|
|
13
|
-
'Ruby-SDK/0.0.
|
|
13
|
+
'Ruby-SDK/0.0.4 (OS: {os-info}, Engine: {engine}/{engine-version})'
|
|
14
14
|
end
|
|
15
15
|
|
|
16
16
|
def self.user_agent_parameters
|
|
@@ -4,8 +4,8 @@
|
|
|
4
4
|
# by APIMATIC v3.0 ( https://www.apimatic.io ).
|
|
5
5
|
|
|
6
6
|
module UnivapayClientSdk
|
|
7
|
-
#
|
|
8
|
-
class
|
|
7
|
+
# CancelsApi
|
|
8
|
+
class CancelsApi < BaseApi
|
|
9
9
|
# Returns a paginated list of cancels for the specified charge.
|
|
10
10
|
# @param [UUID | String] store_id Required parameter: The unique identifier
|
|
11
11
|
# of the store.
|
|
@@ -4,8 +4,8 @@
|
|
|
4
4
|
# by APIMATIC v3.0 ( https://www.apimatic.io ).
|
|
5
5
|
|
|
6
6
|
module UnivapayClientSdk
|
|
7
|
-
#
|
|
8
|
-
class
|
|
7
|
+
# ChargesApi
|
|
8
|
+
class ChargesApi < BaseApi
|
|
9
9
|
# Creates a charge on a payment instrument (e.g. transaction token).
|
|
10
10
|
# @param [String] idempotency_key Optional parameter: An optional
|
|
11
11
|
# idempotency key to prevent double charges and duplicate operations. We
|
|
@@ -4,8 +4,8 @@
|
|
|
4
4
|
# by APIMATIC v3.0 ( https://www.apimatic.io ).
|
|
5
5
|
|
|
6
6
|
module UnivapayClientSdk
|
|
7
|
-
#
|
|
8
|
-
class
|
|
7
|
+
# MerchantsApi
|
|
8
|
+
class MerchantsApi < BaseApi
|
|
9
9
|
# Returns merchant identity and the effective configuration resolved from
|
|
10
10
|
# bearer credentials. Treat this as the canonical introspection endpoint for
|
|
11
11
|
# merchant integrations.
|
|
@@ -4,8 +4,8 @@
|
|
|
4
4
|
# by APIMATIC v3.0 ( https://www.apimatic.io ).
|
|
5
5
|
|
|
6
6
|
module UnivapayClientSdk
|
|
7
|
-
#
|
|
8
|
-
class
|
|
7
|
+
# RefundsApi
|
|
8
|
+
class RefundsApi < BaseApi
|
|
9
9
|
# Retrieves a list of all refunds for a specific charge.
|
|
10
10
|
# @param [UUID | String] store_id Required parameter: The unique identifier
|
|
11
11
|
# of the store.
|
|
@@ -4,8 +4,8 @@
|
|
|
4
4
|
# by APIMATIC v3.0 ( https://www.apimatic.io ).
|
|
5
5
|
|
|
6
6
|
module UnivapayClientSdk
|
|
7
|
-
#
|
|
8
|
-
class
|
|
7
|
+
# StoresApi
|
|
8
|
+
class StoresApi < BaseApi
|
|
9
9
|
# Returns stores visible to the current merchant credential. Supports cursor
|
|
10
10
|
# pagination plus `short_id` and free-text `search` filters.
|
|
11
11
|
# @param [Integer] limit Optional parameter: Maximum number of resources to
|
data/lib/univapay_client_sdk/{controllers/subscriptions_controller.rb → apis/subscriptions_api.rb}
RENAMED
|
@@ -4,8 +4,8 @@
|
|
|
4
4
|
# by APIMATIC v3.0 ( https://www.apimatic.io ).
|
|
5
5
|
|
|
6
6
|
module UnivapayClientSdk
|
|
7
|
-
#
|
|
8
|
-
class
|
|
7
|
+
# SubscriptionsApi
|
|
8
|
+
class SubscriptionsApi < BaseApi
|
|
9
9
|
# Creates a new subscription.
|
|
10
10
|
# @param [String] idempotency_key Optional parameter: An optional
|
|
11
11
|
# idempotency key to prevent double charges and duplicate operations. We
|
|
@@ -4,8 +4,8 @@
|
|
|
4
4
|
# by APIMATIC v3.0 ( https://www.apimatic.io ).
|
|
5
5
|
|
|
6
6
|
module UnivapayClientSdk
|
|
7
|
-
#
|
|
8
|
-
class
|
|
7
|
+
# TransactionTokensApi
|
|
8
|
+
class TransactionTokensApi < BaseApi
|
|
9
9
|
# Exchange raw payment data for a secure token. **PCI DSS Compliance
|
|
10
10
|
# Required** if sending raw card numbers.
|
|
11
11
|
# @param [TransactionTokenCreateRequest] body Required parameter: Request
|
|
@@ -4,8 +4,8 @@
|
|
|
4
4
|
# by APIMATIC v3.0 ( https://www.apimatic.io ).
|
|
5
5
|
|
|
6
6
|
module UnivapayClientSdk
|
|
7
|
-
#
|
|
8
|
-
class
|
|
7
|
+
# WebhooksApi
|
|
8
|
+
class WebhooksApi < BaseApi
|
|
9
9
|
# Returns a paginated list of webhooks for the specified store. Requires a
|
|
10
10
|
# secret-bearing token.
|
|
11
11
|
# @param [UUID | String] store_id Required parameter: The unique identifier
|
|
@@ -14,51 +14,51 @@ module UnivapayClientSdk
|
|
|
14
14
|
end
|
|
15
15
|
|
|
16
16
|
# Access to charges controller.
|
|
17
|
-
# @return [
|
|
17
|
+
# @return [ChargesApi] Returns the controller instance.
|
|
18
18
|
def charges
|
|
19
|
-
@charges ||=
|
|
19
|
+
@charges ||= ChargesApi.new @global_configuration
|
|
20
20
|
end
|
|
21
21
|
|
|
22
22
|
# Access to transaction_tokens controller.
|
|
23
|
-
# @return [
|
|
23
|
+
# @return [TransactionTokensApi] Returns the controller instance.
|
|
24
24
|
def transaction_tokens
|
|
25
|
-
@transaction_tokens ||=
|
|
25
|
+
@transaction_tokens ||= TransactionTokensApi.new @global_configuration
|
|
26
26
|
end
|
|
27
27
|
|
|
28
28
|
# Access to refunds controller.
|
|
29
|
-
# @return [
|
|
29
|
+
# @return [RefundsApi] Returns the controller instance.
|
|
30
30
|
def refunds
|
|
31
|
-
@refunds ||=
|
|
31
|
+
@refunds ||= RefundsApi.new @global_configuration
|
|
32
32
|
end
|
|
33
33
|
|
|
34
34
|
# Access to subscriptions controller.
|
|
35
|
-
# @return [
|
|
35
|
+
# @return [SubscriptionsApi] Returns the controller instance.
|
|
36
36
|
def subscriptions
|
|
37
|
-
@subscriptions ||=
|
|
37
|
+
@subscriptions ||= SubscriptionsApi.new @global_configuration
|
|
38
38
|
end
|
|
39
39
|
|
|
40
40
|
# Access to cancels controller.
|
|
41
|
-
# @return [
|
|
41
|
+
# @return [CancelsApi] Returns the controller instance.
|
|
42
42
|
def cancels
|
|
43
|
-
@cancels ||=
|
|
43
|
+
@cancels ||= CancelsApi.new @global_configuration
|
|
44
44
|
end
|
|
45
45
|
|
|
46
46
|
# Access to merchants controller.
|
|
47
|
-
# @return [
|
|
47
|
+
# @return [MerchantsApi] Returns the controller instance.
|
|
48
48
|
def merchants
|
|
49
|
-
@merchants ||=
|
|
49
|
+
@merchants ||= MerchantsApi.new @global_configuration
|
|
50
50
|
end
|
|
51
51
|
|
|
52
52
|
# Access to stores controller.
|
|
53
|
-
# @return [
|
|
53
|
+
# @return [StoresApi] Returns the controller instance.
|
|
54
54
|
def stores
|
|
55
|
-
@stores ||=
|
|
55
|
+
@stores ||= StoresApi.new @global_configuration
|
|
56
56
|
end
|
|
57
57
|
|
|
58
58
|
# Access to webhooks controller.
|
|
59
|
-
# @return [
|
|
59
|
+
# @return [WebhooksApi] Returns the controller instance.
|
|
60
60
|
def webhooks
|
|
61
|
-
@webhooks ||=
|
|
61
|
+
@webhooks ||= WebhooksApi.new @global_configuration
|
|
62
62
|
end
|
|
63
63
|
|
|
64
64
|
def initialize(
|
|
@@ -85,12 +85,12 @@ module UnivapayClientSdk
|
|
|
85
85
|
else
|
|
86
86
|
config
|
|
87
87
|
end
|
|
88
|
-
user_agent_params =
|
|
88
|
+
user_agent_params = BaseApi.user_agent_parameters
|
|
89
89
|
|
|
90
90
|
@global_configuration = GlobalConfiguration.new(client_configuration: @config)
|
|
91
91
|
.base_uri_executor(@config.method(:get_base_uri))
|
|
92
|
-
.global_errors(
|
|
93
|
-
.user_agent(
|
|
92
|
+
.global_errors(BaseApi::GLOBAL_ERRORS)
|
|
93
|
+
.user_agent(BaseApi.user_agent,
|
|
94
94
|
agent_parameters: user_agent_params)
|
|
95
95
|
|
|
96
96
|
initialize_auth_managers(@global_configuration)
|
data/lib/univapay_client_sdk.rb
CHANGED
|
@@ -311,12 +311,12 @@ require_relative 'univapay_client_sdk/exceptions/api_error_exception'
|
|
|
311
311
|
require_relative 'univapay_client_sdk/configuration'
|
|
312
312
|
|
|
313
313
|
# Controllers
|
|
314
|
-
require_relative 'univapay_client_sdk/
|
|
315
|
-
require_relative 'univapay_client_sdk/
|
|
316
|
-
require_relative 'univapay_client_sdk/
|
|
317
|
-
require_relative 'univapay_client_sdk/
|
|
318
|
-
require_relative 'univapay_client_sdk/
|
|
319
|
-
require_relative 'univapay_client_sdk/
|
|
320
|
-
require_relative 'univapay_client_sdk/
|
|
321
|
-
require_relative 'univapay_client_sdk/
|
|
322
|
-
require_relative 'univapay_client_sdk/
|
|
314
|
+
require_relative 'univapay_client_sdk/apis/base_api'
|
|
315
|
+
require_relative 'univapay_client_sdk/apis/charges_api'
|
|
316
|
+
require_relative 'univapay_client_sdk/apis/transaction_tokens_api'
|
|
317
|
+
require_relative 'univapay_client_sdk/apis/refunds_api'
|
|
318
|
+
require_relative 'univapay_client_sdk/apis/subscriptions_api'
|
|
319
|
+
require_relative 'univapay_client_sdk/apis/cancels_api'
|
|
320
|
+
require_relative 'univapay_client_sdk/apis/merchants_api'
|
|
321
|
+
require_relative 'univapay_client_sdk/apis/stores_api'
|
|
322
|
+
require_relative 'univapay_client_sdk/apis/webhooks_api'
|
|
@@ -11,7 +11,7 @@ require 'minitest/proveit'
|
|
|
11
11
|
require 'univapay_client_sdk'
|
|
12
12
|
require_relative '../http_response_catcher'
|
|
13
13
|
|
|
14
|
-
class
|
|
14
|
+
class ApiTestBase < Minitest::Test
|
|
15
15
|
parallelize_me!
|
|
16
16
|
include UnivapayClientSdk
|
|
17
17
|
include CoreLibrary
|
|
@@ -3,9 +3,9 @@
|
|
|
3
3
|
# This file was automatically generated for Univapay
|
|
4
4
|
# by APIMATIC v3.0 ( https://www.apimatic.io ).
|
|
5
5
|
|
|
6
|
-
require_relative '
|
|
6
|
+
require_relative 'api_test_base'
|
|
7
7
|
|
|
8
|
-
class
|
|
8
|
+
class CancelsApiTest < ApiTestBase
|
|
9
9
|
# Called only once for the class before any test has executed
|
|
10
10
|
def setup
|
|
11
11
|
setup_class
|
|
@@ -3,9 +3,9 @@
|
|
|
3
3
|
# This file was automatically generated for Univapay
|
|
4
4
|
# by APIMATIC v3.0 ( https://www.apimatic.io ).
|
|
5
5
|
|
|
6
|
-
require_relative '
|
|
6
|
+
require_relative 'api_test_base'
|
|
7
7
|
|
|
8
|
-
class
|
|
8
|
+
class ChargesApiTest < ApiTestBase
|
|
9
9
|
# Called only once for the class before any test has executed
|
|
10
10
|
def setup
|
|
11
11
|
setup_class
|
|
@@ -3,9 +3,9 @@
|
|
|
3
3
|
# This file was automatically generated for Univapay
|
|
4
4
|
# by APIMATIC v3.0 ( https://www.apimatic.io ).
|
|
5
5
|
|
|
6
|
-
require_relative '
|
|
6
|
+
require_relative 'api_test_base'
|
|
7
7
|
|
|
8
|
-
class
|
|
8
|
+
class MerchantsApiTest < ApiTestBase
|
|
9
9
|
# Called only once for the class before any test has executed
|
|
10
10
|
def setup
|
|
11
11
|
setup_class
|
|
@@ -3,9 +3,9 @@
|
|
|
3
3
|
# This file was automatically generated for Univapay
|
|
4
4
|
# by APIMATIC v3.0 ( https://www.apimatic.io ).
|
|
5
5
|
|
|
6
|
-
require_relative '
|
|
6
|
+
require_relative 'api_test_base'
|
|
7
7
|
|
|
8
|
-
class
|
|
8
|
+
class RefundsApiTest < ApiTestBase
|
|
9
9
|
# Called only once for the class before any test has executed
|
|
10
10
|
def setup
|
|
11
11
|
setup_class
|
|
@@ -3,9 +3,9 @@
|
|
|
3
3
|
# This file was automatically generated for Univapay
|
|
4
4
|
# by APIMATIC v3.0 ( https://www.apimatic.io ).
|
|
5
5
|
|
|
6
|
-
require_relative '
|
|
6
|
+
require_relative 'api_test_base'
|
|
7
7
|
|
|
8
|
-
class
|
|
8
|
+
class StoresApiTest < ApiTestBase
|
|
9
9
|
# Called only once for the class before any test has executed
|
|
10
10
|
def setup
|
|
11
11
|
setup_class
|
|
@@ -3,9 +3,9 @@
|
|
|
3
3
|
# This file was automatically generated for Univapay
|
|
4
4
|
# by APIMATIC v3.0 ( https://www.apimatic.io ).
|
|
5
5
|
|
|
6
|
-
require_relative '
|
|
6
|
+
require_relative 'api_test_base'
|
|
7
7
|
|
|
8
|
-
class
|
|
8
|
+
class SubscriptionsApiTest < ApiTestBase
|
|
9
9
|
# Called only once for the class before any test has executed
|
|
10
10
|
def setup
|
|
11
11
|
setup_class
|
data/test/{controllers/test_transaction_tokens_controller.rb → apis/test_transaction_tokens_api.rb}
RENAMED
|
@@ -3,9 +3,9 @@
|
|
|
3
3
|
# This file was automatically generated for Univapay
|
|
4
4
|
# by APIMATIC v3.0 ( https://www.apimatic.io ).
|
|
5
5
|
|
|
6
|
-
require_relative '
|
|
6
|
+
require_relative 'api_test_base'
|
|
7
7
|
|
|
8
|
-
class
|
|
8
|
+
class TransactionTokensApiTest < ApiTestBase
|
|
9
9
|
# Called only once for the class before any test has executed
|
|
10
10
|
def setup
|
|
11
11
|
setup_class
|
|
@@ -3,9 +3,9 @@
|
|
|
3
3
|
# This file was automatically generated for Univapay
|
|
4
4
|
# by APIMATIC v3.0 ( https://www.apimatic.io ).
|
|
5
5
|
|
|
6
|
-
require_relative '
|
|
6
|
+
require_relative 'api_test_base'
|
|
7
7
|
|
|
8
|
-
class
|
|
8
|
+
class WebhooksApiTest < ApiTestBase
|
|
9
9
|
# Called only once for the class before any test has executed
|
|
10
10
|
def setup
|
|
11
11
|
setup_class
|
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: univapay-apimatic-sdk
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.0.
|
|
4
|
+
version: 0.0.4
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Muhammad Rafay
|
|
@@ -106,17 +106,17 @@ files:
|
|
|
106
106
|
- bin/console
|
|
107
107
|
- lib/univapay_client_sdk.rb
|
|
108
108
|
- lib/univapay_client_sdk/api_helper.rb
|
|
109
|
+
- lib/univapay_client_sdk/apis/base_api.rb
|
|
110
|
+
- lib/univapay_client_sdk/apis/cancels_api.rb
|
|
111
|
+
- lib/univapay_client_sdk/apis/charges_api.rb
|
|
112
|
+
- lib/univapay_client_sdk/apis/merchants_api.rb
|
|
113
|
+
- lib/univapay_client_sdk/apis/refunds_api.rb
|
|
114
|
+
- lib/univapay_client_sdk/apis/stores_api.rb
|
|
115
|
+
- lib/univapay_client_sdk/apis/subscriptions_api.rb
|
|
116
|
+
- lib/univapay_client_sdk/apis/transaction_tokens_api.rb
|
|
117
|
+
- lib/univapay_client_sdk/apis/webhooks_api.rb
|
|
109
118
|
- lib/univapay_client_sdk/client.rb
|
|
110
119
|
- lib/univapay_client_sdk/configuration.rb
|
|
111
|
-
- lib/univapay_client_sdk/controllers/base_controller.rb
|
|
112
|
-
- lib/univapay_client_sdk/controllers/cancels_controller.rb
|
|
113
|
-
- lib/univapay_client_sdk/controllers/charges_controller.rb
|
|
114
|
-
- lib/univapay_client_sdk/controllers/merchants_controller.rb
|
|
115
|
-
- lib/univapay_client_sdk/controllers/refunds_controller.rb
|
|
116
|
-
- lib/univapay_client_sdk/controllers/stores_controller.rb
|
|
117
|
-
- lib/univapay_client_sdk/controllers/subscriptions_controller.rb
|
|
118
|
-
- lib/univapay_client_sdk/controllers/transaction_tokens_controller.rb
|
|
119
|
-
- lib/univapay_client_sdk/controllers/webhooks_controller.rb
|
|
120
120
|
- lib/univapay_client_sdk/events/unknown_event.rb
|
|
121
121
|
- lib/univapay_client_sdk/events/webhooks/bank_transfer_handler.rb
|
|
122
122
|
- lib/univapay_client_sdk/events/webhooks/cancel_handler.rb
|
|
@@ -335,15 +335,15 @@ files:
|
|
|
335
335
|
- lib/univapay_client_sdk/utilities/date_time_helper.rb
|
|
336
336
|
- lib/univapay_client_sdk/utilities/file_wrapper.rb
|
|
337
337
|
- lib/univapay_client_sdk/utilities/union_type_lookup.rb
|
|
338
|
-
- test/
|
|
339
|
-
- test/
|
|
340
|
-
- test/
|
|
341
|
-
- test/
|
|
342
|
-
- test/
|
|
343
|
-
- test/
|
|
344
|
-
- test/
|
|
345
|
-
- test/
|
|
346
|
-
- test/
|
|
338
|
+
- test/apis/api_test_base.rb
|
|
339
|
+
- test/apis/test_cancels_api.rb
|
|
340
|
+
- test/apis/test_charges_api.rb
|
|
341
|
+
- test/apis/test_merchants_api.rb
|
|
342
|
+
- test/apis/test_refunds_api.rb
|
|
343
|
+
- test/apis/test_stores_api.rb
|
|
344
|
+
- test/apis/test_subscriptions_api.rb
|
|
345
|
+
- test/apis/test_transaction_tokens_api.rb
|
|
346
|
+
- test/apis/test_webhooks_api.rb
|
|
347
347
|
- test/events/webhooks/test_bank_transfer_handler.rb
|
|
348
348
|
- test/events/webhooks/test_cancel_handler.rb
|
|
349
349
|
- test/events/webhooks/test_charge_finished_handler.rb
|