All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.unblu.webapi.jersey.v3.api.AuditApi Maven / Gradle / Ivy

package com.unblu.webapi.jersey.v3.api;

import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import java.util.Map;

import jakarta.ws.rs.core.GenericType;

import com.unblu.webapi.jersey.v3.invoker.ApiClient;
import com.unblu.webapi.jersey.v3.invoker.ApiException;
import com.unblu.webapi.jersey.v3.invoker.ApiResponse;
import com.unblu.webapi.jersey.v3.invoker.Configuration;
import com.unblu.webapi.jersey.v3.invoker.Pair;
import com.unblu.webapi.model.v3.AuditChangeQuery;
import com.unblu.webapi.model.v3.AuditChangeResult;

public class AuditApi {
	private ApiClient apiClient;

	public AuditApi() {
		this(Configuration.getDefaultApiClient());
	}

	public AuditApi(ApiClient apiClient) {
		this.apiClient = apiClient;
	}

	public ApiClient getApiClient() {
		return apiClient;
	}

	public void setApiClient(ApiClient apiClient) {
		this.apiClient = apiClient;
	}

	/**
	 * search Search for audit log entries <ul> <li>of database entities in the current account for ADMIN role user. <li>of global owner type
	 * entities and account entities for SUPERADMIN role user. </ul><br>
	 * 
	 * @param auditChangeQuery (required)
	 * @return AuditChangeResult
	 * @throws ApiException if fails to make API call
	 */
	public AuditChangeResult auditSearch(AuditChangeQuery auditChangeQuery) throws ApiException {
		return auditSearchWithHttpInfo(auditChangeQuery).getData();
	}

	/**
	 * search Search for audit log entries <ul> <li>of database entities in the current account for ADMIN role user. <li>of global owner type
	 * entities and account entities for SUPERADMIN role user. </ul><br>
	 * 
	 * @param auditChangeQuery (required)
	 * @return ApiResponse<AuditChangeResult>
	 * @throws ApiException if fails to make API call
	 */
	public ApiResponse auditSearchWithHttpInfo(AuditChangeQuery auditChangeQuery) throws ApiException {
		Object localVarPostBody = auditChangeQuery;

		// verify the required parameter 'auditChangeQuery' is set
		if (auditChangeQuery == null) {
			throw new ApiException(400, "Missing the required parameter 'auditChangeQuery' when calling auditSearch");
		}

		// create path and map variables
		String localVarPath = "/audit/search";

		// query params
		List localVarQueryParams = new ArrayList();
		Map localVarHeaderParams = new HashMap();
		Map localVarFormParams = new HashMap();

		final String[] localVarAccepts = {
			"application/json"
		};
		final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts);

		final String[] localVarContentTypes = {
			"application/json"
		};
		final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes);

		String[] localVarAuthNames = new String[] { "basicAuth" };

		GenericType localVarReturnType = new GenericType() {
		};
		return apiClient.invokeAPI(localVarPath, "POST", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAccept, localVarContentType, localVarAuthNames, localVarReturnType);
	}
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy