conekta 6.0.4 → 6.0.5
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 +9 -5
- data/VERSION +1 -1
- data/config-ruby.json +1 -1
- data/docs/ChargesApi.md +78 -0
- data/docs/ChargesOrderResponse.md +22 -0
- data/docs/ChargesOrderResponseAllOfData.md +52 -0
- data/docs/CheckoutRequest.md +2 -0
- data/docs/Customer.md +4 -0
- data/docs/CustomerResponse.md +4 -0
- data/docs/OrderResponseCheckout.md +2 -0
- data/docs/PaymentMethodCash.md +4 -0
- data/docs/PaymentMethodTokenRequest.md +1 -1
- data/docs/PayoutOrdersApi.md +74 -0
- data/docs/UpdateCustomer.md +4 -0
- data/lib/conekta/api/charges_api.rb +84 -0
- data/lib/conekta/api/payout_orders_api.rb +70 -0
- data/lib/conekta/models/charges_order_response.rb +258 -0
- data/lib/conekta/models/charges_order_response_all_of_data.rb +382 -0
- data/lib/conekta/models/checkout_request.rb +11 -1
- data/lib/conekta/models/customer.rb +21 -1
- data/lib/conekta/models/customer_response.rb +21 -1
- data/lib/conekta/models/order_refund_request.rb +0 -1
- data/lib/conekta/models/order_response_checkout.rb +12 -1
- data/lib/conekta/models/payment_method_cash.rb +21 -1
- data/lib/conekta/models/update_customer.rb +21 -1
- data/lib/conekta/version.rb +1 -1
- data/lib/conekta.rb +2 -0
- metadata +23 -19
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 1e98acb32c3e76886c5a5679dffc113c74c61585c0ee400ab95fcc81e1cb4499
|
4
|
+
data.tar.gz: 879d3c2bf03856ae3998efc4860d9bbf38bb0aceadfe1edee35789b583cf1a12
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 631b7f455552dcb3da143d8ba624ae61d4f7496995ff084a011f2a21c9193acc09afc80588fe2de3d56963b0352598c4d948f84b111e4f392db36180898bf4df
|
7
|
+
data.tar.gz: 7c881ad3460ccb1e832ddb31489ece2069bf3d3b619e5215e738ca3ac81c985bf8efe8d3ef8be99596708ef0e107b97149d26b768b9737f4042bb78d1745859d
|
data/README.md
CHANGED
@@ -7,8 +7,8 @@ Conekta sdk
|
|
7
7
|
This SDK is automatically generated by the [OpenAPI Generator](https://openapi-generator.tech) project:
|
8
8
|
|
9
9
|
- API version: 2.1.0
|
10
|
-
- Package version: 6.0.
|
11
|
-
- Build date:
|
10
|
+
- Package version: 6.0.5
|
11
|
+
- Build date: 2025-02-12T18:24:23.186518636Z[Etc/UTC]
|
12
12
|
- Generator version: 7.5.0
|
13
13
|
- Build package: org.openapitools.codegen.languages.RubyClientCodegen
|
14
14
|
For more information, please visit [https://github.com/conekta/openapi/issues](https://github.com/conekta/openapi/issues)
|
@@ -26,16 +26,16 @@ gem build conekta.gemspec
|
|
26
26
|
Then either install the gem locally:
|
27
27
|
|
28
28
|
```shell
|
29
|
-
gem install ./conekta-6.0.
|
29
|
+
gem install ./conekta-6.0.5.gem
|
30
30
|
```
|
31
31
|
|
32
|
-
(for development, run `gem install --dev ./conekta-6.0.
|
32
|
+
(for development, run `gem install --dev ./conekta-6.0.5.gem` to install the development dependencies)
|
33
33
|
|
34
34
|
or publish the gem to a gem hosting service, e.g. [RubyGems](https://rubygems.org/).
|
35
35
|
|
36
36
|
Finally add this to the Gemfile:
|
37
37
|
|
38
|
-
gem 'conekta', '~> 6.0.
|
38
|
+
gem 'conekta', '~> 6.0.5'
|
39
39
|
|
40
40
|
### Install from Git
|
41
41
|
|
@@ -105,6 +105,7 @@ Class | Method | HTTP request | Description
|
|
105
105
|
*Conekta::BalancesApi* | [**get_balance**](docs/BalancesApi.md#get_balance) | **GET** /balance | Get a company's balance
|
106
106
|
*Conekta::ChargesApi* | [**get_charges**](docs/ChargesApi.md#get_charges) | **GET** /charges | Get A List of Charges
|
107
107
|
*Conekta::ChargesApi* | [**orders_create_charge**](docs/ChargesApi.md#orders_create_charge) | **POST** /orders/{id}/charges | Create charge
|
108
|
+
*Conekta::ChargesApi* | [**orders_create_charges**](docs/ChargesApi.md#orders_create_charges) | **POST** /orders/{id}/add_charges | Create charges
|
108
109
|
*Conekta::ChargesApi* | [**update_charge**](docs/ChargesApi.md#update_charge) | **PUT** /charges/{id} | Update a charge
|
109
110
|
*Conekta::CompaniesApi* | [**get_companies**](docs/CompaniesApi.md#get_companies) | **GET** /companies | Get List of Companies
|
110
111
|
*Conekta::CompaniesApi* | [**get_company**](docs/CompaniesApi.md#get_company) | **GET** /companies/{id} | Get Company
|
@@ -143,6 +144,7 @@ Class | Method | HTTP request | Description
|
|
143
144
|
*Conekta::PaymentMethodsApi* | [**delete_customer_payment_methods**](docs/PaymentMethodsApi.md#delete_customer_payment_methods) | **DELETE** /customers/{id}/payment_sources/{payment_method_id} | Delete Payment Method
|
144
145
|
*Conekta::PaymentMethodsApi* | [**get_customer_payment_methods**](docs/PaymentMethodsApi.md#get_customer_payment_methods) | **GET** /customers/{id}/payment_sources | Get Payment Methods
|
145
146
|
*Conekta::PaymentMethodsApi* | [**update_customer_payment_methods**](docs/PaymentMethodsApi.md#update_customer_payment_methods) | **PUT** /customers/{id}/payment_sources/{payment_method_id} | Update Payment Method
|
147
|
+
*Conekta::PayoutOrdersApi* | [**cancel_payout_order_by_id**](docs/PayoutOrdersApi.md#cancel_payout_order_by_id) | **PUT** /payout_orders/{id}/cancel | Cancel Payout Order
|
146
148
|
*Conekta::PayoutOrdersApi* | [**create_payout_order**](docs/PayoutOrdersApi.md#create_payout_order) | **POST** /payout_orders | Create payout order
|
147
149
|
*Conekta::PayoutOrdersApi* | [**get_payout_order_by_id**](docs/PayoutOrdersApi.md#get_payout_order_by_id) | **GET** /payout_orders/{id} | Get Payout Order
|
148
150
|
*Conekta::PayoutOrdersApi* | [**get_payout_orders**](docs/PayoutOrdersApi.md#get_payout_orders) | **GET** /payout_orders | Get a list of Payout Orders
|
@@ -209,6 +211,8 @@ Class | Method | HTTP request | Description
|
|
209
211
|
- [Conekta::ChargeResponseRefundsData](docs/ChargeResponseRefundsData.md)
|
210
212
|
- [Conekta::ChargeUpdateRequest](docs/ChargeUpdateRequest.md)
|
211
213
|
- [Conekta::ChargesDataResponse](docs/ChargesDataResponse.md)
|
214
|
+
- [Conekta::ChargesOrderResponse](docs/ChargesOrderResponse.md)
|
215
|
+
- [Conekta::ChargesOrderResponseAllOfData](docs/ChargesOrderResponseAllOfData.md)
|
212
216
|
- [Conekta::Checkout](docs/Checkout.md)
|
213
217
|
- [Conekta::CheckoutOrderTemplate](docs/CheckoutOrderTemplate.md)
|
214
218
|
- [Conekta::CheckoutOrderTemplateCustomerInfo](docs/CheckoutOrderTemplateCustomerInfo.md)
|
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
6.0.
|
1
|
+
6.0.5
|
data/config-ruby.json
CHANGED
data/docs/ChargesApi.md
CHANGED
@@ -6,6 +6,7 @@ All URIs are relative to *https://api.conekta.io*
|
|
6
6
|
| ------ | ------------ | ----------- |
|
7
7
|
| [**get_charges**](ChargesApi.md#get_charges) | **GET** /charges | Get A List of Charges |
|
8
8
|
| [**orders_create_charge**](ChargesApi.md#orders_create_charge) | **POST** /orders/{id}/charges | Create charge |
|
9
|
+
| [**orders_create_charges**](ChargesApi.md#orders_create_charges) | **POST** /orders/{id}/add_charges | Create charges |
|
9
10
|
| [**update_charge**](ChargesApi.md#update_charge) | **PUT** /charges/{id} | Update a charge |
|
10
11
|
|
11
12
|
|
@@ -165,6 +166,83 @@ end
|
|
165
166
|
- **Accept**: application/vnd.conekta-v2.1.0+json
|
166
167
|
|
167
168
|
|
169
|
+
## orders_create_charges
|
170
|
+
|
171
|
+
> <ChargesOrderResponse> orders_create_charges(id, charge_request, opts)
|
172
|
+
|
173
|
+
Create charges
|
174
|
+
|
175
|
+
Create charges for an existing orden
|
176
|
+
|
177
|
+
### Examples
|
178
|
+
|
179
|
+
```ruby
|
180
|
+
require 'time'
|
181
|
+
require 'conekta'
|
182
|
+
# setup authorization
|
183
|
+
Conekta.configure do |config|
|
184
|
+
# Configure Bearer authorization: bearerAuth
|
185
|
+
config.access_token = 'YOUR_BEARER_TOKEN'
|
186
|
+
end
|
187
|
+
|
188
|
+
api_instance = Conekta::ChargesApi.new
|
189
|
+
id = '6307a60c41de27127515a575' # String | Identifier of the resource
|
190
|
+
charge_request = Conekta::ChargeRequest.new({payment_method: Conekta::PaymentMethodCardRequest.new({type: 'card | cash | spei', cvc: '198', exp_month: '12', exp_year: '2025', name: 'John Doe', number: '4242424242424242'})}) # ChargeRequest | requested field for a charge
|
191
|
+
opts = {
|
192
|
+
accept_language: 'es', # String | Use for knowing which language to use
|
193
|
+
x_child_company_id: '6441b6376b60c3a638da80af' # String | In the case of a holding company, the company id of the child company to which will process the request.
|
194
|
+
}
|
195
|
+
|
196
|
+
begin
|
197
|
+
# Create charges
|
198
|
+
result = api_instance.orders_create_charges(id, charge_request, opts)
|
199
|
+
p result
|
200
|
+
rescue Conekta::ApiError => e
|
201
|
+
puts "Error when calling ChargesApi->orders_create_charges: #{e}"
|
202
|
+
end
|
203
|
+
```
|
204
|
+
|
205
|
+
#### Using the orders_create_charges_with_http_info variant
|
206
|
+
|
207
|
+
This returns an Array which contains the response data, status code and headers.
|
208
|
+
|
209
|
+
> <Array(<ChargesOrderResponse>, Integer, Hash)> orders_create_charges_with_http_info(id, charge_request, opts)
|
210
|
+
|
211
|
+
```ruby
|
212
|
+
begin
|
213
|
+
# Create charges
|
214
|
+
data, status_code, headers = api_instance.orders_create_charges_with_http_info(id, charge_request, opts)
|
215
|
+
p status_code # => 2xx
|
216
|
+
p headers # => { ... }
|
217
|
+
p data # => <ChargesOrderResponse>
|
218
|
+
rescue Conekta::ApiError => e
|
219
|
+
puts "Error when calling ChargesApi->orders_create_charges_with_http_info: #{e}"
|
220
|
+
end
|
221
|
+
```
|
222
|
+
|
223
|
+
### Parameters
|
224
|
+
|
225
|
+
| Name | Type | Description | Notes |
|
226
|
+
| ---- | ---- | ----------- | ----- |
|
227
|
+
| **id** | **String** | Identifier of the resource | |
|
228
|
+
| **charge_request** | [**ChargeRequest**](ChargeRequest.md) | requested field for a charge | |
|
229
|
+
| **accept_language** | **String** | Use for knowing which language to use | [optional][default to 'es'] |
|
230
|
+
| **x_child_company_id** | **String** | In the case of a holding company, the company id of the child company to which will process the request. | [optional] |
|
231
|
+
|
232
|
+
### Return type
|
233
|
+
|
234
|
+
[**ChargesOrderResponse**](ChargesOrderResponse.md)
|
235
|
+
|
236
|
+
### Authorization
|
237
|
+
|
238
|
+
[bearerAuth](../README.md#bearerAuth)
|
239
|
+
|
240
|
+
### HTTP request headers
|
241
|
+
|
242
|
+
- **Content-Type**: application/json
|
243
|
+
- **Accept**: application/vnd.conekta-v2.1.0+json
|
244
|
+
|
245
|
+
|
168
246
|
## update_charge
|
169
247
|
|
170
248
|
> <ChargeResponse> update_charge(id, charge_update_request, opts)
|
@@ -0,0 +1,22 @@
|
|
1
|
+
# Conekta::ChargesOrderResponse
|
2
|
+
|
3
|
+
## Properties
|
4
|
+
|
5
|
+
| Name | Type | Description | Notes |
|
6
|
+
| ---- | ---- | ----------- | ----- |
|
7
|
+
| **has_more** | **Boolean** | Indicates if there are more pages to be requested | |
|
8
|
+
| **object** | **String** | Object type, in this case is list | |
|
9
|
+
| **data** | [**Array<ChargesOrderResponseAllOfData>**](ChargesOrderResponseAllOfData.md) | | [optional] |
|
10
|
+
|
11
|
+
## Example
|
12
|
+
|
13
|
+
```ruby
|
14
|
+
require 'conekta'
|
15
|
+
|
16
|
+
instance = Conekta::ChargesOrderResponse.new(
|
17
|
+
has_more: false,
|
18
|
+
object: list,
|
19
|
+
data: null
|
20
|
+
)
|
21
|
+
```
|
22
|
+
|
@@ -0,0 +1,52 @@
|
|
1
|
+
# Conekta::ChargesOrderResponseAllOfData
|
2
|
+
|
3
|
+
## Properties
|
4
|
+
|
5
|
+
| Name | Type | Description | Notes |
|
6
|
+
| ---- | ---- | ----------- | ----- |
|
7
|
+
| **amount** | **Integer** | | [optional] |
|
8
|
+
| **channel** | [**ChargeResponseChannel**](ChargeResponseChannel.md) | | [optional] |
|
9
|
+
| **created_at** | **Integer** | | [optional] |
|
10
|
+
| **currency** | **String** | | [optional] |
|
11
|
+
| **customer_id** | **String** | | [optional] |
|
12
|
+
| **description** | **String** | | [optional] |
|
13
|
+
| **device_fingerprint** | **String** | | [optional] |
|
14
|
+
| **failure_code** | **String** | | [optional] |
|
15
|
+
| **failure_message** | **String** | | [optional] |
|
16
|
+
| **id** | **String** | Charge ID | [optional] |
|
17
|
+
| **livemode** | **Boolean** | Whether the charge was made in live mode or not | [optional] |
|
18
|
+
| **object** | **String** | | [optional] |
|
19
|
+
| **order_id** | **String** | Order ID | [optional] |
|
20
|
+
| **paid_at** | **Integer** | Payment date | [optional] |
|
21
|
+
| **payment_method** | [**ChargeResponsePaymentMethod**](ChargeResponsePaymentMethod.md) | | [optional] |
|
22
|
+
| **reference_id** | **String** | Reference ID of the charge | [optional] |
|
23
|
+
| **refunds** | [**ChargeResponseRefunds**](ChargeResponseRefunds.md) | | [optional] |
|
24
|
+
| **status** | **String** | | [optional] |
|
25
|
+
|
26
|
+
## Example
|
27
|
+
|
28
|
+
```ruby
|
29
|
+
require 'conekta'
|
30
|
+
|
31
|
+
instance = Conekta::ChargesOrderResponseAllOfData.new(
|
32
|
+
amount: 4321,
|
33
|
+
channel: null,
|
34
|
+
created_at: 1676386026,
|
35
|
+
currency: MXN,
|
36
|
+
customer_id: null,
|
37
|
+
description: Payment from order,
|
38
|
+
device_fingerprint: 6FR3chaU4Y1nGAW5NAGd1rcjAKa142Ba,
|
39
|
+
failure_code: suspected_fraud,
|
40
|
+
failure_message: Este cargo ha sido declinado porque el comportamiento del comprador es sospechoso.,
|
41
|
+
id: 63efa757cf65380001aec040,
|
42
|
+
livemode: false,
|
43
|
+
object: charge,
|
44
|
+
order_id: ord_2tN73UdUSNrYRPD9r,
|
45
|
+
paid_at: 1676390742,
|
46
|
+
payment_method: null,
|
47
|
+
reference_id: ref_2tN73UdUSNrYRPD9r,
|
48
|
+
refunds: null,
|
49
|
+
status: pending_payment
|
50
|
+
)
|
51
|
+
```
|
52
|
+
|
data/docs/CheckoutRequest.md
CHANGED
@@ -9,6 +9,7 @@
|
|
9
9
|
| **failure_url** | **String** | Redirection url back to the site in case of failed payment, applies only to HostedPayment. | [optional] |
|
10
10
|
| **monthly_installments_enabled** | **Boolean** | | [optional] |
|
11
11
|
| **monthly_installments_options** | **Array<Integer>** | | [optional] |
|
12
|
+
| **max_failed_retries** | **Integer** | Number of retries allowed before the checkout is marked as failed | [optional] |
|
12
13
|
| **name** | **String** | Reason for payment | [optional] |
|
13
14
|
| **on_demand_enabled** | **Boolean** | | [optional] |
|
14
15
|
| **redirection_time** | **Integer** | number of seconds to wait before redirecting to the success_url | [optional] |
|
@@ -26,6 +27,7 @@ instance = Conekta::CheckoutRequest.new(
|
|
26
27
|
failure_url: null,
|
27
28
|
monthly_installments_enabled: false,
|
28
29
|
monthly_installments_options: [3,6,12],
|
30
|
+
max_failed_retries: 3,
|
29
31
|
name: null,
|
30
32
|
on_demand_enabled: true,
|
31
33
|
redirection_time: 10,
|
data/docs/Customer.md
CHANGED
@@ -7,12 +7,14 @@
|
|
7
7
|
| **antifraud_info** | [**CustomerAntifraudInfo**](CustomerAntifraudInfo.md) | | [optional] |
|
8
8
|
| **corporate** | **Boolean** | It is a value that allows identifying if the email is corporate or not. | [optional][default to false] |
|
9
9
|
| **custom_reference** | **String** | It is an undefined value. | [optional] |
|
10
|
+
| **date_of_birth** | **String** | It is a parameter that allows to identify the date of birth of the client. | [optional] |
|
10
11
|
| **email** | **String** | An email address is a series of customizable characters followed by a universal Internet symbol, the at symbol (@), the name of a host server, and a web domain ending (.mx, .com, .org, . net, etc). | |
|
11
12
|
| **default_payment_source_id** | **String** | It is a parameter that allows to identify in the response, the Conekta ID of a payment method (payment_id) | [optional] |
|
12
13
|
| **default_shipping_contact_id** | **String** | It is a parameter that allows to identify in the response, the Conekta ID of the shipping address (shipping_contact) | [optional] |
|
13
14
|
| **fiscal_entities** | [**Array<CustomerFiscalEntitiesRequest>**](CustomerFiscalEntitiesRequest.md) | | [optional] |
|
14
15
|
| **metadata** | **Hash<String, Object>** | | [optional] |
|
15
16
|
| **name** | **String** | Client's name | |
|
17
|
+
| **national_id** | **String** | It is a parameter that allows to identify the national identification number of the client. | [optional] |
|
16
18
|
| **payment_sources** | [**Array<CustomerPaymentMethodsRequest>**](CustomerPaymentMethodsRequest.md) | Contains details of the payment methods that the customer has active or has used in Conekta | [optional] |
|
17
19
|
| **phone** | **String** | Is the customer's phone number | |
|
18
20
|
| **plan_id** | **String** | Contains the ID of a plan, which could together with name, email and phone create a client directly to a subscription | [optional] |
|
@@ -28,12 +30,14 @@ instance = Conekta::Customer.new(
|
|
28
30
|
antifraud_info: null,
|
29
31
|
corporate: false,
|
30
32
|
custom_reference: null,
|
33
|
+
date_of_birth: 24/07/1992,
|
31
34
|
email: miguel@gmail.com,
|
32
35
|
default_payment_source_id: src_1a2b3c4d5e6f7g8h,
|
33
36
|
default_shipping_contact_id: ship_cont_1a2b3c4d5e6f7g8h,
|
34
37
|
fiscal_entities: null,
|
35
38
|
metadata: null,
|
36
39
|
name: miguel,
|
40
|
+
national_id: HEGG560427MVZRRL04,
|
37
41
|
payment_sources: null,
|
38
42
|
phone: +5215555555555,
|
39
43
|
plan_id: plan_987234823,
|
data/docs/CustomerResponse.md
CHANGED
@@ -8,6 +8,7 @@
|
|
8
8
|
| **corporate** | **Boolean** | true if the customer is a company | [optional] |
|
9
9
|
| **created_at** | **Integer** | Creation date of the object | |
|
10
10
|
| **custom_reference** | **String** | Custom reference | [optional] |
|
11
|
+
| **date_of_birth** | **String** | It is a parameter that allows to identify the date of birth of the client. | [optional] |
|
11
12
|
| **default_fiscal_entity_id** | **String** | | [optional] |
|
12
13
|
| **default_shipping_contact_id** | **String** | | [optional] |
|
13
14
|
| **default_payment_source_id** | **String** | | [optional] |
|
@@ -16,6 +17,7 @@
|
|
16
17
|
| **id** | **String** | Customer's ID | |
|
17
18
|
| **livemode** | **Boolean** | true if the object exists in live mode or the value false if the object exists in test mode | |
|
18
19
|
| **name** | **String** | Customer's name | |
|
20
|
+
| **national_id** | **String** | It is a parameter that allows to identify the national identification number of the client. | [optional] |
|
19
21
|
| **metadata** | **Hash<String, Object>** | | [optional] |
|
20
22
|
| **object** | **String** | | |
|
21
23
|
| **payment_sources** | [**CustomerPaymentMethodsResponse**](CustomerPaymentMethodsResponse.md) | | [optional] |
|
@@ -33,6 +35,7 @@ instance = Conekta::CustomerResponse.new(
|
|
33
35
|
corporate: null,
|
34
36
|
created_at: 1485151007,
|
35
37
|
custom_reference: custom_reference,
|
38
|
+
date_of_birth: 24/07/1992,
|
36
39
|
default_fiscal_entity_id: fis_ent_2tKqqAfqPi21oCmEJ,
|
37
40
|
default_shipping_contact_id: ship_cont_2tKZsTYcsryyu7Ah8,
|
38
41
|
default_payment_source_id: src_2tHJfJ79KyUwpxTio,
|
@@ -41,6 +44,7 @@ instance = Conekta::CustomerResponse.new(
|
|
41
44
|
id: cus_2tHJfJ79KyUwpxTik,
|
42
45
|
livemode: true,
|
43
46
|
name: Felipe,
|
47
|
+
national_id: HEGG560427MVZRRL04,
|
44
48
|
metadata: null,
|
45
49
|
object: customer,
|
46
50
|
payment_sources: null,
|
@@ -14,6 +14,7 @@
|
|
14
14
|
| **id** | **String** | | [optional] |
|
15
15
|
| **is_redirect_on_failure** | **Boolean** | | [optional] |
|
16
16
|
| **livemode** | **Boolean** | | [optional] |
|
17
|
+
| **max_failed_retries** | **Integer** | Number of retries allowed before the checkout is marked as failed | [optional] |
|
17
18
|
| **metadata** | **Hash<String, Object>** | | [optional] |
|
18
19
|
| **monthly_installments_enabled** | **Boolean** | | [optional] |
|
19
20
|
| **monthly_installments_options** | **Array<Integer>** | | [optional] |
|
@@ -48,6 +49,7 @@ instance = Conekta::OrderResponseCheckout.new(
|
|
48
49
|
id: 6fca054a-8519-4c43-971e-cea35cc519bb,
|
49
50
|
is_redirect_on_failure: false,
|
50
51
|
livemode: false,
|
52
|
+
max_failed_retries: 3,
|
51
53
|
metadata: null,
|
52
54
|
monthly_installments_enabled: false,
|
53
55
|
monthly_installments_options: null,
|
data/docs/PaymentMethodCash.md
CHANGED
@@ -6,11 +6,13 @@
|
|
6
6
|
| ---- | ---- | ----------- | ----- |
|
7
7
|
| **type** | **String** | | [optional] |
|
8
8
|
| **object** | **String** | | |
|
9
|
+
| **agreement** | **String** | Agreement ID | [optional] |
|
9
10
|
| **auth_code** | **Integer** | | [optional] |
|
10
11
|
| **cashier_id** | **String** | | [optional] |
|
11
12
|
| **reference** | **String** | | [optional] |
|
12
13
|
| **barcode_url** | **String** | | [optional] |
|
13
14
|
| **expires_at** | **Integer** | | [optional] |
|
15
|
+
| **product_type** | **String** | Product type, e.g. bbva_cash_in, cash_in, pespay_cash_in, etc. | [optional] |
|
14
16
|
| **service_name** | **String** | | [optional] |
|
15
17
|
| **store** | **String** | | [optional] |
|
16
18
|
| **store_name** | **String** | | [optional] |
|
@@ -24,11 +26,13 @@ require 'conekta'
|
|
24
26
|
instance = Conekta::PaymentMethodCash.new(
|
25
27
|
type: null,
|
26
28
|
object: payment_source,
|
29
|
+
agreement: agreement_2tN73UdUSNrYRPD9r,
|
27
30
|
auth_code: 542563,
|
28
31
|
cashier_id: OINM01010,
|
29
32
|
reference: 93000262276908,
|
30
33
|
barcode_url: https://pt-common-s3-stg.s3.amazonaws.com/644ebf80f2243197aad6cd8810375b905b613dbe.png?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=ASIA3UN6375MP4SLLCWV%2F20230203%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20230203T215750Z&X-Amz-Expires=604800&X-Amz-Security-Token=IQoJb3JpZ2luX2VjEH4aCXVzLWVhc3QtMSJGMEQCICd79cu7DYu%2F4%2B3HnVVswydgU9yHcE9kmQIIk2TLoZJrAiBVZ0HxVSeboK5lhdQSqADjwQF62XX35jhC%2F2riB0M8uCqQBAj2%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F8BEAIaDDc5OTgwMTA4MTY4OCIMXWZds9ZI5hzUdbeGKuQDFreMyeWnWWPqDuGZ2%2BHk6usCr%2Fl096%2FNJh9xtf8htLu56K%2FhWUTx%2BjiqFWM2O%2FF5zTS%2BIV6TqkLDZ%2BQ5Jo1miQrRmR57YDz6uP2Yd1mNZ1ouq5ipnNjUuu5UWCCBAmqyZQsrVmeMQpSV2IB%2BTERCCcW2SukFEYU%2F20%2Fzy5orsoZ8DxOW460IymR3cWBk5u3Xh2cV6Y1RdPEwDEThhqYEF5w%2ByKbLENloMsI%2FUm6sG5PPrO3yQOAP9aK2muLJs9lXQRU%2FL%2FSsmS4FKSUFOqlN6YU%2Bi2Y%2FyGIKAJT2VDkngvz5Sl%2Fadj0j%2BPKftVRV5FcEhySB6Rl%2BSkPN7kVQMJp6pS8hMJ6JCyEA%2BA3eWYdIfKgQhWVXAR4oCBfJ62DH8FU3a7WfSjjpTwfVkiReWen3GGCYfUWETTVKp46MKnJ9PG0CD3KzxKV8VfmEGc5krK%2FI%2F%2BDV2wtSa%2F9qf1%2BK1YYJIK9qZGb25ljUiGhTB4T%2BMUOSQFjetiWUoOJc5Q3Jz%2FXJbiTAMTST39MhdbCgiMgfrc8OGKN5DOVbex33Z7dn0xf%2FOCkSqurhLaG08efKQBdhLNS0RlE9hbg9yZ2ywwtQIF39fI6A7eeH0T11a5HMlvm51u4rAffPHRuEJfwJoIuj%2F2s3QzDg7%2FWeBjqmAbnPOlGfysjrDdvHyG7HVnaX02kdG%2BI3Q4PFOO4Mjaa3ocpjcfPT70%2BZ5a%2FSv5vP0jDLGrLToeM9%2BAUlNepptICRu23a1tLGW4ri0twPA%2FZ4JDTtUUUgdblyG8bKpcUTNp4oOsdmLLBz3FVyr4c2xQbDZSu2zYOtoOxB18W0AC6kIbsMWVU55Bf0mBhPeBWxGrtM4Kw1SgHHlt%2F8vetQi2OwtUcg08c%3D&X-Amz-SignedHeaders=host&X-Amz-Signature=d06dfa41550003359f2aabc8006063a80dfd806a13a54d244024946a76aa9abc,
|
31
34
|
expires_at: 0,
|
35
|
+
product_type: bbva_cash_in,
|
32
36
|
service_name: OxxoPay,
|
33
37
|
store: 10MON50EDI,
|
34
38
|
store_name: OXXO,
|
data/docs/PayoutOrdersApi.md
CHANGED
@@ -4,11 +4,85 @@ All URIs are relative to *https://api.conekta.io*
|
|
4
4
|
|
5
5
|
| Method | HTTP request | Description |
|
6
6
|
| ------ | ------------ | ----------- |
|
7
|
+
| [**cancel_payout_order_by_id**](PayoutOrdersApi.md#cancel_payout_order_by_id) | **PUT** /payout_orders/{id}/cancel | Cancel Payout Order |
|
7
8
|
| [**create_payout_order**](PayoutOrdersApi.md#create_payout_order) | **POST** /payout_orders | Create payout order |
|
8
9
|
| [**get_payout_order_by_id**](PayoutOrdersApi.md#get_payout_order_by_id) | **GET** /payout_orders/{id} | Get Payout Order |
|
9
10
|
| [**get_payout_orders**](PayoutOrdersApi.md#get_payout_orders) | **GET** /payout_orders | Get a list of Payout Orders |
|
10
11
|
|
11
12
|
|
13
|
+
## cancel_payout_order_by_id
|
14
|
+
|
15
|
+
> <PayoutOrderResponse> cancel_payout_order_by_id(id, opts)
|
16
|
+
|
17
|
+
Cancel Payout Order
|
18
|
+
|
19
|
+
Cancel a payout Order resource that corresponds to a payout order ID.
|
20
|
+
|
21
|
+
### Examples
|
22
|
+
|
23
|
+
```ruby
|
24
|
+
require 'time'
|
25
|
+
require 'conekta'
|
26
|
+
# setup authorization
|
27
|
+
Conekta.configure do |config|
|
28
|
+
# Configure Bearer authorization: bearerAuth
|
29
|
+
config.access_token = 'YOUR_BEARER_TOKEN'
|
30
|
+
end
|
31
|
+
|
32
|
+
api_instance = Conekta::PayoutOrdersApi.new
|
33
|
+
id = '6307a60c41de27127515a575' # String | Identifier of the resource
|
34
|
+
opts = {
|
35
|
+
accept_language: 'es' # String | Use for knowing which language to use
|
36
|
+
}
|
37
|
+
|
38
|
+
begin
|
39
|
+
# Cancel Payout Order
|
40
|
+
result = api_instance.cancel_payout_order_by_id(id, opts)
|
41
|
+
p result
|
42
|
+
rescue Conekta::ApiError => e
|
43
|
+
puts "Error when calling PayoutOrdersApi->cancel_payout_order_by_id: #{e}"
|
44
|
+
end
|
45
|
+
```
|
46
|
+
|
47
|
+
#### Using the cancel_payout_order_by_id_with_http_info variant
|
48
|
+
|
49
|
+
This returns an Array which contains the response data, status code and headers.
|
50
|
+
|
51
|
+
> <Array(<PayoutOrderResponse>, Integer, Hash)> cancel_payout_order_by_id_with_http_info(id, opts)
|
52
|
+
|
53
|
+
```ruby
|
54
|
+
begin
|
55
|
+
# Cancel Payout Order
|
56
|
+
data, status_code, headers = api_instance.cancel_payout_order_by_id_with_http_info(id, opts)
|
57
|
+
p status_code # => 2xx
|
58
|
+
p headers # => { ... }
|
59
|
+
p data # => <PayoutOrderResponse>
|
60
|
+
rescue Conekta::ApiError => e
|
61
|
+
puts "Error when calling PayoutOrdersApi->cancel_payout_order_by_id_with_http_info: #{e}"
|
62
|
+
end
|
63
|
+
```
|
64
|
+
|
65
|
+
### Parameters
|
66
|
+
|
67
|
+
| Name | Type | Description | Notes |
|
68
|
+
| ---- | ---- | ----------- | ----- |
|
69
|
+
| **id** | **String** | Identifier of the resource | |
|
70
|
+
| **accept_language** | **String** | Use for knowing which language to use | [optional][default to 'es'] |
|
71
|
+
|
72
|
+
### Return type
|
73
|
+
|
74
|
+
[**PayoutOrderResponse**](PayoutOrderResponse.md)
|
75
|
+
|
76
|
+
### Authorization
|
77
|
+
|
78
|
+
[bearerAuth](../README.md#bearerAuth)
|
79
|
+
|
80
|
+
### HTTP request headers
|
81
|
+
|
82
|
+
- **Content-Type**: Not defined
|
83
|
+
- **Accept**: application/vnd.conekta-v2.1.0+json
|
84
|
+
|
85
|
+
|
12
86
|
## create_payout_order
|
13
87
|
|
14
88
|
> <PayoutOrderResponse> create_payout_order(payout_order, opts)
|
data/docs/UpdateCustomer.md
CHANGED
@@ -5,6 +5,7 @@
|
|
5
5
|
| Name | Type | Description | Notes |
|
6
6
|
| ---- | ---- | ----------- | ----- |
|
7
7
|
| **antifraud_info** | [**UpdateCustomerAntifraudInfo**](UpdateCustomerAntifraudInfo.md) | | [optional] |
|
8
|
+
| **date_of_birth** | **String** | It is a parameter that allows to identify the date of birth of the client. | [optional] |
|
8
9
|
| **default_payment_source_id** | **String** | It is a parameter that allows to identify in the response, the Conekta ID of a payment method (payment_id) | [optional] |
|
9
10
|
| **email** | **String** | An email address is a series of customizable characters followed by a universal Internet symbol, the at symbol (@), the name of a host server, and a web domain ending (.mx, .com, .org, . net, etc). | [optional] |
|
10
11
|
| **name** | **String** | Client's name | [optional] |
|
@@ -15,6 +16,7 @@
|
|
15
16
|
| **custom_reference** | **String** | It is an undefined value. | [optional] |
|
16
17
|
| **fiscal_entities** | [**Array<CustomerFiscalEntitiesRequest>**](CustomerFiscalEntitiesRequest.md) | | [optional] |
|
17
18
|
| **metadata** | **Hash<String, Object>** | | [optional] |
|
19
|
+
| **national_id** | **String** | It is a parameter that allows to identify the national identification number of the client. | [optional] |
|
18
20
|
| **payment_sources** | [**Array<CustomerPaymentMethodsRequest>**](CustomerPaymentMethodsRequest.md) | Contains details of the payment methods that the customer has active or has used in Conekta | [optional] |
|
19
21
|
| **shipping_contacts** | [**Array<CustomerShippingContacts>**](CustomerShippingContacts.md) | Contains the detail of the shipping addresses that the client has active or has used in Conekta | [optional] |
|
20
22
|
| **subscription** | [**SubscriptionRequest**](SubscriptionRequest.md) | | [optional] |
|
@@ -26,6 +28,7 @@ require 'conekta'
|
|
26
28
|
|
27
29
|
instance = Conekta::UpdateCustomer.new(
|
28
30
|
antifraud_info: null,
|
31
|
+
date_of_birth: 24/07/1992,
|
29
32
|
default_payment_source_id: src_1a2b3c4d5e6f7g8h,
|
30
33
|
email: miguel@gmail.com,
|
31
34
|
name: miguel,
|
@@ -36,6 +39,7 @@ instance = Conekta::UpdateCustomer.new(
|
|
36
39
|
custom_reference: null,
|
37
40
|
fiscal_entities: null,
|
38
41
|
metadata: null,
|
42
|
+
national_id: HEGG560427MVZRRL04,
|
39
43
|
payment_sources: null,
|
40
44
|
shipping_contacts: null,
|
41
45
|
subscription: null
|
@@ -188,6 +188,90 @@ module Conekta
|
|
188
188
|
return data, status_code, headers
|
189
189
|
end
|
190
190
|
|
191
|
+
# Create charges
|
192
|
+
# Create charges for an existing orden
|
193
|
+
# @param id [String] Identifier of the resource
|
194
|
+
# @param charge_request [ChargeRequest] requested field for a charge
|
195
|
+
# @param [Hash] opts the optional parameters
|
196
|
+
# @option opts [String] :accept_language Use for knowing which language to use (default to 'es')
|
197
|
+
# @option opts [String] :x_child_company_id In the case of a holding company, the company id of the child company to which will process the request.
|
198
|
+
# @return [ChargesOrderResponse]
|
199
|
+
def orders_create_charges(id, charge_request, opts = {})
|
200
|
+
data, _status_code, _headers = orders_create_charges_with_http_info(id, charge_request, opts)
|
201
|
+
data
|
202
|
+
end
|
203
|
+
|
204
|
+
# Create charges
|
205
|
+
# Create charges for an existing orden
|
206
|
+
# @param id [String] Identifier of the resource
|
207
|
+
# @param charge_request [ChargeRequest] requested field for a charge
|
208
|
+
# @param [Hash] opts the optional parameters
|
209
|
+
# @option opts [String] :accept_language Use for knowing which language to use (default to 'es')
|
210
|
+
# @option opts [String] :x_child_company_id In the case of a holding company, the company id of the child company to which will process the request.
|
211
|
+
# @return [Array<(ChargesOrderResponse, Integer, Hash)>] ChargesOrderResponse data, response status code and response headers
|
212
|
+
def orders_create_charges_with_http_info(id, charge_request, opts = {})
|
213
|
+
if @api_client.config.debugging
|
214
|
+
@api_client.config.logger.debug 'Calling API: ChargesApi.orders_create_charges ...'
|
215
|
+
end
|
216
|
+
# verify the required parameter 'id' is set
|
217
|
+
if @api_client.config.client_side_validation && id.nil?
|
218
|
+
fail ArgumentError, "Missing the required parameter 'id' when calling ChargesApi.orders_create_charges"
|
219
|
+
end
|
220
|
+
# verify the required parameter 'charge_request' is set
|
221
|
+
if @api_client.config.client_side_validation && charge_request.nil?
|
222
|
+
fail ArgumentError, "Missing the required parameter 'charge_request' when calling ChargesApi.orders_create_charges"
|
223
|
+
end
|
224
|
+
allowable_values = ["es", "en"]
|
225
|
+
if @api_client.config.client_side_validation && opts[:'accept_language'] && !allowable_values.include?(opts[:'accept_language'])
|
226
|
+
fail ArgumentError, "invalid value for \"accept_language\", must be one of #{allowable_values}"
|
227
|
+
end
|
228
|
+
# resource path
|
229
|
+
local_var_path = '/orders/{id}/add_charges'.sub('{' + 'id' + '}', CGI.escape(id.to_s))
|
230
|
+
|
231
|
+
# query parameters
|
232
|
+
query_params = opts[:query_params] || {}
|
233
|
+
|
234
|
+
# header parameters
|
235
|
+
header_params = opts[:header_params] || {}
|
236
|
+
# HTTP header 'Accept' (if needed)
|
237
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/vnd.conekta-v2.1.0+json'])
|
238
|
+
# HTTP header 'Content-Type'
|
239
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
240
|
+
if !content_type.nil?
|
241
|
+
header_params['Content-Type'] = content_type
|
242
|
+
end
|
243
|
+
header_params[:'Accept-Language'] = opts[:'accept_language'] if !opts[:'accept_language'].nil?
|
244
|
+
header_params[:'X-Child-Company-Id'] = opts[:'x_child_company_id'] if !opts[:'x_child_company_id'].nil?
|
245
|
+
|
246
|
+
# form parameters
|
247
|
+
form_params = opts[:form_params] || {}
|
248
|
+
|
249
|
+
# http body (model)
|
250
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(charge_request)
|
251
|
+
|
252
|
+
# return_type
|
253
|
+
return_type = opts[:debug_return_type] || 'ChargesOrderResponse'
|
254
|
+
|
255
|
+
# auth_names
|
256
|
+
auth_names = opts[:debug_auth_names] || ['bearerAuth']
|
257
|
+
|
258
|
+
new_options = opts.merge(
|
259
|
+
:operation => :"ChargesApi.orders_create_charges",
|
260
|
+
:header_params => header_params,
|
261
|
+
:query_params => query_params,
|
262
|
+
:form_params => form_params,
|
263
|
+
:body => post_body,
|
264
|
+
:auth_names => auth_names,
|
265
|
+
:return_type => return_type
|
266
|
+
)
|
267
|
+
|
268
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
269
|
+
if @api_client.config.debugging
|
270
|
+
@api_client.config.logger.debug "API called: ChargesApi#orders_create_charges\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
271
|
+
end
|
272
|
+
return data, status_code, headers
|
273
|
+
end
|
274
|
+
|
191
275
|
# Update a charge
|
192
276
|
# @param id [String] Identifier of the resource
|
193
277
|
# @param charge_update_request [ChargeUpdateRequest] requested field for update a charge
|