com.svix.internal.api.HealthApi Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of svix Show documentation
Show all versions of svix Show documentation
Svix webhooks API client and webhook verification library
The newest version!
/*
* Svix API
* No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
*
* The version of the OpenAPI document: 1.1.1
*
*
* 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.svix.internal.api;
import com.svix.internal.ApiCallback;
import com.svix.internal.ApiClient;
import com.svix.internal.ApiException;
import com.svix.internal.ApiResponse;
import com.svix.internal.Configuration;
import com.svix.internal.Pair;
import com.svix.internal.ProgressRequestBody;
import com.svix.internal.ProgressResponseBody;
import com.google.gson.reflect.TypeToken;
import java.io.IOException;
import com.svix.models.HTTPValidationError;
import com.svix.models.HttpErrorOut;
import java.lang.reflect.Type;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
public class HealthApi {
private ApiClient localVarApiClient;
private int localHostIndex;
private String localCustomBaseUrl;
public HealthApi() {
this(Configuration.getDefaultApiClient());
}
public HealthApi(ApiClient apiClient) {
this.localVarApiClient = apiClient;
}
public ApiClient getApiClient() {
return localVarApiClient;
}
public void setApiClient(ApiClient apiClient) {
this.localVarApiClient = apiClient;
}
public int getHostIndex() {
return localHostIndex;
}
public void setHostIndex(int hostIndex) {
this.localHostIndex = hostIndex;
}
public String getCustomBaseUrl() {
return localCustomBaseUrl;
}
public void setCustomBaseUrl(String customBaseUrl) {
this.localCustomBaseUrl = customBaseUrl;
}
/**
* Build call for v1HealthGet
* @param _callback Callback for upload/download progress
* @return Call to execute
* @throws ApiException If fail to serialize the request body object
* @http.response.details
Status Code Description Response Headers
204 no content -
400 Bad request -
401 Unauthorized -
403 Forbidden -
404 Not Found -
409 Conflict -
422 Validation Error -
429 Too Many Requests -
*/
public okhttp3.Call v1HealthGetCall(final ApiCallback _callback) throws ApiException {
String basePath = null;
// Operation Servers
String[] localBasePaths = new String[] { };
// Determine Base Path to Use
if (localCustomBaseUrl != null){
basePath = localCustomBaseUrl;
} else if ( localBasePaths.length > 0 ) {
basePath = localBasePaths[localHostIndex];
} else {
basePath = null;
}
Object localVarPostBody = null;
// create path and map variables
String localVarPath = "/api/v1/health";
List localVarQueryParams = new ArrayList();
List localVarCollectionQueryParams = new ArrayList();
Map localVarHeaderParams = new HashMap();
Map localVarCookieParams = new HashMap();
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);
if (localVarContentType != null) {
localVarHeaderParams.put("Content-Type", localVarContentType);
}
String[] localVarAuthNames = new String[] { };
return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback);
}
@SuppressWarnings("rawtypes")
private okhttp3.Call v1HealthGetValidateBeforeCall(final ApiCallback _callback) throws ApiException {
return v1HealthGetCall(_callback);
}
/**
* Health
* Verify the API server is up and running.
* @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
* @http.response.details
Status Code Description Response Headers
204 no content -
400 Bad request -
401 Unauthorized -
403 Forbidden -
404 Not Found -
409 Conflict -
422 Validation Error -
429 Too Many Requests -
*/
public void v1HealthGet() throws ApiException {
v1HealthGetWithHttpInfo();
}
/**
* Health
* Verify the API server is up and running.
* @return ApiResponse<Void>
* @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
* @http.response.details
Status Code Description Response Headers
204 no content -
400 Bad request -
401 Unauthorized -
403 Forbidden -
404 Not Found -
409 Conflict -
422 Validation Error -
429 Too Many Requests -
*/
public ApiResponse v1HealthGetWithHttpInfo() throws ApiException {
okhttp3.Call localVarCall = v1HealthGetValidateBeforeCall(null);
return localVarApiClient.execute(localVarCall);
}
/**
* Health (asynchronously)
* Verify the API server is up and running.
* @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
* @http.response.details
Status Code Description Response Headers
204 no content -
400 Bad request -
401 Unauthorized -
403 Forbidden -
404 Not Found -
409 Conflict -
422 Validation Error -
429 Too Many Requests -
*/
public okhttp3.Call v1HealthGetAsync(final ApiCallback _callback) throws ApiException {
okhttp3.Call localVarCall = v1HealthGetValidateBeforeCall(_callback);
localVarApiClient.executeAsync(localVarCall, _callback);
return localVarCall;
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy