/*
 * Swagger of Opencellsoft Api
 * @#Introduction
 *
 * The version of the OpenAPI document: 7.3.1-SNAPSHOT
 * Contact: contact@opencellsoft.fr
 *
 * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
 * https://openapi-generator.tech
 * Do not edit the class manually.
 */


package org.openapitools.client.api;

import org.openapitools.client.ApiCallback;
import org.openapitools.client.ApiClient;
import org.openapitools.client.ApiException;
import org.openapitools.client.ApiResponse;
import org.openapitools.client.Configuration;
import org.openapitools.client.Pair;
import org.openapitools.client.ProgressRequestBody;
import org.openapitools.client.ProgressResponseBody;

import com.google.gson.reflect.TypeToken;

import java.io.IOException;


import org.openapitools.client.model.ActionStatus;
import org.openapitools.client.model.GetInvoiceSubCategoryResponse;
import org.openapitools.client.model.InvoiceSubCategoryDto;

import java.lang.reflect.Type;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import java.util.Map;

public class InvoiceSubCategoryApi {
    private ApiClient localVarApiClient;

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

    public InvoiceSubCategoryApi(ApiClient apiClient) {
        this.localVarApiClient = apiClient;
    }

    public ApiClient getApiClient() {
        return localVarApiClient;
    }

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

    /**
     * Build call for dELETEInvoiceSubCategoryInvoiceSubCategoryCode1
     * @param invoiceSubCategoryCode  invoiceSubCategoryCode invoice sub category  (required)
     * @param _callback Callback for upload/download progress
     * @return Call to execute
     * @throws ApiException If fail to serialize the request body object
     * @http.response.details
     <table summary="Response Details" border="1">
        <tr><td> Status Code </td><td> Description </td><td> Response Headers </td></tr>
        <tr><td> 0 </td><td>  action status  </td><td>  -  </td></tr>
     </table>
     */
    public okhttp3.Call dELETEInvoiceSubCategoryInvoiceSubCategoryCode1Call(String invoiceSubCategoryCode, final ApiCallback _callback) throws ApiException {
        Object localVarPostBody = null;

        // create path and map variables
        String localVarPath = "/invoiceSubCategory/{invoiceSubCategoryCode}"
            .replaceAll("\\{" + "invoiceSubCategoryCode" + "\\}", localVarApiClient.escapeString(invoiceSubCategoryCode.toString()));

        List<Pair> localVarQueryParams = new ArrayList<Pair>();
        List<Pair> localVarCollectionQueryParams = new ArrayList<Pair>();
        Map<String, String> localVarHeaderParams = new HashMap<String, String>();
        Map<String, Object> localVarFormParams = new HashMap<String, Object>();
        final String[] localVarAccepts = {
            "application/json", "application/xml"
        };
        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[] { "auth" };
        return localVarApiClient.buildCall(localVarPath, "DELETE", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, _callback);
    }

    @SuppressWarnings("rawtypes")
    private okhttp3.Call dELETEInvoiceSubCategoryInvoiceSubCategoryCode1ValidateBeforeCall(String invoiceSubCategoryCode, final ApiCallback _callback) throws ApiException {
        
        // verify the required parameter 'invoiceSubCategoryCode' is set
        if (invoiceSubCategoryCode == null) {
            throw new ApiException("Missing the required parameter 'invoiceSubCategoryCode' when calling dELETEInvoiceSubCategoryInvoiceSubCategoryCode1(Async)");
        }
        

        okhttp3.Call localVarCall = dELETEInvoiceSubCategoryInvoiceSubCategoryCode1Call(invoiceSubCategoryCode, _callback);
        return localVarCall;

    }

    /**
     *  Remove invoice sub category with a given code.  
     *  Remove invoice sub category with a given code.  
     * @param invoiceSubCategoryCode  invoiceSubCategoryCode invoice sub category  (required)
     * @return ActionStatus
     * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
     * @http.response.details
     <table summary="Response Details" border="1">
        <tr><td> Status Code </td><td> Description </td><td> Response Headers </td></tr>
        <tr><td> 0 </td><td>  action status  </td><td>  -  </td></tr>
     </table>
     */
    public ActionStatus dELETEInvoiceSubCategoryInvoiceSubCategoryCode1(String invoiceSubCategoryCode) throws ApiException {
        ApiResponse<ActionStatus> localVarResp = dELETEInvoiceSubCategoryInvoiceSubCategoryCode1WithHttpInfo(invoiceSubCategoryCode);
        return localVarResp.getData();
    }

    /**
     *  Remove invoice sub category with a given code.  
     *  Remove invoice sub category with a given code.  
     * @param invoiceSubCategoryCode  invoiceSubCategoryCode invoice sub category  (required)
     * @return ApiResponse&lt;ActionStatus&gt;
     * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
     * @http.response.details
     <table summary="Response Details" border="1">
        <tr><td> Status Code </td><td> Description </td><td> Response Headers </td></tr>
        <tr><td> 0 </td><td>  action status  </td><td>  -  </td></tr>
     </table>
     */
    public ApiResponse<ActionStatus> dELETEInvoiceSubCategoryInvoiceSubCategoryCode1WithHttpInfo(String invoiceSubCategoryCode) throws ApiException {
        okhttp3.Call localVarCall = dELETEInvoiceSubCategoryInvoiceSubCategoryCode1ValidateBeforeCall(invoiceSubCategoryCode, null);
        Type localVarReturnType = new TypeToken<ActionStatus>(){}.getType();
        return localVarApiClient.execute(localVarCall, localVarReturnType);
    }

    /**
     *  Remove invoice sub category with a given code.   (asynchronously)
     *  Remove invoice sub category with a given code.  
     * @param invoiceSubCategoryCode  invoiceSubCategoryCode invoice sub category  (required)
     * @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
     <table summary="Response Details" border="1">
        <tr><td> Status Code </td><td> Description </td><td> Response Headers </td></tr>
        <tr><td> 0 </td><td>  action status  </td><td>  -  </td></tr>
     </table>
     */
    public okhttp3.Call dELETEInvoiceSubCategoryInvoiceSubCategoryCode1Async(String invoiceSubCategoryCode, final ApiCallback<ActionStatus> _callback) throws ApiException {

        okhttp3.Call localVarCall = dELETEInvoiceSubCategoryInvoiceSubCategoryCode1ValidateBeforeCall(invoiceSubCategoryCode, _callback);
        Type localVarReturnType = new TypeToken<ActionStatus>(){}.getType();
        localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback);
        return localVarCall;
    }
    /**
     * Build call for gETIBaseVersion10
     * @param _callback Callback for upload/download progress
     * @return Call to execute
     * @throws ApiException If fail to serialize the request body object
     * @http.response.details
     <table summary="Response Details" border="1">
        <tr><td> Status Code </td><td> Description </td><td> Response Headers </td></tr>
        <tr><td> 0 </td><td>  Action status with version number as a message  </td><td>  -  </td></tr>
     </table>
     */
    public okhttp3.Call gETIBaseVersion10Call(final ApiCallback _callback) throws ApiException {
        Object localVarPostBody = null;

        // create path and map variables
        String localVarPath = "/invoiceSubCategory/version";

        List<Pair> localVarQueryParams = new ArrayList<Pair>();
        List<Pair> localVarCollectionQueryParams = new ArrayList<Pair>();
        Map<String, String> localVarHeaderParams = new HashMap<String, String>();
        Map<String, Object> localVarFormParams = new HashMap<String, Object>();
        final String[] localVarAccepts = {
            "application/json", "application/xml"
        };
        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[] { "auth" };
        return localVarApiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, _callback);
    }

    @SuppressWarnings("rawtypes")
    private okhttp3.Call gETIBaseVersion10ValidateBeforeCall(final ApiCallback _callback) throws ApiException {
        

        okhttp3.Call localVarCall = gETIBaseVersion10Call(_callback);
        return localVarCall;

    }

    /**
     *  Get version of application  
     *  Get version of application  
     * @return ActionStatus
     * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
     * @http.response.details
     <table summary="Response Details" border="1">
        <tr><td> Status Code </td><td> Description </td><td> Response Headers </td></tr>
        <tr><td> 0 </td><td>  Action status with version number as a message  </td><td>  -  </td></tr>
     </table>
     */
    public ActionStatus gETIBaseVersion10() throws ApiException {
        ApiResponse<ActionStatus> localVarResp = gETIBaseVersion10WithHttpInfo();
        return localVarResp.getData();
    }

    /**
     *  Get version of application  
     *  Get version of application  
     * @return ApiResponse&lt;ActionStatus&gt;
     * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
     * @http.response.details
     <table summary="Response Details" border="1">
        <tr><td> Status Code </td><td> Description </td><td> Response Headers </td></tr>
        <tr><td> 0 </td><td>  Action status with version number as a message  </td><td>  -  </td></tr>
     </table>
     */
    public ApiResponse<ActionStatus> gETIBaseVersion10WithHttpInfo() throws ApiException {
        okhttp3.Call localVarCall = gETIBaseVersion10ValidateBeforeCall(null);
        Type localVarReturnType = new TypeToken<ActionStatus>(){}.getType();
        return localVarApiClient.execute(localVarCall, localVarReturnType);
    }

    /**
     *  Get version of application   (asynchronously)
     *  Get version of application  
     * @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
     <table summary="Response Details" border="1">
        <tr><td> Status Code </td><td> Description </td><td> Response Headers </td></tr>
        <tr><td> 0 </td><td>  Action status with version number as a message  </td><td>  -  </td></tr>
     </table>
     */
    public okhttp3.Call gETIBaseVersion10Async(final ApiCallback<ActionStatus> _callback) throws ApiException {

        okhttp3.Call localVarCall = gETIBaseVersion10ValidateBeforeCall(_callback);
        Type localVarReturnType = new TypeToken<ActionStatus>(){}.getType();
        localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback);
        return localVarCall;
    }
    /**
     * Build call for gETInvoiceSubCategorySearch1
     * @param invoiceSubCategoryCode  invoiceSubCategoryCode invoice sub category code  (optional)
     * @param _callback Callback for upload/download progress
     * @return Call to execute
     * @throws ApiException If fail to serialize the request body object
     * @http.response.details
     <table summary="Response Details" border="1">
        <tr><td> Status Code </td><td> Description </td><td> Response Headers </td></tr>
        <tr><td> 0 </td><td>  invoice sub category  </td><td>  -  </td></tr>
     </table>
     */
    public okhttp3.Call gETInvoiceSubCategorySearch1Call(String invoiceSubCategoryCode, final ApiCallback _callback) throws ApiException {
        Object localVarPostBody = null;

        // create path and map variables
        String localVarPath = "/invoiceSubCategory";

        List<Pair> localVarQueryParams = new ArrayList<Pair>();
        List<Pair> localVarCollectionQueryParams = new ArrayList<Pair>();
        if (invoiceSubCategoryCode != null) {
            localVarQueryParams.addAll(localVarApiClient.parameterToPair("invoiceSubCategoryCode", invoiceSubCategoryCode));
        }

        Map<String, String> localVarHeaderParams = new HashMap<String, String>();
        Map<String, Object> localVarFormParams = new HashMap<String, Object>();
        final String[] localVarAccepts = {
            "application/json", "application/xml"
        };
        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[] { "auth" };
        return localVarApiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, _callback);
    }

    @SuppressWarnings("rawtypes")
    private okhttp3.Call gETInvoiceSubCategorySearch1ValidateBeforeCall(String invoiceSubCategoryCode, final ApiCallback _callback) throws ApiException {
        

        okhttp3.Call localVarCall = gETInvoiceSubCategorySearch1Call(invoiceSubCategoryCode, _callback);
        return localVarCall;

    }

    /**
     *  Search for invoice sub category with a given code.  
     *  Search for invoice sub category with a given code.  
     * @param invoiceSubCategoryCode  invoiceSubCategoryCode invoice sub category code  (optional)
     * @return GetInvoiceSubCategoryResponse
     * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
     * @http.response.details
     <table summary="Response Details" border="1">
        <tr><td> Status Code </td><td> Description </td><td> Response Headers </td></tr>
        <tr><td> 0 </td><td>  invoice sub category  </td><td>  -  </td></tr>
     </table>
     */
    public GetInvoiceSubCategoryResponse gETInvoiceSubCategorySearch1(String invoiceSubCategoryCode) throws ApiException {
        ApiResponse<GetInvoiceSubCategoryResponse> localVarResp = gETInvoiceSubCategorySearch1WithHttpInfo(invoiceSubCategoryCode);
        return localVarResp.getData();
    }

    /**
     *  Search for invoice sub category with a given code.  
     *  Search for invoice sub category with a given code.  
     * @param invoiceSubCategoryCode  invoiceSubCategoryCode invoice sub category code  (optional)
     * @return ApiResponse&lt;GetInvoiceSubCategoryResponse&gt;
     * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
     * @http.response.details
     <table summary="Response Details" border="1">
        <tr><td> Status Code </td><td> Description </td><td> Response Headers </td></tr>
        <tr><td> 0 </td><td>  invoice sub category  </td><td>  -  </td></tr>
     </table>
     */
    public ApiResponse<GetInvoiceSubCategoryResponse> gETInvoiceSubCategorySearch1WithHttpInfo(String invoiceSubCategoryCode) throws ApiException {
        okhttp3.Call localVarCall = gETInvoiceSubCategorySearch1ValidateBeforeCall(invoiceSubCategoryCode, null);
        Type localVarReturnType = new TypeToken<GetInvoiceSubCategoryResponse>(){}.getType();
        return localVarApiClient.execute(localVarCall, localVarReturnType);
    }

    /**
     *  Search for invoice sub category with a given code.   (asynchronously)
     *  Search for invoice sub category with a given code.  
     * @param invoiceSubCategoryCode  invoiceSubCategoryCode invoice sub category code  (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
     * @http.response.details
     <table summary="Response Details" border="1">
        <tr><td> Status Code </td><td> Description </td><td> Response Headers </td></tr>
        <tr><td> 0 </td><td>  invoice sub category  </td><td>  -  </td></tr>
     </table>
     */
    public okhttp3.Call gETInvoiceSubCategorySearch1Async(String invoiceSubCategoryCode, final ApiCallback<GetInvoiceSubCategoryResponse> _callback) throws ApiException {

        okhttp3.Call localVarCall = gETInvoiceSubCategorySearch1ValidateBeforeCall(invoiceSubCategoryCode, _callback);
        Type localVarReturnType = new TypeToken<GetInvoiceSubCategoryResponse>(){}.getType();
        localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback);
        return localVarCall;
    }
    /**
     * Build call for pOSTInvoiceSubCategoryCreate1
     * @param invoiceSubCategoryDto  postData invoice sub category to be created  (optional)
     * @param _callback Callback for upload/download progress
     * @return Call to execute
     * @throws ApiException If fail to serialize the request body object
     * @http.response.details
     <table summary="Response Details" border="1">
        <tr><td> Status Code </td><td> Description </td><td> Response Headers </td></tr>
        <tr><td> 0 </td><td>  action status.  </td><td>  -  </td></tr>
     </table>
     */
    public okhttp3.Call pOSTInvoiceSubCategoryCreate1Call(InvoiceSubCategoryDto invoiceSubCategoryDto, final ApiCallback _callback) throws ApiException {
        Object localVarPostBody = invoiceSubCategoryDto;

        // create path and map variables
        String localVarPath = "/invoiceSubCategory";

        List<Pair> localVarQueryParams = new ArrayList<Pair>();
        List<Pair> localVarCollectionQueryParams = new ArrayList<Pair>();
        Map<String, String> localVarHeaderParams = new HashMap<String, String>();
        Map<String, Object> localVarFormParams = new HashMap<String, Object>();
        final String[] localVarAccepts = {
            "application/json", "application/xml"
        };
        final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts);
        if (localVarAccept != null) {
            localVarHeaderParams.put("Accept", localVarAccept);
        }

        final String[] localVarContentTypes = {
            "application/json", "application/xml"
        };
        final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes);
        localVarHeaderParams.put("Content-Type", localVarContentType);

        String[] localVarAuthNames = new String[] { "auth" };
        return localVarApiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, _callback);
    }

    @SuppressWarnings("rawtypes")
    private okhttp3.Call pOSTInvoiceSubCategoryCreate1ValidateBeforeCall(InvoiceSubCategoryDto invoiceSubCategoryDto, final ApiCallback _callback) throws ApiException {
        

        okhttp3.Call localVarCall = pOSTInvoiceSubCategoryCreate1Call(invoiceSubCategoryDto, _callback);
        return localVarCall;

    }

    /**
     *  Create invoice sub category.  
     *  Create invoice sub category.  
     * @param invoiceSubCategoryDto  postData invoice sub category to be created  (optional)
     * @return ActionStatus
     * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
     * @http.response.details
     <table summary="Response Details" border="1">
        <tr><td> Status Code </td><td> Description </td><td> Response Headers </td></tr>
        <tr><td> 0 </td><td>  action status.  </td><td>  -  </td></tr>
     </table>
     */
    public ActionStatus pOSTInvoiceSubCategoryCreate1(InvoiceSubCategoryDto invoiceSubCategoryDto) throws ApiException {
        ApiResponse<ActionStatus> localVarResp = pOSTInvoiceSubCategoryCreate1WithHttpInfo(invoiceSubCategoryDto);
        return localVarResp.getData();
    }

    /**
     *  Create invoice sub category.  
     *  Create invoice sub category.  
     * @param invoiceSubCategoryDto  postData invoice sub category to be created  (optional)
     * @return ApiResponse&lt;ActionStatus&gt;
     * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
     * @http.response.details
     <table summary="Response Details" border="1">
        <tr><td> Status Code </td><td> Description </td><td> Response Headers </td></tr>
        <tr><td> 0 </td><td>  action status.  </td><td>  -  </td></tr>
     </table>
     */
    public ApiResponse<ActionStatus> pOSTInvoiceSubCategoryCreate1WithHttpInfo(InvoiceSubCategoryDto invoiceSubCategoryDto) throws ApiException {
        okhttp3.Call localVarCall = pOSTInvoiceSubCategoryCreate1ValidateBeforeCall(invoiceSubCategoryDto, null);
        Type localVarReturnType = new TypeToken<ActionStatus>(){}.getType();
        return localVarApiClient.execute(localVarCall, localVarReturnType);
    }

    /**
     *  Create invoice sub category.   (asynchronously)
     *  Create invoice sub category.  
     * @param invoiceSubCategoryDto  postData invoice sub category to be created  (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
     * @http.response.details
     <table summary="Response Details" border="1">
        <tr><td> Status Code </td><td> Description </td><td> Response Headers </td></tr>
        <tr><td> 0 </td><td>  action status.  </td><td>  -  </td></tr>
     </table>
     */
    public okhttp3.Call pOSTInvoiceSubCategoryCreate1Async(InvoiceSubCategoryDto invoiceSubCategoryDto, final ApiCallback<ActionStatus> _callback) throws ApiException {

        okhttp3.Call localVarCall = pOSTInvoiceSubCategoryCreate1ValidateBeforeCall(invoiceSubCategoryDto, _callback);
        Type localVarReturnType = new TypeToken<ActionStatus>(){}.getType();
        localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback);
        return localVarCall;
    }
    /**
     * Build call for pOSTInvoiceSubCategoryCreateOrUpdate1
     * @param invoiceSubCategoryDto  postData invoice sub category  (optional)
     * @param _callback Callback for upload/download progress
     * @return Call to execute
     * @throws ApiException If fail to serialize the request body object
     * @http.response.details
     <table summary="Response Details" border="1">
        <tr><td> Status Code </td><td> Description </td><td> Response Headers </td></tr>
        <tr><td> 0 </td><td>  action status  </td><td>  -  </td></tr>
     </table>
     */
    public okhttp3.Call pOSTInvoiceSubCategoryCreateOrUpdate1Call(InvoiceSubCategoryDto invoiceSubCategoryDto, final ApiCallback _callback) throws ApiException {
        Object localVarPostBody = invoiceSubCategoryDto;

        // create path and map variables
        String localVarPath = "/invoiceSubCategory/createOrUpdate";

        List<Pair> localVarQueryParams = new ArrayList<Pair>();
        List<Pair> localVarCollectionQueryParams = new ArrayList<Pair>();
        Map<String, String> localVarHeaderParams = new HashMap<String, String>();
        Map<String, Object> localVarFormParams = new HashMap<String, Object>();
        final String[] localVarAccepts = {
            "application/json", "application/xml"
        };
        final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts);
        if (localVarAccept != null) {
            localVarHeaderParams.put("Accept", localVarAccept);
        }

        final String[] localVarContentTypes = {
            "application/json", "application/xml"
        };
        final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes);
        localVarHeaderParams.put("Content-Type", localVarContentType);

        String[] localVarAuthNames = new String[] { "auth" };
        return localVarApiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, _callback);
    }

    @SuppressWarnings("rawtypes")
    private okhttp3.Call pOSTInvoiceSubCategoryCreateOrUpdate1ValidateBeforeCall(InvoiceSubCategoryDto invoiceSubCategoryDto, final ApiCallback _callback) throws ApiException {
        

        okhttp3.Call localVarCall = pOSTInvoiceSubCategoryCreateOrUpdate1Call(invoiceSubCategoryDto, _callback);
        return localVarCall;

    }

    /**
     *  Create or update invoice sub category.  
     *  Create or update invoice sub category.  
     * @param invoiceSubCategoryDto  postData invoice sub category  (optional)
     * @return ActionStatus
     * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
     * @http.response.details
     <table summary="Response Details" border="1">
        <tr><td> Status Code </td><td> Description </td><td> Response Headers </td></tr>
        <tr><td> 0 </td><td>  action status  </td><td>  -  </td></tr>
     </table>
     */
    public ActionStatus pOSTInvoiceSubCategoryCreateOrUpdate1(InvoiceSubCategoryDto invoiceSubCategoryDto) throws ApiException {
        ApiResponse<ActionStatus> localVarResp = pOSTInvoiceSubCategoryCreateOrUpdate1WithHttpInfo(invoiceSubCategoryDto);
        return localVarResp.getData();
    }

    /**
     *  Create or update invoice sub category.  
     *  Create or update invoice sub category.  
     * @param invoiceSubCategoryDto  postData invoice sub category  (optional)
     * @return ApiResponse&lt;ActionStatus&gt;
     * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
     * @http.response.details
     <table summary="Response Details" border="1">
        <tr><td> Status Code </td><td> Description </td><td> Response Headers </td></tr>
        <tr><td> 0 </td><td>  action status  </td><td>  -  </td></tr>
     </table>
     */
    public ApiResponse<ActionStatus> pOSTInvoiceSubCategoryCreateOrUpdate1WithHttpInfo(InvoiceSubCategoryDto invoiceSubCategoryDto) throws ApiException {
        okhttp3.Call localVarCall = pOSTInvoiceSubCategoryCreateOrUpdate1ValidateBeforeCall(invoiceSubCategoryDto, null);
        Type localVarReturnType = new TypeToken<ActionStatus>(){}.getType();
        return localVarApiClient.execute(localVarCall, localVarReturnType);
    }

    /**
     *  Create or update invoice sub category.   (asynchronously)
     *  Create or update invoice sub category.  
     * @param invoiceSubCategoryDto  postData invoice sub category  (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
     * @http.response.details
     <table summary="Response Details" border="1">
        <tr><td> Status Code </td><td> Description </td><td> Response Headers </td></tr>
        <tr><td> 0 </td><td>  action status  </td><td>  -  </td></tr>
     </table>
     */
    public okhttp3.Call pOSTInvoiceSubCategoryCreateOrUpdate1Async(InvoiceSubCategoryDto invoiceSubCategoryDto, final ApiCallback<ActionStatus> _callback) throws ApiException {

        okhttp3.Call localVarCall = pOSTInvoiceSubCategoryCreateOrUpdate1ValidateBeforeCall(invoiceSubCategoryDto, _callback);
        Type localVarReturnType = new TypeToken<ActionStatus>(){}.getType();
        localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback);
        return localVarCall;
    }
    /**
     * Build call for pUTInvoiceSubCategoryUpdate1
     * @param invoiceSubCategoryDto  postData invoice sub category to be created  (optional)
     * @param _callback Callback for upload/download progress
     * @return Call to execute
     * @throws ApiException If fail to serialize the request body object
     * @http.response.details
     <table summary="Response Details" border="1">
        <tr><td> Status Code </td><td> Description </td><td> Response Headers </td></tr>
        <tr><td> 0 </td><td>  action status  </td><td>  -  </td></tr>
     </table>
     */
    public okhttp3.Call pUTInvoiceSubCategoryUpdate1Call(InvoiceSubCategoryDto invoiceSubCategoryDto, final ApiCallback _callback) throws ApiException {
        Object localVarPostBody = invoiceSubCategoryDto;

        // create path and map variables
        String localVarPath = "/invoiceSubCategory";

        List<Pair> localVarQueryParams = new ArrayList<Pair>();
        List<Pair> localVarCollectionQueryParams = new ArrayList<Pair>();
        Map<String, String> localVarHeaderParams = new HashMap<String, String>();
        Map<String, Object> localVarFormParams = new HashMap<String, Object>();
        final String[] localVarAccepts = {
            "application/json", "application/xml"
        };
        final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts);
        if (localVarAccept != null) {
            localVarHeaderParams.put("Accept", localVarAccept);
        }

        final String[] localVarContentTypes = {
            "application/json", "application/xml"
        };
        final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes);
        localVarHeaderParams.put("Content-Type", localVarContentType);

        String[] localVarAuthNames = new String[] { "auth" };
        return localVarApiClient.buildCall(localVarPath, "PUT", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, _callback);
    }

    @SuppressWarnings("rawtypes")
    private okhttp3.Call pUTInvoiceSubCategoryUpdate1ValidateBeforeCall(InvoiceSubCategoryDto invoiceSubCategoryDto, final ApiCallback _callback) throws ApiException {
        

        okhttp3.Call localVarCall = pUTInvoiceSubCategoryUpdate1Call(invoiceSubCategoryDto, _callback);
        return localVarCall;

    }

    /**
     *  Update invoice sub category.  
     *  Update invoice sub category.  
     * @param invoiceSubCategoryDto  postData invoice sub category to be created  (optional)
     * @return ActionStatus
     * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
     * @http.response.details
     <table summary="Response Details" border="1">
        <tr><td> Status Code </td><td> Description </td><td> Response Headers </td></tr>
        <tr><td> 0 </td><td>  action status  </td><td>  -  </td></tr>
     </table>
     */
    public ActionStatus pUTInvoiceSubCategoryUpdate1(InvoiceSubCategoryDto invoiceSubCategoryDto) throws ApiException {
        ApiResponse<ActionStatus> localVarResp = pUTInvoiceSubCategoryUpdate1WithHttpInfo(invoiceSubCategoryDto);
        return localVarResp.getData();
    }

    /**
     *  Update invoice sub category.  
     *  Update invoice sub category.  
     * @param invoiceSubCategoryDto  postData invoice sub category to be created  (optional)
     * @return ApiResponse&lt;ActionStatus&gt;
     * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
     * @http.response.details
     <table summary="Response Details" border="1">
        <tr><td> Status Code </td><td> Description </td><td> Response Headers </td></tr>
        <tr><td> 0 </td><td>  action status  </td><td>  -  </td></tr>
     </table>
     */
    public ApiResponse<ActionStatus> pUTInvoiceSubCategoryUpdate1WithHttpInfo(InvoiceSubCategoryDto invoiceSubCategoryDto) throws ApiException {
        okhttp3.Call localVarCall = pUTInvoiceSubCategoryUpdate1ValidateBeforeCall(invoiceSubCategoryDto, null);
        Type localVarReturnType = new TypeToken<ActionStatus>(){}.getType();
        return localVarApiClient.execute(localVarCall, localVarReturnType);
    }

    /**
     *  Update invoice sub category.   (asynchronously)
     *  Update invoice sub category.  
     * @param invoiceSubCategoryDto  postData invoice sub category to be created  (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
     * @http.response.details
     <table summary="Response Details" border="1">
        <tr><td> Status Code </td><td> Description </td><td> Response Headers </td></tr>
        <tr><td> 0 </td><td>  action status  </td><td>  -  </td></tr>
     </table>
     */
    public okhttp3.Call pUTInvoiceSubCategoryUpdate1Async(InvoiceSubCategoryDto invoiceSubCategoryDto, final ApiCallback<ActionStatus> _callback) throws ApiException {

        okhttp3.Call localVarCall = pUTInvoiceSubCategoryUpdate1ValidateBeforeCall(invoiceSubCategoryDto, _callback);
        Type localVarReturnType = new TypeToken<ActionStatus>(){}.getType();
        localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback);
        return localVarCall;
    }
    /**
     * Build call for user63
     * @param _callback Callback for upload/download progress
     * @return Call to execute
     * @throws ApiException If fail to serialize the request body object
     * @http.response.details
     <table summary="Response Details" border="1">
        <tr><td> Status Code </td><td> Description </td><td> Response Headers </td></tr>
        <tr><td> 0 </td><td> default response </td><td>  -  </td></tr>
     </table>
     */
    public okhttp3.Call user63Call(final ApiCallback _callback) throws ApiException {
        Object localVarPostBody = null;

        // create path and map variables
        String localVarPath = "/invoiceSubCategory/user";

        List<Pair> localVarQueryParams = new ArrayList<Pair>();
        List<Pair> localVarCollectionQueryParams = new ArrayList<Pair>();
        Map<String, String> localVarHeaderParams = new HashMap<String, String>();
        Map<String, Object> localVarFormParams = new HashMap<String, Object>();
        final String[] localVarAccepts = {
            "application/json", "application/xml"
        };
        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[] { "auth" };
        return localVarApiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, _callback);
    }

    @SuppressWarnings("rawtypes")
    private okhttp3.Call user63ValidateBeforeCall(final ApiCallback _callback) throws ApiException {
        

        okhttp3.Call localVarCall = user63Call(_callback);
        return localVarCall;

    }

    /**
     * 
     * 
     * @return ActionStatus
     * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
     * @http.response.details
     <table summary="Response Details" border="1">
        <tr><td> Status Code </td><td> Description </td><td> Response Headers </td></tr>
        <tr><td> 0 </td><td> default response </td><td>  -  </td></tr>
     </table>
     */
    public ActionStatus user63() throws ApiException {
        ApiResponse<ActionStatus> localVarResp = user63WithHttpInfo();
        return localVarResp.getData();
    }

    /**
     * 
     * 
     * @return ApiResponse&lt;ActionStatus&gt;
     * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
     * @http.response.details
     <table summary="Response Details" border="1">
        <tr><td> Status Code </td><td> Description </td><td> Response Headers </td></tr>
        <tr><td> 0 </td><td> default response </td><td>  -  </td></tr>
     </table>
     */
    public ApiResponse<ActionStatus> user63WithHttpInfo() throws ApiException {
        okhttp3.Call localVarCall = user63ValidateBeforeCall(null);
        Type localVarReturnType = new TypeToken<ActionStatus>(){}.getType();
        return localVarApiClient.execute(localVarCall, localVarReturnType);
    }

    /**
     *  (asynchronously)
     * 
     * @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
     <table summary="Response Details" border="1">
        <tr><td> Status Code </td><td> Description </td><td> Response Headers </td></tr>
        <tr><td> 0 </td><td> default response </td><td>  -  </td></tr>
     </table>
     */
    public okhttp3.Call user63Async(final ApiCallback<ActionStatus> _callback) throws ApiException {

        okhttp3.Call localVarCall = user63ValidateBeforeCall(_callback);
        Type localVarReturnType = new TypeToken<ActionStatus>(){}.getType();
        localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback);
        return localVarCall;
    }
}
