Many resources are needed to download a project. Please understand that we have to compensate our server costs. Thank you in advance. Project price only 1 $
You can buy this project and download/modify it how often you want.
Java SDK to be used with a First Data Gateway account. This SDK has been created and packaged to offer the easiest way to integrate your application into the First Data Gateway. This SDK gives you the ability to run transactions such as sales, preauthorizations, postauthorizations, credits, voids, and returns; transaction inquiries; setting up scheduled payments and much more.
/*
* Payment Gateway API Specification.
* The documentation here is designed to provide all of the technical guidance required to consume and integrate with our APIs for payment processing. To learn more about our APIs please visit https://docs.firstdata.com/org/gateway.
*
* The version of the OpenAPI document: 21.2.0.20210406.001
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
* https://openapi-generator.tech
* Do not edit the class manually.
*/
package com.github.GBSEcom.api;
import com.github.GBSEcom.client.ApiCallback;
import com.github.GBSEcom.client.ApiClient;
import com.github.GBSEcom.client.ApiException;
import com.github.GBSEcom.client.ApiResponse;
import com.github.GBSEcom.client.Configuration;
import com.github.GBSEcom.client.Pair;
import com.github.GBSEcom.client.ProgressRequestBody;
import com.github.GBSEcom.client.ProgressResponseBody;
import com.google.gson.reflect.TypeToken;
import java.io.IOException;
import com.github.GBSEcom.model.ErrorResponse;
import com.github.GBSEcom.model.PaymentSchedulesErrorResponse;
import com.github.GBSEcom.model.PaymentSchedulesRequest;
import com.github.GBSEcom.model.PaymentSchedulesResponse;
import com.github.GBSEcom.model.RecurringPaymentDetailsResponse;
import java.lang.reflect.Type;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
public class PaymentSchedulesApi {
private ApiClient localVarApiClient;
public PaymentSchedulesApi() {
this(Configuration.getDefaultApiClient());
}
public PaymentSchedulesApi(ApiClient apiClient) {
this.localVarApiClient = apiClient;
}
public ApiClient getApiClient() {
return localVarApiClient;
}
public void setApiClient(ApiClient apiClient) {
this.localVarApiClient = apiClient;
}
/**
* Build call for cancelPaymentSchedule
* @param contentType Content type. (required)
* @param clientRequestId A client-generated ID for request tracking and signature creation, unique per request. This is also used for idempotency control. We recommend 128-bit UUID format. (required)
* @param apiKey Key given to merchant after boarding associating their requests with the appropriate app in Apigee. (required)
* @param timestamp Epoch timestamp in milliseconds in the request from a client system. Used for Message Signature generation and time limit (5 mins). (required)
* @param orderId Gateway order identifier as returned in the parameter orderId. (required)
* @param messageSignature Used to ensure the request has not been tampered with during transmission. The Message-Signature is the Base64 encoded HMAC hash (SHA256 algorithm with the API Secret as the key.) For more information, refer to the supporting documentation on the Developer Portal. (optional)
* @param region Indicates the region where the client wants the transaction to be processed. This will override the default processing region identified for the client. Available options are argentina, brazil, germany, india and northamerica. Region specific store setup and APIGEE boarding is required in order to use an alternate region for processing. (optional)
* @param storeId An optional outlet ID for clients that support multiple stores in the same developer app. (optional)
* @param _callback Callback for upload/download progress
* @return Call to execute
* @throws ApiException If fail to serialize the request body object
Status Code
Description
Response Headers
200
Success response.
-
400
The request cannot be validated.
-
401
The request was unauthorized.
-
404
The requested resource doesn't exist.
-
409
There was a problem communicating with the endpoint.
-
415
Format that is not supported by the server for the HTTP method.
-
422
There was a problem communicating with the endpoint.
-
500
An unexpected internal server error occurred.
-
*/
public okhttp3.Call cancelPaymentScheduleCall(String contentType, String clientRequestId, String apiKey, Long timestamp, String orderId, String messageSignature, String region, String storeId, final ApiCallback _callback) throws ApiException {
Object localVarPostBody = null;
// create path and map variables
String localVarPath = "/payment-schedules/{order-id}"
.replaceAll("\\{" + "order-id" + "\\}", localVarApiClient.escapeString(orderId.toString()));
List localVarQueryParams = new ArrayList();
List localVarCollectionQueryParams = new ArrayList();
if (storeId != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("storeId", storeId));
}
Map localVarHeaderParams = new HashMap();
if (contentType != null) {
localVarHeaderParams.put("Content-Type", localVarApiClient.parameterToString(contentType));
}
if (clientRequestId != null) {
localVarHeaderParams.put("Client-Request-Id", localVarApiClient.parameterToString(clientRequestId));
}
if (apiKey != null) {
localVarHeaderParams.put("Api-Key", localVarApiClient.parameterToString(apiKey));
}
if (timestamp != null) {
localVarHeaderParams.put("Timestamp", localVarApiClient.parameterToString(timestamp));
}
if (messageSignature != null) {
localVarHeaderParams.put("Message-Signature", localVarApiClient.parameterToString(messageSignature));
}
if (region != null) {
localVarHeaderParams.put("Region", localVarApiClient.parameterToString(region));
}
Map localVarFormParams = new HashMap();
final String[] localVarAccepts = {
"application/json"
};
final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts);
if (localVarAccept != null) {
localVarHeaderParams.put("Accept", localVarAccept);
}
final String[] localVarContentTypes = {
};
final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes);
localVarHeaderParams.put("Content-Type", localVarContentType);
String[] localVarAuthNames = new String[] { };
return localVarApiClient.buildCall(localVarPath, "DELETE", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, _callback);
}
@SuppressWarnings("rawtypes")
private okhttp3.Call cancelPaymentScheduleValidateBeforeCall(String contentType, String clientRequestId, String apiKey, Long timestamp, String orderId, String messageSignature, String region, String storeId, final ApiCallback _callback) throws ApiException {
// verify the required parameter 'contentType' is set
if (contentType == null) {
throw new ApiException("Missing the required parameter 'contentType' when calling cancelPaymentSchedule(Async)");
}
// verify the required parameter 'clientRequestId' is set
if (clientRequestId == null) {
throw new ApiException("Missing the required parameter 'clientRequestId' when calling cancelPaymentSchedule(Async)");
}
// verify the required parameter 'apiKey' is set
if (apiKey == null) {
throw new ApiException("Missing the required parameter 'apiKey' when calling cancelPaymentSchedule(Async)");
}
// verify the required parameter 'timestamp' is set
if (timestamp == null) {
throw new ApiException("Missing the required parameter 'timestamp' when calling cancelPaymentSchedule(Async)");
}
// verify the required parameter 'orderId' is set
if (orderId == null) {
throw new ApiException("Missing the required parameter 'orderId' when calling cancelPaymentSchedule(Async)");
}
okhttp3.Call localVarCall = cancelPaymentScheduleCall(contentType, clientRequestId, apiKey, timestamp, orderId, messageSignature, region, storeId, _callback);
return localVarCall;
}
/**
* Cancel a gateway payment schedule.
* Use this to cancel an existing gateway payment schedule.
* @param contentType Content type. (required)
* @param clientRequestId A client-generated ID for request tracking and signature creation, unique per request. This is also used for idempotency control. We recommend 128-bit UUID format. (required)
* @param apiKey Key given to merchant after boarding associating their requests with the appropriate app in Apigee. (required)
* @param timestamp Epoch timestamp in milliseconds in the request from a client system. Used for Message Signature generation and time limit (5 mins). (required)
* @param orderId Gateway order identifier as returned in the parameter orderId. (required)
* @param messageSignature Used to ensure the request has not been tampered with during transmission. The Message-Signature is the Base64 encoded HMAC hash (SHA256 algorithm with the API Secret as the key.) For more information, refer to the supporting documentation on the Developer Portal. (optional)
* @param region Indicates the region where the client wants the transaction to be processed. This will override the default processing region identified for the client. Available options are argentina, brazil, germany, india and northamerica. Region specific store setup and APIGEE boarding is required in order to use an alternate region for processing. (optional)
* @param storeId An optional outlet ID for clients that support multiple stores in the same developer app. (optional)
* @return PaymentSchedulesResponse
* @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
Status Code
Description
Response Headers
200
Success response.
-
400
The request cannot be validated.
-
401
The request was unauthorized.
-
404
The requested resource doesn't exist.
-
409
There was a problem communicating with the endpoint.
-
415
Format that is not supported by the server for the HTTP method.
-
422
There was a problem communicating with the endpoint.
-
500
An unexpected internal server error occurred.
-
*/
public PaymentSchedulesResponse cancelPaymentSchedule(String contentType, String clientRequestId, String apiKey, Long timestamp, String orderId, String messageSignature, String region, String storeId) throws ApiException {
ApiResponse localVarResp = cancelPaymentScheduleWithHttpInfo(contentType, clientRequestId, apiKey, timestamp, orderId, messageSignature, region, storeId);
return localVarResp.getData();
}
/**
* Cancel a gateway payment schedule.
* Use this to cancel an existing gateway payment schedule.
* @param contentType Content type. (required)
* @param clientRequestId A client-generated ID for request tracking and signature creation, unique per request. This is also used for idempotency control. We recommend 128-bit UUID format. (required)
* @param apiKey Key given to merchant after boarding associating their requests with the appropriate app in Apigee. (required)
* @param timestamp Epoch timestamp in milliseconds in the request from a client system. Used for Message Signature generation and time limit (5 mins). (required)
* @param orderId Gateway order identifier as returned in the parameter orderId. (required)
* @param messageSignature Used to ensure the request has not been tampered with during transmission. The Message-Signature is the Base64 encoded HMAC hash (SHA256 algorithm with the API Secret as the key.) For more information, refer to the supporting documentation on the Developer Portal. (optional)
* @param region Indicates the region where the client wants the transaction to be processed. This will override the default processing region identified for the client. Available options are argentina, brazil, germany, india and northamerica. Region specific store setup and APIGEE boarding is required in order to use an alternate region for processing. (optional)
* @param storeId An optional outlet ID for clients that support multiple stores in the same developer app. (optional)
* @return ApiResponse<PaymentSchedulesResponse>
* @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
Status Code
Description
Response Headers
200
Success response.
-
400
The request cannot be validated.
-
401
The request was unauthorized.
-
404
The requested resource doesn't exist.
-
409
There was a problem communicating with the endpoint.
-
415
Format that is not supported by the server for the HTTP method.
-
422
There was a problem communicating with the endpoint.
-
500
An unexpected internal server error occurred.
-
*/
public ApiResponse cancelPaymentScheduleWithHttpInfo(String contentType, String clientRequestId, String apiKey, Long timestamp, String orderId, String messageSignature, String region, String storeId) throws ApiException {
okhttp3.Call localVarCall = cancelPaymentScheduleValidateBeforeCall(contentType, clientRequestId, apiKey, timestamp, orderId, messageSignature, region, storeId, null);
Type localVarReturnType = new TypeToken(){}.getType();
return localVarApiClient.execute(localVarCall, localVarReturnType);
}
/**
* Cancel a gateway payment schedule. (asynchronously)
* Use this to cancel an existing gateway payment schedule.
* @param contentType Content type. (required)
* @param clientRequestId A client-generated ID for request tracking and signature creation, unique per request. This is also used for idempotency control. We recommend 128-bit UUID format. (required)
* @param apiKey Key given to merchant after boarding associating their requests with the appropriate app in Apigee. (required)
* @param timestamp Epoch timestamp in milliseconds in the request from a client system. Used for Message Signature generation and time limit (5 mins). (required)
* @param orderId Gateway order identifier as returned in the parameter orderId. (required)
* @param messageSignature Used to ensure the request has not been tampered with during transmission. The Message-Signature is the Base64 encoded HMAC hash (SHA256 algorithm with the API Secret as the key.) For more information, refer to the supporting documentation on the Developer Portal. (optional)
* @param region Indicates the region where the client wants the transaction to be processed. This will override the default processing region identified for the client. Available options are argentina, brazil, germany, india and northamerica. Region specific store setup and APIGEE boarding is required in order to use an alternate region for processing. (optional)
* @param storeId An optional outlet ID for clients that support multiple stores in the same developer app. (optional)
* @param _callback The callback to be executed when the API call finishes
* @return The request call
* @throws ApiException If fail to process the API call, e.g. serializing the request body object
Status Code
Description
Response Headers
200
Success response.
-
400
The request cannot be validated.
-
401
The request was unauthorized.
-
404
The requested resource doesn't exist.
-
409
There was a problem communicating with the endpoint.
-
415
Format that is not supported by the server for the HTTP method.
-
422
There was a problem communicating with the endpoint.
-
500
An unexpected internal server error occurred.
-
*/
public okhttp3.Call cancelPaymentScheduleAsync(String contentType, String clientRequestId, String apiKey, Long timestamp, String orderId, String messageSignature, String region, String storeId, final ApiCallback _callback) throws ApiException {
okhttp3.Call localVarCall = cancelPaymentScheduleValidateBeforeCall(contentType, clientRequestId, apiKey, timestamp, orderId, messageSignature, region, storeId, _callback);
Type localVarReturnType = new TypeToken(){}.getType();
localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback);
return localVarCall;
}
/**
* Build call for createPaymentSchedule
* @param contentType Content type. (required)
* @param clientRequestId A client-generated ID for request tracking and signature creation, unique per request. This is also used for idempotency control. We recommend 128-bit UUID format. (required)
* @param apiKey Key given to merchant after boarding associating their requests with the appropriate app in Apigee. (required)
* @param timestamp Epoch timestamp in milliseconds in the request from a client system. Used for Message Signature generation and time limit (5 mins). (required)
* @param paymentSchedulesRequest Accepted request types: PaymentMethodPaymentSchedulesRequest and ReferencedOrderPaymentSchedulesRequest. (required)
* @param messageSignature Used to ensure the request has not been tampered with during transmission. The Message-Signature is the Base64 encoded HMAC hash (SHA256 algorithm with the API Secret as the key.) For more information, refer to the supporting documentation on the Developer Portal. (optional)
* @param region Indicates the region where the client wants the transaction to be processed. This will override the default processing region identified for the client. Available options are argentina, brazil, germany, india and northamerica. Region specific store setup and APIGEE boarding is required in order to use an alternate region for processing. (optional)
* @param _callback Callback for upload/download progress
* @return Call to execute
* @throws ApiException If fail to serialize the request body object
Status Code
Description
Response Headers
200
Success response.
-
400
The request cannot be validated.
-
401
The request was unauthorized.
-
404
The requested resource doesn't exist.
-
409
The attempted action is not valid according to gateway rules.
-
415
Format that is not supported by the server for the HTTP method.
-
422
The endpoint declined the transaction.
-
500
An unexpected internal server error occurred.
-
*/
public okhttp3.Call createPaymentScheduleCall(String contentType, String clientRequestId, String apiKey, Long timestamp, PaymentSchedulesRequest paymentSchedulesRequest, String messageSignature, String region, final ApiCallback _callback) throws ApiException {
Object localVarPostBody = paymentSchedulesRequest;
// create path and map variables
String localVarPath = "/payment-schedules";
List localVarQueryParams = new ArrayList();
List localVarCollectionQueryParams = new ArrayList();
Map localVarHeaderParams = new HashMap();
if (contentType != null) {
localVarHeaderParams.put("Content-Type", localVarApiClient.parameterToString(contentType));
}
if (clientRequestId != null) {
localVarHeaderParams.put("Client-Request-Id", localVarApiClient.parameterToString(clientRequestId));
}
if (apiKey != null) {
localVarHeaderParams.put("Api-Key", localVarApiClient.parameterToString(apiKey));
}
if (timestamp != null) {
localVarHeaderParams.put("Timestamp", localVarApiClient.parameterToString(timestamp));
}
if (messageSignature != null) {
localVarHeaderParams.put("Message-Signature", localVarApiClient.parameterToString(messageSignature));
}
if (region != null) {
localVarHeaderParams.put("Region", localVarApiClient.parameterToString(region));
}
Map localVarFormParams = new HashMap();
final String[] localVarAccepts = {
"application/json"
};
final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts);
if (localVarAccept != null) {
localVarHeaderParams.put("Accept", localVarAccept);
}
final String[] localVarContentTypes = {
"application/json"
};
final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes);
localVarHeaderParams.put("Content-Type", localVarContentType);
String[] localVarAuthNames = new String[] { };
return localVarApiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, _callback);
}
@SuppressWarnings("rawtypes")
private okhttp3.Call createPaymentScheduleValidateBeforeCall(String contentType, String clientRequestId, String apiKey, Long timestamp, PaymentSchedulesRequest paymentSchedulesRequest, String messageSignature, String region, final ApiCallback _callback) throws ApiException {
// verify the required parameter 'contentType' is set
if (contentType == null) {
throw new ApiException("Missing the required parameter 'contentType' when calling createPaymentSchedule(Async)");
}
// verify the required parameter 'clientRequestId' is set
if (clientRequestId == null) {
throw new ApiException("Missing the required parameter 'clientRequestId' when calling createPaymentSchedule(Async)");
}
// verify the required parameter 'apiKey' is set
if (apiKey == null) {
throw new ApiException("Missing the required parameter 'apiKey' when calling createPaymentSchedule(Async)");
}
// verify the required parameter 'timestamp' is set
if (timestamp == null) {
throw new ApiException("Missing the required parameter 'timestamp' when calling createPaymentSchedule(Async)");
}
// verify the required parameter 'paymentSchedulesRequest' is set
if (paymentSchedulesRequest == null) {
throw new ApiException("Missing the required parameter 'paymentSchedulesRequest' when calling createPaymentSchedule(Async)");
}
okhttp3.Call localVarCall = createPaymentScheduleCall(contentType, clientRequestId, apiKey, timestamp, paymentSchedulesRequest, messageSignature, region, _callback);
return localVarCall;
}
/**
* Create gateway payment schedule.
* Use this to create a gateway payment schedule.
* @param contentType Content type. (required)
* @param clientRequestId A client-generated ID for request tracking and signature creation, unique per request. This is also used for idempotency control. We recommend 128-bit UUID format. (required)
* @param apiKey Key given to merchant after boarding associating their requests with the appropriate app in Apigee. (required)
* @param timestamp Epoch timestamp in milliseconds in the request from a client system. Used for Message Signature generation and time limit (5 mins). (required)
* @param paymentSchedulesRequest Accepted request types: PaymentMethodPaymentSchedulesRequest and ReferencedOrderPaymentSchedulesRequest. (required)
* @param messageSignature Used to ensure the request has not been tampered with during transmission. The Message-Signature is the Base64 encoded HMAC hash (SHA256 algorithm with the API Secret as the key.) For more information, refer to the supporting documentation on the Developer Portal. (optional)
* @param region Indicates the region where the client wants the transaction to be processed. This will override the default processing region identified for the client. Available options are argentina, brazil, germany, india and northamerica. Region specific store setup and APIGEE boarding is required in order to use an alternate region for processing. (optional)
* @return PaymentSchedulesResponse
* @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
Status Code
Description
Response Headers
200
Success response.
-
400
The request cannot be validated.
-
401
The request was unauthorized.
-
404
The requested resource doesn't exist.
-
409
The attempted action is not valid according to gateway rules.
-
415
Format that is not supported by the server for the HTTP method.
-
422
The endpoint declined the transaction.
-
500
An unexpected internal server error occurred.
-
*/
public PaymentSchedulesResponse createPaymentSchedule(String contentType, String clientRequestId, String apiKey, Long timestamp, PaymentSchedulesRequest paymentSchedulesRequest, String messageSignature, String region) throws ApiException {
ApiResponse localVarResp = createPaymentScheduleWithHttpInfo(contentType, clientRequestId, apiKey, timestamp, paymentSchedulesRequest, messageSignature, region);
return localVarResp.getData();
}
/**
* Create gateway payment schedule.
* Use this to create a gateway payment schedule.
* @param contentType Content type. (required)
* @param clientRequestId A client-generated ID for request tracking and signature creation, unique per request. This is also used for idempotency control. We recommend 128-bit UUID format. (required)
* @param apiKey Key given to merchant after boarding associating their requests with the appropriate app in Apigee. (required)
* @param timestamp Epoch timestamp in milliseconds in the request from a client system. Used for Message Signature generation and time limit (5 mins). (required)
* @param paymentSchedulesRequest Accepted request types: PaymentMethodPaymentSchedulesRequest and ReferencedOrderPaymentSchedulesRequest. (required)
* @param messageSignature Used to ensure the request has not been tampered with during transmission. The Message-Signature is the Base64 encoded HMAC hash (SHA256 algorithm with the API Secret as the key.) For more information, refer to the supporting documentation on the Developer Portal. (optional)
* @param region Indicates the region where the client wants the transaction to be processed. This will override the default processing region identified for the client. Available options are argentina, brazil, germany, india and northamerica. Region specific store setup and APIGEE boarding is required in order to use an alternate region for processing. (optional)
* @return ApiResponse<PaymentSchedulesResponse>
* @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
Status Code
Description
Response Headers
200
Success response.
-
400
The request cannot be validated.
-
401
The request was unauthorized.
-
404
The requested resource doesn't exist.
-
409
The attempted action is not valid according to gateway rules.
-
415
Format that is not supported by the server for the HTTP method.
-
422
The endpoint declined the transaction.
-
500
An unexpected internal server error occurred.
-
*/
public ApiResponse createPaymentScheduleWithHttpInfo(String contentType, String clientRequestId, String apiKey, Long timestamp, PaymentSchedulesRequest paymentSchedulesRequest, String messageSignature, String region) throws ApiException {
okhttp3.Call localVarCall = createPaymentScheduleValidateBeforeCall(contentType, clientRequestId, apiKey, timestamp, paymentSchedulesRequest, messageSignature, region, null);
Type localVarReturnType = new TypeToken(){}.getType();
return localVarApiClient.execute(localVarCall, localVarReturnType);
}
/**
* Create gateway payment schedule. (asynchronously)
* Use this to create a gateway payment schedule.
* @param contentType Content type. (required)
* @param clientRequestId A client-generated ID for request tracking and signature creation, unique per request. This is also used for idempotency control. We recommend 128-bit UUID format. (required)
* @param apiKey Key given to merchant after boarding associating their requests with the appropriate app in Apigee. (required)
* @param timestamp Epoch timestamp in milliseconds in the request from a client system. Used for Message Signature generation and time limit (5 mins). (required)
* @param paymentSchedulesRequest Accepted request types: PaymentMethodPaymentSchedulesRequest and ReferencedOrderPaymentSchedulesRequest. (required)
* @param messageSignature Used to ensure the request has not been tampered with during transmission. The Message-Signature is the Base64 encoded HMAC hash (SHA256 algorithm with the API Secret as the key.) For more information, refer to the supporting documentation on the Developer Portal. (optional)
* @param region Indicates the region where the client wants the transaction to be processed. This will override the default processing region identified for the client. Available options are argentina, brazil, germany, india and northamerica. Region specific store setup and APIGEE boarding is required in order to use an alternate region for processing. (optional)
* @param _callback The callback to be executed when the API call finishes
* @return The request call
* @throws ApiException If fail to process the API call, e.g. serializing the request body object
Status Code
Description
Response Headers
200
Success response.
-
400
The request cannot be validated.
-
401
The request was unauthorized.
-
404
The requested resource doesn't exist.
-
409
The attempted action is not valid according to gateway rules.
-
415
Format that is not supported by the server for the HTTP method.
-
422
The endpoint declined the transaction.
-
500
An unexpected internal server error occurred.
-
*/
public okhttp3.Call createPaymentScheduleAsync(String contentType, String clientRequestId, String apiKey, Long timestamp, PaymentSchedulesRequest paymentSchedulesRequest, String messageSignature, String region, final ApiCallback _callback) throws ApiException {
okhttp3.Call localVarCall = createPaymentScheduleValidateBeforeCall(contentType, clientRequestId, apiKey, timestamp, paymentSchedulesRequest, messageSignature, region, _callback);
Type localVarReturnType = new TypeToken(){}.getType();
localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback);
return localVarCall;
}
/**
* Build call for inquiryPaymentSchedule
* @param contentType Content type. (required)
* @param clientRequestId A client-generated ID for request tracking and signature creation, unique per request. This is also used for idempotency control. We recommend 128-bit UUID format. (required)
* @param apiKey Key given to merchant after boarding associating their requests with the appropriate app in Apigee. (required)
* @param timestamp Epoch timestamp in milliseconds in the request from a client system. Used for Message Signature generation and time limit (5 mins). (required)
* @param orderId Gateway order identifier as returned in the parameter orderId. (required)
* @param messageSignature Used to ensure the request has not been tampered with during transmission. The Message-Signature is the Base64 encoded HMAC hash (SHA256 algorithm with the API Secret as the key.) For more information, refer to the supporting documentation on the Developer Portal. (optional)
* @param region Indicates the region where the client wants the transaction to be processed. This will override the default processing region identified for the client. Available options are argentina, brazil, germany, india and northamerica. Region specific store setup and APIGEE boarding is required in order to use an alternate region for processing. (optional)
* @param storeId An optional outlet ID for clients that support multiple stores in the same developer app. (optional)
* @param _callback Callback for upload/download progress
* @return Call to execute
* @throws ApiException If fail to serialize the request body object
Status Code
Description
Response Headers
200
Success response.
-
400
The request cannot be validated.
-
401
The request was unauthorized.
-
404
The requested resource doesn't exist.
-
415
Format that is not supported by the server for the HTTP method.
-
500
An unexpected internal server error occurred.
-
*/
public okhttp3.Call inquiryPaymentScheduleCall(String contentType, String clientRequestId, String apiKey, Long timestamp, String orderId, String messageSignature, String region, String storeId, final ApiCallback _callback) throws ApiException {
Object localVarPostBody = null;
// create path and map variables
String localVarPath = "/payment-schedules/{order-id}"
.replaceAll("\\{" + "order-id" + "\\}", localVarApiClient.escapeString(orderId.toString()));
List localVarQueryParams = new ArrayList();
List localVarCollectionQueryParams = new ArrayList();
if (storeId != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("storeId", storeId));
}
Map localVarHeaderParams = new HashMap();
if (contentType != null) {
localVarHeaderParams.put("Content-Type", localVarApiClient.parameterToString(contentType));
}
if (clientRequestId != null) {
localVarHeaderParams.put("Client-Request-Id", localVarApiClient.parameterToString(clientRequestId));
}
if (apiKey != null) {
localVarHeaderParams.put("Api-Key", localVarApiClient.parameterToString(apiKey));
}
if (timestamp != null) {
localVarHeaderParams.put("Timestamp", localVarApiClient.parameterToString(timestamp));
}
if (messageSignature != null) {
localVarHeaderParams.put("Message-Signature", localVarApiClient.parameterToString(messageSignature));
}
if (region != null) {
localVarHeaderParams.put("Region", localVarApiClient.parameterToString(region));
}
Map localVarFormParams = new HashMap();
final String[] localVarAccepts = {
"application/json"
};
final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts);
if (localVarAccept != null) {
localVarHeaderParams.put("Accept", localVarAccept);
}
final String[] localVarContentTypes = {
};
final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes);
localVarHeaderParams.put("Content-Type", localVarContentType);
String[] localVarAuthNames = new String[] { };
return localVarApiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, _callback);
}
@SuppressWarnings("rawtypes")
private okhttp3.Call inquiryPaymentScheduleValidateBeforeCall(String contentType, String clientRequestId, String apiKey, Long timestamp, String orderId, String messageSignature, String region, String storeId, final ApiCallback _callback) throws ApiException {
// verify the required parameter 'contentType' is set
if (contentType == null) {
throw new ApiException("Missing the required parameter 'contentType' when calling inquiryPaymentSchedule(Async)");
}
// verify the required parameter 'clientRequestId' is set
if (clientRequestId == null) {
throw new ApiException("Missing the required parameter 'clientRequestId' when calling inquiryPaymentSchedule(Async)");
}
// verify the required parameter 'apiKey' is set
if (apiKey == null) {
throw new ApiException("Missing the required parameter 'apiKey' when calling inquiryPaymentSchedule(Async)");
}
// verify the required parameter 'timestamp' is set
if (timestamp == null) {
throw new ApiException("Missing the required parameter 'timestamp' when calling inquiryPaymentSchedule(Async)");
}
// verify the required parameter 'orderId' is set
if (orderId == null) {
throw new ApiException("Missing the required parameter 'orderId' when calling inquiryPaymentSchedule(Async)");
}
okhttp3.Call localVarCall = inquiryPaymentScheduleCall(contentType, clientRequestId, apiKey, timestamp, orderId, messageSignature, region, storeId, _callback);
return localVarCall;
}
/**
* View a gateway payment schedule.
* Use this to view an existing gateway payment schedule.
* @param contentType Content type. (required)
* @param clientRequestId A client-generated ID for request tracking and signature creation, unique per request. This is also used for idempotency control. We recommend 128-bit UUID format. (required)
* @param apiKey Key given to merchant after boarding associating their requests with the appropriate app in Apigee. (required)
* @param timestamp Epoch timestamp in milliseconds in the request from a client system. Used for Message Signature generation and time limit (5 mins). (required)
* @param orderId Gateway order identifier as returned in the parameter orderId. (required)
* @param messageSignature Used to ensure the request has not been tampered with during transmission. The Message-Signature is the Base64 encoded HMAC hash (SHA256 algorithm with the API Secret as the key.) For more information, refer to the supporting documentation on the Developer Portal. (optional)
* @param region Indicates the region where the client wants the transaction to be processed. This will override the default processing region identified for the client. Available options are argentina, brazil, germany, india and northamerica. Region specific store setup and APIGEE boarding is required in order to use an alternate region for processing. (optional)
* @param storeId An optional outlet ID for clients that support multiple stores in the same developer app. (optional)
* @return RecurringPaymentDetailsResponse
* @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
Status Code
Description
Response Headers
200
Success response.
-
400
The request cannot be validated.
-
401
The request was unauthorized.
-
404
The requested resource doesn't exist.
-
415
Format that is not supported by the server for the HTTP method.
-
500
An unexpected internal server error occurred.
-
*/
public RecurringPaymentDetailsResponse inquiryPaymentSchedule(String contentType, String clientRequestId, String apiKey, Long timestamp, String orderId, String messageSignature, String region, String storeId) throws ApiException {
ApiResponse localVarResp = inquiryPaymentScheduleWithHttpInfo(contentType, clientRequestId, apiKey, timestamp, orderId, messageSignature, region, storeId);
return localVarResp.getData();
}
/**
* View a gateway payment schedule.
* Use this to view an existing gateway payment schedule.
* @param contentType Content type. (required)
* @param clientRequestId A client-generated ID for request tracking and signature creation, unique per request. This is also used for idempotency control. We recommend 128-bit UUID format. (required)
* @param apiKey Key given to merchant after boarding associating their requests with the appropriate app in Apigee. (required)
* @param timestamp Epoch timestamp in milliseconds in the request from a client system. Used for Message Signature generation and time limit (5 mins). (required)
* @param orderId Gateway order identifier as returned in the parameter orderId. (required)
* @param messageSignature Used to ensure the request has not been tampered with during transmission. The Message-Signature is the Base64 encoded HMAC hash (SHA256 algorithm with the API Secret as the key.) For more information, refer to the supporting documentation on the Developer Portal. (optional)
* @param region Indicates the region where the client wants the transaction to be processed. This will override the default processing region identified for the client. Available options are argentina, brazil, germany, india and northamerica. Region specific store setup and APIGEE boarding is required in order to use an alternate region for processing. (optional)
* @param storeId An optional outlet ID for clients that support multiple stores in the same developer app. (optional)
* @return ApiResponse<RecurringPaymentDetailsResponse>
* @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
Status Code
Description
Response Headers
200
Success response.
-
400
The request cannot be validated.
-
401
The request was unauthorized.
-
404
The requested resource doesn't exist.
-
415
Format that is not supported by the server for the HTTP method.
-
500
An unexpected internal server error occurred.
-
*/
public ApiResponse inquiryPaymentScheduleWithHttpInfo(String contentType, String clientRequestId, String apiKey, Long timestamp, String orderId, String messageSignature, String region, String storeId) throws ApiException {
okhttp3.Call localVarCall = inquiryPaymentScheduleValidateBeforeCall(contentType, clientRequestId, apiKey, timestamp, orderId, messageSignature, region, storeId, null);
Type localVarReturnType = new TypeToken(){}.getType();
return localVarApiClient.execute(localVarCall, localVarReturnType);
}
/**
* View a gateway payment schedule. (asynchronously)
* Use this to view an existing gateway payment schedule.
* @param contentType Content type. (required)
* @param clientRequestId A client-generated ID for request tracking and signature creation, unique per request. This is also used for idempotency control. We recommend 128-bit UUID format. (required)
* @param apiKey Key given to merchant after boarding associating their requests with the appropriate app in Apigee. (required)
* @param timestamp Epoch timestamp in milliseconds in the request from a client system. Used for Message Signature generation and time limit (5 mins). (required)
* @param orderId Gateway order identifier as returned in the parameter orderId. (required)
* @param messageSignature Used to ensure the request has not been tampered with during transmission. The Message-Signature is the Base64 encoded HMAC hash (SHA256 algorithm with the API Secret as the key.) For more information, refer to the supporting documentation on the Developer Portal. (optional)
* @param region Indicates the region where the client wants the transaction to be processed. This will override the default processing region identified for the client. Available options are argentina, brazil, germany, india and northamerica. Region specific store setup and APIGEE boarding is required in order to use an alternate region for processing. (optional)
* @param storeId An optional outlet ID for clients that support multiple stores in the same developer app. (optional)
* @param _callback The callback to be executed when the API call finishes
* @return The request call
* @throws ApiException If fail to process the API call, e.g. serializing the request body object
Status Code
Description
Response Headers
200
Success response.
-
400
The request cannot be validated.
-
401
The request was unauthorized.
-
404
The requested resource doesn't exist.
-
415
Format that is not supported by the server for the HTTP method.
-
500
An unexpected internal server error occurred.
-
*/
public okhttp3.Call inquiryPaymentScheduleAsync(String contentType, String clientRequestId, String apiKey, Long timestamp, String orderId, String messageSignature, String region, String storeId, final ApiCallback _callback) throws ApiException {
okhttp3.Call localVarCall = inquiryPaymentScheduleValidateBeforeCall(contentType, clientRequestId, apiKey, timestamp, orderId, messageSignature, region, storeId, _callback);
Type localVarReturnType = new TypeToken(){}.getType();
localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback);
return localVarCall;
}
/**
* Build call for updatePaymentSchedule
* @param contentType Content type. (required)
* @param clientRequestId A client-generated ID for request tracking and signature creation, unique per request. This is also used for idempotency control. We recommend 128-bit UUID format. (required)
* @param apiKey Key given to merchant after boarding associating their requests with the appropriate app in Apigee. (required)
* @param timestamp Epoch timestamp in milliseconds in the request from a client system. Used for Message Signature generation and time limit (5 mins). (required)
* @param orderId Gateway order identifier as returned in the parameter orderId. (required)
* @param paymentSchedulesRequest Accepted request types: PaymentMethodPaymentSchedulesRequest and ReferencedOrderPaymentSchedulesRequest. (required)
* @param messageSignature Used to ensure the request has not been tampered with during transmission. The Message-Signature is the Base64 encoded HMAC hash (SHA256 algorithm with the API Secret as the key.) For more information, refer to the supporting documentation on the Developer Portal. (optional)
* @param region Indicates the region where the client wants the transaction to be processed. This will override the default processing region identified for the client. Available options are argentina, brazil, germany, india and northamerica. Region specific store setup and APIGEE boarding is required in order to use an alternate region for processing. (optional)
* @param _callback Callback for upload/download progress
* @return Call to execute
* @throws ApiException If fail to serialize the request body object
Status Code
Description
Response Headers
200
Success response.
-
400
The request cannot be validated.
-
401
The request was unauthorized.
-
404
The requested resource doesn't exist.
-
409
There was a problem communicating with the endpoint.
-
422
There was a problem communicating with the endpoint.
-
500
An unexpected internal server error occurred.
-
*/
public okhttp3.Call updatePaymentScheduleCall(String contentType, String clientRequestId, String apiKey, Long timestamp, String orderId, PaymentSchedulesRequest paymentSchedulesRequest, String messageSignature, String region, final ApiCallback _callback) throws ApiException {
Object localVarPostBody = paymentSchedulesRequest;
// create path and map variables
String localVarPath = "/payment-schedules/{order-id}"
.replaceAll("\\{" + "order-id" + "\\}", localVarApiClient.escapeString(orderId.toString()));
List localVarQueryParams = new ArrayList();
List localVarCollectionQueryParams = new ArrayList();
Map localVarHeaderParams = new HashMap();
if (contentType != null) {
localVarHeaderParams.put("Content-Type", localVarApiClient.parameterToString(contentType));
}
if (clientRequestId != null) {
localVarHeaderParams.put("Client-Request-Id", localVarApiClient.parameterToString(clientRequestId));
}
if (apiKey != null) {
localVarHeaderParams.put("Api-Key", localVarApiClient.parameterToString(apiKey));
}
if (timestamp != null) {
localVarHeaderParams.put("Timestamp", localVarApiClient.parameterToString(timestamp));
}
if (messageSignature != null) {
localVarHeaderParams.put("Message-Signature", localVarApiClient.parameterToString(messageSignature));
}
if (region != null) {
localVarHeaderParams.put("Region", localVarApiClient.parameterToString(region));
}
Map localVarFormParams = new HashMap();
final String[] localVarAccepts = {
"application/json"
};
final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts);
if (localVarAccept != null) {
localVarHeaderParams.put("Accept", localVarAccept);
}
final String[] localVarContentTypes = {
"application/json"
};
final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes);
localVarHeaderParams.put("Content-Type", localVarContentType);
String[] localVarAuthNames = new String[] { };
return localVarApiClient.buildCall(localVarPath, "PATCH", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, _callback);
}
@SuppressWarnings("rawtypes")
private okhttp3.Call updatePaymentScheduleValidateBeforeCall(String contentType, String clientRequestId, String apiKey, Long timestamp, String orderId, PaymentSchedulesRequest paymentSchedulesRequest, String messageSignature, String region, final ApiCallback _callback) throws ApiException {
// verify the required parameter 'contentType' is set
if (contentType == null) {
throw new ApiException("Missing the required parameter 'contentType' when calling updatePaymentSchedule(Async)");
}
// verify the required parameter 'clientRequestId' is set
if (clientRequestId == null) {
throw new ApiException("Missing the required parameter 'clientRequestId' when calling updatePaymentSchedule(Async)");
}
// verify the required parameter 'apiKey' is set
if (apiKey == null) {
throw new ApiException("Missing the required parameter 'apiKey' when calling updatePaymentSchedule(Async)");
}
// verify the required parameter 'timestamp' is set
if (timestamp == null) {
throw new ApiException("Missing the required parameter 'timestamp' when calling updatePaymentSchedule(Async)");
}
// verify the required parameter 'orderId' is set
if (orderId == null) {
throw new ApiException("Missing the required parameter 'orderId' when calling updatePaymentSchedule(Async)");
}
// verify the required parameter 'paymentSchedulesRequest' is set
if (paymentSchedulesRequest == null) {
throw new ApiException("Missing the required parameter 'paymentSchedulesRequest' when calling updatePaymentSchedule(Async)");
}
okhttp3.Call localVarCall = updatePaymentScheduleCall(contentType, clientRequestId, apiKey, timestamp, orderId, paymentSchedulesRequest, messageSignature, region, _callback);
return localVarCall;
}
/**
* Update a gateway payment schedule.
* Use this to update a gateway payment schedule.
* @param contentType Content type. (required)
* @param clientRequestId A client-generated ID for request tracking and signature creation, unique per request. This is also used for idempotency control. We recommend 128-bit UUID format. (required)
* @param apiKey Key given to merchant after boarding associating their requests with the appropriate app in Apigee. (required)
* @param timestamp Epoch timestamp in milliseconds in the request from a client system. Used for Message Signature generation and time limit (5 mins). (required)
* @param orderId Gateway order identifier as returned in the parameter orderId. (required)
* @param paymentSchedulesRequest Accepted request types: PaymentMethodPaymentSchedulesRequest and ReferencedOrderPaymentSchedulesRequest. (required)
* @param messageSignature Used to ensure the request has not been tampered with during transmission. The Message-Signature is the Base64 encoded HMAC hash (SHA256 algorithm with the API Secret as the key.) For more information, refer to the supporting documentation on the Developer Portal. (optional)
* @param region Indicates the region where the client wants the transaction to be processed. This will override the default processing region identified for the client. Available options are argentina, brazil, germany, india and northamerica. Region specific store setup and APIGEE boarding is required in order to use an alternate region for processing. (optional)
* @return PaymentSchedulesResponse
* @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
Status Code
Description
Response Headers
200
Success response.
-
400
The request cannot be validated.
-
401
The request was unauthorized.
-
404
The requested resource doesn't exist.
-
409
There was a problem communicating with the endpoint.
-
422
There was a problem communicating with the endpoint.
-
500
An unexpected internal server error occurred.
-
*/
public PaymentSchedulesResponse updatePaymentSchedule(String contentType, String clientRequestId, String apiKey, Long timestamp, String orderId, PaymentSchedulesRequest paymentSchedulesRequest, String messageSignature, String region) throws ApiException {
ApiResponse localVarResp = updatePaymentScheduleWithHttpInfo(contentType, clientRequestId, apiKey, timestamp, orderId, paymentSchedulesRequest, messageSignature, region);
return localVarResp.getData();
}
/**
* Update a gateway payment schedule.
* Use this to update a gateway payment schedule.
* @param contentType Content type. (required)
* @param clientRequestId A client-generated ID for request tracking and signature creation, unique per request. This is also used for idempotency control. We recommend 128-bit UUID format. (required)
* @param apiKey Key given to merchant after boarding associating their requests with the appropriate app in Apigee. (required)
* @param timestamp Epoch timestamp in milliseconds in the request from a client system. Used for Message Signature generation and time limit (5 mins). (required)
* @param orderId Gateway order identifier as returned in the parameter orderId. (required)
* @param paymentSchedulesRequest Accepted request types: PaymentMethodPaymentSchedulesRequest and ReferencedOrderPaymentSchedulesRequest. (required)
* @param messageSignature Used to ensure the request has not been tampered with during transmission. The Message-Signature is the Base64 encoded HMAC hash (SHA256 algorithm with the API Secret as the key.) For more information, refer to the supporting documentation on the Developer Portal. (optional)
* @param region Indicates the region where the client wants the transaction to be processed. This will override the default processing region identified for the client. Available options are argentina, brazil, germany, india and northamerica. Region specific store setup and APIGEE boarding is required in order to use an alternate region for processing. (optional)
* @return ApiResponse<PaymentSchedulesResponse>
* @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
Status Code
Description
Response Headers
200
Success response.
-
400
The request cannot be validated.
-
401
The request was unauthorized.
-
404
The requested resource doesn't exist.
-
409
There was a problem communicating with the endpoint.
-
422
There was a problem communicating with the endpoint.
-
500
An unexpected internal server error occurred.
-
*/
public ApiResponse updatePaymentScheduleWithHttpInfo(String contentType, String clientRequestId, String apiKey, Long timestamp, String orderId, PaymentSchedulesRequest paymentSchedulesRequest, String messageSignature, String region) throws ApiException {
okhttp3.Call localVarCall = updatePaymentScheduleValidateBeforeCall(contentType, clientRequestId, apiKey, timestamp, orderId, paymentSchedulesRequest, messageSignature, region, null);
Type localVarReturnType = new TypeToken(){}.getType();
return localVarApiClient.execute(localVarCall, localVarReturnType);
}
/**
* Update a gateway payment schedule. (asynchronously)
* Use this to update a gateway payment schedule.
* @param contentType Content type. (required)
* @param clientRequestId A client-generated ID for request tracking and signature creation, unique per request. This is also used for idempotency control. We recommend 128-bit UUID format. (required)
* @param apiKey Key given to merchant after boarding associating their requests with the appropriate app in Apigee. (required)
* @param timestamp Epoch timestamp in milliseconds in the request from a client system. Used for Message Signature generation and time limit (5 mins). (required)
* @param orderId Gateway order identifier as returned in the parameter orderId. (required)
* @param paymentSchedulesRequest Accepted request types: PaymentMethodPaymentSchedulesRequest and ReferencedOrderPaymentSchedulesRequest. (required)
* @param messageSignature Used to ensure the request has not been tampered with during transmission. The Message-Signature is the Base64 encoded HMAC hash (SHA256 algorithm with the API Secret as the key.) For more information, refer to the supporting documentation on the Developer Portal. (optional)
* @param region Indicates the region where the client wants the transaction to be processed. This will override the default processing region identified for the client. Available options are argentina, brazil, germany, india and northamerica. Region specific store setup and APIGEE boarding is required in order to use an alternate region for processing. (optional)
* @param _callback The callback to be executed when the API call finishes
* @return The request call
* @throws ApiException If fail to process the API call, e.g. serializing the request body object
Status Code
Description
Response Headers
200
Success response.
-
400
The request cannot be validated.
-
401
The request was unauthorized.
-
404
The requested resource doesn't exist.
-
409
There was a problem communicating with the endpoint.
-
422
There was a problem communicating with the endpoint.
-
500
An unexpected internal server error occurred.
-
*/
public okhttp3.Call updatePaymentScheduleAsync(String contentType, String clientRequestId, String apiKey, Long timestamp, String orderId, PaymentSchedulesRequest paymentSchedulesRequest, String messageSignature, String region, final ApiCallback _callback) throws ApiException {
okhttp3.Call localVarCall = updatePaymentScheduleValidateBeforeCall(contentType, clientRequestId, apiKey, timestamp, orderId, paymentSchedulesRequest, messageSignature, region, _callback);
Type localVarReturnType = new TypeToken(){}.getType();
localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback);
return localVarCall;
}
}