/*
 * Daytona
 * Daytona AI platform API Docs
 *
 * The version of the OpenAPI document: 1.0
 * Contact: support@daytona.com
 *
 * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
 * https://openapi-generator.tech
 * Do not edit the class manually.
 */


package io.daytona.api.client.api;

import io.daytona.api.client.ApiCallback;
import io.daytona.api.client.ApiClient;
import io.daytona.api.client.ApiException;
import io.daytona.api.client.ApiResponse;
import io.daytona.api.client.Configuration;
import io.daytona.api.client.Pair;
import io.daytona.api.client.ProgressRequestBody;
import io.daytona.api.client.ProgressResponseBody;

import com.google.gson.reflect.TypeToken;

import java.io.IOException;


import java.math.BigDecimal;
import io.daytona.api.client.model.CreateWorkspace;
import io.daytona.api.client.model.SandboxLabels;
import io.daytona.api.client.model.Workspace;
import io.daytona.api.client.model.WorkspacePortPreviewUrl;

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

public class WorkspaceApi {
    private ApiClient localVarApiClient;
    private int localHostIndex;
    private String localCustomBaseUrl;

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

    public WorkspaceApi(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 archiveWorkspaceDeprecated
     * @param workspaceId  (required)
     * @param xDaytonaOrganizationID Use with JWT to specify the organization ID (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 border="1">
       <caption>Response Details</caption>
        <tr><td> Status Code </td><td> Description </td><td> Response Headers </td></tr>
        <tr><td> 200 </td><td> Workspace has been archived </td><td>  -  </td></tr>
     </table>
     * @deprecated
     */
    @Deprecated
    public okhttp3.Call archiveWorkspaceDeprecatedCall(@javax.annotation.Nonnull String workspaceId, @javax.annotation.Nullable String xDaytonaOrganizationID, 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 = "/workspace/{workspaceId}/archive"
            .replace("{" + "workspaceId" + "}", localVarApiClient.escapeString(workspaceId.toString()));

        List<Pair> localVarQueryParams = new ArrayList<Pair>();
        List<Pair> localVarCollectionQueryParams = new ArrayList<Pair>();
        Map<String, String> localVarHeaderParams = new HashMap<String, String>();
        Map<String, String> localVarCookieParams = new HashMap<String, String>();
        Map<String, Object> localVarFormParams = new HashMap<String, Object>();

        final String[] localVarAccepts = {
        };
        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);
        }

        if (xDaytonaOrganizationID != null) {
            localVarHeaderParams.put("X-Daytona-Organization-ID", localVarApiClient.parameterToString(xDaytonaOrganizationID));
        }


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

    @Deprecated
    @SuppressWarnings("rawtypes")
    private okhttp3.Call archiveWorkspaceDeprecatedValidateBeforeCall(@javax.annotation.Nonnull String workspaceId, @javax.annotation.Nullable String xDaytonaOrganizationID, final ApiCallback _callback) throws ApiException {
        // verify the required parameter 'workspaceId' is set
        if (workspaceId == null) {
            throw new ApiException("Missing the required parameter 'workspaceId' when calling archiveWorkspaceDeprecated(Async)");
        }

        return archiveWorkspaceDeprecatedCall(workspaceId, xDaytonaOrganizationID, _callback);

    }

    /**
     * [DEPRECATED] Archive workspace
     * 
     * @param workspaceId  (required)
     * @param xDaytonaOrganizationID Use with JWT to specify the organization ID (optional)
     * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
     * @http.response.details
     <table border="1">
       <caption>Response Details</caption>
        <tr><td> Status Code </td><td> Description </td><td> Response Headers </td></tr>
        <tr><td> 200 </td><td> Workspace has been archived </td><td>  -  </td></tr>
     </table>
     * @deprecated
     */
    @Deprecated
    public void archiveWorkspaceDeprecated(@javax.annotation.Nonnull String workspaceId, @javax.annotation.Nullable String xDaytonaOrganizationID) throws ApiException {
        archiveWorkspaceDeprecatedWithHttpInfo(workspaceId, xDaytonaOrganizationID);
    }

    /**
     * [DEPRECATED] Archive workspace
     * 
     * @param workspaceId  (required)
     * @param xDaytonaOrganizationID Use with JWT to specify the organization ID (optional)
     * @return ApiResponse&lt;Void&gt;
     * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
     * @http.response.details
     <table border="1">
       <caption>Response Details</caption>
        <tr><td> Status Code </td><td> Description </td><td> Response Headers </td></tr>
        <tr><td> 200 </td><td> Workspace has been archived </td><td>  -  </td></tr>
     </table>
     * @deprecated
     */
    @Deprecated
    public ApiResponse<Void> archiveWorkspaceDeprecatedWithHttpInfo(@javax.annotation.Nonnull String workspaceId, @javax.annotation.Nullable String xDaytonaOrganizationID) throws ApiException {
        okhttp3.Call localVarCall = archiveWorkspaceDeprecatedValidateBeforeCall(workspaceId, xDaytonaOrganizationID, null);
        return localVarApiClient.execute(localVarCall);
    }

    /**
     * [DEPRECATED] Archive workspace (asynchronously)
     * 
     * @param workspaceId  (required)
     * @param xDaytonaOrganizationID Use with JWT to specify the organization ID (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 border="1">
       <caption>Response Details</caption>
        <tr><td> Status Code </td><td> Description </td><td> Response Headers </td></tr>
        <tr><td> 200 </td><td> Workspace has been archived </td><td>  -  </td></tr>
     </table>
     * @deprecated
     */
    @Deprecated
    public okhttp3.Call archiveWorkspaceDeprecatedAsync(@javax.annotation.Nonnull String workspaceId, @javax.annotation.Nullable String xDaytonaOrganizationID, final ApiCallback<Void> _callback) throws ApiException {

        okhttp3.Call localVarCall = archiveWorkspaceDeprecatedValidateBeforeCall(workspaceId, xDaytonaOrganizationID, _callback);
        localVarApiClient.executeAsync(localVarCall, _callback);
        return localVarCall;
    }
    /**
     * Build call for createBackupWorkspaceDeprecated
     * @param workspaceId ID of the workspace (required)
     * @param xDaytonaOrganizationID Use with JWT to specify the organization ID (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 border="1">
       <caption>Response Details</caption>
        <tr><td> Status Code </td><td> Description </td><td> Response Headers </td></tr>
        <tr><td> 200 </td><td> Workspace backup has been initiated </td><td>  -  </td></tr>
     </table>
     * @deprecated
     */
    @Deprecated
    public okhttp3.Call createBackupWorkspaceDeprecatedCall(@javax.annotation.Nonnull String workspaceId, @javax.annotation.Nullable String xDaytonaOrganizationID, 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 = "/workspace/{workspaceId}/backup"
            .replace("{" + "workspaceId" + "}", localVarApiClient.escapeString(workspaceId.toString()));

        List<Pair> localVarQueryParams = new ArrayList<Pair>();
        List<Pair> localVarCollectionQueryParams = new ArrayList<Pair>();
        Map<String, String> localVarHeaderParams = new HashMap<String, String>();
        Map<String, String> localVarCookieParams = new HashMap<String, String>();
        Map<String, Object> localVarFormParams = new HashMap<String, Object>();

        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);
        }

        if (xDaytonaOrganizationID != null) {
            localVarHeaderParams.put("X-Daytona-Organization-ID", localVarApiClient.parameterToString(xDaytonaOrganizationID));
        }


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

    @Deprecated
    @SuppressWarnings("rawtypes")
    private okhttp3.Call createBackupWorkspaceDeprecatedValidateBeforeCall(@javax.annotation.Nonnull String workspaceId, @javax.annotation.Nullable String xDaytonaOrganizationID, final ApiCallback _callback) throws ApiException {
        // verify the required parameter 'workspaceId' is set
        if (workspaceId == null) {
            throw new ApiException("Missing the required parameter 'workspaceId' when calling createBackupWorkspaceDeprecated(Async)");
        }

        return createBackupWorkspaceDeprecatedCall(workspaceId, xDaytonaOrganizationID, _callback);

    }

    /**
     * [DEPRECATED] Create workspace backup
     * 
     * @param workspaceId ID of the workspace (required)
     * @param xDaytonaOrganizationID Use with JWT to specify the organization ID (optional)
     * @return Workspace
     * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
     * @http.response.details
     <table border="1">
       <caption>Response Details</caption>
        <tr><td> Status Code </td><td> Description </td><td> Response Headers </td></tr>
        <tr><td> 200 </td><td> Workspace backup has been initiated </td><td>  -  </td></tr>
     </table>
     * @deprecated
     */
    @Deprecated
    public Workspace createBackupWorkspaceDeprecated(@javax.annotation.Nonnull String workspaceId, @javax.annotation.Nullable String xDaytonaOrganizationID) throws ApiException {
        ApiResponse<Workspace> localVarResp = createBackupWorkspaceDeprecatedWithHttpInfo(workspaceId, xDaytonaOrganizationID);
        return localVarResp.getData();
    }

    /**
     * [DEPRECATED] Create workspace backup
     * 
     * @param workspaceId ID of the workspace (required)
     * @param xDaytonaOrganizationID Use with JWT to specify the organization ID (optional)
     * @return ApiResponse&lt;Workspace&gt;
     * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
     * @http.response.details
     <table border="1">
       <caption>Response Details</caption>
        <tr><td> Status Code </td><td> Description </td><td> Response Headers </td></tr>
        <tr><td> 200 </td><td> Workspace backup has been initiated </td><td>  -  </td></tr>
     </table>
     * @deprecated
     */
    @Deprecated
    public ApiResponse<Workspace> createBackupWorkspaceDeprecatedWithHttpInfo(@javax.annotation.Nonnull String workspaceId, @javax.annotation.Nullable String xDaytonaOrganizationID) throws ApiException {
        okhttp3.Call localVarCall = createBackupWorkspaceDeprecatedValidateBeforeCall(workspaceId, xDaytonaOrganizationID, null);
        Type localVarReturnType = new TypeToken<Workspace>(){}.getType();
        return localVarApiClient.execute(localVarCall, localVarReturnType);
    }

    /**
     * [DEPRECATED] Create workspace backup (asynchronously)
     * 
     * @param workspaceId ID of the workspace (required)
     * @param xDaytonaOrganizationID Use with JWT to specify the organization ID (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 border="1">
       <caption>Response Details</caption>
        <tr><td> Status Code </td><td> Description </td><td> Response Headers </td></tr>
        <tr><td> 200 </td><td> Workspace backup has been initiated </td><td>  -  </td></tr>
     </table>
     * @deprecated
     */
    @Deprecated
    public okhttp3.Call createBackupWorkspaceDeprecatedAsync(@javax.annotation.Nonnull String workspaceId, @javax.annotation.Nullable String xDaytonaOrganizationID, final ApiCallback<Workspace> _callback) throws ApiException {

        okhttp3.Call localVarCall = createBackupWorkspaceDeprecatedValidateBeforeCall(workspaceId, xDaytonaOrganizationID, _callback);
        Type localVarReturnType = new TypeToken<Workspace>(){}.getType();
        localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback);
        return localVarCall;
    }
    /**
     * Build call for createWorkspaceDeprecated
     * @param createWorkspace  (required)
     * @param xDaytonaOrganizationID Use with JWT to specify the organization ID (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 border="1">
       <caption>Response Details</caption>
        <tr><td> Status Code </td><td> Description </td><td> Response Headers </td></tr>
        <tr><td> 200 </td><td> The workspace has been successfully created. </td><td>  -  </td></tr>
     </table>
     * @deprecated
     */
    @Deprecated
    public okhttp3.Call createWorkspaceDeprecatedCall(@javax.annotation.Nonnull CreateWorkspace createWorkspace, @javax.annotation.Nullable String xDaytonaOrganizationID, 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 = createWorkspace;

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

        List<Pair> localVarQueryParams = new ArrayList<Pair>();
        List<Pair> localVarCollectionQueryParams = new ArrayList<Pair>();
        Map<String, String> localVarHeaderParams = new HashMap<String, String>();
        Map<String, String> localVarCookieParams = new HashMap<String, String>();
        Map<String, Object> localVarFormParams = new HashMap<String, Object>();

        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);
        if (localVarContentType != null) {
            localVarHeaderParams.put("Content-Type", localVarContentType);
        }

        if (xDaytonaOrganizationID != null) {
            localVarHeaderParams.put("X-Daytona-Organization-ID", localVarApiClient.parameterToString(xDaytonaOrganizationID));
        }


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

    @Deprecated
    @SuppressWarnings("rawtypes")
    private okhttp3.Call createWorkspaceDeprecatedValidateBeforeCall(@javax.annotation.Nonnull CreateWorkspace createWorkspace, @javax.annotation.Nullable String xDaytonaOrganizationID, final ApiCallback _callback) throws ApiException {
        // verify the required parameter 'createWorkspace' is set
        if (createWorkspace == null) {
            throw new ApiException("Missing the required parameter 'createWorkspace' when calling createWorkspaceDeprecated(Async)");
        }

        return createWorkspaceDeprecatedCall(createWorkspace, xDaytonaOrganizationID, _callback);

    }

    /**
     * [DEPRECATED] Create a new workspace
     * 
     * @param createWorkspace  (required)
     * @param xDaytonaOrganizationID Use with JWT to specify the organization ID (optional)
     * @return Workspace
     * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
     * @http.response.details
     <table border="1">
       <caption>Response Details</caption>
        <tr><td> Status Code </td><td> Description </td><td> Response Headers </td></tr>
        <tr><td> 200 </td><td> The workspace has been successfully created. </td><td>  -  </td></tr>
     </table>
     * @deprecated
     */
    @Deprecated
    public Workspace createWorkspaceDeprecated(@javax.annotation.Nonnull CreateWorkspace createWorkspace, @javax.annotation.Nullable String xDaytonaOrganizationID) throws ApiException {
        ApiResponse<Workspace> localVarResp = createWorkspaceDeprecatedWithHttpInfo(createWorkspace, xDaytonaOrganizationID);
        return localVarResp.getData();
    }

    /**
     * [DEPRECATED] Create a new workspace
     * 
     * @param createWorkspace  (required)
     * @param xDaytonaOrganizationID Use with JWT to specify the organization ID (optional)
     * @return ApiResponse&lt;Workspace&gt;
     * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
     * @http.response.details
     <table border="1">
       <caption>Response Details</caption>
        <tr><td> Status Code </td><td> Description </td><td> Response Headers </td></tr>
        <tr><td> 200 </td><td> The workspace has been successfully created. </td><td>  -  </td></tr>
     </table>
     * @deprecated
     */
    @Deprecated
    public ApiResponse<Workspace> createWorkspaceDeprecatedWithHttpInfo(@javax.annotation.Nonnull CreateWorkspace createWorkspace, @javax.annotation.Nullable String xDaytonaOrganizationID) throws ApiException {
        okhttp3.Call localVarCall = createWorkspaceDeprecatedValidateBeforeCall(createWorkspace, xDaytonaOrganizationID, null);
        Type localVarReturnType = new TypeToken<Workspace>(){}.getType();
        return localVarApiClient.execute(localVarCall, localVarReturnType);
    }

    /**
     * [DEPRECATED] Create a new workspace (asynchronously)
     * 
     * @param createWorkspace  (required)
     * @param xDaytonaOrganizationID Use with JWT to specify the organization ID (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 border="1">
       <caption>Response Details</caption>
        <tr><td> Status Code </td><td> Description </td><td> Response Headers </td></tr>
        <tr><td> 200 </td><td> The workspace has been successfully created. </td><td>  -  </td></tr>
     </table>
     * @deprecated
     */
    @Deprecated
    public okhttp3.Call createWorkspaceDeprecatedAsync(@javax.annotation.Nonnull CreateWorkspace createWorkspace, @javax.annotation.Nullable String xDaytonaOrganizationID, final ApiCallback<Workspace> _callback) throws ApiException {

        okhttp3.Call localVarCall = createWorkspaceDeprecatedValidateBeforeCall(createWorkspace, xDaytonaOrganizationID, _callback);
        Type localVarReturnType = new TypeToken<Workspace>(){}.getType();
        localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback);
        return localVarCall;
    }
    /**
     * Build call for deleteWorkspaceDeprecated
     * @param workspaceId ID of the workspace (required)
     * @param force  (required)
     * @param xDaytonaOrganizationID Use with JWT to specify the organization ID (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 border="1">
       <caption>Response Details</caption>
        <tr><td> Status Code </td><td> Description </td><td> Response Headers </td></tr>
        <tr><td> 200 </td><td> Workspace has been deleted </td><td>  -  </td></tr>
     </table>
     * @deprecated
     */
    @Deprecated
    public okhttp3.Call deleteWorkspaceDeprecatedCall(@javax.annotation.Nonnull String workspaceId, @javax.annotation.Nonnull Boolean force, @javax.annotation.Nullable String xDaytonaOrganizationID, 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 = "/workspace/{workspaceId}"
            .replace("{" + "workspaceId" + "}", localVarApiClient.escapeString(workspaceId.toString()));

        List<Pair> localVarQueryParams = new ArrayList<Pair>();
        List<Pair> localVarCollectionQueryParams = new ArrayList<Pair>();
        Map<String, String> localVarHeaderParams = new HashMap<String, String>();
        Map<String, String> localVarCookieParams = new HashMap<String, String>();
        Map<String, Object> localVarFormParams = new HashMap<String, Object>();

        if (force != null) {
            localVarQueryParams.addAll(localVarApiClient.parameterToPair("force", force));
        }

        final String[] localVarAccepts = {
        };
        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);
        }

        if (xDaytonaOrganizationID != null) {
            localVarHeaderParams.put("X-Daytona-Organization-ID", localVarApiClient.parameterToString(xDaytonaOrganizationID));
        }


        String[] localVarAuthNames = new String[] { "bearer", "oauth2" };
        return localVarApiClient.buildCall(basePath, localVarPath, "DELETE", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback);
    }

    @Deprecated
    @SuppressWarnings("rawtypes")
    private okhttp3.Call deleteWorkspaceDeprecatedValidateBeforeCall(@javax.annotation.Nonnull String workspaceId, @javax.annotation.Nonnull Boolean force, @javax.annotation.Nullable String xDaytonaOrganizationID, final ApiCallback _callback) throws ApiException {
        // verify the required parameter 'workspaceId' is set
        if (workspaceId == null) {
            throw new ApiException("Missing the required parameter 'workspaceId' when calling deleteWorkspaceDeprecated(Async)");
        }

        // verify the required parameter 'force' is set
        if (force == null) {
            throw new ApiException("Missing the required parameter 'force' when calling deleteWorkspaceDeprecated(Async)");
        }

        return deleteWorkspaceDeprecatedCall(workspaceId, force, xDaytonaOrganizationID, _callback);

    }

    /**
     * [DEPRECATED] Delete workspace
     * 
     * @param workspaceId ID of the workspace (required)
     * @param force  (required)
     * @param xDaytonaOrganizationID Use with JWT to specify the organization ID (optional)
     * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
     * @http.response.details
     <table border="1">
       <caption>Response Details</caption>
        <tr><td> Status Code </td><td> Description </td><td> Response Headers </td></tr>
        <tr><td> 200 </td><td> Workspace has been deleted </td><td>  -  </td></tr>
     </table>
     * @deprecated
     */
    @Deprecated
    public void deleteWorkspaceDeprecated(@javax.annotation.Nonnull String workspaceId, @javax.annotation.Nonnull Boolean force, @javax.annotation.Nullable String xDaytonaOrganizationID) throws ApiException {
        deleteWorkspaceDeprecatedWithHttpInfo(workspaceId, force, xDaytonaOrganizationID);
    }

    /**
     * [DEPRECATED] Delete workspace
     * 
     * @param workspaceId ID of the workspace (required)
     * @param force  (required)
     * @param xDaytonaOrganizationID Use with JWT to specify the organization ID (optional)
     * @return ApiResponse&lt;Void&gt;
     * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
     * @http.response.details
     <table border="1">
       <caption>Response Details</caption>
        <tr><td> Status Code </td><td> Description </td><td> Response Headers </td></tr>
        <tr><td> 200 </td><td> Workspace has been deleted </td><td>  -  </td></tr>
     </table>
     * @deprecated
     */
    @Deprecated
    public ApiResponse<Void> deleteWorkspaceDeprecatedWithHttpInfo(@javax.annotation.Nonnull String workspaceId, @javax.annotation.Nonnull Boolean force, @javax.annotation.Nullable String xDaytonaOrganizationID) throws ApiException {
        okhttp3.Call localVarCall = deleteWorkspaceDeprecatedValidateBeforeCall(workspaceId, force, xDaytonaOrganizationID, null);
        return localVarApiClient.execute(localVarCall);
    }

    /**
     * [DEPRECATED] Delete workspace (asynchronously)
     * 
     * @param workspaceId ID of the workspace (required)
     * @param force  (required)
     * @param xDaytonaOrganizationID Use with JWT to specify the organization ID (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 border="1">
       <caption>Response Details</caption>
        <tr><td> Status Code </td><td> Description </td><td> Response Headers </td></tr>
        <tr><td> 200 </td><td> Workspace has been deleted </td><td>  -  </td></tr>
     </table>
     * @deprecated
     */
    @Deprecated
    public okhttp3.Call deleteWorkspaceDeprecatedAsync(@javax.annotation.Nonnull String workspaceId, @javax.annotation.Nonnull Boolean force, @javax.annotation.Nullable String xDaytonaOrganizationID, final ApiCallback<Void> _callback) throws ApiException {

        okhttp3.Call localVarCall = deleteWorkspaceDeprecatedValidateBeforeCall(workspaceId, force, xDaytonaOrganizationID, _callback);
        localVarApiClient.executeAsync(localVarCall, _callback);
        return localVarCall;
    }
    /**
     * Build call for getBuildLogsWorkspaceDeprecated
     * @param workspaceId ID of the workspace (required)
     * @param xDaytonaOrganizationID Use with JWT to specify the organization ID (optional)
     * @param follow Whether to follow the logs stream (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 border="1">
       <caption>Response Details</caption>
        <tr><td> Status Code </td><td> Description </td><td> Response Headers </td></tr>
        <tr><td> 200 </td><td> Build logs stream </td><td>  -  </td></tr>
     </table>
     * @deprecated
     */
    @Deprecated
    public okhttp3.Call getBuildLogsWorkspaceDeprecatedCall(@javax.annotation.Nonnull String workspaceId, @javax.annotation.Nullable String xDaytonaOrganizationID, @javax.annotation.Nullable Boolean follow, 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 = "/workspace/{workspaceId}/build-logs"
            .replace("{" + "workspaceId" + "}", localVarApiClient.escapeString(workspaceId.toString()));

        List<Pair> localVarQueryParams = new ArrayList<Pair>();
        List<Pair> localVarCollectionQueryParams = new ArrayList<Pair>();
        Map<String, String> localVarHeaderParams = new HashMap<String, String>();
        Map<String, String> localVarCookieParams = new HashMap<String, String>();
        Map<String, Object> localVarFormParams = new HashMap<String, Object>();

        if (follow != null) {
            localVarQueryParams.addAll(localVarApiClient.parameterToPair("follow", follow));
        }

        final String[] localVarAccepts = {
        };
        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);
        }

        if (xDaytonaOrganizationID != null) {
            localVarHeaderParams.put("X-Daytona-Organization-ID", localVarApiClient.parameterToString(xDaytonaOrganizationID));
        }


        String[] localVarAuthNames = new String[] { "bearer", "oauth2" };
        return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback);
    }

    @Deprecated
    @SuppressWarnings("rawtypes")
    private okhttp3.Call getBuildLogsWorkspaceDeprecatedValidateBeforeCall(@javax.annotation.Nonnull String workspaceId, @javax.annotation.Nullable String xDaytonaOrganizationID, @javax.annotation.Nullable Boolean follow, final ApiCallback _callback) throws ApiException {
        // verify the required parameter 'workspaceId' is set
        if (workspaceId == null) {
            throw new ApiException("Missing the required parameter 'workspaceId' when calling getBuildLogsWorkspaceDeprecated(Async)");
        }

        return getBuildLogsWorkspaceDeprecatedCall(workspaceId, xDaytonaOrganizationID, follow, _callback);

    }

    /**
     * [DEPRECATED] Get build logs
     * 
     * @param workspaceId ID of the workspace (required)
     * @param xDaytonaOrganizationID Use with JWT to specify the organization ID (optional)
     * @param follow Whether to follow the logs stream (optional)
     * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
     * @http.response.details
     <table border="1">
       <caption>Response Details</caption>
        <tr><td> Status Code </td><td> Description </td><td> Response Headers </td></tr>
        <tr><td> 200 </td><td> Build logs stream </td><td>  -  </td></tr>
     </table>
     * @deprecated
     */
    @Deprecated
    public void getBuildLogsWorkspaceDeprecated(@javax.annotation.Nonnull String workspaceId, @javax.annotation.Nullable String xDaytonaOrganizationID, @javax.annotation.Nullable Boolean follow) throws ApiException {
        getBuildLogsWorkspaceDeprecatedWithHttpInfo(workspaceId, xDaytonaOrganizationID, follow);
    }

    /**
     * [DEPRECATED] Get build logs
     * 
     * @param workspaceId ID of the workspace (required)
     * @param xDaytonaOrganizationID Use with JWT to specify the organization ID (optional)
     * @param follow Whether to follow the logs stream (optional)
     * @return ApiResponse&lt;Void&gt;
     * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
     * @http.response.details
     <table border="1">
       <caption>Response Details</caption>
        <tr><td> Status Code </td><td> Description </td><td> Response Headers </td></tr>
        <tr><td> 200 </td><td> Build logs stream </td><td>  -  </td></tr>
     </table>
     * @deprecated
     */
    @Deprecated
    public ApiResponse<Void> getBuildLogsWorkspaceDeprecatedWithHttpInfo(@javax.annotation.Nonnull String workspaceId, @javax.annotation.Nullable String xDaytonaOrganizationID, @javax.annotation.Nullable Boolean follow) throws ApiException {
        okhttp3.Call localVarCall = getBuildLogsWorkspaceDeprecatedValidateBeforeCall(workspaceId, xDaytonaOrganizationID, follow, null);
        return localVarApiClient.execute(localVarCall);
    }

    /**
     * [DEPRECATED] Get build logs (asynchronously)
     * 
     * @param workspaceId ID of the workspace (required)
     * @param xDaytonaOrganizationID Use with JWT to specify the organization ID (optional)
     * @param follow Whether to follow the logs stream (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 border="1">
       <caption>Response Details</caption>
        <tr><td> Status Code </td><td> Description </td><td> Response Headers </td></tr>
        <tr><td> 200 </td><td> Build logs stream </td><td>  -  </td></tr>
     </table>
     * @deprecated
     */
    @Deprecated
    public okhttp3.Call getBuildLogsWorkspaceDeprecatedAsync(@javax.annotation.Nonnull String workspaceId, @javax.annotation.Nullable String xDaytonaOrganizationID, @javax.annotation.Nullable Boolean follow, final ApiCallback<Void> _callback) throws ApiException {

        okhttp3.Call localVarCall = getBuildLogsWorkspaceDeprecatedValidateBeforeCall(workspaceId, xDaytonaOrganizationID, follow, _callback);
        localVarApiClient.executeAsync(localVarCall, _callback);
        return localVarCall;
    }
    /**
     * Build call for getPortPreviewUrlWorkspaceDeprecated
     * @param workspaceId ID of the workspace (required)
     * @param port Port number to get preview URL for (required)
     * @param xDaytonaOrganizationID Use with JWT to specify the organization ID (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 border="1">
       <caption>Response Details</caption>
        <tr><td> Status Code </td><td> Description </td><td> Response Headers </td></tr>
        <tr><td> 200 </td><td> Preview URL for the specified port </td><td>  -  </td></tr>
     </table>
     * @deprecated
     */
    @Deprecated
    public okhttp3.Call getPortPreviewUrlWorkspaceDeprecatedCall(@javax.annotation.Nonnull String workspaceId, @javax.annotation.Nonnull BigDecimal port, @javax.annotation.Nullable String xDaytonaOrganizationID, 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 = "/workspace/{workspaceId}/ports/{port}/preview-url"
            .replace("{" + "workspaceId" + "}", localVarApiClient.escapeString(workspaceId.toString()))
            .replace("{" + "port" + "}", localVarApiClient.escapeString(port.toString()));

        List<Pair> localVarQueryParams = new ArrayList<Pair>();
        List<Pair> localVarCollectionQueryParams = new ArrayList<Pair>();
        Map<String, String> localVarHeaderParams = new HashMap<String, String>();
        Map<String, String> localVarCookieParams = new HashMap<String, String>();
        Map<String, Object> localVarFormParams = new HashMap<String, Object>();

        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);
        }

        if (xDaytonaOrganizationID != null) {
            localVarHeaderParams.put("X-Daytona-Organization-ID", localVarApiClient.parameterToString(xDaytonaOrganizationID));
        }


        String[] localVarAuthNames = new String[] { "bearer", "oauth2" };
        return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback);
    }

    @Deprecated
    @SuppressWarnings("rawtypes")
    private okhttp3.Call getPortPreviewUrlWorkspaceDeprecatedValidateBeforeCall(@javax.annotation.Nonnull String workspaceId, @javax.annotation.Nonnull BigDecimal port, @javax.annotation.Nullable String xDaytonaOrganizationID, final ApiCallback _callback) throws ApiException {
        // verify the required parameter 'workspaceId' is set
        if (workspaceId == null) {
            throw new ApiException("Missing the required parameter 'workspaceId' when calling getPortPreviewUrlWorkspaceDeprecated(Async)");
        }

        // verify the required parameter 'port' is set
        if (port == null) {
            throw new ApiException("Missing the required parameter 'port' when calling getPortPreviewUrlWorkspaceDeprecated(Async)");
        }

        return getPortPreviewUrlWorkspaceDeprecatedCall(workspaceId, port, xDaytonaOrganizationID, _callback);

    }

    /**
     * [DEPRECATED] Get preview URL for a workspace port
     * 
     * @param workspaceId ID of the workspace (required)
     * @param port Port number to get preview URL for (required)
     * @param xDaytonaOrganizationID Use with JWT to specify the organization ID (optional)
     * @return WorkspacePortPreviewUrl
     * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
     * @http.response.details
     <table border="1">
       <caption>Response Details</caption>
        <tr><td> Status Code </td><td> Description </td><td> Response Headers </td></tr>
        <tr><td> 200 </td><td> Preview URL for the specified port </td><td>  -  </td></tr>
     </table>
     * @deprecated
     */
    @Deprecated
    public WorkspacePortPreviewUrl getPortPreviewUrlWorkspaceDeprecated(@javax.annotation.Nonnull String workspaceId, @javax.annotation.Nonnull BigDecimal port, @javax.annotation.Nullable String xDaytonaOrganizationID) throws ApiException {
        ApiResponse<WorkspacePortPreviewUrl> localVarResp = getPortPreviewUrlWorkspaceDeprecatedWithHttpInfo(workspaceId, port, xDaytonaOrganizationID);
        return localVarResp.getData();
    }

    /**
     * [DEPRECATED] Get preview URL for a workspace port
     * 
     * @param workspaceId ID of the workspace (required)
     * @param port Port number to get preview URL for (required)
     * @param xDaytonaOrganizationID Use with JWT to specify the organization ID (optional)
     * @return ApiResponse&lt;WorkspacePortPreviewUrl&gt;
     * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
     * @http.response.details
     <table border="1">
       <caption>Response Details</caption>
        <tr><td> Status Code </td><td> Description </td><td> Response Headers </td></tr>
        <tr><td> 200 </td><td> Preview URL for the specified port </td><td>  -  </td></tr>
     </table>
     * @deprecated
     */
    @Deprecated
    public ApiResponse<WorkspacePortPreviewUrl> getPortPreviewUrlWorkspaceDeprecatedWithHttpInfo(@javax.annotation.Nonnull String workspaceId, @javax.annotation.Nonnull BigDecimal port, @javax.annotation.Nullable String xDaytonaOrganizationID) throws ApiException {
        okhttp3.Call localVarCall = getPortPreviewUrlWorkspaceDeprecatedValidateBeforeCall(workspaceId, port, xDaytonaOrganizationID, null);
        Type localVarReturnType = new TypeToken<WorkspacePortPreviewUrl>(){}.getType();
        return localVarApiClient.execute(localVarCall, localVarReturnType);
    }

    /**
     * [DEPRECATED] Get preview URL for a workspace port (asynchronously)
     * 
     * @param workspaceId ID of the workspace (required)
     * @param port Port number to get preview URL for (required)
     * @param xDaytonaOrganizationID Use with JWT to specify the organization ID (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 border="1">
       <caption>Response Details</caption>
        <tr><td> Status Code </td><td> Description </td><td> Response Headers </td></tr>
        <tr><td> 200 </td><td> Preview URL for the specified port </td><td>  -  </td></tr>
     </table>
     * @deprecated
     */
    @Deprecated
    public okhttp3.Call getPortPreviewUrlWorkspaceDeprecatedAsync(@javax.annotation.Nonnull String workspaceId, @javax.annotation.Nonnull BigDecimal port, @javax.annotation.Nullable String xDaytonaOrganizationID, final ApiCallback<WorkspacePortPreviewUrl> _callback) throws ApiException {

        okhttp3.Call localVarCall = getPortPreviewUrlWorkspaceDeprecatedValidateBeforeCall(workspaceId, port, xDaytonaOrganizationID, _callback);
        Type localVarReturnType = new TypeToken<WorkspacePortPreviewUrl>(){}.getType();
        localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback);
        return localVarCall;
    }
    /**
     * Build call for getWorkspaceDeprecated
     * @param workspaceId ID of the workspace (required)
     * @param xDaytonaOrganizationID Use with JWT to specify the organization ID (optional)
     * @param verbose Include verbose output (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 border="1">
       <caption>Response Details</caption>
        <tr><td> Status Code </td><td> Description </td><td> Response Headers </td></tr>
        <tr><td> 200 </td><td> Workspace details </td><td>  -  </td></tr>
     </table>
     * @deprecated
     */
    @Deprecated
    public okhttp3.Call getWorkspaceDeprecatedCall(@javax.annotation.Nonnull String workspaceId, @javax.annotation.Nullable String xDaytonaOrganizationID, @javax.annotation.Nullable Boolean verbose, 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 = "/workspace/{workspaceId}"
            .replace("{" + "workspaceId" + "}", localVarApiClient.escapeString(workspaceId.toString()));

        List<Pair> localVarQueryParams = new ArrayList<Pair>();
        List<Pair> localVarCollectionQueryParams = new ArrayList<Pair>();
        Map<String, String> localVarHeaderParams = new HashMap<String, String>();
        Map<String, String> localVarCookieParams = new HashMap<String, String>();
        Map<String, Object> localVarFormParams = new HashMap<String, Object>();

        if (verbose != null) {
            localVarQueryParams.addAll(localVarApiClient.parameterToPair("verbose", verbose));
        }

        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);
        }

        if (xDaytonaOrganizationID != null) {
            localVarHeaderParams.put("X-Daytona-Organization-ID", localVarApiClient.parameterToString(xDaytonaOrganizationID));
        }


        String[] localVarAuthNames = new String[] { "bearer", "oauth2" };
        return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback);
    }

    @Deprecated
    @SuppressWarnings("rawtypes")
    private okhttp3.Call getWorkspaceDeprecatedValidateBeforeCall(@javax.annotation.Nonnull String workspaceId, @javax.annotation.Nullable String xDaytonaOrganizationID, @javax.annotation.Nullable Boolean verbose, final ApiCallback _callback) throws ApiException {
        // verify the required parameter 'workspaceId' is set
        if (workspaceId == null) {
            throw new ApiException("Missing the required parameter 'workspaceId' when calling getWorkspaceDeprecated(Async)");
        }

        return getWorkspaceDeprecatedCall(workspaceId, xDaytonaOrganizationID, verbose, _callback);

    }

    /**
     * [DEPRECATED] Get workspace details
     * 
     * @param workspaceId ID of the workspace (required)
     * @param xDaytonaOrganizationID Use with JWT to specify the organization ID (optional)
     * @param verbose Include verbose output (optional)
     * @return Workspace
     * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
     * @http.response.details
     <table border="1">
       <caption>Response Details</caption>
        <tr><td> Status Code </td><td> Description </td><td> Response Headers </td></tr>
        <tr><td> 200 </td><td> Workspace details </td><td>  -  </td></tr>
     </table>
     * @deprecated
     */
    @Deprecated
    public Workspace getWorkspaceDeprecated(@javax.annotation.Nonnull String workspaceId, @javax.annotation.Nullable String xDaytonaOrganizationID, @javax.annotation.Nullable Boolean verbose) throws ApiException {
        ApiResponse<Workspace> localVarResp = getWorkspaceDeprecatedWithHttpInfo(workspaceId, xDaytonaOrganizationID, verbose);
        return localVarResp.getData();
    }

    /**
     * [DEPRECATED] Get workspace details
     * 
     * @param workspaceId ID of the workspace (required)
     * @param xDaytonaOrganizationID Use with JWT to specify the organization ID (optional)
     * @param verbose Include verbose output (optional)
     * @return ApiResponse&lt;Workspace&gt;
     * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
     * @http.response.details
     <table border="1">
       <caption>Response Details</caption>
        <tr><td> Status Code </td><td> Description </td><td> Response Headers </td></tr>
        <tr><td> 200 </td><td> Workspace details </td><td>  -  </td></tr>
     </table>
     * @deprecated
     */
    @Deprecated
    public ApiResponse<Workspace> getWorkspaceDeprecatedWithHttpInfo(@javax.annotation.Nonnull String workspaceId, @javax.annotation.Nullable String xDaytonaOrganizationID, @javax.annotation.Nullable Boolean verbose) throws ApiException {
        okhttp3.Call localVarCall = getWorkspaceDeprecatedValidateBeforeCall(workspaceId, xDaytonaOrganizationID, verbose, null);
        Type localVarReturnType = new TypeToken<Workspace>(){}.getType();
        return localVarApiClient.execute(localVarCall, localVarReturnType);
    }

    /**
     * [DEPRECATED] Get workspace details (asynchronously)
     * 
     * @param workspaceId ID of the workspace (required)
     * @param xDaytonaOrganizationID Use with JWT to specify the organization ID (optional)
     * @param verbose Include verbose output (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 border="1">
       <caption>Response Details</caption>
        <tr><td> Status Code </td><td> Description </td><td> Response Headers </td></tr>
        <tr><td> 200 </td><td> Workspace details </td><td>  -  </td></tr>
     </table>
     * @deprecated
     */
    @Deprecated
    public okhttp3.Call getWorkspaceDeprecatedAsync(@javax.annotation.Nonnull String workspaceId, @javax.annotation.Nullable String xDaytonaOrganizationID, @javax.annotation.Nullable Boolean verbose, final ApiCallback<Workspace> _callback) throws ApiException {

        okhttp3.Call localVarCall = getWorkspaceDeprecatedValidateBeforeCall(workspaceId, xDaytonaOrganizationID, verbose, _callback);
        Type localVarReturnType = new TypeToken<Workspace>(){}.getType();
        localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback);
        return localVarCall;
    }
    /**
     * Build call for listWorkspacesDeprecated
     * @param xDaytonaOrganizationID Use with JWT to specify the organization ID (optional)
     * @param verbose Include verbose output (optional)
     * @param labels JSON encoded labels to filter by (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 border="1">
       <caption>Response Details</caption>
        <tr><td> Status Code </td><td> Description </td><td> Response Headers </td></tr>
        <tr><td> 200 </td><td> List of all workspacees </td><td>  -  </td></tr>
     </table>
     * @deprecated
     */
    @Deprecated
    public okhttp3.Call listWorkspacesDeprecatedCall(@javax.annotation.Nullable String xDaytonaOrganizationID, @javax.annotation.Nullable Boolean verbose, @javax.annotation.Nullable String labels, 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 = "/workspace";

        List<Pair> localVarQueryParams = new ArrayList<Pair>();
        List<Pair> localVarCollectionQueryParams = new ArrayList<Pair>();
        Map<String, String> localVarHeaderParams = new HashMap<String, String>();
        Map<String, String> localVarCookieParams = new HashMap<String, String>();
        Map<String, Object> localVarFormParams = new HashMap<String, Object>();

        if (verbose != null) {
            localVarQueryParams.addAll(localVarApiClient.parameterToPair("verbose", verbose));
        }

        if (labels != null) {
            localVarQueryParams.addAll(localVarApiClient.parameterToPair("labels", labels));
        }

        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);
        }

        if (xDaytonaOrganizationID != null) {
            localVarHeaderParams.put("X-Daytona-Organization-ID", localVarApiClient.parameterToString(xDaytonaOrganizationID));
        }


        String[] localVarAuthNames = new String[] { "bearer", "oauth2" };
        return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback);
    }

    @Deprecated
    @SuppressWarnings("rawtypes")
    private okhttp3.Call listWorkspacesDeprecatedValidateBeforeCall(@javax.annotation.Nullable String xDaytonaOrganizationID, @javax.annotation.Nullable Boolean verbose, @javax.annotation.Nullable String labels, final ApiCallback _callback) throws ApiException {
        return listWorkspacesDeprecatedCall(xDaytonaOrganizationID, verbose, labels, _callback);

    }

    /**
     * [DEPRECATED] List all workspaces
     * 
     * @param xDaytonaOrganizationID Use with JWT to specify the organization ID (optional)
     * @param verbose Include verbose output (optional)
     * @param labels JSON encoded labels to filter by (optional)
     * @return List&lt;Workspace&gt;
     * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
     * @http.response.details
     <table border="1">
       <caption>Response Details</caption>
        <tr><td> Status Code </td><td> Description </td><td> Response Headers </td></tr>
        <tr><td> 200 </td><td> List of all workspacees </td><td>  -  </td></tr>
     </table>
     * @deprecated
     */
    @Deprecated
    public List<Workspace> listWorkspacesDeprecated(@javax.annotation.Nullable String xDaytonaOrganizationID, @javax.annotation.Nullable Boolean verbose, @javax.annotation.Nullable String labels) throws ApiException {
        ApiResponse<List<Workspace>> localVarResp = listWorkspacesDeprecatedWithHttpInfo(xDaytonaOrganizationID, verbose, labels);
        return localVarResp.getData();
    }

    /**
     * [DEPRECATED] List all workspaces
     * 
     * @param xDaytonaOrganizationID Use with JWT to specify the organization ID (optional)
     * @param verbose Include verbose output (optional)
     * @param labels JSON encoded labels to filter by (optional)
     * @return ApiResponse&lt;List&lt;Workspace&gt;&gt;
     * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
     * @http.response.details
     <table border="1">
       <caption>Response Details</caption>
        <tr><td> Status Code </td><td> Description </td><td> Response Headers </td></tr>
        <tr><td> 200 </td><td> List of all workspacees </td><td>  -  </td></tr>
     </table>
     * @deprecated
     */
    @Deprecated
    public ApiResponse<List<Workspace>> listWorkspacesDeprecatedWithHttpInfo(@javax.annotation.Nullable String xDaytonaOrganizationID, @javax.annotation.Nullable Boolean verbose, @javax.annotation.Nullable String labels) throws ApiException {
        okhttp3.Call localVarCall = listWorkspacesDeprecatedValidateBeforeCall(xDaytonaOrganizationID, verbose, labels, null);
        Type localVarReturnType = new TypeToken<List<Workspace>>(){}.getType();
        return localVarApiClient.execute(localVarCall, localVarReturnType);
    }

    /**
     * [DEPRECATED] List all workspaces (asynchronously)
     * 
     * @param xDaytonaOrganizationID Use with JWT to specify the organization ID (optional)
     * @param verbose Include verbose output (optional)
     * @param labels JSON encoded labels to filter by (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 border="1">
       <caption>Response Details</caption>
        <tr><td> Status Code </td><td> Description </td><td> Response Headers </td></tr>
        <tr><td> 200 </td><td> List of all workspacees </td><td>  -  </td></tr>
     </table>
     * @deprecated
     */
    @Deprecated
    public okhttp3.Call listWorkspacesDeprecatedAsync(@javax.annotation.Nullable String xDaytonaOrganizationID, @javax.annotation.Nullable Boolean verbose, @javax.annotation.Nullable String labels, final ApiCallback<List<Workspace>> _callback) throws ApiException {

        okhttp3.Call localVarCall = listWorkspacesDeprecatedValidateBeforeCall(xDaytonaOrganizationID, verbose, labels, _callback);
        Type localVarReturnType = new TypeToken<List<Workspace>>(){}.getType();
        localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback);
        return localVarCall;
    }
    /**
     * Build call for replaceLabelsWorkspaceDeprecated
     * @param workspaceId ID of the workspace (required)
     * @param sandboxLabels  (required)
     * @param xDaytonaOrganizationID Use with JWT to specify the organization ID (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 border="1">
       <caption>Response Details</caption>
        <tr><td> Status Code </td><td> Description </td><td> Response Headers </td></tr>
        <tr><td> 200 </td><td> Labels have been successfully replaced </td><td>  -  </td></tr>
     </table>
     * @deprecated
     */
    @Deprecated
    public okhttp3.Call replaceLabelsWorkspaceDeprecatedCall(@javax.annotation.Nonnull String workspaceId, @javax.annotation.Nonnull SandboxLabels sandboxLabels, @javax.annotation.Nullable String xDaytonaOrganizationID, 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 = sandboxLabels;

        // create path and map variables
        String localVarPath = "/workspace/{workspaceId}/labels"
            .replace("{" + "workspaceId" + "}", localVarApiClient.escapeString(workspaceId.toString()));

        List<Pair> localVarQueryParams = new ArrayList<Pair>();
        List<Pair> localVarCollectionQueryParams = new ArrayList<Pair>();
        Map<String, String> localVarHeaderParams = new HashMap<String, String>();
        Map<String, String> localVarCookieParams = new HashMap<String, String>();
        Map<String, Object> localVarFormParams = new HashMap<String, Object>();

        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);
        if (localVarContentType != null) {
            localVarHeaderParams.put("Content-Type", localVarContentType);
        }

        if (xDaytonaOrganizationID != null) {
            localVarHeaderParams.put("X-Daytona-Organization-ID", localVarApiClient.parameterToString(xDaytonaOrganizationID));
        }


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

    @Deprecated
    @SuppressWarnings("rawtypes")
    private okhttp3.Call replaceLabelsWorkspaceDeprecatedValidateBeforeCall(@javax.annotation.Nonnull String workspaceId, @javax.annotation.Nonnull SandboxLabels sandboxLabels, @javax.annotation.Nullable String xDaytonaOrganizationID, final ApiCallback _callback) throws ApiException {
        // verify the required parameter 'workspaceId' is set
        if (workspaceId == null) {
            throw new ApiException("Missing the required parameter 'workspaceId' when calling replaceLabelsWorkspaceDeprecated(Async)");
        }

        // verify the required parameter 'sandboxLabels' is set
        if (sandboxLabels == null) {
            throw new ApiException("Missing the required parameter 'sandboxLabels' when calling replaceLabelsWorkspaceDeprecated(Async)");
        }

        return replaceLabelsWorkspaceDeprecatedCall(workspaceId, sandboxLabels, xDaytonaOrganizationID, _callback);

    }

    /**
     * [DEPRECATED] Replace workspace labels
     * 
     * @param workspaceId ID of the workspace (required)
     * @param sandboxLabels  (required)
     * @param xDaytonaOrganizationID Use with JWT to specify the organization ID (optional)
     * @return SandboxLabels
     * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
     * @http.response.details
     <table border="1">
       <caption>Response Details</caption>
        <tr><td> Status Code </td><td> Description </td><td> Response Headers </td></tr>
        <tr><td> 200 </td><td> Labels have been successfully replaced </td><td>  -  </td></tr>
     </table>
     * @deprecated
     */
    @Deprecated
    public SandboxLabels replaceLabelsWorkspaceDeprecated(@javax.annotation.Nonnull String workspaceId, @javax.annotation.Nonnull SandboxLabels sandboxLabels, @javax.annotation.Nullable String xDaytonaOrganizationID) throws ApiException {
        ApiResponse<SandboxLabels> localVarResp = replaceLabelsWorkspaceDeprecatedWithHttpInfo(workspaceId, sandboxLabels, xDaytonaOrganizationID);
        return localVarResp.getData();
    }

    /**
     * [DEPRECATED] Replace workspace labels
     * 
     * @param workspaceId ID of the workspace (required)
     * @param sandboxLabels  (required)
     * @param xDaytonaOrganizationID Use with JWT to specify the organization ID (optional)
     * @return ApiResponse&lt;SandboxLabels&gt;
     * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
     * @http.response.details
     <table border="1">
       <caption>Response Details</caption>
        <tr><td> Status Code </td><td> Description </td><td> Response Headers </td></tr>
        <tr><td> 200 </td><td> Labels have been successfully replaced </td><td>  -  </td></tr>
     </table>
     * @deprecated
     */
    @Deprecated
    public ApiResponse<SandboxLabels> replaceLabelsWorkspaceDeprecatedWithHttpInfo(@javax.annotation.Nonnull String workspaceId, @javax.annotation.Nonnull SandboxLabels sandboxLabels, @javax.annotation.Nullable String xDaytonaOrganizationID) throws ApiException {
        okhttp3.Call localVarCall = replaceLabelsWorkspaceDeprecatedValidateBeforeCall(workspaceId, sandboxLabels, xDaytonaOrganizationID, null);
        Type localVarReturnType = new TypeToken<SandboxLabels>(){}.getType();
        return localVarApiClient.execute(localVarCall, localVarReturnType);
    }

    /**
     * [DEPRECATED] Replace workspace labels (asynchronously)
     * 
     * @param workspaceId ID of the workspace (required)
     * @param sandboxLabels  (required)
     * @param xDaytonaOrganizationID Use with JWT to specify the organization ID (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 border="1">
       <caption>Response Details</caption>
        <tr><td> Status Code </td><td> Description </td><td> Response Headers </td></tr>
        <tr><td> 200 </td><td> Labels have been successfully replaced </td><td>  -  </td></tr>
     </table>
     * @deprecated
     */
    @Deprecated
    public okhttp3.Call replaceLabelsWorkspaceDeprecatedAsync(@javax.annotation.Nonnull String workspaceId, @javax.annotation.Nonnull SandboxLabels sandboxLabels, @javax.annotation.Nullable String xDaytonaOrganizationID, final ApiCallback<SandboxLabels> _callback) throws ApiException {

        okhttp3.Call localVarCall = replaceLabelsWorkspaceDeprecatedValidateBeforeCall(workspaceId, sandboxLabels, xDaytonaOrganizationID, _callback);
        Type localVarReturnType = new TypeToken<SandboxLabels>(){}.getType();
        localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback);
        return localVarCall;
    }
    /**
     * Build call for setAutoArchiveIntervalWorkspaceDeprecated
     * @param workspaceId ID of the workspace (required)
     * @param interval Auto-archive interval in minutes (0 means the maximum interval will be used) (required)
     * @param xDaytonaOrganizationID Use with JWT to specify the organization ID (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 border="1">
       <caption>Response Details</caption>
        <tr><td> Status Code </td><td> Description </td><td> Response Headers </td></tr>
        <tr><td> 200 </td><td> Auto-archive interval has been set </td><td>  -  </td></tr>
     </table>
     * @deprecated
     */
    @Deprecated
    public okhttp3.Call setAutoArchiveIntervalWorkspaceDeprecatedCall(@javax.annotation.Nonnull String workspaceId, @javax.annotation.Nonnull BigDecimal interval, @javax.annotation.Nullable String xDaytonaOrganizationID, 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 = "/workspace/{workspaceId}/autoarchive/{interval}"
            .replace("{" + "workspaceId" + "}", localVarApiClient.escapeString(workspaceId.toString()))
            .replace("{" + "interval" + "}", localVarApiClient.escapeString(interval.toString()));

        List<Pair> localVarQueryParams = new ArrayList<Pair>();
        List<Pair> localVarCollectionQueryParams = new ArrayList<Pair>();
        Map<String, String> localVarHeaderParams = new HashMap<String, String>();
        Map<String, String> localVarCookieParams = new HashMap<String, String>();
        Map<String, Object> localVarFormParams = new HashMap<String, Object>();

        final String[] localVarAccepts = {
        };
        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);
        }

        if (xDaytonaOrganizationID != null) {
            localVarHeaderParams.put("X-Daytona-Organization-ID", localVarApiClient.parameterToString(xDaytonaOrganizationID));
        }


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

    @Deprecated
    @SuppressWarnings("rawtypes")
    private okhttp3.Call setAutoArchiveIntervalWorkspaceDeprecatedValidateBeforeCall(@javax.annotation.Nonnull String workspaceId, @javax.annotation.Nonnull BigDecimal interval, @javax.annotation.Nullable String xDaytonaOrganizationID, final ApiCallback _callback) throws ApiException {
        // verify the required parameter 'workspaceId' is set
        if (workspaceId == null) {
            throw new ApiException("Missing the required parameter 'workspaceId' when calling setAutoArchiveIntervalWorkspaceDeprecated(Async)");
        }

        // verify the required parameter 'interval' is set
        if (interval == null) {
            throw new ApiException("Missing the required parameter 'interval' when calling setAutoArchiveIntervalWorkspaceDeprecated(Async)");
        }

        return setAutoArchiveIntervalWorkspaceDeprecatedCall(workspaceId, interval, xDaytonaOrganizationID, _callback);

    }

    /**
     * [DEPRECATED] Set workspace auto-archive interval
     * 
     * @param workspaceId ID of the workspace (required)
     * @param interval Auto-archive interval in minutes (0 means the maximum interval will be used) (required)
     * @param xDaytonaOrganizationID Use with JWT to specify the organization ID (optional)
     * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
     * @http.response.details
     <table border="1">
       <caption>Response Details</caption>
        <tr><td> Status Code </td><td> Description </td><td> Response Headers </td></tr>
        <tr><td> 200 </td><td> Auto-archive interval has been set </td><td>  -  </td></tr>
     </table>
     * @deprecated
     */
    @Deprecated
    public void setAutoArchiveIntervalWorkspaceDeprecated(@javax.annotation.Nonnull String workspaceId, @javax.annotation.Nonnull BigDecimal interval, @javax.annotation.Nullable String xDaytonaOrganizationID) throws ApiException {
        setAutoArchiveIntervalWorkspaceDeprecatedWithHttpInfo(workspaceId, interval, xDaytonaOrganizationID);
    }

    /**
     * [DEPRECATED] Set workspace auto-archive interval
     * 
     * @param workspaceId ID of the workspace (required)
     * @param interval Auto-archive interval in minutes (0 means the maximum interval will be used) (required)
     * @param xDaytonaOrganizationID Use with JWT to specify the organization ID (optional)
     * @return ApiResponse&lt;Void&gt;
     * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
     * @http.response.details
     <table border="1">
       <caption>Response Details</caption>
        <tr><td> Status Code </td><td> Description </td><td> Response Headers </td></tr>
        <tr><td> 200 </td><td> Auto-archive interval has been set </td><td>  -  </td></tr>
     </table>
     * @deprecated
     */
    @Deprecated
    public ApiResponse<Void> setAutoArchiveIntervalWorkspaceDeprecatedWithHttpInfo(@javax.annotation.Nonnull String workspaceId, @javax.annotation.Nonnull BigDecimal interval, @javax.annotation.Nullable String xDaytonaOrganizationID) throws ApiException {
        okhttp3.Call localVarCall = setAutoArchiveIntervalWorkspaceDeprecatedValidateBeforeCall(workspaceId, interval, xDaytonaOrganizationID, null);
        return localVarApiClient.execute(localVarCall);
    }

    /**
     * [DEPRECATED] Set workspace auto-archive interval (asynchronously)
     * 
     * @param workspaceId ID of the workspace (required)
     * @param interval Auto-archive interval in minutes (0 means the maximum interval will be used) (required)
     * @param xDaytonaOrganizationID Use with JWT to specify the organization ID (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 border="1">
       <caption>Response Details</caption>
        <tr><td> Status Code </td><td> Description </td><td> Response Headers </td></tr>
        <tr><td> 200 </td><td> Auto-archive interval has been set </td><td>  -  </td></tr>
     </table>
     * @deprecated
     */
    @Deprecated
    public okhttp3.Call setAutoArchiveIntervalWorkspaceDeprecatedAsync(@javax.annotation.Nonnull String workspaceId, @javax.annotation.Nonnull BigDecimal interval, @javax.annotation.Nullable String xDaytonaOrganizationID, final ApiCallback<Void> _callback) throws ApiException {

        okhttp3.Call localVarCall = setAutoArchiveIntervalWorkspaceDeprecatedValidateBeforeCall(workspaceId, interval, xDaytonaOrganizationID, _callback);
        localVarApiClient.executeAsync(localVarCall, _callback);
        return localVarCall;
    }
    /**
     * Build call for setAutostopIntervalWorkspaceDeprecated
     * @param workspaceId ID of the workspace (required)
     * @param interval Auto-stop interval in minutes (0 to disable) (required)
     * @param xDaytonaOrganizationID Use with JWT to specify the organization ID (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 border="1">
       <caption>Response Details</caption>
        <tr><td> Status Code </td><td> Description </td><td> Response Headers </td></tr>
        <tr><td> 200 </td><td> Auto-stop interval has been set </td><td>  -  </td></tr>
     </table>
     * @deprecated
     */
    @Deprecated
    public okhttp3.Call setAutostopIntervalWorkspaceDeprecatedCall(@javax.annotation.Nonnull String workspaceId, @javax.annotation.Nonnull BigDecimal interval, @javax.annotation.Nullable String xDaytonaOrganizationID, 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 = "/workspace/{workspaceId}/autostop/{interval}"
            .replace("{" + "workspaceId" + "}", localVarApiClient.escapeString(workspaceId.toString()))
            .replace("{" + "interval" + "}", localVarApiClient.escapeString(interval.toString()));

        List<Pair> localVarQueryParams = new ArrayList<Pair>();
        List<Pair> localVarCollectionQueryParams = new ArrayList<Pair>();
        Map<String, String> localVarHeaderParams = new HashMap<String, String>();
        Map<String, String> localVarCookieParams = new HashMap<String, String>();
        Map<String, Object> localVarFormParams = new HashMap<String, Object>();

        final String[] localVarAccepts = {
        };
        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);
        }

        if (xDaytonaOrganizationID != null) {
            localVarHeaderParams.put("X-Daytona-Organization-ID", localVarApiClient.parameterToString(xDaytonaOrganizationID));
        }


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

    @Deprecated
    @SuppressWarnings("rawtypes")
    private okhttp3.Call setAutostopIntervalWorkspaceDeprecatedValidateBeforeCall(@javax.annotation.Nonnull String workspaceId, @javax.annotation.Nonnull BigDecimal interval, @javax.annotation.Nullable String xDaytonaOrganizationID, final ApiCallback _callback) throws ApiException {
        // verify the required parameter 'workspaceId' is set
        if (workspaceId == null) {
            throw new ApiException("Missing the required parameter 'workspaceId' when calling setAutostopIntervalWorkspaceDeprecated(Async)");
        }

        // verify the required parameter 'interval' is set
        if (interval == null) {
            throw new ApiException("Missing the required parameter 'interval' when calling setAutostopIntervalWorkspaceDeprecated(Async)");
        }

        return setAutostopIntervalWorkspaceDeprecatedCall(workspaceId, interval, xDaytonaOrganizationID, _callback);

    }

    /**
     * [DEPRECATED] Set workspace auto-stop interval
     * 
     * @param workspaceId ID of the workspace (required)
     * @param interval Auto-stop interval in minutes (0 to disable) (required)
     * @param xDaytonaOrganizationID Use with JWT to specify the organization ID (optional)
     * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
     * @http.response.details
     <table border="1">
       <caption>Response Details</caption>
        <tr><td> Status Code </td><td> Description </td><td> Response Headers </td></tr>
        <tr><td> 200 </td><td> Auto-stop interval has been set </td><td>  -  </td></tr>
     </table>
     * @deprecated
     */
    @Deprecated
    public void setAutostopIntervalWorkspaceDeprecated(@javax.annotation.Nonnull String workspaceId, @javax.annotation.Nonnull BigDecimal interval, @javax.annotation.Nullable String xDaytonaOrganizationID) throws ApiException {
        setAutostopIntervalWorkspaceDeprecatedWithHttpInfo(workspaceId, interval, xDaytonaOrganizationID);
    }

    /**
     * [DEPRECATED] Set workspace auto-stop interval
     * 
     * @param workspaceId ID of the workspace (required)
     * @param interval Auto-stop interval in minutes (0 to disable) (required)
     * @param xDaytonaOrganizationID Use with JWT to specify the organization ID (optional)
     * @return ApiResponse&lt;Void&gt;
     * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
     * @http.response.details
     <table border="1">
       <caption>Response Details</caption>
        <tr><td> Status Code </td><td> Description </td><td> Response Headers </td></tr>
        <tr><td> 200 </td><td> Auto-stop interval has been set </td><td>  -  </td></tr>
     </table>
     * @deprecated
     */
    @Deprecated
    public ApiResponse<Void> setAutostopIntervalWorkspaceDeprecatedWithHttpInfo(@javax.annotation.Nonnull String workspaceId, @javax.annotation.Nonnull BigDecimal interval, @javax.annotation.Nullable String xDaytonaOrganizationID) throws ApiException {
        okhttp3.Call localVarCall = setAutostopIntervalWorkspaceDeprecatedValidateBeforeCall(workspaceId, interval, xDaytonaOrganizationID, null);
        return localVarApiClient.execute(localVarCall);
    }

    /**
     * [DEPRECATED] Set workspace auto-stop interval (asynchronously)
     * 
     * @param workspaceId ID of the workspace (required)
     * @param interval Auto-stop interval in minutes (0 to disable) (required)
     * @param xDaytonaOrganizationID Use with JWT to specify the organization ID (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 border="1">
       <caption>Response Details</caption>
        <tr><td> Status Code </td><td> Description </td><td> Response Headers </td></tr>
        <tr><td> 200 </td><td> Auto-stop interval has been set </td><td>  -  </td></tr>
     </table>
     * @deprecated
     */
    @Deprecated
    public okhttp3.Call setAutostopIntervalWorkspaceDeprecatedAsync(@javax.annotation.Nonnull String workspaceId, @javax.annotation.Nonnull BigDecimal interval, @javax.annotation.Nullable String xDaytonaOrganizationID, final ApiCallback<Void> _callback) throws ApiException {

        okhttp3.Call localVarCall = setAutostopIntervalWorkspaceDeprecatedValidateBeforeCall(workspaceId, interval, xDaytonaOrganizationID, _callback);
        localVarApiClient.executeAsync(localVarCall, _callback);
        return localVarCall;
    }
    /**
     * Build call for startWorkspaceDeprecated
     * @param workspaceId ID of the workspace (required)
     * @param xDaytonaOrganizationID Use with JWT to specify the organization ID (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 border="1">
       <caption>Response Details</caption>
        <tr><td> Status Code </td><td> Description </td><td> Response Headers </td></tr>
        <tr><td> 200 </td><td> Workspace has been started </td><td>  -  </td></tr>
     </table>
     * @deprecated
     */
    @Deprecated
    public okhttp3.Call startWorkspaceDeprecatedCall(@javax.annotation.Nonnull String workspaceId, @javax.annotation.Nullable String xDaytonaOrganizationID, 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 = "/workspace/{workspaceId}/start"
            .replace("{" + "workspaceId" + "}", localVarApiClient.escapeString(workspaceId.toString()));

        List<Pair> localVarQueryParams = new ArrayList<Pair>();
        List<Pair> localVarCollectionQueryParams = new ArrayList<Pair>();
        Map<String, String> localVarHeaderParams = new HashMap<String, String>();
        Map<String, String> localVarCookieParams = new HashMap<String, String>();
        Map<String, Object> localVarFormParams = new HashMap<String, Object>();

        final String[] localVarAccepts = {
        };
        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);
        }

        if (xDaytonaOrganizationID != null) {
            localVarHeaderParams.put("X-Daytona-Organization-ID", localVarApiClient.parameterToString(xDaytonaOrganizationID));
        }


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

    @Deprecated
    @SuppressWarnings("rawtypes")
    private okhttp3.Call startWorkspaceDeprecatedValidateBeforeCall(@javax.annotation.Nonnull String workspaceId, @javax.annotation.Nullable String xDaytonaOrganizationID, final ApiCallback _callback) throws ApiException {
        // verify the required parameter 'workspaceId' is set
        if (workspaceId == null) {
            throw new ApiException("Missing the required parameter 'workspaceId' when calling startWorkspaceDeprecated(Async)");
        }

        return startWorkspaceDeprecatedCall(workspaceId, xDaytonaOrganizationID, _callback);

    }

    /**
     * [DEPRECATED] Start workspace
     * 
     * @param workspaceId ID of the workspace (required)
     * @param xDaytonaOrganizationID Use with JWT to specify the organization ID (optional)
     * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
     * @http.response.details
     <table border="1">
       <caption>Response Details</caption>
        <tr><td> Status Code </td><td> Description </td><td> Response Headers </td></tr>
        <tr><td> 200 </td><td> Workspace has been started </td><td>  -  </td></tr>
     </table>
     * @deprecated
     */
    @Deprecated
    public void startWorkspaceDeprecated(@javax.annotation.Nonnull String workspaceId, @javax.annotation.Nullable String xDaytonaOrganizationID) throws ApiException {
        startWorkspaceDeprecatedWithHttpInfo(workspaceId, xDaytonaOrganizationID);
    }

    /**
     * [DEPRECATED] Start workspace
     * 
     * @param workspaceId ID of the workspace (required)
     * @param xDaytonaOrganizationID Use with JWT to specify the organization ID (optional)
     * @return ApiResponse&lt;Void&gt;
     * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
     * @http.response.details
     <table border="1">
       <caption>Response Details</caption>
        <tr><td> Status Code </td><td> Description </td><td> Response Headers </td></tr>
        <tr><td> 200 </td><td> Workspace has been started </td><td>  -  </td></tr>
     </table>
     * @deprecated
     */
    @Deprecated
    public ApiResponse<Void> startWorkspaceDeprecatedWithHttpInfo(@javax.annotation.Nonnull String workspaceId, @javax.annotation.Nullable String xDaytonaOrganizationID) throws ApiException {
        okhttp3.Call localVarCall = startWorkspaceDeprecatedValidateBeforeCall(workspaceId, xDaytonaOrganizationID, null);
        return localVarApiClient.execute(localVarCall);
    }

    /**
     * [DEPRECATED] Start workspace (asynchronously)
     * 
     * @param workspaceId ID of the workspace (required)
     * @param xDaytonaOrganizationID Use with JWT to specify the organization ID (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 border="1">
       <caption>Response Details</caption>
        <tr><td> Status Code </td><td> Description </td><td> Response Headers </td></tr>
        <tr><td> 200 </td><td> Workspace has been started </td><td>  -  </td></tr>
     </table>
     * @deprecated
     */
    @Deprecated
    public okhttp3.Call startWorkspaceDeprecatedAsync(@javax.annotation.Nonnull String workspaceId, @javax.annotation.Nullable String xDaytonaOrganizationID, final ApiCallback<Void> _callback) throws ApiException {

        okhttp3.Call localVarCall = startWorkspaceDeprecatedValidateBeforeCall(workspaceId, xDaytonaOrganizationID, _callback);
        localVarApiClient.executeAsync(localVarCall, _callback);
        return localVarCall;
    }
    /**
     * Build call for stopWorkspaceDeprecated
     * @param workspaceId ID of the workspace (required)
     * @param xDaytonaOrganizationID Use with JWT to specify the organization ID (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 border="1">
       <caption>Response Details</caption>
        <tr><td> Status Code </td><td> Description </td><td> Response Headers </td></tr>
        <tr><td> 200 </td><td> Workspace has been stopped </td><td>  -  </td></tr>
     </table>
     * @deprecated
     */
    @Deprecated
    public okhttp3.Call stopWorkspaceDeprecatedCall(@javax.annotation.Nonnull String workspaceId, @javax.annotation.Nullable String xDaytonaOrganizationID, 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 = "/workspace/{workspaceId}/stop"
            .replace("{" + "workspaceId" + "}", localVarApiClient.escapeString(workspaceId.toString()));

        List<Pair> localVarQueryParams = new ArrayList<Pair>();
        List<Pair> localVarCollectionQueryParams = new ArrayList<Pair>();
        Map<String, String> localVarHeaderParams = new HashMap<String, String>();
        Map<String, String> localVarCookieParams = new HashMap<String, String>();
        Map<String, Object> localVarFormParams = new HashMap<String, Object>();

        final String[] localVarAccepts = {
        };
        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);
        }

        if (xDaytonaOrganizationID != null) {
            localVarHeaderParams.put("X-Daytona-Organization-ID", localVarApiClient.parameterToString(xDaytonaOrganizationID));
        }


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

    @Deprecated
    @SuppressWarnings("rawtypes")
    private okhttp3.Call stopWorkspaceDeprecatedValidateBeforeCall(@javax.annotation.Nonnull String workspaceId, @javax.annotation.Nullable String xDaytonaOrganizationID, final ApiCallback _callback) throws ApiException {
        // verify the required parameter 'workspaceId' is set
        if (workspaceId == null) {
            throw new ApiException("Missing the required parameter 'workspaceId' when calling stopWorkspaceDeprecated(Async)");
        }

        return stopWorkspaceDeprecatedCall(workspaceId, xDaytonaOrganizationID, _callback);

    }

    /**
     * [DEPRECATED] Stop workspace
     * 
     * @param workspaceId ID of the workspace (required)
     * @param xDaytonaOrganizationID Use with JWT to specify the organization ID (optional)
     * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
     * @http.response.details
     <table border="1">
       <caption>Response Details</caption>
        <tr><td> Status Code </td><td> Description </td><td> Response Headers </td></tr>
        <tr><td> 200 </td><td> Workspace has been stopped </td><td>  -  </td></tr>
     </table>
     * @deprecated
     */
    @Deprecated
    public void stopWorkspaceDeprecated(@javax.annotation.Nonnull String workspaceId, @javax.annotation.Nullable String xDaytonaOrganizationID) throws ApiException {
        stopWorkspaceDeprecatedWithHttpInfo(workspaceId, xDaytonaOrganizationID);
    }

    /**
     * [DEPRECATED] Stop workspace
     * 
     * @param workspaceId ID of the workspace (required)
     * @param xDaytonaOrganizationID Use with JWT to specify the organization ID (optional)
     * @return ApiResponse&lt;Void&gt;
     * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
     * @http.response.details
     <table border="1">
       <caption>Response Details</caption>
        <tr><td> Status Code </td><td> Description </td><td> Response Headers </td></tr>
        <tr><td> 200 </td><td> Workspace has been stopped </td><td>  -  </td></tr>
     </table>
     * @deprecated
     */
    @Deprecated
    public ApiResponse<Void> stopWorkspaceDeprecatedWithHttpInfo(@javax.annotation.Nonnull String workspaceId, @javax.annotation.Nullable String xDaytonaOrganizationID) throws ApiException {
        okhttp3.Call localVarCall = stopWorkspaceDeprecatedValidateBeforeCall(workspaceId, xDaytonaOrganizationID, null);
        return localVarApiClient.execute(localVarCall);
    }

    /**
     * [DEPRECATED] Stop workspace (asynchronously)
     * 
     * @param workspaceId ID of the workspace (required)
     * @param xDaytonaOrganizationID Use with JWT to specify the organization ID (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 border="1">
       <caption>Response Details</caption>
        <tr><td> Status Code </td><td> Description </td><td> Response Headers </td></tr>
        <tr><td> 200 </td><td> Workspace has been stopped </td><td>  -  </td></tr>
     </table>
     * @deprecated
     */
    @Deprecated
    public okhttp3.Call stopWorkspaceDeprecatedAsync(@javax.annotation.Nonnull String workspaceId, @javax.annotation.Nullable String xDaytonaOrganizationID, final ApiCallback<Void> _callback) throws ApiException {

        okhttp3.Call localVarCall = stopWorkspaceDeprecatedValidateBeforeCall(workspaceId, xDaytonaOrganizationID, _callback);
        localVarApiClient.executeAsync(localVarCall, _callback);
        return localVarCall;
    }
    /**
     * Build call for updatePublicStatusWorkspaceDeprecated
     * @param workspaceId ID of the workspace (required)
     * @param isPublic Public status to set (required)
     * @param xDaytonaOrganizationID Use with JWT to specify the organization ID (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 border="1">
       <caption>Response Details</caption>
        <tr><td> Status Code </td><td> Description </td><td> Response Headers </td></tr>
        <tr><td> 201 </td><td>  </td><td>  -  </td></tr>
     </table>
     * @deprecated
     */
    @Deprecated
    public okhttp3.Call updatePublicStatusWorkspaceDeprecatedCall(@javax.annotation.Nonnull String workspaceId, @javax.annotation.Nonnull Boolean isPublic, @javax.annotation.Nullable String xDaytonaOrganizationID, 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 = "/workspace/{workspaceId}/public/{isPublic}"
            .replace("{" + "workspaceId" + "}", localVarApiClient.escapeString(workspaceId.toString()))
            .replace("{" + "isPublic" + "}", localVarApiClient.escapeString(isPublic.toString()));

        List<Pair> localVarQueryParams = new ArrayList<Pair>();
        List<Pair> localVarCollectionQueryParams = new ArrayList<Pair>();
        Map<String, String> localVarHeaderParams = new HashMap<String, String>();
        Map<String, String> localVarCookieParams = new HashMap<String, String>();
        Map<String, Object> localVarFormParams = new HashMap<String, Object>();

        final String[] localVarAccepts = {
        };
        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);
        }

        if (xDaytonaOrganizationID != null) {
            localVarHeaderParams.put("X-Daytona-Organization-ID", localVarApiClient.parameterToString(xDaytonaOrganizationID));
        }


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

    @Deprecated
    @SuppressWarnings("rawtypes")
    private okhttp3.Call updatePublicStatusWorkspaceDeprecatedValidateBeforeCall(@javax.annotation.Nonnull String workspaceId, @javax.annotation.Nonnull Boolean isPublic, @javax.annotation.Nullable String xDaytonaOrganizationID, final ApiCallback _callback) throws ApiException {
        // verify the required parameter 'workspaceId' is set
        if (workspaceId == null) {
            throw new ApiException("Missing the required parameter 'workspaceId' when calling updatePublicStatusWorkspaceDeprecated(Async)");
        }

        // verify the required parameter 'isPublic' is set
        if (isPublic == null) {
            throw new ApiException("Missing the required parameter 'isPublic' when calling updatePublicStatusWorkspaceDeprecated(Async)");
        }

        return updatePublicStatusWorkspaceDeprecatedCall(workspaceId, isPublic, xDaytonaOrganizationID, _callback);

    }

    /**
     * [DEPRECATED] Update public status
     * 
     * @param workspaceId ID of the workspace (required)
     * @param isPublic Public status to set (required)
     * @param xDaytonaOrganizationID Use with JWT to specify the organization ID (optional)
     * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
     * @http.response.details
     <table border="1">
       <caption>Response Details</caption>
        <tr><td> Status Code </td><td> Description </td><td> Response Headers </td></tr>
        <tr><td> 201 </td><td>  </td><td>  -  </td></tr>
     </table>
     * @deprecated
     */
    @Deprecated
    public void updatePublicStatusWorkspaceDeprecated(@javax.annotation.Nonnull String workspaceId, @javax.annotation.Nonnull Boolean isPublic, @javax.annotation.Nullable String xDaytonaOrganizationID) throws ApiException {
        updatePublicStatusWorkspaceDeprecatedWithHttpInfo(workspaceId, isPublic, xDaytonaOrganizationID);
    }

    /**
     * [DEPRECATED] Update public status
     * 
     * @param workspaceId ID of the workspace (required)
     * @param isPublic Public status to set (required)
     * @param xDaytonaOrganizationID Use with JWT to specify the organization ID (optional)
     * @return ApiResponse&lt;Void&gt;
     * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
     * @http.response.details
     <table border="1">
       <caption>Response Details</caption>
        <tr><td> Status Code </td><td> Description </td><td> Response Headers </td></tr>
        <tr><td> 201 </td><td>  </td><td>  -  </td></tr>
     </table>
     * @deprecated
     */
    @Deprecated
    public ApiResponse<Void> updatePublicStatusWorkspaceDeprecatedWithHttpInfo(@javax.annotation.Nonnull String workspaceId, @javax.annotation.Nonnull Boolean isPublic, @javax.annotation.Nullable String xDaytonaOrganizationID) throws ApiException {
        okhttp3.Call localVarCall = updatePublicStatusWorkspaceDeprecatedValidateBeforeCall(workspaceId, isPublic, xDaytonaOrganizationID, null);
        return localVarApiClient.execute(localVarCall);
    }

    /**
     * [DEPRECATED] Update public status (asynchronously)
     * 
     * @param workspaceId ID of the workspace (required)
     * @param isPublic Public status to set (required)
     * @param xDaytonaOrganizationID Use with JWT to specify the organization ID (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 border="1">
       <caption>Response Details</caption>
        <tr><td> Status Code </td><td> Description </td><td> Response Headers </td></tr>
        <tr><td> 201 </td><td>  </td><td>  -  </td></tr>
     </table>
     * @deprecated
     */
    @Deprecated
    public okhttp3.Call updatePublicStatusWorkspaceDeprecatedAsync(@javax.annotation.Nonnull String workspaceId, @javax.annotation.Nonnull Boolean isPublic, @javax.annotation.Nullable String xDaytonaOrganizationID, final ApiCallback<Void> _callback) throws ApiException {

        okhttp3.Call localVarCall = updatePublicStatusWorkspaceDeprecatedValidateBeforeCall(workspaceId, isPublic, xDaytonaOrganizationID, _callback);
        localVarApiClient.executeAsync(localVarCall, _callback);
        return localVarCall;
    }
}
