subfi_pay 0.1.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 +7 -0
- data/Gemfile +11 -0
- data/Gemfile.lock +101 -0
- data/README.md +188 -0
- data/Rakefile +10 -0
- data/bin/console +11 -0
- data/docs/AccessKey.md +32 -0
- data/docs/AccessKeysApi.md +228 -0
- data/docs/AccountAttributes.md +20 -0
- data/docs/AccountAttributesAccount.md +20 -0
- data/docs/AccountCreateRequest.md +18 -0
- data/docs/AccountResponse.md +26 -0
- data/docs/AccountsApi.md +227 -0
- data/docs/BalanceTransactionAttributes.md +30 -0
- data/docs/BalanceTransactionResponse.md +38 -0
- data/docs/BalanceTransactionsApi.md +87 -0
- data/docs/BankAccountProfile.md +28 -0
- data/docs/BillingAddress.md +36 -0
- data/docs/CardProfile.md +42 -0
- data/docs/ChargeAttributes.md +26 -0
- data/docs/ChargeResponse.md +42 -0
- data/docs/ChargesApi.md +167 -0
- data/docs/ConnectedAccountAttributes.md +20 -0
- data/docs/ConnectedAccountResponse.md +26 -0
- data/docs/CreateAccountRequest.md +18 -0
- data/docs/CreateAccountRequestAccount.md +20 -0
- data/docs/CreateCustomerRequest.md +24 -0
- data/docs/CreateWebhookEndpointRequest.md +18 -0
- data/docs/CreateWebhookEndpointRequestWebhookEndpoint.md +28 -0
- data/docs/Customer.md +26 -0
- data/docs/CustomerAttributes.md +24 -0
- data/docs/CustomerAttributesCustomer.md +24 -0
- data/docs/CustomerCreateRequest.md +18 -0
- data/docs/CustomerUpdateAttributes.md +20 -0
- data/docs/CustomerUpdateAttributesCustomer.md +20 -0
- data/docs/CustomerUpdateRequest.md +18 -0
- data/docs/CustomersApi.md +307 -0
- data/docs/Event.md +30 -0
- data/docs/EventsApi.md +159 -0
- data/docs/ListAccessKeysResponse.md +20 -0
- data/docs/ListAccountsResponse.md +20 -0
- data/docs/ListBalanceTransactionsResponse.md +20 -0
- data/docs/ListChargesResponse.md +20 -0
- data/docs/ListCustomersResponse.md +20 -0
- data/docs/ListEventsResponse.md +20 -0
- data/docs/ListPaymentIntentsResponse.md +20 -0
- data/docs/ListPaymentMethodsResponse.md +20 -0
- data/docs/ListRefundsResponse.md +20 -0
- data/docs/ListWebhookEndpointsResponse.md +20 -0
- data/docs/ListWebhookRequestsResponse.md +20 -0
- data/docs/Meta.md +28 -0
- data/docs/PaymentIntentAttributes.md +26 -0
- data/docs/PaymentIntentAttributesPaymentIntent.md +26 -0
- data/docs/PaymentIntentCreateRequest.md +18 -0
- data/docs/PaymentIntentResponse.md +30 -0
- data/docs/PaymentIntentUpdateAttributes.md +18 -0
- data/docs/PaymentIntentUpdateAttributesPaymentIntent.md +18 -0
- data/docs/PaymentIntentsApi.md +533 -0
- data/docs/PaymentMethodAttributes.md +24 -0
- data/docs/PaymentMethodResponse.md +36 -0
- data/docs/PaymentMethodsApi.md +239 -0
- data/docs/RefundAttributes.md +20 -0
- data/docs/RefundResponse.md +30 -0
- data/docs/RefundsApi.md +311 -0
- data/docs/RollAccessKeyAttributes.md +18 -0
- data/docs/RollAccessKeyAttributesAccessKey.md +18 -0
- data/docs/RollAccessKeyRequest.md +18 -0
- data/docs/RollAccessKeyRequestAccessKey.md +18 -0
- data/docs/SubscriptionAttributes.md +30 -0
- data/docs/SubscriptionAttributesSubscription.md +30 -0
- data/docs/SubscriptionCreateRequest.md +18 -0
- data/docs/SubscriptionCreateRequestSubscription.md +30 -0
- data/docs/SubscriptionResponse.md +36 -0
- data/docs/SubscriptionsApi.md +155 -0
- data/docs/WebhookEndpoint.md +34 -0
- data/docs/WebhookEndpointsApi.md +380 -0
- data/docs/WebhookRequest.md +38 -0
- data/docs/WebhookRequestsApi.md +85 -0
- data/git_push.sh +57 -0
- data/lib/subfi_pay/api/access_keys_api.rb +235 -0
- data/lib/subfi_pay/api/accounts_api.rb +231 -0
- data/lib/subfi_pay/api/balance_transactions_api.rb +100 -0
- data/lib/subfi_pay/api/charges_api.rb +181 -0
- data/lib/subfi_pay/api/customers_api.rb +331 -0
- data/lib/subfi_pay/api/events_api.rb +172 -0
- data/lib/subfi_pay/api/payment_intents_api.rb +566 -0
- data/lib/subfi_pay/api/payment_methods_api.rb +262 -0
- data/lib/subfi_pay/api/refunds_api.rb +334 -0
- data/lib/subfi_pay/api/subscriptions_api.rb +177 -0
- data/lib/subfi_pay/api/webhook_endpoints_api.rb +404 -0
- data/lib/subfi_pay/api/webhook_requests_api.rb +97 -0
- data/lib/subfi_pay/api_client.rb +394 -0
- data/lib/subfi_pay/api_error.rb +58 -0
- data/lib/subfi_pay/configuration.rb +305 -0
- data/lib/subfi_pay/models/access_key.rb +275 -0
- data/lib/subfi_pay/models/account_attributes.rb +221 -0
- data/lib/subfi_pay/models/account_attributes_account.rb +221 -0
- data/lib/subfi_pay/models/account_create_request.rb +212 -0
- data/lib/subfi_pay/models/account_response.rb +248 -0
- data/lib/subfi_pay/models/balance_transaction_attributes.rb +266 -0
- data/lib/subfi_pay/models/balance_transaction_response.rb +303 -0
- data/lib/subfi_pay/models/bank_account_profile.rb +257 -0
- data/lib/subfi_pay/models/billing_address.rb +294 -0
- data/lib/subfi_pay/models/card_profile.rb +324 -0
- data/lib/subfi_pay/models/charge_attributes.rb +265 -0
- data/lib/subfi_pay/models/charge_response.rb +326 -0
- data/lib/subfi_pay/models/connected_account_attributes.rb +235 -0
- data/lib/subfi_pay/models/connected_account_response.rb +248 -0
- data/lib/subfi_pay/models/create_account_request.rb +219 -0
- data/lib/subfi_pay/models/create_account_request_account.rb +221 -0
- data/lib/subfi_pay/models/create_customer_request.rb +239 -0
- data/lib/subfi_pay/models/create_webhook_endpoint_request.rb +212 -0
- data/lib/subfi_pay/models/create_webhook_endpoint_request_webhook_endpoint.rb +257 -0
- data/lib/subfi_pay/models/customer.rb +248 -0
- data/lib/subfi_pay/models/customer_attributes.rb +239 -0
- data/lib/subfi_pay/models/customer_attributes_customer.rb +239 -0
- data/lib/subfi_pay/models/customer_create_request.rb +212 -0
- data/lib/subfi_pay/models/customer_update_attributes.rb +221 -0
- data/lib/subfi_pay/models/customer_update_attributes_customer.rb +221 -0
- data/lib/subfi_pay/models/customer_update_request.rb +212 -0
- data/lib/subfi_pay/models/event.rb +266 -0
- data/lib/subfi_pay/models/list_access_keys_response.rb +223 -0
- data/lib/subfi_pay/models/list_accounts_response.rb +223 -0
- data/lib/subfi_pay/models/list_balance_transactions_response.rb +223 -0
- data/lib/subfi_pay/models/list_charges_response.rb +223 -0
- data/lib/subfi_pay/models/list_customers_response.rb +223 -0
- data/lib/subfi_pay/models/list_events_response.rb +223 -0
- data/lib/subfi_pay/models/list_payment_intents_response.rb +223 -0
- data/lib/subfi_pay/models/list_payment_methods_response.rb +223 -0
- data/lib/subfi_pay/models/list_refunds_response.rb +223 -0
- data/lib/subfi_pay/models/list_webhook_endpoints_response.rb +223 -0
- data/lib/subfi_pay/models/list_webhook_requests_response.rb +223 -0
- data/lib/subfi_pay/models/meta.rb +259 -0
- data/lib/subfi_pay/models/payment_intent_attributes.rb +257 -0
- data/lib/subfi_pay/models/payment_intent_attributes_payment_intent.rb +257 -0
- data/lib/subfi_pay/models/payment_intent_create_request.rb +212 -0
- data/lib/subfi_pay/models/payment_intent_response.rb +268 -0
- data/lib/subfi_pay/models/payment_intent_update_attributes.rb +212 -0
- data/lib/subfi_pay/models/payment_intent_update_attributes_payment_intent.rb +214 -0
- data/lib/subfi_pay/models/payment_method_attributes.rb +246 -0
- data/lib/subfi_pay/models/payment_method_response.rb +296 -0
- data/lib/subfi_pay/models/refund_attributes.rb +228 -0
- data/lib/subfi_pay/models/refund_response.rb +268 -0
- data/lib/subfi_pay/models/roll_access_key_attributes.rb +212 -0
- data/lib/subfi_pay/models/roll_access_key_attributes_access_key.rb +219 -0
- data/lib/subfi_pay/models/roll_access_key_request.rb +212 -0
- data/lib/subfi_pay/models/roll_access_key_request_access_key.rb +219 -0
- data/lib/subfi_pay/models/subscription_attributes.rb +266 -0
- data/lib/subfi_pay/models/subscription_attributes_subscription.rb +266 -0
- data/lib/subfi_pay/models/subscription_create_request.rb +212 -0
- data/lib/subfi_pay/models/subscription_create_request_subscription.rb +266 -0
- data/lib/subfi_pay/models/subscription_response.rb +293 -0
- data/lib/subfi_pay/models/webhook_endpoint.rb +284 -0
- data/lib/subfi_pay/models/webhook_request.rb +302 -0
- data/lib/subfi_pay/version.rb +15 -0
- data/lib/subfi_pay.rb +99 -0
- data/run_fix_gemfile.sh +11 -0
- data/spec/api/access_keys_api_spec.rb +138 -0
- data/spec/api/accounts_api_spec.rb +145 -0
- data/spec/api/balance_transactions_api_spec.rb +86 -0
- data/spec/api/charges_api_spec.rb +121 -0
- data/spec/api/customers_api_spec.rb +134 -0
- data/spec/api/events_api_spec.rb +105 -0
- data/spec/api/payment_intents_api_spec.rb +250 -0
- data/spec/api/payment_methods_api_spec.rb +226 -0
- data/spec/api/refunds_api_spec.rb +158 -0
- data/spec/api/subscriptions_api_spec.rb +113 -0
- data/spec/api/webhook_endpoints_api_spec.rb +198 -0
- data/spec/api/webhook_requests_api_spec.rb +79 -0
- data/spec/configuration_spec.rb +23 -0
- data/spec/fixtures/access_keys/list_200.json +1 -0
- data/spec/fixtures/access_keys/roll_200.json +1 -0
- data/spec/fixtures/accounts/create_201.json +1 -0
- data/spec/fixtures/accounts/list_200.json +1 -0
- data/spec/fixtures/accounts/show_200.json +1 -0
- data/spec/fixtures/balance_transactions/list_200.json +69 -0
- data/spec/fixtures/charges/create_201.json +39 -0
- data/spec/fixtures/charges/list_200.json +1 -0
- data/spec/fixtures/charges/retrieve_200.json +1 -0
- data/spec/fixtures/customers/create_201.json +1 -0
- data/spec/fixtures/customers/list_200.json +1 -0
- data/spec/fixtures/customers/show_200.json +1 -0
- data/spec/fixtures/events/list_200.json +1 -0
- data/spec/fixtures/events/show_200.json +1 -0
- data/spec/fixtures/payment_intents/cancel_200.json +1 -0
- data/spec/fixtures/payment_intents/capture_200.json +1 -0
- data/spec/fixtures/payment_intents/confirm_200.json +1 -0
- data/spec/fixtures/payment_intents/create_201.json +1 -0
- data/spec/fixtures/payment_intents/fetch_200.json +1 -0
- data/spec/fixtures/payment_intents/list_200.json +1 -0
- data/spec/fixtures/payment_intents/update_200.json +1 -0
- data/spec/fixtures/payment_methods/create_bank_account_201.json +1 -0
- data/spec/fixtures/payment_methods/create_card_201.json +1 -0
- data/spec/fixtures/payment_methods/get_bank_account_200.json +29 -0
- data/spec/fixtures/payment_methods/get_card_200.json +1 -0
- data/spec/fixtures/payment_methods/list_200.json +1 -0
- data/spec/fixtures/refunds/create_201.json +1 -0
- data/spec/fixtures/refunds/list_200.json +1 -0
- data/spec/fixtures/refunds/show_200.json +1 -0
- data/spec/fixtures/subscriptions/create_201.json +1 -0
- data/spec/fixtures/subscriptions/show_200.json +1 -0
- data/spec/fixtures/webhook_endpoints/create_201.json +11 -0
- data/spec/fixtures/webhook_endpoints/list_200.json +1 -0
- data/spec/fixtures/webhook_endpoints/show_200.json +1 -0
- data/spec/fixtures/webhook_endpoints/update_200.json +13 -0
- data/spec/fixtures/webhook_requests/list_200.json +1 -0
- data/spec/models/access_key_spec.rb +39 -0
- data/spec/models/account_attributes_spec.rb +40 -0
- data/spec/models/account_create_request_spec.rb +38 -0
- data/spec/models/account_response_spec.rb +39 -0
- data/spec/models/balance_transaction_response_spec.rb +38 -0
- data/spec/models/bank_account_profile_spec.rb +38 -0
- data/spec/models/billing_address_spec.rb +38 -0
- data/spec/models/card_profile_spec.rb +38 -0
- data/spec/models/charge_attributes_spec.rb +45 -0
- data/spec/models/charge_response_spec.rb +45 -0
- data/spec/models/connected_account_attributes_spec.rb +38 -0
- data/spec/models/connected_account_response_spec.rb +39 -0
- data/spec/models/create_account_request_account_spec.rb +39 -0
- data/spec/models/create_account_request_spec.rb +39 -0
- data/spec/models/create_webhook_endpoint_request_spec.rb +38 -0
- data/spec/models/create_webhook_endpoint_request_webhook_endpoint_spec.rb +38 -0
- data/spec/models/customer_attributes_spec.rb +40 -0
- data/spec/models/customer_create_request_spec.rb +38 -0
- data/spec/models/customer_spec.rb +39 -0
- data/spec/models/customer_update_attributes_spec.rb +39 -0
- data/spec/models/customer_update_request_spec.rb +39 -0
- data/spec/models/event_spec.rb +39 -0
- data/spec/models/list_access_keys_response_spec.rb +38 -0
- data/spec/models/list_accounts_response_spec.rb +38 -0
- data/spec/models/list_balance_transactions_response_spec.rb +38 -0
- data/spec/models/list_charges_response_spec.rb +38 -0
- data/spec/models/list_customers_response_spec.rb +39 -0
- data/spec/models/list_events_response_spec.rb +38 -0
- data/spec/models/list_payment_intents_response_spec.rb +45 -0
- data/spec/models/list_payment_methods_response_spec.rb +39 -0
- data/spec/models/list_refunds_response_spec.rb +38 -0
- data/spec/models/list_webhook_endpoints_response_spec.rb +38 -0
- data/spec/models/list_webhook_requests_response_spec.rb +39 -0
- data/spec/models/meta_spec.rb +38 -0
- data/spec/models/payment_intent_attributes_spec.rb +44 -0
- data/spec/models/payment_intent_create_request_spec.rb +38 -0
- data/spec/models/payment_intent_response_spec.rb +45 -0
- data/spec/models/payment_intent_update_attributes_payment_intent_spec.rb +38 -0
- data/spec/models/payment_intent_update_attributes_spec.rb +37 -0
- data/spec/models/payment_method_attributes_spec.rb +38 -0
- data/spec/models/payment_method_response_spec.rb +38 -0
- data/spec/models/refund_attributes_spec.rb +39 -0
- data/spec/models/refund_response_spec.rb +38 -0
- data/spec/models/roll_access_key_attributes_access_key_spec.rb +39 -0
- data/spec/models/roll_access_key_attributes_spec.rb +40 -0
- data/spec/models/roll_access_key_request_access_key_spec.rb +38 -0
- data/spec/models/roll_access_key_request_spec.rb +37 -0
- data/spec/models/subscription_attributes_spec.rb +38 -0
- data/spec/models/subscription_create_request_spec.rb +40 -0
- data/spec/models/subscription_response_spec.rb +38 -0
- data/spec/models/webhook_endpoint_spec.rb +40 -0
- data/spec/models/webhook_request_spec.rb +40 -0
- data/spec/spec_helper.rb +123 -0
- data/subfi_pay.gemspec +39 -0
- metadata +444 -0
@@ -0,0 +1,307 @@
|
|
1
|
+
# SubFiPay::CustomersApi
|
2
|
+
|
3
|
+
All URIs are relative to *https://pay-sandbox.subfi.com*
|
4
|
+
|
5
|
+
| Method | HTTP request | Description |
|
6
|
+
| ------ | ------------ | ----------- |
|
7
|
+
| [**create_customer**](CustomersApi.md#create_customer) | **POST** /customers | Create a new customer |
|
8
|
+
| [**get_customer**](CustomersApi.md#get_customer) | **GET** /customers/{id} | Retrieve a customer by ID |
|
9
|
+
| [**list_customers**](CustomersApi.md#list_customers) | **GET** /customers | List all customers |
|
10
|
+
| [**update_customer**](CustomersApi.md#update_customer) | **PATCH** /customers/{id} | Update a customer by ID |
|
11
|
+
|
12
|
+
|
13
|
+
## create_customer
|
14
|
+
|
15
|
+
> <Customer> create_customer(x_api_version, customer_create_request)
|
16
|
+
|
17
|
+
Create a new customer
|
18
|
+
|
19
|
+
### Examples
|
20
|
+
|
21
|
+
```ruby
|
22
|
+
require 'time'
|
23
|
+
require 'subfi_pay'
|
24
|
+
# setup authorization
|
25
|
+
SubFiPay.configure do |config|
|
26
|
+
# Configure API key authorization: ApiKeyAuth
|
27
|
+
config.api_key['ApiKeyAuth'] = 'YOUR API KEY'
|
28
|
+
# Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
|
29
|
+
# config.api_key_prefix['ApiKeyAuth'] = 'Bearer'
|
30
|
+
end
|
31
|
+
|
32
|
+
api_instance = SubFiPay::CustomersApi.new
|
33
|
+
x_api_version = 'x_api_version_example' # String |
|
34
|
+
customer_create_request = SubFiPay::CustomerCreateRequest.new # CustomerCreateRequest |
|
35
|
+
|
36
|
+
begin
|
37
|
+
# Create a new customer
|
38
|
+
result = api_instance.create_customer(x_api_version, customer_create_request)
|
39
|
+
p result
|
40
|
+
rescue SubFiPay::ApiError => e
|
41
|
+
puts "Error when calling CustomersApi->create_customer: #{e}"
|
42
|
+
end
|
43
|
+
```
|
44
|
+
|
45
|
+
#### Using the create_customer_with_http_info variant
|
46
|
+
|
47
|
+
This returns an Array which contains the response data, status code and headers.
|
48
|
+
|
49
|
+
> <Array(<Customer>, Integer, Hash)> create_customer_with_http_info(x_api_version, customer_create_request)
|
50
|
+
|
51
|
+
```ruby
|
52
|
+
begin
|
53
|
+
# Create a new customer
|
54
|
+
data, status_code, headers = api_instance.create_customer_with_http_info(x_api_version, customer_create_request)
|
55
|
+
p status_code # => 2xx
|
56
|
+
p headers # => { ... }
|
57
|
+
p data # => <Customer>
|
58
|
+
rescue SubFiPay::ApiError => e
|
59
|
+
puts "Error when calling CustomersApi->create_customer_with_http_info: #{e}"
|
60
|
+
end
|
61
|
+
```
|
62
|
+
|
63
|
+
### Parameters
|
64
|
+
|
65
|
+
| Name | Type | Description | Notes |
|
66
|
+
| ---- | ---- | ----------- | ----- |
|
67
|
+
| **x_api_version** | **String** | | |
|
68
|
+
| **customer_create_request** | [**CustomerCreateRequest**](CustomerCreateRequest.md) | | |
|
69
|
+
|
70
|
+
### Return type
|
71
|
+
|
72
|
+
[**Customer**](Customer.md)
|
73
|
+
|
74
|
+
### Authorization
|
75
|
+
|
76
|
+
[ApiKeyAuth](../README.md#ApiKeyAuth)
|
77
|
+
|
78
|
+
### HTTP request headers
|
79
|
+
|
80
|
+
- **Content-Type**: application/json
|
81
|
+
- **Accept**: application/json
|
82
|
+
|
83
|
+
|
84
|
+
## get_customer
|
85
|
+
|
86
|
+
> <Customer> get_customer(x_api_version, x_account_id, id)
|
87
|
+
|
88
|
+
Retrieve a customer by ID
|
89
|
+
|
90
|
+
### Examples
|
91
|
+
|
92
|
+
```ruby
|
93
|
+
require 'time'
|
94
|
+
require 'subfi_pay'
|
95
|
+
# setup authorization
|
96
|
+
SubFiPay.configure do |config|
|
97
|
+
# Configure API key authorization: ApiKeyAuth
|
98
|
+
config.api_key['ApiKeyAuth'] = 'YOUR API KEY'
|
99
|
+
# Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
|
100
|
+
# config.api_key_prefix['ApiKeyAuth'] = 'Bearer'
|
101
|
+
end
|
102
|
+
|
103
|
+
api_instance = SubFiPay::CustomersApi.new
|
104
|
+
x_api_version = 'x_api_version_example' # String |
|
105
|
+
x_account_id = 'x_account_id_example' # String |
|
106
|
+
id = 'id_example' # String |
|
107
|
+
|
108
|
+
begin
|
109
|
+
# Retrieve a customer by ID
|
110
|
+
result = api_instance.get_customer(x_api_version, x_account_id, id)
|
111
|
+
p result
|
112
|
+
rescue SubFiPay::ApiError => e
|
113
|
+
puts "Error when calling CustomersApi->get_customer: #{e}"
|
114
|
+
end
|
115
|
+
```
|
116
|
+
|
117
|
+
#### Using the get_customer_with_http_info variant
|
118
|
+
|
119
|
+
This returns an Array which contains the response data, status code and headers.
|
120
|
+
|
121
|
+
> <Array(<Customer>, Integer, Hash)> get_customer_with_http_info(x_api_version, x_account_id, id)
|
122
|
+
|
123
|
+
```ruby
|
124
|
+
begin
|
125
|
+
# Retrieve a customer by ID
|
126
|
+
data, status_code, headers = api_instance.get_customer_with_http_info(x_api_version, x_account_id, id)
|
127
|
+
p status_code # => 2xx
|
128
|
+
p headers # => { ... }
|
129
|
+
p data # => <Customer>
|
130
|
+
rescue SubFiPay::ApiError => e
|
131
|
+
puts "Error when calling CustomersApi->get_customer_with_http_info: #{e}"
|
132
|
+
end
|
133
|
+
```
|
134
|
+
|
135
|
+
### Parameters
|
136
|
+
|
137
|
+
| Name | Type | Description | Notes |
|
138
|
+
| ---- | ---- | ----------- | ----- |
|
139
|
+
| **x_api_version** | **String** | | |
|
140
|
+
| **x_account_id** | **String** | | |
|
141
|
+
| **id** | **String** | | |
|
142
|
+
|
143
|
+
### Return type
|
144
|
+
|
145
|
+
[**Customer**](Customer.md)
|
146
|
+
|
147
|
+
### Authorization
|
148
|
+
|
149
|
+
[ApiKeyAuth](../README.md#ApiKeyAuth)
|
150
|
+
|
151
|
+
### HTTP request headers
|
152
|
+
|
153
|
+
- **Content-Type**: Not defined
|
154
|
+
- **Accept**: application/json
|
155
|
+
|
156
|
+
|
157
|
+
## list_customers
|
158
|
+
|
159
|
+
> <ListCustomersResponse> list_customers(x_api_version, x_account_id, opts)
|
160
|
+
|
161
|
+
List all customers
|
162
|
+
|
163
|
+
### Examples
|
164
|
+
|
165
|
+
```ruby
|
166
|
+
require 'time'
|
167
|
+
require 'subfi_pay'
|
168
|
+
# setup authorization
|
169
|
+
SubFiPay.configure do |config|
|
170
|
+
# Configure API key authorization: ApiKeyAuth
|
171
|
+
config.api_key['ApiKeyAuth'] = 'YOUR API KEY'
|
172
|
+
# Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
|
173
|
+
# config.api_key_prefix['ApiKeyAuth'] = 'Bearer'
|
174
|
+
end
|
175
|
+
|
176
|
+
api_instance = SubFiPay::CustomersApi.new
|
177
|
+
x_api_version = 'x_api_version_example' # String |
|
178
|
+
x_account_id = 'x_account_id_example' # String |
|
179
|
+
opts = {
|
180
|
+
page: 56, # Integer | The page of results to retrieve.
|
181
|
+
per_page: 56 # Integer | Number of results per page.
|
182
|
+
}
|
183
|
+
|
184
|
+
begin
|
185
|
+
# List all customers
|
186
|
+
result = api_instance.list_customers(x_api_version, x_account_id, opts)
|
187
|
+
p result
|
188
|
+
rescue SubFiPay::ApiError => e
|
189
|
+
puts "Error when calling CustomersApi->list_customers: #{e}"
|
190
|
+
end
|
191
|
+
```
|
192
|
+
|
193
|
+
#### Using the list_customers_with_http_info variant
|
194
|
+
|
195
|
+
This returns an Array which contains the response data, status code and headers.
|
196
|
+
|
197
|
+
> <Array(<ListCustomersResponse>, Integer, Hash)> list_customers_with_http_info(x_api_version, x_account_id, opts)
|
198
|
+
|
199
|
+
```ruby
|
200
|
+
begin
|
201
|
+
# List all customers
|
202
|
+
data, status_code, headers = api_instance.list_customers_with_http_info(x_api_version, x_account_id, opts)
|
203
|
+
p status_code # => 2xx
|
204
|
+
p headers # => { ... }
|
205
|
+
p data # => <ListCustomersResponse>
|
206
|
+
rescue SubFiPay::ApiError => e
|
207
|
+
puts "Error when calling CustomersApi->list_customers_with_http_info: #{e}"
|
208
|
+
end
|
209
|
+
```
|
210
|
+
|
211
|
+
### Parameters
|
212
|
+
|
213
|
+
| Name | Type | Description | Notes |
|
214
|
+
| ---- | ---- | ----------- | ----- |
|
215
|
+
| **x_api_version** | **String** | | |
|
216
|
+
| **x_account_id** | **String** | | |
|
217
|
+
| **page** | **Integer** | The page of results to retrieve. | [optional] |
|
218
|
+
| **per_page** | **Integer** | Number of results per page. | [optional] |
|
219
|
+
|
220
|
+
### Return type
|
221
|
+
|
222
|
+
[**ListCustomersResponse**](ListCustomersResponse.md)
|
223
|
+
|
224
|
+
### Authorization
|
225
|
+
|
226
|
+
[ApiKeyAuth](../README.md#ApiKeyAuth)
|
227
|
+
|
228
|
+
### HTTP request headers
|
229
|
+
|
230
|
+
- **Content-Type**: Not defined
|
231
|
+
- **Accept**: application/json
|
232
|
+
|
233
|
+
|
234
|
+
## update_customer
|
235
|
+
|
236
|
+
> <Customer> update_customer(x_api_version, x_account_id, id, customer_update_request)
|
237
|
+
|
238
|
+
Update a customer by ID
|
239
|
+
|
240
|
+
### Examples
|
241
|
+
|
242
|
+
```ruby
|
243
|
+
require 'time'
|
244
|
+
require 'subfi_pay'
|
245
|
+
# setup authorization
|
246
|
+
SubFiPay.configure do |config|
|
247
|
+
# Configure API key authorization: ApiKeyAuth
|
248
|
+
config.api_key['ApiKeyAuth'] = 'YOUR API KEY'
|
249
|
+
# Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
|
250
|
+
# config.api_key_prefix['ApiKeyAuth'] = 'Bearer'
|
251
|
+
end
|
252
|
+
|
253
|
+
api_instance = SubFiPay::CustomersApi.new
|
254
|
+
x_api_version = 'x_api_version_example' # String |
|
255
|
+
x_account_id = 'x_account_id_example' # String |
|
256
|
+
id = 'id_example' # String |
|
257
|
+
customer_update_request = SubFiPay::CustomerUpdateRequest.new # CustomerUpdateRequest |
|
258
|
+
|
259
|
+
begin
|
260
|
+
# Update a customer by ID
|
261
|
+
result = api_instance.update_customer(x_api_version, x_account_id, id, customer_update_request)
|
262
|
+
p result
|
263
|
+
rescue SubFiPay::ApiError => e
|
264
|
+
puts "Error when calling CustomersApi->update_customer: #{e}"
|
265
|
+
end
|
266
|
+
```
|
267
|
+
|
268
|
+
#### Using the update_customer_with_http_info variant
|
269
|
+
|
270
|
+
This returns an Array which contains the response data, status code and headers.
|
271
|
+
|
272
|
+
> <Array(<Customer>, Integer, Hash)> update_customer_with_http_info(x_api_version, x_account_id, id, customer_update_request)
|
273
|
+
|
274
|
+
```ruby
|
275
|
+
begin
|
276
|
+
# Update a customer by ID
|
277
|
+
data, status_code, headers = api_instance.update_customer_with_http_info(x_api_version, x_account_id, id, customer_update_request)
|
278
|
+
p status_code # => 2xx
|
279
|
+
p headers # => { ... }
|
280
|
+
p data # => <Customer>
|
281
|
+
rescue SubFiPay::ApiError => e
|
282
|
+
puts "Error when calling CustomersApi->update_customer_with_http_info: #{e}"
|
283
|
+
end
|
284
|
+
```
|
285
|
+
|
286
|
+
### Parameters
|
287
|
+
|
288
|
+
| Name | Type | Description | Notes |
|
289
|
+
| ---- | ---- | ----------- | ----- |
|
290
|
+
| **x_api_version** | **String** | | |
|
291
|
+
| **x_account_id** | **String** | | |
|
292
|
+
| **id** | **String** | | |
|
293
|
+
| **customer_update_request** | [**CustomerUpdateRequest**](CustomerUpdateRequest.md) | | |
|
294
|
+
|
295
|
+
### Return type
|
296
|
+
|
297
|
+
[**Customer**](Customer.md)
|
298
|
+
|
299
|
+
### Authorization
|
300
|
+
|
301
|
+
[ApiKeyAuth](../README.md#ApiKeyAuth)
|
302
|
+
|
303
|
+
### HTTP request headers
|
304
|
+
|
305
|
+
- **Content-Type**: application/json
|
306
|
+
- **Accept**: application/json
|
307
|
+
|
data/docs/Event.md
ADDED
@@ -0,0 +1,30 @@
|
|
1
|
+
# SubFiPay::Event
|
2
|
+
|
3
|
+
## Properties
|
4
|
+
|
5
|
+
| Name | Type | Description | Notes |
|
6
|
+
| ---- | ---- | ----------- | ----- |
|
7
|
+
| **id** | **String** | | [optional] |
|
8
|
+
| **event** | **String** | | [optional] |
|
9
|
+
| **data** | **Object** | | [optional] |
|
10
|
+
| **account_id** | **String** | | [optional] |
|
11
|
+
| **connected_account_id** | **String** | | [optional] |
|
12
|
+
| **created_at** | **Time** | | [optional] |
|
13
|
+
| **updated_at** | **Time** | | [optional] |
|
14
|
+
|
15
|
+
## Example
|
16
|
+
|
17
|
+
```ruby
|
18
|
+
require 'subfi_pay'
|
19
|
+
|
20
|
+
instance = SubFiPay::Event.new(
|
21
|
+
id: null,
|
22
|
+
event: null,
|
23
|
+
data: null,
|
24
|
+
account_id: null,
|
25
|
+
connected_account_id: null,
|
26
|
+
created_at: null,
|
27
|
+
updated_at: null
|
28
|
+
)
|
29
|
+
```
|
30
|
+
|
data/docs/EventsApi.md
ADDED
@@ -0,0 +1,159 @@
|
|
1
|
+
# SubFiPay::EventsApi
|
2
|
+
|
3
|
+
All URIs are relative to *https://pay-sandbox.subfi.com*
|
4
|
+
|
5
|
+
| Method | HTTP request | Description |
|
6
|
+
| ------ | ------------ | ----------- |
|
7
|
+
| [**get_event**](EventsApi.md#get_event) | **GET** /events/{id} | Retrieve a single event by ID |
|
8
|
+
| [**list_events**](EventsApi.md#list_events) | **GET** /events | List all events |
|
9
|
+
|
10
|
+
|
11
|
+
## get_event
|
12
|
+
|
13
|
+
> <Event> get_event(x_api_version, x_account_id, id)
|
14
|
+
|
15
|
+
Retrieve a single event by ID
|
16
|
+
|
17
|
+
### Examples
|
18
|
+
|
19
|
+
```ruby
|
20
|
+
require 'time'
|
21
|
+
require 'subfi_pay'
|
22
|
+
# setup authorization
|
23
|
+
SubFiPay.configure do |config|
|
24
|
+
# Configure API key authorization: ApiKeyAuth
|
25
|
+
config.api_key['ApiKeyAuth'] = 'YOUR API KEY'
|
26
|
+
# Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
|
27
|
+
# config.api_key_prefix['ApiKeyAuth'] = 'Bearer'
|
28
|
+
end
|
29
|
+
|
30
|
+
api_instance = SubFiPay::EventsApi.new
|
31
|
+
x_api_version = 'x_api_version_example' # String |
|
32
|
+
x_account_id = 'x_account_id_example' # String |
|
33
|
+
id = 'id_example' # String |
|
34
|
+
|
35
|
+
begin
|
36
|
+
# Retrieve a single event by ID
|
37
|
+
result = api_instance.get_event(x_api_version, x_account_id, id)
|
38
|
+
p result
|
39
|
+
rescue SubFiPay::ApiError => e
|
40
|
+
puts "Error when calling EventsApi->get_event: #{e}"
|
41
|
+
end
|
42
|
+
```
|
43
|
+
|
44
|
+
#### Using the get_event_with_http_info variant
|
45
|
+
|
46
|
+
This returns an Array which contains the response data, status code and headers.
|
47
|
+
|
48
|
+
> <Array(<Event>, Integer, Hash)> get_event_with_http_info(x_api_version, x_account_id, id)
|
49
|
+
|
50
|
+
```ruby
|
51
|
+
begin
|
52
|
+
# Retrieve a single event by ID
|
53
|
+
data, status_code, headers = api_instance.get_event_with_http_info(x_api_version, x_account_id, id)
|
54
|
+
p status_code # => 2xx
|
55
|
+
p headers # => { ... }
|
56
|
+
p data # => <Event>
|
57
|
+
rescue SubFiPay::ApiError => e
|
58
|
+
puts "Error when calling EventsApi->get_event_with_http_info: #{e}"
|
59
|
+
end
|
60
|
+
```
|
61
|
+
|
62
|
+
### Parameters
|
63
|
+
|
64
|
+
| Name | Type | Description | Notes |
|
65
|
+
| ---- | ---- | ----------- | ----- |
|
66
|
+
| **x_api_version** | **String** | | |
|
67
|
+
| **x_account_id** | **String** | | |
|
68
|
+
| **id** | **String** | | |
|
69
|
+
|
70
|
+
### Return type
|
71
|
+
|
72
|
+
[**Event**](Event.md)
|
73
|
+
|
74
|
+
### Authorization
|
75
|
+
|
76
|
+
[ApiKeyAuth](../README.md#ApiKeyAuth)
|
77
|
+
|
78
|
+
### HTTP request headers
|
79
|
+
|
80
|
+
- **Content-Type**: Not defined
|
81
|
+
- **Accept**: application/json
|
82
|
+
|
83
|
+
|
84
|
+
## list_events
|
85
|
+
|
86
|
+
> <ListEventsResponse> list_events(x_api_version, x_account_id, opts)
|
87
|
+
|
88
|
+
List all events
|
89
|
+
|
90
|
+
### Examples
|
91
|
+
|
92
|
+
```ruby
|
93
|
+
require 'time'
|
94
|
+
require 'subfi_pay'
|
95
|
+
# setup authorization
|
96
|
+
SubFiPay.configure do |config|
|
97
|
+
# Configure API key authorization: ApiKeyAuth
|
98
|
+
config.api_key['ApiKeyAuth'] = 'YOUR API KEY'
|
99
|
+
# Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
|
100
|
+
# config.api_key_prefix['ApiKeyAuth'] = 'Bearer'
|
101
|
+
end
|
102
|
+
|
103
|
+
api_instance = SubFiPay::EventsApi.new
|
104
|
+
x_api_version = 'x_api_version_example' # String |
|
105
|
+
x_account_id = 'x_account_id_example' # String |
|
106
|
+
opts = {
|
107
|
+
page: 56, # Integer | The page of results to retrieve.
|
108
|
+
per_page: 56 # Integer | Number of results per page.
|
109
|
+
}
|
110
|
+
|
111
|
+
begin
|
112
|
+
# List all events
|
113
|
+
result = api_instance.list_events(x_api_version, x_account_id, opts)
|
114
|
+
p result
|
115
|
+
rescue SubFiPay::ApiError => e
|
116
|
+
puts "Error when calling EventsApi->list_events: #{e}"
|
117
|
+
end
|
118
|
+
```
|
119
|
+
|
120
|
+
#### Using the list_events_with_http_info variant
|
121
|
+
|
122
|
+
This returns an Array which contains the response data, status code and headers.
|
123
|
+
|
124
|
+
> <Array(<ListEventsResponse>, Integer, Hash)> list_events_with_http_info(x_api_version, x_account_id, opts)
|
125
|
+
|
126
|
+
```ruby
|
127
|
+
begin
|
128
|
+
# List all events
|
129
|
+
data, status_code, headers = api_instance.list_events_with_http_info(x_api_version, x_account_id, opts)
|
130
|
+
p status_code # => 2xx
|
131
|
+
p headers # => { ... }
|
132
|
+
p data # => <ListEventsResponse>
|
133
|
+
rescue SubFiPay::ApiError => e
|
134
|
+
puts "Error when calling EventsApi->list_events_with_http_info: #{e}"
|
135
|
+
end
|
136
|
+
```
|
137
|
+
|
138
|
+
### Parameters
|
139
|
+
|
140
|
+
| Name | Type | Description | Notes |
|
141
|
+
| ---- | ---- | ----------- | ----- |
|
142
|
+
| **x_api_version** | **String** | | |
|
143
|
+
| **x_account_id** | **String** | | |
|
144
|
+
| **page** | **Integer** | The page of results to retrieve. | [optional] |
|
145
|
+
| **per_page** | **Integer** | Number of results per page. | [optional] |
|
146
|
+
|
147
|
+
### Return type
|
148
|
+
|
149
|
+
[**ListEventsResponse**](ListEventsResponse.md)
|
150
|
+
|
151
|
+
### Authorization
|
152
|
+
|
153
|
+
[ApiKeyAuth](../README.md#ApiKeyAuth)
|
154
|
+
|
155
|
+
### HTTP request headers
|
156
|
+
|
157
|
+
- **Content-Type**: Not defined
|
158
|
+
- **Accept**: application/json
|
159
|
+
|
@@ -0,0 +1,20 @@
|
|
1
|
+
# SubFiPay::ListAccessKeysResponse
|
2
|
+
|
3
|
+
## Properties
|
4
|
+
|
5
|
+
| Name | Type | Description | Notes |
|
6
|
+
| ---- | ---- | ----------- | ----- |
|
7
|
+
| **data** | [**Array<AccessKey>**](AccessKey.md) | | [optional] |
|
8
|
+
| **meta** | [**Meta**](Meta.md) | | [optional] |
|
9
|
+
|
10
|
+
## Example
|
11
|
+
|
12
|
+
```ruby
|
13
|
+
require 'subfi_pay'
|
14
|
+
|
15
|
+
instance = SubFiPay::ListAccessKeysResponse.new(
|
16
|
+
data: null,
|
17
|
+
meta: null
|
18
|
+
)
|
19
|
+
```
|
20
|
+
|
@@ -0,0 +1,20 @@
|
|
1
|
+
# SubFiPay::ListAccountsResponse
|
2
|
+
|
3
|
+
## Properties
|
4
|
+
|
5
|
+
| Name | Type | Description | Notes |
|
6
|
+
| ---- | ---- | ----------- | ----- |
|
7
|
+
| **data** | [**Array<AccountResponse>**](AccountResponse.md) | | [optional] |
|
8
|
+
| **meta** | [**Meta**](Meta.md) | | [optional] |
|
9
|
+
|
10
|
+
## Example
|
11
|
+
|
12
|
+
```ruby
|
13
|
+
require 'subfi_pay'
|
14
|
+
|
15
|
+
instance = SubFiPay::ListAccountsResponse.new(
|
16
|
+
data: null,
|
17
|
+
meta: null
|
18
|
+
)
|
19
|
+
```
|
20
|
+
|
@@ -0,0 +1,20 @@
|
|
1
|
+
# SubFiPay::ListBalanceTransactionsResponse
|
2
|
+
|
3
|
+
## Properties
|
4
|
+
|
5
|
+
| Name | Type | Description | Notes |
|
6
|
+
| ---- | ---- | ----------- | ----- |
|
7
|
+
| **data** | [**Array<BalanceTransactionResponse>**](BalanceTransactionResponse.md) | | [optional] |
|
8
|
+
| **meta** | [**Meta**](Meta.md) | | [optional] |
|
9
|
+
|
10
|
+
## Example
|
11
|
+
|
12
|
+
```ruby
|
13
|
+
require 'subfi_pay'
|
14
|
+
|
15
|
+
instance = SubFiPay::ListBalanceTransactionsResponse.new(
|
16
|
+
data: null,
|
17
|
+
meta: null
|
18
|
+
)
|
19
|
+
```
|
20
|
+
|
@@ -0,0 +1,20 @@
|
|
1
|
+
# SubFiPay::ListChargesResponse
|
2
|
+
|
3
|
+
## Properties
|
4
|
+
|
5
|
+
| Name | Type | Description | Notes |
|
6
|
+
| ---- | ---- | ----------- | ----- |
|
7
|
+
| **data** | [**Array<ChargeResponse>**](ChargeResponse.md) | | [optional] |
|
8
|
+
| **meta** | [**Meta**](Meta.md) | | [optional] |
|
9
|
+
|
10
|
+
## Example
|
11
|
+
|
12
|
+
```ruby
|
13
|
+
require 'subfi_pay'
|
14
|
+
|
15
|
+
instance = SubFiPay::ListChargesResponse.new(
|
16
|
+
data: null,
|
17
|
+
meta: null
|
18
|
+
)
|
19
|
+
```
|
20
|
+
|
@@ -0,0 +1,20 @@
|
|
1
|
+
# SubFiPay::ListCustomersResponse
|
2
|
+
|
3
|
+
## Properties
|
4
|
+
|
5
|
+
| Name | Type | Description | Notes |
|
6
|
+
| ---- | ---- | ----------- | ----- |
|
7
|
+
| **data** | [**Array<Customer>**](Customer.md) | | [optional] |
|
8
|
+
| **meta** | [**Meta**](Meta.md) | | [optional] |
|
9
|
+
|
10
|
+
## Example
|
11
|
+
|
12
|
+
```ruby
|
13
|
+
require 'subfi_pay'
|
14
|
+
|
15
|
+
instance = SubFiPay::ListCustomersResponse.new(
|
16
|
+
data: null,
|
17
|
+
meta: null
|
18
|
+
)
|
19
|
+
```
|
20
|
+
|
@@ -0,0 +1,20 @@
|
|
1
|
+
# SubFiPay::ListEventsResponse
|
2
|
+
|
3
|
+
## Properties
|
4
|
+
|
5
|
+
| Name | Type | Description | Notes |
|
6
|
+
| ---- | ---- | ----------- | ----- |
|
7
|
+
| **data** | [**Array<Event>**](Event.md) | | [optional] |
|
8
|
+
| **meta** | [**Meta**](Meta.md) | | [optional] |
|
9
|
+
|
10
|
+
## Example
|
11
|
+
|
12
|
+
```ruby
|
13
|
+
require 'subfi_pay'
|
14
|
+
|
15
|
+
instance = SubFiPay::ListEventsResponse.new(
|
16
|
+
data: null,
|
17
|
+
meta: null
|
18
|
+
)
|
19
|
+
```
|
20
|
+
|
@@ -0,0 +1,20 @@
|
|
1
|
+
# SubFiPay::ListPaymentIntentsResponse
|
2
|
+
|
3
|
+
## Properties
|
4
|
+
|
5
|
+
| Name | Type | Description | Notes |
|
6
|
+
| ---- | ---- | ----------- | ----- |
|
7
|
+
| **data** | [**Array<PaymentIntentResponse>**](PaymentIntentResponse.md) | | [optional] |
|
8
|
+
| **meta** | [**Meta**](Meta.md) | | [optional] |
|
9
|
+
|
10
|
+
## Example
|
11
|
+
|
12
|
+
```ruby
|
13
|
+
require 'subfi_pay'
|
14
|
+
|
15
|
+
instance = SubFiPay::ListPaymentIntentsResponse.new(
|
16
|
+
data: null,
|
17
|
+
meta: null
|
18
|
+
)
|
19
|
+
```
|
20
|
+
|
@@ -0,0 +1,20 @@
|
|
1
|
+
# SubFiPay::ListPaymentMethodsResponse
|
2
|
+
|
3
|
+
## Properties
|
4
|
+
|
5
|
+
| Name | Type | Description | Notes |
|
6
|
+
| ---- | ---- | ----------- | ----- |
|
7
|
+
| **data** | [**Array<PaymentMethodResponse>**](PaymentMethodResponse.md) | | [optional] |
|
8
|
+
| **meta** | [**Meta**](Meta.md) | | [optional] |
|
9
|
+
|
10
|
+
## Example
|
11
|
+
|
12
|
+
```ruby
|
13
|
+
require 'subfi_pay'
|
14
|
+
|
15
|
+
instance = SubFiPay::ListPaymentMethodsResponse.new(
|
16
|
+
data: null,
|
17
|
+
meta: null
|
18
|
+
)
|
19
|
+
```
|
20
|
+
|
@@ -0,0 +1,20 @@
|
|
1
|
+
# SubFiPay::ListRefundsResponse
|
2
|
+
|
3
|
+
## Properties
|
4
|
+
|
5
|
+
| Name | Type | Description | Notes |
|
6
|
+
| ---- | ---- | ----------- | ----- |
|
7
|
+
| **data** | [**Array<RefundResponse>**](RefundResponse.md) | | [optional] |
|
8
|
+
| **meta** | [**Meta**](Meta.md) | | [optional] |
|
9
|
+
|
10
|
+
## Example
|
11
|
+
|
12
|
+
```ruby
|
13
|
+
require 'subfi_pay'
|
14
|
+
|
15
|
+
instance = SubFiPay::ListRefundsResponse.new(
|
16
|
+
data: null,
|
17
|
+
meta: null
|
18
|
+
)
|
19
|
+
```
|
20
|
+
|
@@ -0,0 +1,20 @@
|
|
1
|
+
# SubFiPay::ListWebhookEndpointsResponse
|
2
|
+
|
3
|
+
## Properties
|
4
|
+
|
5
|
+
| Name | Type | Description | Notes |
|
6
|
+
| ---- | ---- | ----------- | ----- |
|
7
|
+
| **data** | [**Array<WebhookEndpoint>**](WebhookEndpoint.md) | | [optional] |
|
8
|
+
| **meta** | [**Meta**](Meta.md) | | [optional] |
|
9
|
+
|
10
|
+
## Example
|
11
|
+
|
12
|
+
```ruby
|
13
|
+
require 'subfi_pay'
|
14
|
+
|
15
|
+
instance = SubFiPay::ListWebhookEndpointsResponse.new(
|
16
|
+
data: null,
|
17
|
+
meta: null
|
18
|
+
)
|
19
|
+
```
|
20
|
+
|