All URIs are relative to https://api.conekta.io
Method | HTTP request | Description |
---|---|---|
cancelOrder | POST /orders/{id}/cancel | Cancel Order |
createOrder | POST /orders | Create order |
getOrderById | GET /orders/{id} | Get Order |
getOrders | GET /orders | Get a list of Orders |
orderCancelRefund | DELETE /orders/{id}/refunds/{refund_id} | Cancel Refund |
orderRefund | POST /orders/{id}/refunds | Refund Order |
ordersCreateCapture | POST /orders/{id}/capture | Capture Order |
updateOrder | PUT /orders/{id} | Update Order |
OrderResponse cancelOrder(id, acceptLanguage, xChildCompanyId)
Cancel Order
Cancel an order that has been previously created.
// Import classes:
import com.conekta.ApiClient;
import com.conekta.ApiException;
import com.conekta.Configuration;
import com.conekta.auth.*;
import com.conekta.model.*;
import com.conekta.OrdersApi;
public class Example {
public static void main(String[] args) {
ApiClient defaultClient = Configuration.getDefaultApiClient();
defaultClient.setBasePath("https://api.conekta.io");
// Configure HTTP bearer authorization: bearerAuth
HttpBearerAuth bearerAuth = (HttpBearerAuth) defaultClient.getAuthentication("bearerAuth");
bearerAuth.setBearerToken("BEARER TOKEN");
OrdersApi apiInstance = new OrdersApi(defaultClient);
String id = "6307a60c41de27127515a575"; // String | Identifier of the resource
String acceptLanguage = "es"; // String | Use for knowing which language to use
String xChildCompanyId = "6441b6376b60c3a638da80af"; // String | In the case of a holding company, the company id of the child company to which will process the request.
try {
OrderResponse result = apiInstance.cancelOrder(id, acceptLanguage, xChildCompanyId);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling OrdersApi#cancelOrder");
System.err.println("Status code: " + e.getCode());
System.err.println("Reason: " + e.getResponseBody());
System.err.println("Response headers: " + e.getResponseHeaders());
e.printStackTrace();
}
}
}
Name | Type | Description | Notes |
---|---|---|---|
id | String | Identifier of the resource | |
acceptLanguage | String | Use for knowing which language to use | [optional] [default to es] [enum: es, en] |
xChildCompanyId | String | In the case of a holding company, the company id of the child company to which will process the request. | [optional] |
- Content-Type: Not defined
- Accept: application/vnd.conekta-v2.1.0+json
Status code | Description | Response headers |
---|---|---|
200 | successful | - |
401 | authentication error | - |
402 | payment required error | - |
404 | not found entity | - |
428 | Precondition Required | - |
500 | internal server error | - |
OrderResponse createOrder(orderRequest, acceptLanguage, xChildCompanyId)
Create order
Create a new order.
// Import classes:
import com.conekta.ApiClient;
import com.conekta.ApiException;
import com.conekta.Configuration;
import com.conekta.auth.*;
import com.conekta.model.*;
import com.conekta.OrdersApi;
public class Example {
public static void main(String[] args) {
ApiClient defaultClient = Configuration.getDefaultApiClient();
defaultClient.setBasePath("https://api.conekta.io");
// Configure HTTP bearer authorization: bearerAuth
HttpBearerAuth bearerAuth = (HttpBearerAuth) defaultClient.getAuthentication("bearerAuth");
bearerAuth.setBearerToken("BEARER TOKEN");
OrdersApi apiInstance = new OrdersApi(defaultClient);
OrderRequest orderRequest = new OrderRequest(); // OrderRequest | requested field for order
String acceptLanguage = "es"; // String | Use for knowing which language to use
String xChildCompanyId = "6441b6376b60c3a638da80af"; // String | In the case of a holding company, the company id of the child company to which will process the request.
try {
OrderResponse result = apiInstance.createOrder(orderRequest, acceptLanguage, xChildCompanyId);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling OrdersApi#createOrder");
System.err.println("Status code: " + e.getCode());
System.err.println("Reason: " + e.getResponseBody());
System.err.println("Response headers: " + e.getResponseHeaders());
e.printStackTrace();
}
}
}
Name | Type | Description | Notes |
---|---|---|---|
orderRequest | OrderRequest | requested field for order | |
acceptLanguage | String | Use for knowing which language to use | [optional] [default to es] [enum: es, en] |
xChildCompanyId | String | In the case of a holding company, the company id of the child company to which will process the request. | [optional] |
- Content-Type: application/json
- Accept: application/vnd.conekta-v2.1.0+json
Status code | Description | Response headers |
---|---|---|
200 | successful operation | - |
422 | parameter validation error | - |
401 | authentication error | - |
402 | payment required error | - |
500 | internal server error | - |
OrderResponse getOrderById(id, acceptLanguage, xChildCompanyId)
Get Order
Info for a specific order
// Import classes:
import com.conekta.ApiClient;
import com.conekta.ApiException;
import com.conekta.Configuration;
import com.conekta.auth.*;
import com.conekta.model.*;
import com.conekta.OrdersApi;
public class Example {
public static void main(String[] args) {
ApiClient defaultClient = Configuration.getDefaultApiClient();
defaultClient.setBasePath("https://api.conekta.io");
// Configure HTTP bearer authorization: bearerAuth
HttpBearerAuth bearerAuth = (HttpBearerAuth) defaultClient.getAuthentication("bearerAuth");
bearerAuth.setBearerToken("BEARER TOKEN");
OrdersApi apiInstance = new OrdersApi(defaultClient);
String id = "6307a60c41de27127515a575"; // String | Identifier of the resource
String acceptLanguage = "es"; // String | Use for knowing which language to use
String xChildCompanyId = "6441b6376b60c3a638da80af"; // String | In the case of a holding company, the company id of the child company to which will process the request.
try {
OrderResponse result = apiInstance.getOrderById(id, acceptLanguage, xChildCompanyId);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling OrdersApi#getOrderById");
System.err.println("Status code: " + e.getCode());
System.err.println("Reason: " + e.getResponseBody());
System.err.println("Response headers: " + e.getResponseHeaders());
e.printStackTrace();
}
}
}
Name | Type | Description | Notes |
---|---|---|---|
id | String | Identifier of the resource | |
acceptLanguage | String | Use for knowing which language to use | [optional] [default to es] [enum: es, en] |
xChildCompanyId | String | In the case of a holding company, the company id of the child company to which will process the request. | [optional] |
- Content-Type: Not defined
- Accept: application/vnd.conekta-v2.1.0+json
Status code | Description | Response headers |
---|---|---|
200 | successful | - |
401 | authentication error | - |
404 | not found entity | - |
500 | internal server error | - |
GetOrdersResponse getOrders(acceptLanguage, xChildCompanyId, limit, search, next, previous, paymentStatus, lastPaymentInfoStatus, createdAt, createdAtGte, createdAtLte, updatedAtGte, updatedAtLte)
Get a list of Orders
Get order details in the form of a list
// Import classes:
import com.conekta.ApiClient;
import com.conekta.ApiException;
import com.conekta.Configuration;
import com.conekta.auth.*;
import com.conekta.model.*;
import com.conekta.OrdersApi;
public class Example {
public static void main(String[] args) {
ApiClient defaultClient = Configuration.getDefaultApiClient();
defaultClient.setBasePath("https://api.conekta.io");
// Configure HTTP bearer authorization: bearerAuth
HttpBearerAuth bearerAuth = (HttpBearerAuth) defaultClient.getAuthentication("bearerAuth");
bearerAuth.setBearerToken("BEARER TOKEN");
OrdersApi apiInstance = new OrdersApi(defaultClient);
String acceptLanguage = "es"; // String | Use for knowing which language to use
String xChildCompanyId = "6441b6376b60c3a638da80af"; // String | In the case of a holding company, the company id of the child company to which will process the request.
Integer limit = 20; // Integer | The numbers of items to return, the maximum value is 250
String search = "search_example"; // String | General order search, e.g. by mail, reference etc.
String next = "next_example"; // String | next page
String previous = "previous_example"; // String | previous page
String paymentStatus = "paid"; // String | Filters by order status
String lastPaymentInfoStatus = "pending_payment"; // String | Filters by last payment info status
Long createdAt = 1612137600L; // Long | created equal to
Long createdAtGte = 1612137600L; // Long | created at greater than or equal to
Long createdAtLte = 1612137600L; // Long | created at less than or equal to
Long updatedAtGte = 1612137600L; // Long | updated at greater than or equal to
Long updatedAtLte = 1612137600L; // Long | updated at less than or equal to
try {
GetOrdersResponse result = apiInstance.getOrders(acceptLanguage, xChildCompanyId, limit, search, next, previous, paymentStatus, lastPaymentInfoStatus, createdAt, createdAtGte, createdAtLte, updatedAtGte, updatedAtLte);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling OrdersApi#getOrders");
System.err.println("Status code: " + e.getCode());
System.err.println("Reason: " + e.getResponseBody());
System.err.println("Response headers: " + e.getResponseHeaders());
e.printStackTrace();
}
}
}
Name | Type | Description | Notes |
---|---|---|---|
acceptLanguage | String | Use for knowing which language to use | [optional] [default to es] [enum: es, en] |
xChildCompanyId | String | In the case of a holding company, the company id of the child company to which will process the request. | [optional] |
limit | Integer | The numbers of items to return, the maximum value is 250 | [optional] [default to 20] |
search | String | General order search, e.g. by mail, reference etc. | [optional] |
next | String | next page | [optional] |
previous | String | previous page | [optional] |
paymentStatus | String | Filters by order status | [optional] |
lastPaymentInfoStatus | String | Filters by last payment info status | [optional] |
createdAt | Long | created equal to | [optional] |
createdAtGte | Long | created at greater than or equal to | [optional] |
createdAtLte | Long | created at less than or equal to | [optional] |
updatedAtGte | Long | updated at greater than or equal to | [optional] |
updatedAtLte | Long | updated at less than or equal to | [optional] |
- Content-Type: Not defined
- Accept: application/vnd.conekta-v2.1.0+json
Status code | Description | Response headers |
---|---|---|
200 | successful operation | - |
401 | authentication error | - |
500 | internal server error | - |
OrderResponse orderCancelRefund(id, refundId, acceptLanguage, xChildCompanyId)
Cancel Refund
A refunded order describes the items, amount, and reason an order is being refunded.
// Import classes:
import com.conekta.ApiClient;
import com.conekta.ApiException;
import com.conekta.Configuration;
import com.conekta.auth.*;
import com.conekta.model.*;
import com.conekta.OrdersApi;
public class Example {
public static void main(String[] args) {
ApiClient defaultClient = Configuration.getDefaultApiClient();
defaultClient.setBasePath("https://api.conekta.io");
// Configure HTTP bearer authorization: bearerAuth
HttpBearerAuth bearerAuth = (HttpBearerAuth) defaultClient.getAuthentication("bearerAuth");
bearerAuth.setBearerToken("BEARER TOKEN");
OrdersApi apiInstance = new OrdersApi(defaultClient);
String id = "6307a60c41de27127515a575"; // String | Identifier of the resource
String refundId = "6407b5bee1329a000175ba11"; // String | refund identifier
String acceptLanguage = "es"; // String | Use for knowing which language to use
String xChildCompanyId = "6441b6376b60c3a638da80af"; // String | In the case of a holding company, the company id of the child company to which will process the request.
try {
OrderResponse result = apiInstance.orderCancelRefund(id, refundId, acceptLanguage, xChildCompanyId);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling OrdersApi#orderCancelRefund");
System.err.println("Status code: " + e.getCode());
System.err.println("Reason: " + e.getResponseBody());
System.err.println("Response headers: " + e.getResponseHeaders());
e.printStackTrace();
}
}
}
Name | Type | Description | Notes |
---|---|---|---|
id | String | Identifier of the resource | |
refundId | String | refund identifier | |
acceptLanguage | String | Use for knowing which language to use | [optional] [default to es] [enum: es, en] |
xChildCompanyId | String | In the case of a holding company, the company id of the child company to which will process the request. | [optional] |
- Content-Type: Not defined
- Accept: application/vnd.conekta-v2.1.0+json
Status code | Description | Response headers |
---|---|---|
200 | successful | - |
401 | authentication error | - |
402 | payment required error | - |
404 | not found entity | - |
422 | parameter validation error | - |
500 | internal server error | - |
OrderResponse orderRefund(id, orderRefundRequest, acceptLanguage, xChildCompanyId)
Refund Order
A refunded order describes the items, amount, and reason an order is being refunded.
// Import classes:
import com.conekta.ApiClient;
import com.conekta.ApiException;
import com.conekta.Configuration;
import com.conekta.auth.*;
import com.conekta.model.*;
import com.conekta.OrdersApi;
public class Example {
public static void main(String[] args) {
ApiClient defaultClient = Configuration.getDefaultApiClient();
defaultClient.setBasePath("https://api.conekta.io");
// Configure HTTP bearer authorization: bearerAuth
HttpBearerAuth bearerAuth = (HttpBearerAuth) defaultClient.getAuthentication("bearerAuth");
bearerAuth.setBearerToken("BEARER TOKEN");
OrdersApi apiInstance = new OrdersApi(defaultClient);
String id = "6307a60c41de27127515a575"; // String | Identifier of the resource
OrderRefundRequest orderRefundRequest = new OrderRefundRequest(); // OrderRefundRequest | requested field for a refund
String acceptLanguage = "es"; // String | Use for knowing which language to use
String xChildCompanyId = "6441b6376b60c3a638da80af"; // String | In the case of a holding company, the company id of the child company to which will process the request.
try {
OrderResponse result = apiInstance.orderRefund(id, orderRefundRequest, acceptLanguage, xChildCompanyId);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling OrdersApi#orderRefund");
System.err.println("Status code: " + e.getCode());
System.err.println("Reason: " + e.getResponseBody());
System.err.println("Response headers: " + e.getResponseHeaders());
e.printStackTrace();
}
}
}
Name | Type | Description | Notes |
---|---|---|---|
id | String | Identifier of the resource | |
orderRefundRequest | OrderRefundRequest | requested field for a refund | |
acceptLanguage | String | Use for knowing which language to use | [optional] [default to es] [enum: es, en] |
xChildCompanyId | String | In the case of a holding company, the company id of the child company to which will process the request. | [optional] |
- Content-Type: application/json
- Accept: application/vnd.conekta-v2.1.0+json
Status code | Description | Response headers |
---|---|---|
200 | successful | - |
401 | authentication error | - |
402 | payment required error | - |
404 | not found entity | - |
422 | parameter validation error | - |
500 | internal server error | - |
OrderResponse ordersCreateCapture(id, acceptLanguage, xChildCompanyId, orderCaptureRequest)
Capture Order
Processes an order that has been previously authorized.
// Import classes:
import com.conekta.ApiClient;
import com.conekta.ApiException;
import com.conekta.Configuration;
import com.conekta.auth.*;
import com.conekta.model.*;
import com.conekta.OrdersApi;
public class Example {
public static void main(String[] args) {
ApiClient defaultClient = Configuration.getDefaultApiClient();
defaultClient.setBasePath("https://api.conekta.io");
// Configure HTTP bearer authorization: bearerAuth
HttpBearerAuth bearerAuth = (HttpBearerAuth) defaultClient.getAuthentication("bearerAuth");
bearerAuth.setBearerToken("BEARER TOKEN");
OrdersApi apiInstance = new OrdersApi(defaultClient);
String id = "6307a60c41de27127515a575"; // String | Identifier of the resource
String acceptLanguage = "es"; // String | Use for knowing which language to use
String xChildCompanyId = "6441b6376b60c3a638da80af"; // String | In the case of a holding company, the company id of the child company to which will process the request.
OrderCaptureRequest orderCaptureRequest = new OrderCaptureRequest(); // OrderCaptureRequest | requested fields for capture order
try {
OrderResponse result = apiInstance.ordersCreateCapture(id, acceptLanguage, xChildCompanyId, orderCaptureRequest);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling OrdersApi#ordersCreateCapture");
System.err.println("Status code: " + e.getCode());
System.err.println("Reason: " + e.getResponseBody());
System.err.println("Response headers: " + e.getResponseHeaders());
e.printStackTrace();
}
}
}
Name | Type | Description | Notes |
---|---|---|---|
id | String | Identifier of the resource | |
acceptLanguage | String | Use for knowing which language to use | [optional] [default to es] [enum: es, en] |
xChildCompanyId | String | In the case of a holding company, the company id of the child company to which will process the request. | [optional] |
orderCaptureRequest | OrderCaptureRequest | requested fields for capture order | [optional] |
- Content-Type: application/json
- Accept: application/vnd.conekta-v2.1.0+json
Status code | Description | Response headers |
---|---|---|
200 | successful | - |
401 | authentication error | - |
404 | not found entity | - |
428 | Precondition Required | - |
500 | internal server error | - |
OrderResponse updateOrder(id, orderUpdateRequest, acceptLanguage)
Update Order
Update an existing Order.
// Import classes:
import com.conekta.ApiClient;
import com.conekta.ApiException;
import com.conekta.Configuration;
import com.conekta.auth.*;
import com.conekta.model.*;
import com.conekta.OrdersApi;
public class Example {
public static void main(String[] args) {
ApiClient defaultClient = Configuration.getDefaultApiClient();
defaultClient.setBasePath("https://api.conekta.io");
// Configure HTTP bearer authorization: bearerAuth
HttpBearerAuth bearerAuth = (HttpBearerAuth) defaultClient.getAuthentication("bearerAuth");
bearerAuth.setBearerToken("BEARER TOKEN");
OrdersApi apiInstance = new OrdersApi(defaultClient);
String id = "6307a60c41de27127515a575"; // String | Identifier of the resource
OrderUpdateRequest orderUpdateRequest = new OrderUpdateRequest(); // OrderUpdateRequest | requested field for an order
String acceptLanguage = "es"; // String | Use for knowing which language to use
try {
OrderResponse result = apiInstance.updateOrder(id, orderUpdateRequest, acceptLanguage);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling OrdersApi#updateOrder");
System.err.println("Status code: " + e.getCode());
System.err.println("Reason: " + e.getResponseBody());
System.err.println("Response headers: " + e.getResponseHeaders());
e.printStackTrace();
}
}
}
Name | Type | Description | Notes |
---|---|---|---|
id | String | Identifier of the resource | |
orderUpdateRequest | OrderUpdateRequest | requested field for an order | |
acceptLanguage | String | Use for knowing which language to use | [optional] [default to es] [enum: es, en] |
- Content-Type: application/json
- Accept: application/vnd.conekta-v2.1.0+json
Status code | Description | Response headers |
---|---|---|
200 | successful | - |
401 | authentication error | - |
404 | not found entity | - |
422 | parameter validation error | - |
500 | internal server error | - |