# FireCloud
#
# FireCloud API
#
# The version of the OpenAPI document: 0.1
#
# Generated by: https://openapi-generator.tech
#' @docType class
#' @title Workspaces operations
#' @description openapi.Workspaces
#' @format An \code{R6Class} generator object
#' @field apiClient Handles the client-server communication.
#'
#' @section Methods:
#' \describe{
#' \strong{ BrowserDownloadAttributes } \emph{ TSV file containing workspace attributes (allows cookie-based authentication) }
#'
#'
#' \itemize{
#' \item \emph{ @param } workspace.namespace character
#' \item \emph{ @param } workspace.name character
#'
#'
#' \item status code : 200 | Workspace attributes in TSV format
#'
#' \item return type : data.frame
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' \item status code : 404 | Workspace does not exist
#'
#'
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' \item status code : 500 | Internal Server Error
#'
#'
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' }
#'
#' \strong{ ChangedWorkspaceNotification } \emph{ Sends notifications for change to workspace }
#'
#'
#' \itemize{
#' \item \emph{ @param } workspace.namespace character
#' \item \emph{ @param } workspace.name character
#'
#'
#' \item status code : 200 | Success
#'
#'
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' \item status code : 403 | Insufficient permisions to send notification on this workspace
#'
#'
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' }
#'
#' \strong{ CheckIamActionWithLock } \emph{ Check IAM action with lock }
#' Check to see if the user has the given action on a workspace in Sam. Takes into account if the workspace is locked too.
#'
#' \itemize{
#' \item \emph{ @param } workspace.namespace character
#' \item \emph{ @param } workspace.name character
#' \item \emph{ @param } sam.action.name character
#'
#'
#' \item status code : 204 | User can perform the given action on the workspace
#'
#'
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' \item status code : 403 | User may not perform the given action on the workspace (including if it doesn't exist)
#'
#'
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' \item status code : 500 | Internal Server Error
#'
#' \item return type : ErrorReport
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' }
#'
#' \strong{ CloneWorkspace } \emph{ Clone Workspace }
#'
#'
#' \itemize{
#' \item \emph{ @param } workspace.namespace character
#' \item \emph{ @param } workspace.name character
#' \item \emph{ @param } workspace \link{WorkspaceRequestClone}
#' \item \emph{ @returnType } \link{WorkspaceDetails} \cr
#'
#'
#' \item status code : 201 | Successful Request
#'
#' \item return type : WorkspaceDetails
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' \item status code : 400 | Unable to create resources for workspace
#'
#'
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' \item status code : 404 | Source workspace not found
#'
#'
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' \item status code : 409 | Destination workspace already exists
#'
#'
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' \item status code : 500 | Internal Server Error
#'
#'
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' }
#'
#' \strong{ CreateWorkspace } \emph{ Create workspace }
#'
#'
#' \itemize{
#' \item \emph{ @param } workspace \link{WorkspaceRequest}
#' \item \emph{ @returnType } \link{WorkspaceDetails} \cr
#'
#'
#' \item status code : 201 | Successful Request
#'
#' \item return type : WorkspaceDetails
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' \item status code : 400 | Bad request
#'
#'
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' \item status code : 403 | Unable to create bucket for workspace
#'
#'
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' \item status code : 409 | Workspace by that name already exists
#'
#'
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' \item status code : 500 | Internal Server Error
#'
#'
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' }
#'
#' \strong{ DeleteWorkspace } \emph{ Delete workspace }
#'
#'
#' \itemize{
#' \item \emph{ @param } workspace.namespace character
#' \item \emph{ @param } workspace.name character
#'
#'
#' \item status code : 202 | Request Accepted
#'
#'
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' \item status code : 403 | User does not have correct permissions to delete a published workspace
#'
#'
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' \item status code : 404 | Workspace does not exist
#'
#'
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' \item status code : 500 | Internal Server Error
#'
#'
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' }
#'
#' \strong{ DeleteWorkspaceTags } \emph{ Remove the user-supplied tags from the workspace. }
#'
#'
#' \itemize{
#' \item \emph{ @param } workspace.namespace character
#' \item \emph{ @param } workspace.name character
#' \item \emph{ @param } tags list( character )
#'
#'
#' \item status code : 200 | Workspace tags
#'
#' \item return type : array[character]
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' \item status code : 400 | Invalid input
#'
#'
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' \item status code : 404 | Workspace not found
#'
#'
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' \item status code : 500 | Internal Error
#'
#'
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' }
#'
#' \strong{ ExportAttributesTSV } \emph{ TSV file containing workspace attributes }
#'
#'
#' \itemize{
#' \item \emph{ @param } workspace.namespace character
#' \item \emph{ @param } workspace.name character
#'
#'
#' \item status code : 200 | Workspace attributes in TSV format
#'
#' \item return type : data.frame
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' \item status code : 404 | Workspace does not exist
#'
#'
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' \item status code : 500 | Internal Server Error
#'
#'
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' }
#'
#' \strong{ GetBucketUsage } \emph{ Get bucket usage }
#'
#'
#' \itemize{
#' \item \emph{ @param } workspace.namespace character
#' \item \emph{ @param } workspace.name character
#'
#'
#' \item status code : 200 | Successful Request
#'
#'
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' }
#'
#' \strong{ GetCatalog } \emph{ Get workspace catalog permission }
#' Get catalog permissions for a workspace
#'
#' \itemize{
#' \item \emph{ @param } workspace.namespace character
#' \item \emph{ @param } workspace.name character
#' \item \emph{ @returnType } list( \link{WorkspaceCatalog} ) \cr
#'
#'
#' \item status code : 200 | Successful Request
#'
#' \item return type : array[WorkspaceCatalog]
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' \item status code : 404 | Workspace not found
#'
#' \item return type : ErrorReport
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' \item status code : 500 | Rawls Internal Error
#'
#' \item return type : ErrorReport
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' }
#'
#' \strong{ GetStorageCostEstimate } \emph{ Calculate an estimate of the monthly storage cost for the workspace bucket }
#'
#'
#' \itemize{
#' \item \emph{ @param } workspace.namespace character
#' \item \emph{ @param } workspace.name character
#'
#'
#' \item status code : 200 | Storage cost estimate
#'
#'
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' \item status code : 404 | Workspace not found
#'
#'
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' \item status code : 500 | Internal Error
#'
#'
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' }
#'
#' \strong{ GetTags } \emph{ Get all tags used in FireCloud (for autocomplete) }
#' list of all tags used in FireCloud and their associated frequencies
#'
#' \itemize{
#' \item \emph{ @param } q character
#' \item \emph{ @returnType } list( \link{WorkspaceTag} ) \cr
#'
#'
#' \item status code : 200 | list of all tags used in FireCloud
#'
#' \item return type : array[WorkspaceTag]
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' \item status code : 500 | Rawls Internal Error
#'
#'
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' }
#'
#' \strong{ GetWorkspace } \emph{ Get workspace }
#' Get a single workspace's details, optionally filtered to only the specified fields. See additional GET methods in this section to retrieve additional details about the workspace. For instance, this API only returns the workspace's owners; use the GET .../acl method to retrieve the full list of all users at all permission levels.
#'
#' \itemize{
#' \item \emph{ @param } workspace.namespace character
#' \item \emph{ @param } workspace.name character
#' \item \emph{ @param } fields list( character )
#' \item \emph{ @returnType } \link{WorkspaceResponse} \cr
#'
#'
#' \item status code : 200 | Successful Request
#'
#' \item return type : WorkspaceResponse
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' \item status code : 400 | Unrecognized query parameters
#'
#'
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' \item status code : 404 | Workspace does not exist
#'
#'
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' \item status code : 500 | Internal Server Error
#'
#'
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' }
#'
#' \strong{ GetWorkspaceAccessInstructions } \emph{ Get workspace access instructions (if any) }
#'
#'
#' \itemize{
#' \item \emph{ @param } workspace.namespace character
#' \item \emph{ @param } workspace.name character
#' \item \emph{ @returnType } list( \link{ManagedGroupAccessInstructions} ) \cr
#'
#'
#' \item status code : 200 | Successful Request
#'
#' \item return type : array[ManagedGroupAccessInstructions]
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' \item status code : 404 | Workspace not found
#'
#'
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' \item status code : 500 | Internal Server Error
#'
#'
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' }
#'
#' \strong{ GetWorkspaceAcl } \emph{ Get workspace ACL }
#'
#'
#' \itemize{
#' \item \emph{ @param } workspace.namespace character
#' \item \emph{ @param } workspace.name character
#' \item \emph{ @returnType } \link{WorkspaceACL} \cr
#'
#'
#' \item status code : 200 | Successful Request
#'
#' \item return type : WorkspaceACL
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' \item status code : 400 | Can't retrieve ACL for workspace
#'
#'
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' \item status code : 404 | Workspace not found
#'
#'
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' \item status code : 500 | Internal Server Error
#'
#'
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' }
#'
#' \strong{ GetWorkspaceBucketOptions } \emph{ Get metadata about the workspace bucket }
#' Returns metadata about the workspace bucket.
#'
#' \itemize{
#' \item \emph{ @param } workspace.namespace character
#' \item \emph{ @param } workspace.name character
#' \item \emph{ @returnType } \link{WorkspaceBucketOptions} \cr
#'
#'
#' \item status code : 200 | Successful Request
#'
#' \item return type : WorkspaceBucketOptions
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' \item status code : 404 | Workspace not found
#'
#' \item return type : ErrorReport
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' \item status code : 500 | Rawls Internal Error
#'
#' \item return type : ErrorReport
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' }
#'
#' \strong{ GetWorkspaceTags } \emph{ Get the tags for this workspace. }
#'
#'
#' \itemize{
#' \item \emph{ @param } workspace.namespace character
#' \item \emph{ @param } workspace.name character
#'
#'
#' \item status code : 200 | Workspace tags
#'
#' \item return type : array[character]
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' \item status code : 404 | Workspace not found
#'
#'
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' \item status code : 500 | Internal Error
#'
#'
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' }
#'
#' \strong{ ImportAttributesTSV } \emph{ Import workspace attributes from a tsv file }
#'
#'
#' \itemize{
#' \item \emph{ @param } workspace.namespace character
#' \item \emph{ @param } workspace.name character
#' \item \emph{ @param } attributes data.frame
#'
#'
#' \item status code : 200 | Successful Request
#'
#'
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' \item status code : 400 | Bad Request
#'
#'
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' \item status code : 404 | Source Workspace not found
#'
#'
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' \item status code : 500 | Internal Error
#'
#'
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' }
#'
#' \strong{ ListWorkspaceMethodConfigs } \emph{ List method configurations in a workspace }
#' List method configurations in a workspace. By default, only Agora method configs are returned. To return configs for all repos, specify `allRepos` to be `true`. #### Expanded discussion on the methodRepoMethod field This endpoint returns method references to Agora in the format ``` \"methodRepoMethod\": { \"methodNamespace\": \"namespace\", \"methodName\": \"name\", \"methodVersion\": 1, \"sourceRepo\": \"agora\", \"methodUri\": \"agora://namespace/name/1\" } ``` and for Dockstore in the format ``` \"methodRepoMethod\": { \"methodPath\": \"path\", \"methodVersion\": \"version\", \"sourceRepo\": \"agora\", \"methodUri\": \"dockstore://path/version\" } ``` If you are only working with Agora methods, the fields `\"sourceRepo\"` and `\"methodUri\"` can be considered informational and do not need to be round-tripped (see the corresponding `POST /api/workspaces/{workspaceNamespace}/{workspaceName}/methodconfigs` for more details).
#'
#' \itemize{
#' \item \emph{ @param } workspace.namespace character
#' \item \emph{ @param } workspace.name character
#' \item \emph{ @param } all.repos character
#'
#'
#' \item status code : 200 | List of Method Configurations
#'
#'
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' \item status code : 404 | Workspace does not exist
#'
#'
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' \item status code : 500 | Internal Server Error
#'
#'
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' }
#'
#' \strong{ ListWorkspaces } \emph{ Lists workspaces. }
#'
#'
#' \itemize{
#' \item \emph{ @param } fields list( character )
#' \item \emph{ @returnType } list( \link{WorkspaceListResponse} ) \cr
#'
#'
#' \item status code : 200 | List of workspaces.
#'
#' \item return type : array[WorkspaceListResponse]
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' \item status code : 400 | Unrecognized query parameters
#'
#'
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' }
#'
#' \strong{ LockWorkspace } \emph{ Lock Workspace }
#'
#'
#' \itemize{
#' \item \emph{ @param } workspace.namespace character
#' \item \emph{ @param } workspace.name character
#'
#'
#' \item status code : 200 | No response was specified
#'
#'
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' \item status code : 204 | Successful Request
#'
#'
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' \item status code : 403 | Not Owner
#'
#'
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' \item status code : 404 | Workspace Not Found
#'
#'
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' \item status code : 500 | Internal Server Error
#'
#'
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' }
#'
#' \strong{ PatchWorkspaceTags } \emph{ Add tags to the workspace without modifying pre-existing tags. }
#'
#'
#' \itemize{
#' \item \emph{ @param } workspace.namespace character
#' \item \emph{ @param } workspace.name character
#' \item \emph{ @param } tags list( character )
#'
#'
#' \item status code : 200 | Workspace tags
#'
#' \item return type : array[character]
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' \item status code : 400 | Invalid input
#'
#'
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' \item status code : 404 | Workspace not found
#'
#'
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' \item status code : 500 | Internal Error
#'
#'
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' }
#'
#' \strong{ PostWorkspaceMethodConfig } \emph{ Create a Method Configuration in a workspace }
#' Create method configurations. #### Expanded discussion on the methodRepoMethod field To create a method config for an Agora method, `\"sourceRepo\": \"agora\"` is optional; the following is sufficient: ``` \"methodRepoMethod\": { \"methodNamespace\": \"namespace\", \"methodName\": \"name\", \"methodVersion\": 1 } ``` To create a method config for a Dockstore method, `\"sourceRepo\": \"dockstore\"` is required: ``` \"methodRepoMethod\": { \"sourceRepo\": \"dockstore\", \"methodPath\": \"path\", \"methodVersion\": \"version\" } ``` You may also use the URI on its own to create a config referencing any supported repo (currently Agora and Dockstore): ``` \"methodRepoMethod\": { \"methodUri\": \"agora://namespace/name/1\" } ``` ``` \"methodRepoMethod\": { \"methodUri\": \"dockstore://path/version\" } ``` The system is specified to check for a URI first before falling back to the legacy fields. Unsupported repos will return a 400 Bad Request.
#'
#' \itemize{
#' \item \emph{ @param } workspace.namespace character
#' \item \emph{ @param } workspace.name character
#' \item \emph{ @param } method.config.json \link{NewMethodConfigIngest}
#'
#'
#' \item status code : 201 | Successful Request
#'
#'
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' \item status code : 404 | Workspace not found
#'
#'
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' \item status code : 409 | Method Configuration already exists
#'
#'
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' \item status code : 500 | Internal Server Error
#'
#'
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' }
#'
#' \strong{ PutWorkspaceTags } \emph{ Replace all tags for this workspace with the user input. }
#'
#'
#' \itemize{
#' \item \emph{ @param } workspace.namespace character
#' \item \emph{ @param } workspace.name character
#' \item \emph{ @param } tags list( character )
#'
#'
#' \item status code : 200 | Workspace tags
#'
#' \item return type : array[character]
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' \item status code : 400 | Invalid input
#'
#'
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' \item status code : 404 | Workspace not found
#'
#'
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' \item status code : 500 | Internal Error
#'
#'
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' }
#'
#' \strong{ ReadBucket } \emph{ Read workspace bucket }
#' Read a workspace bucket
#'
#' \itemize{
#' \item \emph{ @param } workspace.namespace character
#' \item \emph{ @param } workspace.name character
#'
#'
#' \item status code : 200 | Successful Request
#'
#'
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' \item status code : 403 | Insufficient permissions to access workspace bucket
#'
#'
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' \item status code : 404 | Workspace Not Found
#'
#'
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' \item status code : 500 | Internal Server Error
#'
#'
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' }
#'
#' \strong{ SetAttributes } \emph{ Set attributes on a workspace. }
#'
#'
#' \itemize{
#' \item \emph{ @param } workspace.namespace character
#' \item \emph{ @param } workspace.name character
#' \item \emph{ @param } new.attributes named list( \link{map(object)} )
#'
#'
#' \item status code : 200 | Success
#'
#'
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' \item status code : 400 | Malformed request
#'
#'
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' \item status code : 404 | Workspace not found
#'
#'
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' \item status code : 500 | Internal Error
#'
#'
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' }
#'
#' \strong{ UnlockWorkspace } \emph{ Unlock Workspace }
#'
#'
#' \itemize{
#' \item \emph{ @param } workspace.namespace character
#' \item \emph{ @param } workspace.name character
#'
#'
#' \item status code : 200 | No response was specified
#'
#'
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' \item status code : 204 | Successful Request
#'
#'
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' \item status code : 403 | Not Owner
#'
#'
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' \item status code : 404 | Workspace Not Found
#'
#'
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' \item status code : 500 | Internal Server Error
#'
#'
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' }
#'
#' \strong{ UpdateAttributes } \emph{ Modify attributes on a workspace. }
#'
#'
#' \itemize{
#' \item \emph{ @param } workspace.namespace character
#' \item \emph{ @param } workspace.name character
#' \item \emph{ @param } workspace.update.json list( \link{AttributeUpdateOperation} )
#' \item \emph{ @returnType } \link{WorkspaceDetails} \cr
#'
#'
#' \item status code : 200 | Success
#'
#' \item return type : WorkspaceDetails
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' \item status code : 400 | Invalid operation
#'
#'
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' \item status code : 404 | Workspace not found
#'
#'
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' \item status code : 500 | Internal Error
#'
#'
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' }
#'
#' \strong{ UpdateCatalog } \emph{ Update catalog permission }
#' Set catalog permisisons for a workspace
#'
#' \itemize{
#' \item \emph{ @param } workspace.namespace character
#' \item \emph{ @param } workspace.name character
#' \item \emph{ @param } catalog.updates list( \link{WorkspaceCatalog} )
#' \item \emph{ @returnType } \link{WorkspaceCatalogUpdateResponseList} \cr
#'
#'
#' \item status code : 200 | Successful Request
#'
#' \item return type : WorkspaceCatalogUpdateResponseList
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' \item status code : 403 | Insufficient permissions to change catalog permissions (must be owner or admin)
#'
#' \item return type : ErrorReport
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' \item status code : 404 | Workspace, user or group not found
#'
#' \item return type : ErrorReport
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' \item status code : 500 | Rawls Internal Error
#'
#' \item return type : ErrorReport
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' }
#'
#' \strong{ UpdateWorkspaceACL } \emph{ Update workspace ACL }
#'
#'
#' \itemize{
#' \item \emph{ @param } workspace.namespace character
#' \item \emph{ @param } workspace.name character
#' \item \emph{ @param } invite.users.not.found character
#' \item \emph{ @param } acl.updates list( \link{WorkspaceACLUpdate} )
#' \item \emph{ @returnType } \link{WorkspaceACLUpdateResponseList} \cr
#'
#'
#' \item status code : 200 | Successful Request
#'
#' \item return type : WorkspaceACLUpdateResponseList
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' \item status code : 400 | Can't set ACL for workspace
#'
#'
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' \item status code : 404 | Workspace not found
#'
#'
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' \item status code : 500 | Internal Server Error
#'
#'
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' }
#'
#' \strong{ WorkspacePermissionReport } \emph{ Retrieve user permissions for the workspace and the workspace's method references }
#'
#'
#' \itemize{
#' \item \emph{ @param } workspace.namespace character
#' \item \emph{ @param } workspace.name character
#' \item \emph{ @param } report.input \link{PermissionReportRequest}
#' \item \emph{ @returnType } \link{PermissionReport} \cr
#'
#'
#' \item status code : 200 | Permission Report
#'
#' \item return type : PermissionReport
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' \item status code : 404 | Workspace does not exist
#'
#'
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' \item status code : 500 | Internal Server Error
#'
#'
#' \item response headers :
#'
#' \tabular{ll}{
#' }
#' }
#'
#' }
#'
#'
#' @examples
#' \dontrun{
#' #################### BrowserDownloadAttributes ####################
#'
#' library(openapi)
#' var.workspace.namespace <- 'workspace.namespace_example' # character | Workspace Namespace
#' var.workspace.name <- 'workspace.name_example' # character | Workspace Name
#'
#' #TSV file containing workspace attributes (allows cookie-based authentication)
#' api.instance <- WorkspacesApi$new()
#'
#' # Configure OAuth2 access token for authorization: googleoauth
#' api.instance$apiClient$accessToken <- 'TODO_YOUR_ACCESS_TOKEN';
#'
#' result <- api.instance$BrowserDownloadAttributes(var.workspace.namespace, var.workspace.name)
#'
#'
#' #################### ChangedWorkspaceNotification ####################
#'
#' library(openapi)
#' var.workspace.namespace <- 'workspace.namespace_example' # character | workspace namespace
#' var.workspace.name <- 'workspace.name_example' # character | workspace name
#'
#' #Sends notifications for change to workspace
#' api.instance <- WorkspacesApi$new()
#'
#' # Configure OAuth2 access token for authorization: googleoauth
#' api.instance$apiClient$accessToken <- 'TODO_YOUR_ACCESS_TOKEN';
#'
#' result <- api.instance$ChangedWorkspaceNotification(var.workspace.namespace, var.workspace.name)
#'
#'
#' #################### CheckIamActionWithLock ####################
#'
#' library(openapi)
#' var.workspace.namespace <- 'workspace.namespace_example' # character | Workspace Namespace
#' var.workspace.name <- 'workspace.name_example' # character | Workspace Name
#' var.sam.action.name <- 'sam.action.name_example' # character | Sam action
#'
#' #Check IAM action with lock
#' api.instance <- WorkspacesApi$new()
#'
#' # Configure OAuth2 access token for authorization: googleoauth
#' api.instance$apiClient$accessToken <- 'TODO_YOUR_ACCESS_TOKEN';
#'
#' result <- api.instance$CheckIamActionWithLock(var.workspace.namespace, var.workspace.name, var.sam.action.name)
#'
#'
#' #################### CloneWorkspace ####################
#'
#' library(openapi)
#' var.workspace.namespace <- 'workspace.namespace_example' # character | Workspace Namespace
#' var.workspace.name <- 'workspace.name_example' # character | Workspace Name
#' var.workspace <- WorkspaceRequestClone$new() # WorkspaceRequestClone | Cloned workspace information
#'
#' #Clone Workspace
#' api.instance <- WorkspacesApi$new()
#'
#' # Configure OAuth2 access token for authorization: googleoauth
#' api.instance$apiClient$accessToken <- 'TODO_YOUR_ACCESS_TOKEN';
#'
#' result <- api.instance$CloneWorkspace(var.workspace.namespace, var.workspace.name, var.workspace)
#'
#'
#' #################### CreateWorkspace ####################
#'
#' library(openapi)
#' var.workspace <- WorkspaceRequest$new() # WorkspaceRequest | New workspace information
#'
#' #Create workspace
#' api.instance <- WorkspacesApi$new()
#'
#' # Configure OAuth2 access token for authorization: googleoauth
#' api.instance$apiClient$accessToken <- 'TODO_YOUR_ACCESS_TOKEN';
#'
#' result <- api.instance$CreateWorkspace(var.workspace)
#'
#'
#' #################### DeleteWorkspace ####################
#'
#' library(openapi)
#' var.workspace.namespace <- 'workspace.namespace_example' # character | Workspace Namespace
#' var.workspace.name <- 'workspace.name_example' # character | Workspace Name
#'
#' #Delete workspace
#' api.instance <- WorkspacesApi$new()
#'
#' # Configure OAuth2 access token for authorization: googleoauth
#' api.instance$apiClient$accessToken <- 'TODO_YOUR_ACCESS_TOKEN';
#'
#' result <- api.instance$DeleteWorkspace(var.workspace.namespace, var.workspace.name)
#'
#'
#' #################### DeleteWorkspaceTags ####################
#'
#' library(openapi)
#' var.workspace.namespace <- 'workspace.namespace_example' # character | Workspace Namespace
#' var.workspace.name <- 'workspace.name_example' # character | Workspace Name
#' var.tags <- ['tags_example'] # array[character] | List of tags.
#'
#' #Remove the user-supplied tags from the workspace.
#' api.instance <- WorkspacesApi$new()
#'
#' # Configure OAuth2 access token for authorization: googleoauth
#' api.instance$apiClient$accessToken <- 'TODO_YOUR_ACCESS_TOKEN';
#'
#' result <- api.instance$DeleteWorkspaceTags(var.workspace.namespace, var.workspace.name, var.tags)
#'
#'
#' #################### ExportAttributesTSV ####################
#'
#' library(openapi)
#' var.workspace.namespace <- 'workspace.namespace_example' # character | Workspace Namespace
#' var.workspace.name <- 'workspace.name_example' # character | Workspace Name
#'
#' #TSV file containing workspace attributes
#' api.instance <- WorkspacesApi$new()
#'
#' # Configure OAuth2 access token for authorization: googleoauth
#' api.instance$apiClient$accessToken <- 'TODO_YOUR_ACCESS_TOKEN';
#'
#' result <- api.instance$ExportAttributesTSV(var.workspace.namespace, var.workspace.name)
#'
#'
#' #################### GetBucketUsage ####################
#'
#' library(openapi)
#' var.workspace.namespace <- 'workspace.namespace_example' # character | Workspace Namespace
#' var.workspace.name <- 'workspace.name_example' # character | Workspace Name
#'
#' #Get bucket usage
#' api.instance <- WorkspacesApi$new()
#'
#' # Configure OAuth2 access token for authorization: googleoauth
#' api.instance$apiClient$accessToken <- 'TODO_YOUR_ACCESS_TOKEN';
#'
#' result <- api.instance$GetBucketUsage(var.workspace.namespace, var.workspace.name)
#'
#'
#' #################### GetCatalog ####################
#'
#' library(openapi)
#' var.workspace.namespace <- 'workspace.namespace_example' # character | Workspace Namespace
#' var.workspace.name <- 'workspace.name_example' # character | Workspace Name
#'
#' #Get workspace catalog permission
#' api.instance <- WorkspacesApi$new()
#'
#' # Configure OAuth2 access token for authorization: googleoauth
#' api.instance$apiClient$accessToken <- 'TODO_YOUR_ACCESS_TOKEN';
#'
#' result <- api.instance$GetCatalog(var.workspace.namespace, var.workspace.name)
#'
#'
#' #################### GetStorageCostEstimate ####################
#'
#' library(openapi)
#' var.workspace.namespace <- 'workspace.namespace_example' # character | Workspace Namespace
#' var.workspace.name <- 'workspace.name_example' # character | Workspace Name
#'
#' #Calculate an estimate of the monthly storage cost for the workspace bucket
#' api.instance <- WorkspacesApi$new()
#'
#' # Configure OAuth2 access token for authorization: googleoauth
#' api.instance$apiClient$accessToken <- 'TODO_YOUR_ACCESS_TOKEN';
#'
#' result <- api.instance$GetStorageCostEstimate(var.workspace.namespace, var.workspace.name)
#'
#'
#' #################### GetTags ####################
#'
#' library(openapi)
#' var.q <- 'q_example' # character | Query string
#'
#' #Get all tags used in FireCloud (for autocomplete)
#' api.instance <- WorkspacesApi$new()
#'
#' # Configure OAuth2 access token for authorization: googleoauth
#' api.instance$apiClient$accessToken <- 'TODO_YOUR_ACCESS_TOKEN';
#'
#' result <- api.instance$GetTags(q=var.q)
#'
#'
#' #################### GetWorkspace ####################
#'
#' library(openapi)
#' var.workspace.namespace <- 'workspace.namespace_example' # character | Workspace Namespace
#' var.workspace.name <- 'workspace.name_example' # character | Workspace Name
#' var.fields <- ['fields_example'] # array[character] | When specified, include only these keys in the response payload and exclude other keys. Accepts a comma-delimited list of values. To include a nested key, specify the key's path using a dot delimiter; for example, to include {\"workspace\": {\"attributes\": {}}}, specify \"workspace.attributes\". Legal values are any first-level key in the response, any first-level key inside the {\"workspace\": {}} object, and any first-level key inside the {\"workspace\": {\"attributes\": {}}} object. If omitted, will return the full response payload.
#'
#' #Get workspace
#' api.instance <- WorkspacesApi$new()
#'
#' # Configure OAuth2 access token for authorization: googleoauth
#' api.instance$apiClient$accessToken <- 'TODO_YOUR_ACCESS_TOKEN';
#'
#' result <- api.instance$GetWorkspace(var.workspace.namespace, var.workspace.name, fields=var.fields)
#'
#'
#' #################### GetWorkspaceAccessInstructions ####################
#'
#' library(openapi)
#' var.workspace.namespace <- 'workspace.namespace_example' # character | Workspace Namespace
#' var.workspace.name <- 'workspace.name_example' # character | Workspace Name
#'
#' #Get workspace access instructions (if any)
#' api.instance <- WorkspacesApi$new()
#'
#' # Configure OAuth2 access token for authorization: googleoauth
#' api.instance$apiClient$accessToken <- 'TODO_YOUR_ACCESS_TOKEN';
#'
#' result <- api.instance$GetWorkspaceAccessInstructions(var.workspace.namespace, var.workspace.name)
#'
#'
#' #################### GetWorkspaceAcl ####################
#'
#' library(openapi)
#' var.workspace.namespace <- 'workspace.namespace_example' # character | Workspace Namespace
#' var.workspace.name <- 'workspace.name_example' # character | Workspace Name
#'
#' #Get workspace ACL
#' api.instance <- WorkspacesApi$new()
#'
#' # Configure OAuth2 access token for authorization: googleoauth
#' api.instance$apiClient$accessToken <- 'TODO_YOUR_ACCESS_TOKEN';
#'
#' result <- api.instance$GetWorkspaceAcl(var.workspace.namespace, var.workspace.name)
#'
#'
#' #################### GetWorkspaceBucketOptions ####################
#'
#' library(openapi)
#' var.workspace.namespace <- 'workspace.namespace_example' # character | Workspace Namespace
#' var.workspace.name <- 'workspace.name_example' # character | Workspace Name
#'
#' #Get metadata about the workspace bucket
#' api.instance <- WorkspacesApi$new()
#'
#' # Configure OAuth2 access token for authorization: googleoauth
#' api.instance$apiClient$accessToken <- 'TODO_YOUR_ACCESS_TOKEN';
#'
#' result <- api.instance$GetWorkspaceBucketOptions(var.workspace.namespace, var.workspace.name)
#'
#'
#' #################### GetWorkspaceTags ####################
#'
#' library(openapi)
#' var.workspace.namespace <- 'workspace.namespace_example' # character | Workspace Namespace
#' var.workspace.name <- 'workspace.name_example' # character | Workspace Name
#'
#' #Get the tags for this workspace.
#' api.instance <- WorkspacesApi$new()
#'
#' # Configure OAuth2 access token for authorization: googleoauth
#' api.instance$apiClient$accessToken <- 'TODO_YOUR_ACCESS_TOKEN';
#'
#' result <- api.instance$GetWorkspaceTags(var.workspace.namespace, var.workspace.name)
#'
#'
#' #################### ImportAttributesTSV ####################
#'
#' library(openapi)
#' var.workspace.namespace <- 'workspace.namespace_example' # character | Workspace Namespace
#' var.workspace.name <- 'workspace.name_example' # character | Workspace Name
#' var.attributes <- File.new('/path/to/file') # data.frame | A valid TSV import file
#'
#' #Import workspace attributes from a tsv file
#' api.instance <- WorkspacesApi$new()
#'
#' # Configure OAuth2 access token for authorization: googleoauth
#' api.instance$apiClient$accessToken <- 'TODO_YOUR_ACCESS_TOKEN';
#'
#' result <- api.instance$ImportAttributesTSV(var.workspace.namespace, var.workspace.name, var.attributes)
#'
#'
#' #################### ListWorkspaceMethodConfigs ####################
#'
#' library(openapi)
#' var.workspace.namespace <- 'workspace.namespace_example' # character | Workspace Namespace
#' var.workspace.name <- 'workspace.name_example' # character | Workspace Name
#' var.all.repos <- FALSE # character | Configs for all repos, not just Agora
#'
#' #List method configurations in a workspace
#' api.instance <- WorkspacesApi$new()
#'
#' # Configure OAuth2 access token for authorization: googleoauth
#' api.instance$apiClient$accessToken <- 'TODO_YOUR_ACCESS_TOKEN';
#'
#' result <- api.instance$ListWorkspaceMethodConfigs(var.workspace.namespace, var.workspace.name, all.repos=var.all.repos)
#'
#'
#' #################### ListWorkspaces ####################
#'
#' library(openapi)
#' var.fields <- ['fields_example'] # array[character] | When specified, include only these keys in the response payload and exclude other keys. Accepts a comma-delimited list of values. To include a nested key, specify the key's path using a dot delimiter; for example, to include {\"workspace\": {\"attributes\": {}}}, specify \"workspace.attributes\". Legal values are any first-level key in the response, any first-level key inside the {\"workspace\": {}} object, and any first-level key inside the {\"workspace\": {\"attributes\": {}}} object. If omitted, will return the full response payload.
#'
#' #Lists workspaces.
#' api.instance <- WorkspacesApi$new()
#'
#' # Configure OAuth2 access token for authorization: googleoauth
#' api.instance$apiClient$accessToken <- 'TODO_YOUR_ACCESS_TOKEN';
#'
#' result <- api.instance$ListWorkspaces(fields=var.fields)
#'
#'
#' #################### LockWorkspace ####################
#'
#' library(openapi)
#' var.workspace.namespace <- 'workspace.namespace_example' # character | Workspace Namespace
#' var.workspace.name <- 'workspace.name_example' # character | Workspace Name
#'
#' #Lock Workspace
#' api.instance <- WorkspacesApi$new()
#'
#' # Configure OAuth2 access token for authorization: googleoauth
#' api.instance$apiClient$accessToken <- 'TODO_YOUR_ACCESS_TOKEN';
#'
#' result <- api.instance$LockWorkspace(var.workspace.namespace, var.workspace.name)
#'
#'
#' #################### PatchWorkspaceTags ####################
#'
#' library(openapi)
#' var.workspace.namespace <- 'workspace.namespace_example' # character | Workspace Namespace
#' var.workspace.name <- 'workspace.name_example' # character | Workspace Name
#' var.tags <- ['tags_example'] # array[character] | List of tags.
#'
#' #Add tags to the workspace without modifying pre-existing tags.
#' api.instance <- WorkspacesApi$new()
#'
#' # Configure OAuth2 access token for authorization: googleoauth
#' api.instance$apiClient$accessToken <- 'TODO_YOUR_ACCESS_TOKEN';
#'
#' result <- api.instance$PatchWorkspaceTags(var.workspace.namespace, var.workspace.name, var.tags)
#'
#'
#' #################### PostWorkspaceMethodConfig ####################
#'
#' library(openapi)
#' var.workspace.namespace <- 'workspace.namespace_example' # character | Workspace Namespace
#' var.workspace.name <- 'workspace.name_example' # character | Workspace Name
#' var.method.config.json <- NewMethodConfigIngest$new() # NewMethodConfigIngest | Method Configuration contents
#'
#' #Create a Method Configuration in a workspace
#' api.instance <- WorkspacesApi$new()
#'
#' # Configure OAuth2 access token for authorization: googleoauth
#' api.instance$apiClient$accessToken <- 'TODO_YOUR_ACCESS_TOKEN';
#'
#' result <- api.instance$PostWorkspaceMethodConfig(var.workspace.namespace, var.workspace.name, var.method.config.json)
#'
#'
#' #################### PutWorkspaceTags ####################
#'
#' library(openapi)
#' var.workspace.namespace <- 'workspace.namespace_example' # character | Workspace Namespace
#' var.workspace.name <- 'workspace.name_example' # character | Workspace Name
#' var.tags <- ['tags_example'] # array[character] | List of tags.
#'
#' #Replace all tags for this workspace with the user input.
#' api.instance <- WorkspacesApi$new()
#'
#' # Configure OAuth2 access token for authorization: googleoauth
#' api.instance$apiClient$accessToken <- 'TODO_YOUR_ACCESS_TOKEN';
#'
#' result <- api.instance$PutWorkspaceTags(var.workspace.namespace, var.workspace.name, var.tags)
#'
#'
#' #################### ReadBucket ####################
#'
#' library(openapi)
#' var.workspace.namespace <- 'workspace.namespace_example' # character | Workspace Namespace
#' var.workspace.name <- 'workspace.name_example' # character | Workspace Name
#'
#' #Read workspace bucket
#' api.instance <- WorkspacesApi$new()
#'
#' # Configure OAuth2 access token for authorization: googleoauth
#' api.instance$apiClient$accessToken <- 'TODO_YOUR_ACCESS_TOKEN';
#'
#' result <- api.instance$ReadBucket(var.workspace.namespace, var.workspace.name)
#'
#'
#' #################### SetAttributes ####################
#'
#' library(openapi)
#' var.workspace.namespace <- 'workspace.namespace_example' # character | Workspace Namespace
#' var.workspace.name <- 'workspace.name_example' # character | Workspace Name
#' var.new.attributes <- NULL # map(object) | New attribute values, as Map[String, Attribute]. WARNING! This should not be used to change library metadata (republish will not happen). Use UpdateAttributes in the library section
#'
#' #Set attributes on a workspace.
#' api.instance <- WorkspacesApi$new()
#'
#' # Configure OAuth2 access token for authorization: googleoauth
#' api.instance$apiClient$accessToken <- 'TODO_YOUR_ACCESS_TOKEN';
#'
#' result <- api.instance$SetAttributes(var.workspace.namespace, var.workspace.name, var.new.attributes)
#'
#'
#' #################### UnlockWorkspace ####################
#'
#' library(openapi)
#' var.workspace.namespace <- 'workspace.namespace_example' # character | Workspace Namespace
#' var.workspace.name <- 'workspace.name_example' # character | Workspace Name
#'
#' #Unlock Workspace
#' api.instance <- WorkspacesApi$new()
#'
#' # Configure OAuth2 access token for authorization: googleoauth
#' api.instance$apiClient$accessToken <- 'TODO_YOUR_ACCESS_TOKEN';
#'
#' result <- api.instance$UnlockWorkspace(var.workspace.namespace, var.workspace.name)
#'
#'
#' #################### UpdateAttributes ####################
#'
#' library(openapi)
#' var.workspace.namespace <- 'workspace.namespace_example' # character | Workspace Namespace
#' var.workspace.name <- 'workspace.name_example' # character | Workspace Name
#' var.workspace.update.json <- [AttributeUpdateOperation$new()] # array[AttributeUpdateOperation] | Attribute operations. WARNING! This should not be used to change library metadata (republish will not happen). Use UpdateAttributes in the library section.
#'
#' #Modify attributes on a workspace.
#' api.instance <- WorkspacesApi$new()
#'
#' # Configure OAuth2 access token for authorization: googleoauth
#' api.instance$apiClient$accessToken <- 'TODO_YOUR_ACCESS_TOKEN';
#'
#' result <- api.instance$UpdateAttributes(var.workspace.namespace, var.workspace.name, var.workspace.update.json)
#'
#'
#' #################### UpdateCatalog ####################
#'
#' library(openapi)
#' var.workspace.namespace <- 'workspace.namespace_example' # character | Workspace Namespace
#' var.workspace.name <- 'workspace.name_example' # character | Workspace Name
#' var.catalog.updates <- [WorkspaceCatalog$new()] # array[WorkspaceCatalog] | Series of Catalog updates for workspace
#'
#' #Update catalog permission
#' api.instance <- WorkspacesApi$new()
#'
#' # Configure OAuth2 access token for authorization: googleoauth
#' api.instance$apiClient$accessToken <- 'TODO_YOUR_ACCESS_TOKEN';
#'
#' result <- api.instance$UpdateCatalog(var.workspace.namespace, var.workspace.name, var.catalog.updates)
#'
#'
#' #################### UpdateWorkspaceACL ####################
#'
#' library(openapi)
#' var.workspace.namespace <- 'workspace.namespace_example' # character | Workspace Namespace
#' var.workspace.name <- 'workspace.name_example' # character | Workspace Name
#' var.invite.users.not.found <- FALSE # character | true to invite unregistered users, false to ignore
#' var.acl.updates <- [WorkspaceACLUpdate$new()] # array[WorkspaceACLUpdate] | Series of ACL updates for workspace
#'
#' #Update workspace ACL
#' api.instance <- WorkspacesApi$new()
#'
#' # Configure OAuth2 access token for authorization: googleoauth
#' api.instance$apiClient$accessToken <- 'TODO_YOUR_ACCESS_TOKEN';
#'
#' result <- api.instance$UpdateWorkspaceACL(var.workspace.namespace, var.workspace.name, var.invite.users.not.found, var.acl.updates)
#'
#'
#' #################### WorkspacePermissionReport ####################
#'
#' library(openapi)
#' var.workspace.namespace <- 'workspace.namespace_example' # character | Workspace Namespace
#' var.workspace.name <- 'workspace.name_example' # character | Workspace Name
#' var.report.input <- PermissionReportRequest$new() # PermissionReportRequest | Users and/or configs on which to report, both optional
#'
#' #Retrieve user permissions for the workspace and the workspace's method references
#' api.instance <- WorkspacesApi$new()
#'
#' # Configure OAuth2 access token for authorization: googleoauth
#' api.instance$apiClient$accessToken <- 'TODO_YOUR_ACCESS_TOKEN';
#'
#' result <- api.instance$WorkspacePermissionReport(var.workspace.namespace, var.workspace.name, var.report.input)
#'
#'
#' }
#' @importFrom R6 R6Class
#' @importFrom base64enc base64encode
#' @export
WorkspacesApi <- R6::R6Class(
'WorkspacesApi',
public = list(
apiClient = NULL,
initialize = function(apiClient){
if (!missing(apiClient)) {
self$apiClient <- apiClient
}
else {
self$apiClient <- ApiClient$new()
}
},
BrowserDownloadAttributes = function(workspace.namespace, workspace.name, ...){
apiResponse <- self$BrowserDownloadAttributesWithHttpInfo(workspace.namespace, workspace.name, ...)
resp <- apiResponse$response
if (httr::status_code(resp) >= 200 && httr::status_code(resp) <= 299) {
apiResponse$content
} else if (httr::status_code(resp) >= 300 && httr::status_code(resp) <= 399) {
apiResponse
} else if (httr::status_code(resp) >= 400 && httr::status_code(resp) <= 499) {
apiResponse
} else if (httr::status_code(resp) >= 500 && httr::status_code(resp) <= 599) {
apiResponse
}
},
BrowserDownloadAttributesWithHttpInfo = function(workspace.namespace, workspace.name, ...){
args <- list(...)
queryParams <- list()
headerParams <- c()
if (missing(`workspace.namespace`)) {
stop("Missing required parameter `workspace.namespace`.")
}
if (missing(`workspace.name`)) {
stop("Missing required parameter `workspace.name`.")
}
body <- NULL
urlPath <- "/cookie-authed/workspaces/{workspaceNamespace}/{workspaceName}/exportAttributesTSV"
if (!missing(`workspace.namespace`)) {
urlPath <- gsub(paste0("\\{", "workspaceNamespace", "\\}"), URLencode(as.character(`workspace.namespace`), reserved = TRUE), urlPath)
}
if (!missing(`workspace.name`)) {
urlPath <- gsub(paste0("\\{", "workspaceName", "\\}"), URLencode(as.character(`workspace.name`), reserved = TRUE), urlPath)
}
# OAuth token
headerParams['Authorization'] <- paste("Bearer", self$apiClient$accessToken, sep=" ")
resp <- self$apiClient$CallApi(url = paste0(self$apiClient$basePath, urlPath),
method = "GET",
queryParams = queryParams,
headerParams = headerParams,
body = body,
...)
if (httr::status_code(resp) >= 200 && httr::status_code(resp) <= 299) {
deserializedRespObj <- tryCatch(
self$apiClient$deserialize(resp, "data.frame", loadNamespace("openapi")),
error = function(e){
stop("Failed to deserialize response")
}
)
ApiResponse$new(deserializedRespObj, resp)
} else if (httr::status_code(resp) >= 300 && httr::status_code(resp) <= 399) {
ApiResponse$new(paste("Server returned " , httr::status_code(resp) , " response status code."), resp)
} else if (httr::status_code(resp) >= 400 && httr::status_code(resp) <= 499) {
ApiResponse$new("API client error", resp)
} else if (httr::status_code(resp) >= 500 && httr::status_code(resp) <= 599) {
ApiResponse$new("API server error", resp)
}
},
ChangedWorkspaceNotification = function(workspace.namespace, workspace.name, ...){
apiResponse <- self$ChangedWorkspaceNotificationWithHttpInfo(workspace.namespace, workspace.name, ...)
resp <- apiResponse$response
if (httr::status_code(resp) >= 200 && httr::status_code(resp) <= 299) {
apiResponse$content
} else if (httr::status_code(resp) >= 300 && httr::status_code(resp) <= 399) {
apiResponse
} else if (httr::status_code(resp) >= 400 && httr::status_code(resp) <= 499) {
apiResponse
} else if (httr::status_code(resp) >= 500 && httr::status_code(resp) <= 599) {
apiResponse
}
},
ChangedWorkspaceNotificationWithHttpInfo = function(workspace.namespace, workspace.name, ...){
args <- list(...)
queryParams <- list()
headerParams <- c()
if (missing(`workspace.namespace`)) {
stop("Missing required parameter `workspace.namespace`.")
}
if (missing(`workspace.name`)) {
stop("Missing required parameter `workspace.name`.")
}
body <- NULL
urlPath <- "/api/workspaces/{workspaceNamespace}/{workspaceName}/sendChangeNotification"
if (!missing(`workspace.namespace`)) {
urlPath <- gsub(paste0("\\{", "workspaceNamespace", "\\}"), URLencode(as.character(`workspace.namespace`), reserved = TRUE), urlPath)
}
if (!missing(`workspace.name`)) {
urlPath <- gsub(paste0("\\{", "workspaceName", "\\}"), URLencode(as.character(`workspace.name`), reserved = TRUE), urlPath)
}
# OAuth token
headerParams['Authorization'] <- paste("Bearer", self$apiClient$accessToken, sep=" ")
resp <- self$apiClient$CallApi(url = paste0(self$apiClient$basePath, urlPath),
method = "POST",
queryParams = queryParams,
headerParams = headerParams,
body = body,
...)
if (httr::status_code(resp) >= 200 && httr::status_code(resp) <= 299) {
ApiResponse$new(NULL, resp)
} else if (httr::status_code(resp) >= 300 && httr::status_code(resp) <= 399) {
ApiResponse$new(paste("Server returned " , httr::status_code(resp) , " response status code."), resp)
} else if (httr::status_code(resp) >= 400 && httr::status_code(resp) <= 499) {
ApiResponse$new("API client error", resp)
} else if (httr::status_code(resp) >= 500 && httr::status_code(resp) <= 599) {
ApiResponse$new("API server error", resp)
}
},
CheckIamActionWithLock = function(workspace.namespace, workspace.name, sam.action.name, ...){
apiResponse <- self$CheckIamActionWithLockWithHttpInfo(workspace.namespace, workspace.name, sam.action.name, ...)
resp <- apiResponse$response
if (httr::status_code(resp) >= 200 && httr::status_code(resp) <= 299) {
apiResponse$content
} else if (httr::status_code(resp) >= 300 && httr::status_code(resp) <= 399) {
apiResponse
} else if (httr::status_code(resp) >= 400 && httr::status_code(resp) <= 499) {
apiResponse
} else if (httr::status_code(resp) >= 500 && httr::status_code(resp) <= 599) {
apiResponse
}
},
CheckIamActionWithLockWithHttpInfo = function(workspace.namespace, workspace.name, sam.action.name, ...){
args <- list(...)
queryParams <- list()
headerParams <- c()
if (missing(`workspace.namespace`)) {
stop("Missing required parameter `workspace.namespace`.")
}
if (missing(`workspace.name`)) {
stop("Missing required parameter `workspace.name`.")
}
if (missing(`sam.action.name`)) {
stop("Missing required parameter `sam.action.name`.")
}
body <- NULL
urlPath <- "/api/workspaces/{workspaceNamespace}/{workspaceName}/checkIamActionWithLock/{samActionName}"
if (!missing(`workspace.namespace`)) {
urlPath <- gsub(paste0("\\{", "workspaceNamespace", "\\}"), URLencode(as.character(`workspace.namespace`), reserved = TRUE), urlPath)
}
if (!missing(`workspace.name`)) {
urlPath <- gsub(paste0("\\{", "workspaceName", "\\}"), URLencode(as.character(`workspace.name`), reserved = TRUE), urlPath)
}
if (!missing(`sam.action.name`)) {
urlPath <- gsub(paste0("\\{", "samActionName", "\\}"), URLencode(as.character(`sam.action.name`), reserved = TRUE), urlPath)
}
# OAuth token
headerParams['Authorization'] <- paste("Bearer", self$apiClient$accessToken, sep=" ")
resp <- self$apiClient$CallApi(url = paste0(self$apiClient$basePath, urlPath),
method = "GET",
queryParams = queryParams,
headerParams = headerParams,
body = body,
...)
if (httr::status_code(resp) >= 200 && httr::status_code(resp) <= 299) {
ApiResponse$new(NULL, resp)
} else if (httr::status_code(resp) >= 300 && httr::status_code(resp) <= 399) {
ApiResponse$new(paste("Server returned " , httr::status_code(resp) , " response status code."), resp)
} else if (httr::status_code(resp) >= 400 && httr::status_code(resp) <= 499) {
ApiResponse$new("API client error", resp)
} else if (httr::status_code(resp) >= 500 && httr::status_code(resp) <= 599) {
ApiResponse$new("API server error", resp)
}
},
CloneWorkspace = function(workspace.namespace, workspace.name, workspace, ...){
apiResponse <- self$CloneWorkspaceWithHttpInfo(workspace.namespace, workspace.name, workspace, ...)
resp <- apiResponse$response
if (httr::status_code(resp) >= 200 && httr::status_code(resp) <= 299) {
apiResponse$content
} else if (httr::status_code(resp) >= 300 && httr::status_code(resp) <= 399) {
apiResponse
} else if (httr::status_code(resp) >= 400 && httr::status_code(resp) <= 499) {
apiResponse
} else if (httr::status_code(resp) >= 500 && httr::status_code(resp) <= 599) {
apiResponse
}
},
CloneWorkspaceWithHttpInfo = function(workspace.namespace, workspace.name, workspace, ...){
args <- list(...)
queryParams <- list()
headerParams <- c()
if (missing(`workspace.namespace`)) {
stop("Missing required parameter `workspace.namespace`.")
}
if (missing(`workspace.name`)) {
stop("Missing required parameter `workspace.name`.")
}
if (missing(`workspace`)) {
stop("Missing required parameter `workspace`.")
}
if (!missing(`workspace`)) {
body <- `workspace`$toJSONString()
} else {
body <- NULL
}
urlPath <- "/api/workspaces/{workspaceNamespace}/{workspaceName}/clone"
if (!missing(`workspace.namespace`)) {
urlPath <- gsub(paste0("\\{", "workspaceNamespace", "\\}"), URLencode(as.character(`workspace.namespace`), reserved = TRUE), urlPath)
}
if (!missing(`workspace.name`)) {
urlPath <- gsub(paste0("\\{", "workspaceName", "\\}"), URLencode(as.character(`workspace.name`), reserved = TRUE), urlPath)
}
# OAuth token
headerParams['Authorization'] <- paste("Bearer", self$apiClient$accessToken, sep=" ")
resp <- self$apiClient$CallApi(url = paste0(self$apiClient$basePath, urlPath),
method = "POST",
queryParams = queryParams,
headerParams = headerParams,
body = body,
...)
if (httr::status_code(resp) >= 200 && httr::status_code(resp) <= 299) {
deserializedRespObj <- tryCatch(
self$apiClient$deserialize(resp, "WorkspaceDetails", loadNamespace("openapi")),
error = function(e){
stop("Failed to deserialize response")
}
)
ApiResponse$new(deserializedRespObj, resp)
} else if (httr::status_code(resp) >= 300 && httr::status_code(resp) <= 399) {
ApiResponse$new(paste("Server returned " , httr::status_code(resp) , " response status code."), resp)
} else if (httr::status_code(resp) >= 400 && httr::status_code(resp) <= 499) {
ApiResponse$new("API client error", resp)
} else if (httr::status_code(resp) >= 500 && httr::status_code(resp) <= 599) {
ApiResponse$new("API server error", resp)
}
},
CreateWorkspace = function(workspace, ...){
apiResponse <- self$CreateWorkspaceWithHttpInfo(workspace, ...)
resp <- apiResponse$response
if (httr::status_code(resp) >= 200 && httr::status_code(resp) <= 299) {
apiResponse$content
} else if (httr::status_code(resp) >= 300 && httr::status_code(resp) <= 399) {
apiResponse
} else if (httr::status_code(resp) >= 400 && httr::status_code(resp) <= 499) {
apiResponse
} else if (httr::status_code(resp) >= 500 && httr::status_code(resp) <= 599) {
apiResponse
}
},
CreateWorkspaceWithHttpInfo = function(workspace, ...){
args <- list(...)
queryParams <- list()
headerParams <- c()
if (missing(`workspace`)) {
stop("Missing required parameter `workspace`.")
}
if (!missing(`workspace`)) {
body <- `workspace`$toJSONString()
} else {
body <- NULL
}
urlPath <- "/api/workspaces"
# OAuth token
headerParams['Authorization'] <- paste("Bearer", self$apiClient$accessToken, sep=" ")
resp <- self$apiClient$CallApi(url = paste0(self$apiClient$basePath, urlPath),
method = "POST",
queryParams = queryParams,
headerParams = headerParams,
body = body,
...)
if (httr::status_code(resp) >= 200 && httr::status_code(resp) <= 299) {
deserializedRespObj <- tryCatch(
self$apiClient$deserialize(resp, "WorkspaceDetails", loadNamespace("openapi")),
error = function(e){
stop("Failed to deserialize response")
}
)
ApiResponse$new(deserializedRespObj, resp)
} else if (httr::status_code(resp) >= 300 && httr::status_code(resp) <= 399) {
ApiResponse$new(paste("Server returned " , httr::status_code(resp) , " response status code."), resp)
} else if (httr::status_code(resp) >= 400 && httr::status_code(resp) <= 499) {
ApiResponse$new("API client error", resp)
} else if (httr::status_code(resp) >= 500 && httr::status_code(resp) <= 599) {
ApiResponse$new("API server error", resp)
}
},
DeleteWorkspace = function(workspace.namespace, workspace.name, ...){
apiResponse <- self$DeleteWorkspaceWithHttpInfo(workspace.namespace, workspace.name, ...)
resp <- apiResponse$response
if (httr::status_code(resp) >= 200 && httr::status_code(resp) <= 299) {
apiResponse$content
} else if (httr::status_code(resp) >= 300 && httr::status_code(resp) <= 399) {
apiResponse
} else if (httr::status_code(resp) >= 400 && httr::status_code(resp) <= 499) {
apiResponse
} else if (httr::status_code(resp) >= 500 && httr::status_code(resp) <= 599) {
apiResponse
}
},
DeleteWorkspaceWithHttpInfo = function(workspace.namespace, workspace.name, ...){
args <- list(...)
queryParams <- list()
headerParams <- c()
if (missing(`workspace.namespace`)) {
stop("Missing required parameter `workspace.namespace`.")
}
if (missing(`workspace.name`)) {
stop("Missing required parameter `workspace.name`.")
}
body <- NULL
urlPath <- "/api/workspaces/{workspaceNamespace}/{workspaceName}"
if (!missing(`workspace.namespace`)) {
urlPath <- gsub(paste0("\\{", "workspaceNamespace", "\\}"), URLencode(as.character(`workspace.namespace`), reserved = TRUE), urlPath)
}
if (!missing(`workspace.name`)) {
urlPath <- gsub(paste0("\\{", "workspaceName", "\\}"), URLencode(as.character(`workspace.name`), reserved = TRUE), urlPath)
}
# OAuth token
headerParams['Authorization'] <- paste("Bearer", self$apiClient$accessToken, sep=" ")
resp <- self$apiClient$CallApi(url = paste0(self$apiClient$basePath, urlPath),
method = "DELETE",
queryParams = queryParams,
headerParams = headerParams,
body = body,
...)
if (httr::status_code(resp) >= 200 && httr::status_code(resp) <= 299) {
ApiResponse$new(NULL, resp)
} else if (httr::status_code(resp) >= 300 && httr::status_code(resp) <= 399) {
ApiResponse$new(paste("Server returned " , httr::status_code(resp) , " response status code."), resp)
} else if (httr::status_code(resp) >= 400 && httr::status_code(resp) <= 499) {
ApiResponse$new("API client error", resp)
} else if (httr::status_code(resp) >= 500 && httr::status_code(resp) <= 599) {
ApiResponse$new("API server error", resp)
}
},
DeleteWorkspaceTags = function(workspace.namespace, workspace.name, tags, ...){
apiResponse <- self$DeleteWorkspaceTagsWithHttpInfo(workspace.namespace, workspace.name, tags, ...)
resp <- apiResponse$response
if (httr::status_code(resp) >= 200 && httr::status_code(resp) <= 299) {
apiResponse$content
} else if (httr::status_code(resp) >= 300 && httr::status_code(resp) <= 399) {
apiResponse
} else if (httr::status_code(resp) >= 400 && httr::status_code(resp) <= 499) {
apiResponse
} else if (httr::status_code(resp) >= 500 && httr::status_code(resp) <= 599) {
apiResponse
}
},
DeleteWorkspaceTagsWithHttpInfo = function(workspace.namespace, workspace.name, tags, ...){
args <- list(...)
queryParams <- list()
headerParams <- c()
if (missing(`workspace.namespace`)) {
stop("Missing required parameter `workspace.namespace`.")
}
if (missing(`workspace.name`)) {
stop("Missing required parameter `workspace.name`.")
}
if (missing(`tags`)) {
stop("Missing required parameter `tags`.")
}
if (!missing(`tags`)) {
body.items = paste(unlist(lapply(tags, function(param){param$toJSONString()})), collapse = ",")
body <- paste0('[', body.items, ']')
} else {
body <- NULL
}
urlPath <- "/api/workspaces/{workspaceNamespace}/{workspaceName}/tags"
if (!missing(`workspace.namespace`)) {
urlPath <- gsub(paste0("\\{", "workspaceNamespace", "\\}"), URLencode(as.character(`workspace.namespace`), reserved = TRUE), urlPath)
}
if (!missing(`workspace.name`)) {
urlPath <- gsub(paste0("\\{", "workspaceName", "\\}"), URLencode(as.character(`workspace.name`), reserved = TRUE), urlPath)
}
# OAuth token
headerParams['Authorization'] <- paste("Bearer", self$apiClient$accessToken, sep=" ")
resp <- self$apiClient$CallApi(url = paste0(self$apiClient$basePath, urlPath),
method = "DELETE",
queryParams = queryParams,
headerParams = headerParams,
body = body,
...)
if (httr::status_code(resp) >= 200 && httr::status_code(resp) <= 299) {
deserializedRespObj <- tryCatch(
self$apiClient$deserialize(resp, "array[character]", loadNamespace("openapi")),
error = function(e){
stop("Failed to deserialize response")
}
)
ApiResponse$new(deserializedRespObj, resp)
} else if (httr::status_code(resp) >= 300 && httr::status_code(resp) <= 399) {
ApiResponse$new(paste("Server returned " , httr::status_code(resp) , " response status code."), resp)
} else if (httr::status_code(resp) >= 400 && httr::status_code(resp) <= 499) {
ApiResponse$new("API client error", resp)
} else if (httr::status_code(resp) >= 500 && httr::status_code(resp) <= 599) {
ApiResponse$new("API server error", resp)
}
},
ExportAttributesTSV = function(workspace.namespace, workspace.name, ...){
apiResponse <- self$ExportAttributesTSVWithHttpInfo(workspace.namespace, workspace.name, ...)
resp <- apiResponse$response
if (httr::status_code(resp) >= 200 && httr::status_code(resp) <= 299) {
apiResponse$content
} else if (httr::status_code(resp) >= 300 && httr::status_code(resp) <= 399) {
apiResponse
} else if (httr::status_code(resp) >= 400 && httr::status_code(resp) <= 499) {
apiResponse
} else if (httr::status_code(resp) >= 500 && httr::status_code(resp) <= 599) {
apiResponse
}
},
ExportAttributesTSVWithHttpInfo = function(workspace.namespace, workspace.name, ...){
args <- list(...)
queryParams <- list()
headerParams <- c()
if (missing(`workspace.namespace`)) {
stop("Missing required parameter `workspace.namespace`.")
}
if (missing(`workspace.name`)) {
stop("Missing required parameter `workspace.name`.")
}
body <- NULL
urlPath <- "/api/workspaces/{workspaceNamespace}/{workspaceName}/exportAttributesTSV"
if (!missing(`workspace.namespace`)) {
urlPath <- gsub(paste0("\\{", "workspaceNamespace", "\\}"), URLencode(as.character(`workspace.namespace`), reserved = TRUE), urlPath)
}
if (!missing(`workspace.name`)) {
urlPath <- gsub(paste0("\\{", "workspaceName", "\\}"), URLencode(as.character(`workspace.name`), reserved = TRUE), urlPath)
}
# OAuth token
headerParams['Authorization'] <- paste("Bearer", self$apiClient$accessToken, sep=" ")
resp <- self$apiClient$CallApi(url = paste0(self$apiClient$basePath, urlPath),
method = "GET",
queryParams = queryParams,
headerParams = headerParams,
body = body,
...)
if (httr::status_code(resp) >= 200 && httr::status_code(resp) <= 299) {
deserializedRespObj <- tryCatch(
self$apiClient$deserialize(resp, "data.frame", loadNamespace("openapi")),
error = function(e){
stop("Failed to deserialize response")
}
)
ApiResponse$new(deserializedRespObj, resp)
} else if (httr::status_code(resp) >= 300 && httr::status_code(resp) <= 399) {
ApiResponse$new(paste("Server returned " , httr::status_code(resp) , " response status code."), resp)
} else if (httr::status_code(resp) >= 400 && httr::status_code(resp) <= 499) {
ApiResponse$new("API client error", resp)
} else if (httr::status_code(resp) >= 500 && httr::status_code(resp) <= 599) {
ApiResponse$new("API server error", resp)
}
},
GetBucketUsage = function(workspace.namespace, workspace.name, ...){
apiResponse <- self$GetBucketUsageWithHttpInfo(workspace.namespace, workspace.name, ...)
resp <- apiResponse$response
if (httr::status_code(resp) >= 200 && httr::status_code(resp) <= 299) {
apiResponse$content
} else if (httr::status_code(resp) >= 300 && httr::status_code(resp) <= 399) {
apiResponse
} else if (httr::status_code(resp) >= 400 && httr::status_code(resp) <= 499) {
apiResponse
} else if (httr::status_code(resp) >= 500 && httr::status_code(resp) <= 599) {
apiResponse
}
},
GetBucketUsageWithHttpInfo = function(workspace.namespace, workspace.name, ...){
args <- list(...)
queryParams <- list()
headerParams <- c()
if (missing(`workspace.namespace`)) {
stop("Missing required parameter `workspace.namespace`.")
}
if (missing(`workspace.name`)) {
stop("Missing required parameter `workspace.name`.")
}
body <- NULL
urlPath <- "/api/workspaces/{workspaceNamespace}/{workspaceName}/bucketUsage"
if (!missing(`workspace.namespace`)) {
urlPath <- gsub(paste0("\\{", "workspaceNamespace", "\\}"), URLencode(as.character(`workspace.namespace`), reserved = TRUE), urlPath)
}
if (!missing(`workspace.name`)) {
urlPath <- gsub(paste0("\\{", "workspaceName", "\\}"), URLencode(as.character(`workspace.name`), reserved = TRUE), urlPath)
}
# OAuth token
headerParams['Authorization'] <- paste("Bearer", self$apiClient$accessToken, sep=" ")
resp <- self$apiClient$CallApi(url = paste0(self$apiClient$basePath, urlPath),
method = "GET",
queryParams = queryParams,
headerParams = headerParams,
body = body,
...)
if (httr::status_code(resp) >= 200 && httr::status_code(resp) <= 299) {
ApiResponse$new(NULL, resp)
} else if (httr::status_code(resp) >= 300 && httr::status_code(resp) <= 399) {
ApiResponse$new(paste("Server returned " , httr::status_code(resp) , " response status code."), resp)
} else if (httr::status_code(resp) >= 400 && httr::status_code(resp) <= 499) {
ApiResponse$new("API client error", resp)
} else if (httr::status_code(resp) >= 500 && httr::status_code(resp) <= 599) {
ApiResponse$new("API server error", resp)
}
},
GetCatalog = function(workspace.namespace, workspace.name, ...){
apiResponse <- self$GetCatalogWithHttpInfo(workspace.namespace, workspace.name, ...)
resp <- apiResponse$response
if (httr::status_code(resp) >= 200 && httr::status_code(resp) <= 299) {
apiResponse$content
} else if (httr::status_code(resp) >= 300 && httr::status_code(resp) <= 399) {
apiResponse
} else if (httr::status_code(resp) >= 400 && httr::status_code(resp) <= 499) {
apiResponse
} else if (httr::status_code(resp) >= 500 && httr::status_code(resp) <= 599) {
apiResponse
}
},
GetCatalogWithHttpInfo = function(workspace.namespace, workspace.name, ...){
args <- list(...)
queryParams <- list()
headerParams <- c()
if (missing(`workspace.namespace`)) {
stop("Missing required parameter `workspace.namespace`.")
}
if (missing(`workspace.name`)) {
stop("Missing required parameter `workspace.name`.")
}
body <- NULL
urlPath <- "/api/workspaces/{workspaceNamespace}/{workspaceName}/catalog"
if (!missing(`workspace.namespace`)) {
urlPath <- gsub(paste0("\\{", "workspaceNamespace", "\\}"), URLencode(as.character(`workspace.namespace`), reserved = TRUE), urlPath)
}
if (!missing(`workspace.name`)) {
urlPath <- gsub(paste0("\\{", "workspaceName", "\\}"), URLencode(as.character(`workspace.name`), reserved = TRUE), urlPath)
}
# OAuth token
headerParams['Authorization'] <- paste("Bearer", self$apiClient$accessToken, sep=" ")
resp <- self$apiClient$CallApi(url = paste0(self$apiClient$basePath, urlPath),
method = "GET",
queryParams = queryParams,
headerParams = headerParams,
body = body,
...)
if (httr::status_code(resp) >= 200 && httr::status_code(resp) <= 299) {
deserializedRespObj <- tryCatch(
self$apiClient$deserialize(resp, "array[WorkspaceCatalog]", loadNamespace("openapi")),
error = function(e){
stop("Failed to deserialize response")
}
)
ApiResponse$new(deserializedRespObj, resp)
} else if (httr::status_code(resp) >= 300 && httr::status_code(resp) <= 399) {
ApiResponse$new(paste("Server returned " , httr::status_code(resp) , " response status code."), resp)
} else if (httr::status_code(resp) >= 400 && httr::status_code(resp) <= 499) {
ApiResponse$new("API client error", resp)
} else if (httr::status_code(resp) >= 500 && httr::status_code(resp) <= 599) {
ApiResponse$new("API server error", resp)
}
},
GetStorageCostEstimate = function(workspace.namespace, workspace.name, ...){
apiResponse <- self$GetStorageCostEstimateWithHttpInfo(workspace.namespace, workspace.name, ...)
resp <- apiResponse$response
if (httr::status_code(resp) >= 200 && httr::status_code(resp) <= 299) {
apiResponse$content
} else if (httr::status_code(resp) >= 300 && httr::status_code(resp) <= 399) {
apiResponse
} else if (httr::status_code(resp) >= 400 && httr::status_code(resp) <= 499) {
apiResponse
} else if (httr::status_code(resp) >= 500 && httr::status_code(resp) <= 599) {
apiResponse
}
},
GetStorageCostEstimateWithHttpInfo = function(workspace.namespace, workspace.name, ...){
args <- list(...)
queryParams <- list()
headerParams <- c()
if (missing(`workspace.namespace`)) {
stop("Missing required parameter `workspace.namespace`.")
}
if (missing(`workspace.name`)) {
stop("Missing required parameter `workspace.name`.")
}
body <- NULL
urlPath <- "/api/workspaces/{workspaceNamespace}/{workspaceName}/storageCostEstimate"
if (!missing(`workspace.namespace`)) {
urlPath <- gsub(paste0("\\{", "workspaceNamespace", "\\}"), URLencode(as.character(`workspace.namespace`), reserved = TRUE), urlPath)
}
if (!missing(`workspace.name`)) {
urlPath <- gsub(paste0("\\{", "workspaceName", "\\}"), URLencode(as.character(`workspace.name`), reserved = TRUE), urlPath)
}
# OAuth token
headerParams['Authorization'] <- paste("Bearer", self$apiClient$accessToken, sep=" ")
resp <- self$apiClient$CallApi(url = paste0(self$apiClient$basePath, urlPath),
method = "GET",
queryParams = queryParams,
headerParams = headerParams,
body = body,
...)
if (httr::status_code(resp) >= 200 && httr::status_code(resp) <= 299) {
ApiResponse$new(NULL, resp)
} else if (httr::status_code(resp) >= 300 && httr::status_code(resp) <= 399) {
ApiResponse$new(paste("Server returned " , httr::status_code(resp) , " response status code."), resp)
} else if (httr::status_code(resp) >= 400 && httr::status_code(resp) <= 499) {
ApiResponse$new("API client error", resp)
} else if (httr::status_code(resp) >= 500 && httr::status_code(resp) <= 599) {
ApiResponse$new("API server error", resp)
}
},
GetTags = function(q=NULL, ...){
apiResponse <- self$GetTagsWithHttpInfo(q, ...)
resp <- apiResponse$response
if (httr::status_code(resp) >= 200 && httr::status_code(resp) <= 299) {
apiResponse$content
} else if (httr::status_code(resp) >= 300 && httr::status_code(resp) <= 399) {
apiResponse
} else if (httr::status_code(resp) >= 400 && httr::status_code(resp) <= 499) {
apiResponse
} else if (httr::status_code(resp) >= 500 && httr::status_code(resp) <= 599) {
apiResponse
}
},
GetTagsWithHttpInfo = function(q=NULL, ...){
args <- list(...)
queryParams <- list()
headerParams <- c()
queryParams['q'] <- q
body <- NULL
urlPath <- "/api/workspaces/tags"
# OAuth token
headerParams['Authorization'] <- paste("Bearer", self$apiClient$accessToken, sep=" ")
resp <- self$apiClient$CallApi(url = paste0(self$apiClient$basePath, urlPath),
method = "GET",
queryParams = queryParams,
headerParams = headerParams,
body = body,
...)
if (httr::status_code(resp) >= 200 && httr::status_code(resp) <= 299) {
deserializedRespObj <- tryCatch(
self$apiClient$deserialize(resp, "array[WorkspaceTag]", loadNamespace("openapi")),
error = function(e){
stop("Failed to deserialize response")
}
)
ApiResponse$new(deserializedRespObj, resp)
} else if (httr::status_code(resp) >= 300 && httr::status_code(resp) <= 399) {
ApiResponse$new(paste("Server returned " , httr::status_code(resp) , " response status code."), resp)
} else if (httr::status_code(resp) >= 400 && httr::status_code(resp) <= 499) {
ApiResponse$new("API client error", resp)
} else if (httr::status_code(resp) >= 500 && httr::status_code(resp) <= 599) {
ApiResponse$new("API server error", resp)
}
},
GetWorkspace = function(workspace.namespace, workspace.name, fields=NULL, ...){
apiResponse <- self$GetWorkspaceWithHttpInfo(workspace.namespace, workspace.name, fields, ...)
resp <- apiResponse$response
if (httr::status_code(resp) >= 200 && httr::status_code(resp) <= 299) {
apiResponse$content
} else if (httr::status_code(resp) >= 300 && httr::status_code(resp) <= 399) {
apiResponse
} else if (httr::status_code(resp) >= 400 && httr::status_code(resp) <= 499) {
apiResponse
} else if (httr::status_code(resp) >= 500 && httr::status_code(resp) <= 599) {
apiResponse
}
},
GetWorkspaceWithHttpInfo = function(workspace.namespace, workspace.name, fields=NULL, ...){
args <- list(...)
queryParams <- list()
headerParams <- c()
if (missing(`workspace.namespace`)) {
stop("Missing required parameter `workspace.namespace`.")
}
if (missing(`workspace.name`)) {
stop("Missing required parameter `workspace.name`.")
}
queryParams['fields'] <- fields
body <- NULL
urlPath <- "/api/workspaces/{workspaceNamespace}/{workspaceName}"
if (!missing(`workspace.namespace`)) {
urlPath <- gsub(paste0("\\{", "workspaceNamespace", "\\}"), URLencode(as.character(`workspace.namespace`), reserved = TRUE), urlPath)
}
if (!missing(`workspace.name`)) {
urlPath <- gsub(paste0("\\{", "workspaceName", "\\}"), URLencode(as.character(`workspace.name`), reserved = TRUE), urlPath)
}
# OAuth token
headerParams['Authorization'] <- paste("Bearer", self$apiClient$accessToken, sep=" ")
resp <- self$apiClient$CallApi(url = paste0(self$apiClient$basePath, urlPath),
method = "GET",
queryParams = queryParams,
headerParams = headerParams,
body = body,
...)
if (httr::status_code(resp) >= 200 && httr::status_code(resp) <= 299) {
deserializedRespObj <- tryCatch(
self$apiClient$deserialize(resp, "WorkspaceResponse", loadNamespace("openapi")),
error = function(e){
stop("Failed to deserialize response")
}
)
ApiResponse$new(deserializedRespObj, resp)
} else if (httr::status_code(resp) >= 300 && httr::status_code(resp) <= 399) {
ApiResponse$new(paste("Server returned " , httr::status_code(resp) , " response status code."), resp)
} else if (httr::status_code(resp) >= 400 && httr::status_code(resp) <= 499) {
ApiResponse$new("API client error", resp)
} else if (httr::status_code(resp) >= 500 && httr::status_code(resp) <= 599) {
ApiResponse$new("API server error", resp)
}
},
GetWorkspaceAccessInstructions = function(workspace.namespace, workspace.name, ...){
apiResponse <- self$GetWorkspaceAccessInstructionsWithHttpInfo(workspace.namespace, workspace.name, ...)
resp <- apiResponse$response
if (httr::status_code(resp) >= 200 && httr::status_code(resp) <= 299) {
apiResponse$content
} else if (httr::status_code(resp) >= 300 && httr::status_code(resp) <= 399) {
apiResponse
} else if (httr::status_code(resp) >= 400 && httr::status_code(resp) <= 499) {
apiResponse
} else if (httr::status_code(resp) >= 500 && httr::status_code(resp) <= 599) {
apiResponse
}
},
GetWorkspaceAccessInstructionsWithHttpInfo = function(workspace.namespace, workspace.name, ...){
args <- list(...)
queryParams <- list()
headerParams <- c()
if (missing(`workspace.namespace`)) {
stop("Missing required parameter `workspace.namespace`.")
}
if (missing(`workspace.name`)) {
stop("Missing required parameter `workspace.name`.")
}
body <- NULL
urlPath <- "/api/workspaces/{workspaceNamespace}/{workspaceName}/accessInstructions"
if (!missing(`workspace.namespace`)) {
urlPath <- gsub(paste0("\\{", "workspaceNamespace", "\\}"), URLencode(as.character(`workspace.namespace`), reserved = TRUE), urlPath)
}
if (!missing(`workspace.name`)) {
urlPath <- gsub(paste0("\\{", "workspaceName", "\\}"), URLencode(as.character(`workspace.name`), reserved = TRUE), urlPath)
}
# OAuth token
headerParams['Authorization'] <- paste("Bearer", self$apiClient$accessToken, sep=" ")
resp <- self$apiClient$CallApi(url = paste0(self$apiClient$basePath, urlPath),
method = "GET",
queryParams = queryParams,
headerParams = headerParams,
body = body,
...)
if (httr::status_code(resp) >= 200 && httr::status_code(resp) <= 299) {
deserializedRespObj <- tryCatch(
self$apiClient$deserialize(resp, "array[ManagedGroupAccessInstructions]", loadNamespace("openapi")),
error = function(e){
stop("Failed to deserialize response")
}
)
ApiResponse$new(deserializedRespObj, resp)
} else if (httr::status_code(resp) >= 300 && httr::status_code(resp) <= 399) {
ApiResponse$new(paste("Server returned " , httr::status_code(resp) , " response status code."), resp)
} else if (httr::status_code(resp) >= 400 && httr::status_code(resp) <= 499) {
ApiResponse$new("API client error", resp)
} else if (httr::status_code(resp) >= 500 && httr::status_code(resp) <= 599) {
ApiResponse$new("API server error", resp)
}
},
GetWorkspaceAcl = function(workspace.namespace, workspace.name, ...){
apiResponse <- self$GetWorkspaceAclWithHttpInfo(workspace.namespace, workspace.name, ...)
resp <- apiResponse$response
if (httr::status_code(resp) >= 200 && httr::status_code(resp) <= 299) {
apiResponse$content
} else if (httr::status_code(resp) >= 300 && httr::status_code(resp) <= 399) {
apiResponse
} else if (httr::status_code(resp) >= 400 && httr::status_code(resp) <= 499) {
apiResponse
} else if (httr::status_code(resp) >= 500 && httr::status_code(resp) <= 599) {
apiResponse
}
},
GetWorkspaceAclWithHttpInfo = function(workspace.namespace, workspace.name, ...){
args <- list(...)
queryParams <- list()
headerParams <- c()
if (missing(`workspace.namespace`)) {
stop("Missing required parameter `workspace.namespace`.")
}
if (missing(`workspace.name`)) {
stop("Missing required parameter `workspace.name`.")
}
body <- NULL
urlPath <- "/api/workspaces/{workspaceNamespace}/{workspaceName}/acl"
if (!missing(`workspace.namespace`)) {
urlPath <- gsub(paste0("\\{", "workspaceNamespace", "\\}"), URLencode(as.character(`workspace.namespace`), reserved = TRUE), urlPath)
}
if (!missing(`workspace.name`)) {
urlPath <- gsub(paste0("\\{", "workspaceName", "\\}"), URLencode(as.character(`workspace.name`), reserved = TRUE), urlPath)
}
# OAuth token
headerParams['Authorization'] <- paste("Bearer", self$apiClient$accessToken, sep=" ")
resp <- self$apiClient$CallApi(url = paste0(self$apiClient$basePath, urlPath),
method = "GET",
queryParams = queryParams,
headerParams = headerParams,
body = body,
...)
if (httr::status_code(resp) >= 200 && httr::status_code(resp) <= 299) {
deserializedRespObj <- tryCatch(
self$apiClient$deserialize(resp, "WorkspaceACL", loadNamespace("openapi")),
error = function(e){
stop("Failed to deserialize response")
}
)
ApiResponse$new(deserializedRespObj, resp)
} else if (httr::status_code(resp) >= 300 && httr::status_code(resp) <= 399) {
ApiResponse$new(paste("Server returned " , httr::status_code(resp) , " response status code."), resp)
} else if (httr::status_code(resp) >= 400 && httr::status_code(resp) <= 499) {
ApiResponse$new("API client error", resp)
} else if (httr::status_code(resp) >= 500 && httr::status_code(resp) <= 599) {
ApiResponse$new("API server error", resp)
}
},
GetWorkspaceBucketOptions = function(workspace.namespace, workspace.name, ...){
apiResponse <- self$GetWorkspaceBucketOptionsWithHttpInfo(workspace.namespace, workspace.name, ...)
resp <- apiResponse$response
if (httr::status_code(resp) >= 200 && httr::status_code(resp) <= 299) {
apiResponse$content
} else if (httr::status_code(resp) >= 300 && httr::status_code(resp) <= 399) {
apiResponse
} else if (httr::status_code(resp) >= 400 && httr::status_code(resp) <= 499) {
apiResponse
} else if (httr::status_code(resp) >= 500 && httr::status_code(resp) <= 599) {
apiResponse
}
},
GetWorkspaceBucketOptionsWithHttpInfo = function(workspace.namespace, workspace.name, ...){
args <- list(...)
queryParams <- list()
headerParams <- c()
if (missing(`workspace.namespace`)) {
stop("Missing required parameter `workspace.namespace`.")
}
if (missing(`workspace.name`)) {
stop("Missing required parameter `workspace.name`.")
}
body <- NULL
urlPath <- "/api/workspaces/{workspaceNamespace}/{workspaceName}/bucketOptions"
if (!missing(`workspace.namespace`)) {
urlPath <- gsub(paste0("\\{", "workspaceNamespace", "\\}"), URLencode(as.character(`workspace.namespace`), reserved = TRUE), urlPath)
}
if (!missing(`workspace.name`)) {
urlPath <- gsub(paste0("\\{", "workspaceName", "\\}"), URLencode(as.character(`workspace.name`), reserved = TRUE), urlPath)
}
# OAuth token
headerParams['Authorization'] <- paste("Bearer", self$apiClient$accessToken, sep=" ")
resp <- self$apiClient$CallApi(url = paste0(self$apiClient$basePath, urlPath),
method = "GET",
queryParams = queryParams,
headerParams = headerParams,
body = body,
...)
if (httr::status_code(resp) >= 200 && httr::status_code(resp) <= 299) {
deserializedRespObj <- tryCatch(
self$apiClient$deserialize(resp, "WorkspaceBucketOptions", loadNamespace("openapi")),
error = function(e){
stop("Failed to deserialize response")
}
)
ApiResponse$new(deserializedRespObj, resp)
} else if (httr::status_code(resp) >= 300 && httr::status_code(resp) <= 399) {
ApiResponse$new(paste("Server returned " , httr::status_code(resp) , " response status code."), resp)
} else if (httr::status_code(resp) >= 400 && httr::status_code(resp) <= 499) {
ApiResponse$new("API client error", resp)
} else if (httr::status_code(resp) >= 500 && httr::status_code(resp) <= 599) {
ApiResponse$new("API server error", resp)
}
},
GetWorkspaceTags = function(workspace.namespace, workspace.name, ...){
apiResponse <- self$GetWorkspaceTagsWithHttpInfo(workspace.namespace, workspace.name, ...)
resp <- apiResponse$response
if (httr::status_code(resp) >= 200 && httr::status_code(resp) <= 299) {
apiResponse$content
} else if (httr::status_code(resp) >= 300 && httr::status_code(resp) <= 399) {
apiResponse
} else if (httr::status_code(resp) >= 400 && httr::status_code(resp) <= 499) {
apiResponse
} else if (httr::status_code(resp) >= 500 && httr::status_code(resp) <= 599) {
apiResponse
}
},
GetWorkspaceTagsWithHttpInfo = function(workspace.namespace, workspace.name, ...){
args <- list(...)
queryParams <- list()
headerParams <- c()
if (missing(`workspace.namespace`)) {
stop("Missing required parameter `workspace.namespace`.")
}
if (missing(`workspace.name`)) {
stop("Missing required parameter `workspace.name`.")
}
body <- NULL
urlPath <- "/api/workspaces/{workspaceNamespace}/{workspaceName}/tags"
if (!missing(`workspace.namespace`)) {
urlPath <- gsub(paste0("\\{", "workspaceNamespace", "\\}"), URLencode(as.character(`workspace.namespace`), reserved = TRUE), urlPath)
}
if (!missing(`workspace.name`)) {
urlPath <- gsub(paste0("\\{", "workspaceName", "\\}"), URLencode(as.character(`workspace.name`), reserved = TRUE), urlPath)
}
# OAuth token
headerParams['Authorization'] <- paste("Bearer", self$apiClient$accessToken, sep=" ")
resp <- self$apiClient$CallApi(url = paste0(self$apiClient$basePath, urlPath),
method = "GET",
queryParams = queryParams,
headerParams = headerParams,
body = body,
...)
if (httr::status_code(resp) >= 200 && httr::status_code(resp) <= 299) {
deserializedRespObj <- tryCatch(
self$apiClient$deserialize(resp, "array[character]", loadNamespace("openapi")),
error = function(e){
stop("Failed to deserialize response")
}
)
ApiResponse$new(deserializedRespObj, resp)
} else if (httr::status_code(resp) >= 300 && httr::status_code(resp) <= 399) {
ApiResponse$new(paste("Server returned " , httr::status_code(resp) , " response status code."), resp)
} else if (httr::status_code(resp) >= 400 && httr::status_code(resp) <= 499) {
ApiResponse$new("API client error", resp)
} else if (httr::status_code(resp) >= 500 && httr::status_code(resp) <= 599) {
ApiResponse$new("API server error", resp)
}
},
ImportAttributesTSV = function(workspace.namespace, workspace.name, attributes, ...){
apiResponse <- self$ImportAttributesTSVWithHttpInfo(workspace.namespace, workspace.name, attributes, ...)
resp <- apiResponse$response
if (httr::status_code(resp) >= 200 && httr::status_code(resp) <= 299) {
apiResponse$content
} else if (httr::status_code(resp) >= 300 && httr::status_code(resp) <= 399) {
apiResponse
} else if (httr::status_code(resp) >= 400 && httr::status_code(resp) <= 499) {
apiResponse
} else if (httr::status_code(resp) >= 500 && httr::status_code(resp) <= 599) {
apiResponse
}
},
ImportAttributesTSVWithHttpInfo = function(workspace.namespace, workspace.name, attributes, ...){
args <- list(...)
queryParams <- list()
headerParams <- c()
if (missing(`workspace.namespace`)) {
stop("Missing required parameter `workspace.namespace`.")
}
if (missing(`workspace.name`)) {
stop("Missing required parameter `workspace.name`.")
}
if (missing(`attributes`)) {
stop("Missing required parameter `attributes`.")
}
body <- list(
"attributes" = httr::upload_file(attributes)
)
urlPath <- "/api/workspaces/{workspaceNamespace}/{workspaceName}/importAttributesTSV"
if (!missing(`workspace.namespace`)) {
urlPath <- gsub(paste0("\\{", "workspaceNamespace", "\\}"), URLencode(as.character(`workspace.namespace`), reserved = TRUE), urlPath)
}
if (!missing(`workspace.name`)) {
urlPath <- gsub(paste0("\\{", "workspaceName", "\\}"), URLencode(as.character(`workspace.name`), reserved = TRUE), urlPath)
}
# OAuth token
headerParams['Authorization'] <- paste("Bearer", self$apiClient$accessToken, sep=" ")
resp <- self$apiClient$CallApi(url = paste0(self$apiClient$basePath, urlPath),
method = "POST",
queryParams = queryParams,
headerParams = headerParams,
body = body,
...)
if (httr::status_code(resp) >= 200 && httr::status_code(resp) <= 299) {
ApiResponse$new(NULL, resp)
} else if (httr::status_code(resp) >= 300 && httr::status_code(resp) <= 399) {
ApiResponse$new(paste("Server returned " , httr::status_code(resp) , " response status code."), resp)
} else if (httr::status_code(resp) >= 400 && httr::status_code(resp) <= 499) {
ApiResponse$new("API client error", resp)
} else if (httr::status_code(resp) >= 500 && httr::status_code(resp) <= 599) {
ApiResponse$new("API server error", resp)
}
},
ListWorkspaceMethodConfigs = function(workspace.namespace, workspace.name, all.repos=FALSE, ...){
apiResponse <- self$ListWorkspaceMethodConfigsWithHttpInfo(workspace.namespace, workspace.name, all.repos, ...)
resp <- apiResponse$response
if (httr::status_code(resp) >= 200 && httr::status_code(resp) <= 299) {
apiResponse$content
} else if (httr::status_code(resp) >= 300 && httr::status_code(resp) <= 399) {
apiResponse
} else if (httr::status_code(resp) >= 400 && httr::status_code(resp) <= 499) {
apiResponse
} else if (httr::status_code(resp) >= 500 && httr::status_code(resp) <= 599) {
apiResponse
}
},
ListWorkspaceMethodConfigsWithHttpInfo = function(workspace.namespace, workspace.name, all.repos=FALSE, ...){
args <- list(...)
queryParams <- list()
headerParams <- c()
if (missing(`workspace.namespace`)) {
stop("Missing required parameter `workspace.namespace`.")
}
if (missing(`workspace.name`)) {
stop("Missing required parameter `workspace.name`.")
}
queryParams['allRepos'] <- all.repos
body <- NULL
urlPath <- "/api/workspaces/{workspaceNamespace}/{workspaceName}/methodconfigs"
if (!missing(`workspace.namespace`)) {
urlPath <- gsub(paste0("\\{", "workspaceNamespace", "\\}"), URLencode(as.character(`workspace.namespace`), reserved = TRUE), urlPath)
}
if (!missing(`workspace.name`)) {
urlPath <- gsub(paste0("\\{", "workspaceName", "\\}"), URLencode(as.character(`workspace.name`), reserved = TRUE), urlPath)
}
# OAuth token
headerParams['Authorization'] <- paste("Bearer", self$apiClient$accessToken, sep=" ")
resp <- self$apiClient$CallApi(url = paste0(self$apiClient$basePath, urlPath),
method = "GET",
queryParams = queryParams,
headerParams = headerParams,
body = body,
...)
if (httr::status_code(resp) >= 200 && httr::status_code(resp) <= 299) {
ApiResponse$new(NULL, resp)
} else if (httr::status_code(resp) >= 300 && httr::status_code(resp) <= 399) {
ApiResponse$new(paste("Server returned " , httr::status_code(resp) , " response status code."), resp)
} else if (httr::status_code(resp) >= 400 && httr::status_code(resp) <= 499) {
ApiResponse$new("API client error", resp)
} else if (httr::status_code(resp) >= 500 && httr::status_code(resp) <= 599) {
ApiResponse$new("API server error", resp)
}
},
ListWorkspaces = function(fields=NULL, ...){
apiResponse <- self$ListWorkspacesWithHttpInfo(fields, ...)
resp <- apiResponse$response
if (httr::status_code(resp) >= 200 && httr::status_code(resp) <= 299) {
apiResponse$content
} else if (httr::status_code(resp) >= 300 && httr::status_code(resp) <= 399) {
apiResponse
} else if (httr::status_code(resp) >= 400 && httr::status_code(resp) <= 499) {
apiResponse
} else if (httr::status_code(resp) >= 500 && httr::status_code(resp) <= 599) {
apiResponse
}
},
ListWorkspacesWithHttpInfo = function(fields=NULL, ...){
args <- list(...)
queryParams <- list()
headerParams <- c()
queryParams['fields'] <- fields
body <- NULL
urlPath <- "/api/workspaces"
# OAuth token
headerParams['Authorization'] <- paste("Bearer", self$apiClient$accessToken, sep=" ")
resp <- self$apiClient$CallApi(url = paste0(self$apiClient$basePath, urlPath),
method = "GET",
queryParams = queryParams,
headerParams = headerParams,
body = body,
...)
if (httr::status_code(resp) >= 200 && httr::status_code(resp) <= 299) {
deserializedRespObj <- tryCatch(
self$apiClient$deserialize(resp, "array[WorkspaceListResponse]", loadNamespace("openapi")),
error = function(e){
stop("Failed to deserialize response")
}
)
ApiResponse$new(deserializedRespObj, resp)
} else if (httr::status_code(resp) >= 300 && httr::status_code(resp) <= 399) {
ApiResponse$new(paste("Server returned " , httr::status_code(resp) , " response status code."), resp)
} else if (httr::status_code(resp) >= 400 && httr::status_code(resp) <= 499) {
ApiResponse$new("API client error", resp)
} else if (httr::status_code(resp) >= 500 && httr::status_code(resp) <= 599) {
ApiResponse$new("API server error", resp)
}
},
LockWorkspace = function(workspace.namespace, workspace.name, ...){
apiResponse <- self$LockWorkspaceWithHttpInfo(workspace.namespace, workspace.name, ...)
resp <- apiResponse$response
if (httr::status_code(resp) >= 200 && httr::status_code(resp) <= 299) {
apiResponse$content
} else if (httr::status_code(resp) >= 300 && httr::status_code(resp) <= 399) {
apiResponse
} else if (httr::status_code(resp) >= 400 && httr::status_code(resp) <= 499) {
apiResponse
} else if (httr::status_code(resp) >= 500 && httr::status_code(resp) <= 599) {
apiResponse
}
},
LockWorkspaceWithHttpInfo = function(workspace.namespace, workspace.name, ...){
args <- list(...)
queryParams <- list()
headerParams <- c()
if (missing(`workspace.namespace`)) {
stop("Missing required parameter `workspace.namespace`.")
}
if (missing(`workspace.name`)) {
stop("Missing required parameter `workspace.name`.")
}
body <- NULL
urlPath <- "/api/workspaces/{workspaceNamespace}/{workspaceName}/lock"
if (!missing(`workspace.namespace`)) {
urlPath <- gsub(paste0("\\{", "workspaceNamespace", "\\}"), URLencode(as.character(`workspace.namespace`), reserved = TRUE), urlPath)
}
if (!missing(`workspace.name`)) {
urlPath <- gsub(paste0("\\{", "workspaceName", "\\}"), URLencode(as.character(`workspace.name`), reserved = TRUE), urlPath)
}
# OAuth token
headerParams['Authorization'] <- paste("Bearer", self$apiClient$accessToken, sep=" ")
resp <- self$apiClient$CallApi(url = paste0(self$apiClient$basePath, urlPath),
method = "PUT",
queryParams = queryParams,
headerParams = headerParams,
body = body,
...)
if (httr::status_code(resp) >= 200 && httr::status_code(resp) <= 299) {
ApiResponse$new(NULL, resp)
} else if (httr::status_code(resp) >= 300 && httr::status_code(resp) <= 399) {
ApiResponse$new(paste("Server returned " , httr::status_code(resp) , " response status code."), resp)
} else if (httr::status_code(resp) >= 400 && httr::status_code(resp) <= 499) {
ApiResponse$new("API client error", resp)
} else if (httr::status_code(resp) >= 500 && httr::status_code(resp) <= 599) {
ApiResponse$new("API server error", resp)
}
},
PatchWorkspaceTags = function(workspace.namespace, workspace.name, tags, ...){
apiResponse <- self$PatchWorkspaceTagsWithHttpInfo(workspace.namespace, workspace.name, tags, ...)
resp <- apiResponse$response
if (httr::status_code(resp) >= 200 && httr::status_code(resp) <= 299) {
apiResponse$content
} else if (httr::status_code(resp) >= 300 && httr::status_code(resp) <= 399) {
apiResponse
} else if (httr::status_code(resp) >= 400 && httr::status_code(resp) <= 499) {
apiResponse
} else if (httr::status_code(resp) >= 500 && httr::status_code(resp) <= 599) {
apiResponse
}
},
PatchWorkspaceTagsWithHttpInfo = function(workspace.namespace, workspace.name, tags, ...){
args <- list(...)
queryParams <- list()
headerParams <- c()
if (missing(`workspace.namespace`)) {
stop("Missing required parameter `workspace.namespace`.")
}
if (missing(`workspace.name`)) {
stop("Missing required parameter `workspace.name`.")
}
if (missing(`tags`)) {
stop("Missing required parameter `tags`.")
}
if (!missing(`tags`)) {
body.items = paste(unlist(lapply(tags, function(param){param$toJSONString()})), collapse = ",")
body <- paste0('[', body.items, ']')
} else {
body <- NULL
}
urlPath <- "/api/workspaces/{workspaceNamespace}/{workspaceName}/tags"
if (!missing(`workspace.namespace`)) {
urlPath <- gsub(paste0("\\{", "workspaceNamespace", "\\}"), URLencode(as.character(`workspace.namespace`), reserved = TRUE), urlPath)
}
if (!missing(`workspace.name`)) {
urlPath <- gsub(paste0("\\{", "workspaceName", "\\}"), URLencode(as.character(`workspace.name`), reserved = TRUE), urlPath)
}
# OAuth token
headerParams['Authorization'] <- paste("Bearer", self$apiClient$accessToken, sep=" ")
resp <- self$apiClient$CallApi(url = paste0(self$apiClient$basePath, urlPath),
method = "PATCH",
queryParams = queryParams,
headerParams = headerParams,
body = body,
...)
if (httr::status_code(resp) >= 200 && httr::status_code(resp) <= 299) {
deserializedRespObj <- tryCatch(
self$apiClient$deserialize(resp, "array[character]", loadNamespace("openapi")),
error = function(e){
stop("Failed to deserialize response")
}
)
ApiResponse$new(deserializedRespObj, resp)
} else if (httr::status_code(resp) >= 300 && httr::status_code(resp) <= 399) {
ApiResponse$new(paste("Server returned " , httr::status_code(resp) , " response status code."), resp)
} else if (httr::status_code(resp) >= 400 && httr::status_code(resp) <= 499) {
ApiResponse$new("API client error", resp)
} else if (httr::status_code(resp) >= 500 && httr::status_code(resp) <= 599) {
ApiResponse$new("API server error", resp)
}
},
PostWorkspaceMethodConfig = function(workspace.namespace, workspace.name, method.config.json, ...){
apiResponse <- self$PostWorkspaceMethodConfigWithHttpInfo(workspace.namespace, workspace.name, method.config.json, ...)
resp <- apiResponse$response
if (httr::status_code(resp) >= 200 && httr::status_code(resp) <= 299) {
apiResponse$content
} else if (httr::status_code(resp) >= 300 && httr::status_code(resp) <= 399) {
apiResponse
} else if (httr::status_code(resp) >= 400 && httr::status_code(resp) <= 499) {
apiResponse
} else if (httr::status_code(resp) >= 500 && httr::status_code(resp) <= 599) {
apiResponse
}
},
PostWorkspaceMethodConfigWithHttpInfo = function(workspace.namespace, workspace.name, method.config.json, ...){
args <- list(...)
queryParams <- list()
headerParams <- c()
if (missing(`workspace.namespace`)) {
stop("Missing required parameter `workspace.namespace`.")
}
if (missing(`workspace.name`)) {
stop("Missing required parameter `workspace.name`.")
}
if (missing(`method.config.json`)) {
stop("Missing required parameter `method.config.json`.")
}
if (!missing(`method.config.json`)) {
body <- `method.config.json`$toJSONString()
} else {
body <- NULL
}
urlPath <- "/api/workspaces/{workspaceNamespace}/{workspaceName}/methodconfigs"
if (!missing(`workspace.namespace`)) {
urlPath <- gsub(paste0("\\{", "workspaceNamespace", "\\}"), URLencode(as.character(`workspace.namespace`), reserved = TRUE), urlPath)
}
if (!missing(`workspace.name`)) {
urlPath <- gsub(paste0("\\{", "workspaceName", "\\}"), URLencode(as.character(`workspace.name`), reserved = TRUE), urlPath)
}
# OAuth token
headerParams['Authorization'] <- paste("Bearer", self$apiClient$accessToken, sep=" ")
resp <- self$apiClient$CallApi(url = paste0(self$apiClient$basePath, urlPath),
method = "POST",
queryParams = queryParams,
headerParams = headerParams,
body = body,
...)
if (httr::status_code(resp) >= 200 && httr::status_code(resp) <= 299) {
ApiResponse$new(NULL, resp)
} else if (httr::status_code(resp) >= 300 && httr::status_code(resp) <= 399) {
ApiResponse$new(paste("Server returned " , httr::status_code(resp) , " response status code."), resp)
} else if (httr::status_code(resp) >= 400 && httr::status_code(resp) <= 499) {
ApiResponse$new("API client error", resp)
} else if (httr::status_code(resp) >= 500 && httr::status_code(resp) <= 599) {
ApiResponse$new("API server error", resp)
}
},
PutWorkspaceTags = function(workspace.namespace, workspace.name, tags, ...){
apiResponse <- self$PutWorkspaceTagsWithHttpInfo(workspace.namespace, workspace.name, tags, ...)
resp <- apiResponse$response
if (httr::status_code(resp) >= 200 && httr::status_code(resp) <= 299) {
apiResponse$content
} else if (httr::status_code(resp) >= 300 && httr::status_code(resp) <= 399) {
apiResponse
} else if (httr::status_code(resp) >= 400 && httr::status_code(resp) <= 499) {
apiResponse
} else if (httr::status_code(resp) >= 500 && httr::status_code(resp) <= 599) {
apiResponse
}
},
PutWorkspaceTagsWithHttpInfo = function(workspace.namespace, workspace.name, tags, ...){
args <- list(...)
queryParams <- list()
headerParams <- c()
if (missing(`workspace.namespace`)) {
stop("Missing required parameter `workspace.namespace`.")
}
if (missing(`workspace.name`)) {
stop("Missing required parameter `workspace.name`.")
}
if (missing(`tags`)) {
stop("Missing required parameter `tags`.")
}
if (!missing(`tags`)) {
body.items = paste(unlist(lapply(tags, function(param){param$toJSONString()})), collapse = ",")
body <- paste0('[', body.items, ']')
} else {
body <- NULL
}
urlPath <- "/api/workspaces/{workspaceNamespace}/{workspaceName}/tags"
if (!missing(`workspace.namespace`)) {
urlPath <- gsub(paste0("\\{", "workspaceNamespace", "\\}"), URLencode(as.character(`workspace.namespace`), reserved = TRUE), urlPath)
}
if (!missing(`workspace.name`)) {
urlPath <- gsub(paste0("\\{", "workspaceName", "\\}"), URLencode(as.character(`workspace.name`), reserved = TRUE), urlPath)
}
# OAuth token
headerParams['Authorization'] <- paste("Bearer", self$apiClient$accessToken, sep=" ")
resp <- self$apiClient$CallApi(url = paste0(self$apiClient$basePath, urlPath),
method = "PUT",
queryParams = queryParams,
headerParams = headerParams,
body = body,
...)
if (httr::status_code(resp) >= 200 && httr::status_code(resp) <= 299) {
deserializedRespObj <- tryCatch(
self$apiClient$deserialize(resp, "array[character]", loadNamespace("openapi")),
error = function(e){
stop("Failed to deserialize response")
}
)
ApiResponse$new(deserializedRespObj, resp)
} else if (httr::status_code(resp) >= 300 && httr::status_code(resp) <= 399) {
ApiResponse$new(paste("Server returned " , httr::status_code(resp) , " response status code."), resp)
} else if (httr::status_code(resp) >= 400 && httr::status_code(resp) <= 499) {
ApiResponse$new("API client error", resp)
} else if (httr::status_code(resp) >= 500 && httr::status_code(resp) <= 599) {
ApiResponse$new("API server error", resp)
}
},
ReadBucket = function(workspace.namespace, workspace.name, ...){
apiResponse <- self$ReadBucketWithHttpInfo(workspace.namespace, workspace.name, ...)
resp <- apiResponse$response
if (httr::status_code(resp) >= 200 && httr::status_code(resp) <= 299) {
apiResponse$content
} else if (httr::status_code(resp) >= 300 && httr::status_code(resp) <= 399) {
apiResponse
} else if (httr::status_code(resp) >= 400 && httr::status_code(resp) <= 499) {
apiResponse
} else if (httr::status_code(resp) >= 500 && httr::status_code(resp) <= 599) {
apiResponse
}
},
ReadBucketWithHttpInfo = function(workspace.namespace, workspace.name, ...){
args <- list(...)
queryParams <- list()
headerParams <- c()
if (missing(`workspace.namespace`)) {
stop("Missing required parameter `workspace.namespace`.")
}
if (missing(`workspace.name`)) {
stop("Missing required parameter `workspace.name`.")
}
body <- NULL
urlPath <- "/api/workspaces/{workspaceNamespace}/{workspaceName}/checkBucketReadAccess"
if (!missing(`workspace.namespace`)) {
urlPath <- gsub(paste0("\\{", "workspaceNamespace", "\\}"), URLencode(as.character(`workspace.namespace`), reserved = TRUE), urlPath)
}
if (!missing(`workspace.name`)) {
urlPath <- gsub(paste0("\\{", "workspaceName", "\\}"), URLencode(as.character(`workspace.name`), reserved = TRUE), urlPath)
}
# OAuth token
headerParams['Authorization'] <- paste("Bearer", self$apiClient$accessToken, sep=" ")
resp <- self$apiClient$CallApi(url = paste0(self$apiClient$basePath, urlPath),
method = "GET",
queryParams = queryParams,
headerParams = headerParams,
body = body,
...)
if (httr::status_code(resp) >= 200 && httr::status_code(resp) <= 299) {
ApiResponse$new(NULL, resp)
} else if (httr::status_code(resp) >= 300 && httr::status_code(resp) <= 399) {
ApiResponse$new(paste("Server returned " , httr::status_code(resp) , " response status code."), resp)
} else if (httr::status_code(resp) >= 400 && httr::status_code(resp) <= 499) {
ApiResponse$new("API client error", resp)
} else if (httr::status_code(resp) >= 500 && httr::status_code(resp) <= 599) {
ApiResponse$new("API server error", resp)
}
},
SetAttributes = function(workspace.namespace, workspace.name, new.attributes, ...){
apiResponse <- self$SetAttributesWithHttpInfo(workspace.namespace, workspace.name, new.attributes, ...)
resp <- apiResponse$response
if (httr::status_code(resp) >= 200 && httr::status_code(resp) <= 299) {
apiResponse$content
} else if (httr::status_code(resp) >= 300 && httr::status_code(resp) <= 399) {
apiResponse
} else if (httr::status_code(resp) >= 400 && httr::status_code(resp) <= 499) {
apiResponse
} else if (httr::status_code(resp) >= 500 && httr::status_code(resp) <= 599) {
apiResponse
}
},
SetAttributesWithHttpInfo = function(workspace.namespace, workspace.name, new.attributes, ...){
args <- list(...)
queryParams <- list()
headerParams <- c()
if (missing(`workspace.namespace`)) {
stop("Missing required parameter `workspace.namespace`.")
}
if (missing(`workspace.name`)) {
stop("Missing required parameter `workspace.name`.")
}
if (missing(`new.attributes`)) {
stop("Missing required parameter `new.attributes`.")
}
if (!missing(`new.attributes`)) {
body <- `new.attributes`$toJSONString()
} else {
body <- NULL
}
urlPath <- "/api/workspaces/{workspaceNamespace}/{workspaceName}/setAttributes"
if (!missing(`workspace.namespace`)) {
urlPath <- gsub(paste0("\\{", "workspaceNamespace", "\\}"), URLencode(as.character(`workspace.namespace`), reserved = TRUE), urlPath)
}
if (!missing(`workspace.name`)) {
urlPath <- gsub(paste0("\\{", "workspaceName", "\\}"), URLencode(as.character(`workspace.name`), reserved = TRUE), urlPath)
}
# OAuth token
headerParams['Authorization'] <- paste("Bearer", self$apiClient$accessToken, sep=" ")
resp <- self$apiClient$CallApi(url = paste0(self$apiClient$basePath, urlPath),
method = "PATCH",
queryParams = queryParams,
headerParams = headerParams,
body = body,
...)
if (httr::status_code(resp) >= 200 && httr::status_code(resp) <= 299) {
ApiResponse$new(NULL, resp)
} else if (httr::status_code(resp) >= 300 && httr::status_code(resp) <= 399) {
ApiResponse$new(paste("Server returned " , httr::status_code(resp) , " response status code."), resp)
} else if (httr::status_code(resp) >= 400 && httr::status_code(resp) <= 499) {
ApiResponse$new("API client error", resp)
} else if (httr::status_code(resp) >= 500 && httr::status_code(resp) <= 599) {
ApiResponse$new("API server error", resp)
}
},
UnlockWorkspace = function(workspace.namespace, workspace.name, ...){
apiResponse <- self$UnlockWorkspaceWithHttpInfo(workspace.namespace, workspace.name, ...)
resp <- apiResponse$response
if (httr::status_code(resp) >= 200 && httr::status_code(resp) <= 299) {
apiResponse$content
} else if (httr::status_code(resp) >= 300 && httr::status_code(resp) <= 399) {
apiResponse
} else if (httr::status_code(resp) >= 400 && httr::status_code(resp) <= 499) {
apiResponse
} else if (httr::status_code(resp) >= 500 && httr::status_code(resp) <= 599) {
apiResponse
}
},
UnlockWorkspaceWithHttpInfo = function(workspace.namespace, workspace.name, ...){
args <- list(...)
queryParams <- list()
headerParams <- c()
if (missing(`workspace.namespace`)) {
stop("Missing required parameter `workspace.namespace`.")
}
if (missing(`workspace.name`)) {
stop("Missing required parameter `workspace.name`.")
}
body <- NULL
urlPath <- "/api/workspaces/{workspaceNamespace}/{workspaceName}/unlock"
if (!missing(`workspace.namespace`)) {
urlPath <- gsub(paste0("\\{", "workspaceNamespace", "\\}"), URLencode(as.character(`workspace.namespace`), reserved = TRUE), urlPath)
}
if (!missing(`workspace.name`)) {
urlPath <- gsub(paste0("\\{", "workspaceName", "\\}"), URLencode(as.character(`workspace.name`), reserved = TRUE), urlPath)
}
# OAuth token
headerParams['Authorization'] <- paste("Bearer", self$apiClient$accessToken, sep=" ")
resp <- self$apiClient$CallApi(url = paste0(self$apiClient$basePath, urlPath),
method = "PUT",
queryParams = queryParams,
headerParams = headerParams,
body = body,
...)
if (httr::status_code(resp) >= 200 && httr::status_code(resp) <= 299) {
ApiResponse$new(NULL, resp)
} else if (httr::status_code(resp) >= 300 && httr::status_code(resp) <= 399) {
ApiResponse$new(paste("Server returned " , httr::status_code(resp) , " response status code."), resp)
} else if (httr::status_code(resp) >= 400 && httr::status_code(resp) <= 499) {
ApiResponse$new("API client error", resp)
} else if (httr::status_code(resp) >= 500 && httr::status_code(resp) <= 599) {
ApiResponse$new("API server error", resp)
}
},
UpdateAttributes = function(workspace.namespace, workspace.name, workspace.update.json, ...){
apiResponse <- self$UpdateAttributesWithHttpInfo(workspace.namespace, workspace.name, workspace.update.json, ...)
resp <- apiResponse$response
if (httr::status_code(resp) >= 200 && httr::status_code(resp) <= 299) {
apiResponse$content
} else if (httr::status_code(resp) >= 300 && httr::status_code(resp) <= 399) {
apiResponse
} else if (httr::status_code(resp) >= 400 && httr::status_code(resp) <= 499) {
apiResponse
} else if (httr::status_code(resp) >= 500 && httr::status_code(resp) <= 599) {
apiResponse
}
},
UpdateAttributesWithHttpInfo = function(workspace.namespace, workspace.name, workspace.update.json, ...){
args <- list(...)
queryParams <- list()
headerParams <- c()
if (missing(`workspace.namespace`)) {
stop("Missing required parameter `workspace.namespace`.")
}
if (missing(`workspace.name`)) {
stop("Missing required parameter `workspace.name`.")
}
if (missing(`workspace.update.json`)) {
stop("Missing required parameter `workspace.update.json`.")
}
if (!missing(`workspace.update.json`)) {
body.items = paste(unlist(lapply(workspace.update.json, function(param){param$toJSONString()})), collapse = ",")
body <- paste0('[', body.items, ']')
} else {
body <- NULL
}
urlPath <- "/api/workspaces/{workspaceNamespace}/{workspaceName}/updateAttributes"
if (!missing(`workspace.namespace`)) {
urlPath <- gsub(paste0("\\{", "workspaceNamespace", "\\}"), URLencode(as.character(`workspace.namespace`), reserved = TRUE), urlPath)
}
if (!missing(`workspace.name`)) {
urlPath <- gsub(paste0("\\{", "workspaceName", "\\}"), URLencode(as.character(`workspace.name`), reserved = TRUE), urlPath)
}
# OAuth token
headerParams['Authorization'] <- paste("Bearer", self$apiClient$accessToken, sep=" ")
resp <- self$apiClient$CallApi(url = paste0(self$apiClient$basePath, urlPath),
method = "PATCH",
queryParams = queryParams,
headerParams = headerParams,
body = body,
...)
if (httr::status_code(resp) >= 200 && httr::status_code(resp) <= 299) {
deserializedRespObj <- tryCatch(
self$apiClient$deserialize(resp, "WorkspaceDetails", loadNamespace("openapi")),
error = function(e){
stop("Failed to deserialize response")
}
)
ApiResponse$new(deserializedRespObj, resp)
} else if (httr::status_code(resp) >= 300 && httr::status_code(resp) <= 399) {
ApiResponse$new(paste("Server returned " , httr::status_code(resp) , " response status code."), resp)
} else if (httr::status_code(resp) >= 400 && httr::status_code(resp) <= 499) {
ApiResponse$new("API client error", resp)
} else if (httr::status_code(resp) >= 500 && httr::status_code(resp) <= 599) {
ApiResponse$new("API server error", resp)
}
},
UpdateCatalog = function(workspace.namespace, workspace.name, catalog.updates, ...){
apiResponse <- self$UpdateCatalogWithHttpInfo(workspace.namespace, workspace.name, catalog.updates, ...)
resp <- apiResponse$response
if (httr::status_code(resp) >= 200 && httr::status_code(resp) <= 299) {
apiResponse$content
} else if (httr::status_code(resp) >= 300 && httr::status_code(resp) <= 399) {
apiResponse
} else if (httr::status_code(resp) >= 400 && httr::status_code(resp) <= 499) {
apiResponse
} else if (httr::status_code(resp) >= 500 && httr::status_code(resp) <= 599) {
apiResponse
}
},
UpdateCatalogWithHttpInfo = function(workspace.namespace, workspace.name, catalog.updates, ...){
args <- list(...)
queryParams <- list()
headerParams <- c()
if (missing(`workspace.namespace`)) {
stop("Missing required parameter `workspace.namespace`.")
}
if (missing(`workspace.name`)) {
stop("Missing required parameter `workspace.name`.")
}
if (missing(`catalog.updates`)) {
stop("Missing required parameter `catalog.updates`.")
}
if (!missing(`catalog.updates`)) {
body.items = paste(unlist(lapply(catalog.updates, function(param){param$toJSONString()})), collapse = ",")
body <- paste0('[', body.items, ']')
} else {
body <- NULL
}
urlPath <- "/api/workspaces/{workspaceNamespace}/{workspaceName}/catalog"
if (!missing(`workspace.namespace`)) {
urlPath <- gsub(paste0("\\{", "workspaceNamespace", "\\}"), URLencode(as.character(`workspace.namespace`), reserved = TRUE), urlPath)
}
if (!missing(`workspace.name`)) {
urlPath <- gsub(paste0("\\{", "workspaceName", "\\}"), URLencode(as.character(`workspace.name`), reserved = TRUE), urlPath)
}
# OAuth token
headerParams['Authorization'] <- paste("Bearer", self$apiClient$accessToken, sep=" ")
resp <- self$apiClient$CallApi(url = paste0(self$apiClient$basePath, urlPath),
method = "PATCH",
queryParams = queryParams,
headerParams = headerParams,
body = body,
...)
if (httr::status_code(resp) >= 200 && httr::status_code(resp) <= 299) {
deserializedRespObj <- tryCatch(
self$apiClient$deserialize(resp, "WorkspaceCatalogUpdateResponseList", loadNamespace("openapi")),
error = function(e){
stop("Failed to deserialize response")
}
)
ApiResponse$new(deserializedRespObj, resp)
} else if (httr::status_code(resp) >= 300 && httr::status_code(resp) <= 399) {
ApiResponse$new(paste("Server returned " , httr::status_code(resp) , " response status code."), resp)
} else if (httr::status_code(resp) >= 400 && httr::status_code(resp) <= 499) {
ApiResponse$new("API client error", resp)
} else if (httr::status_code(resp) >= 500 && httr::status_code(resp) <= 599) {
ApiResponse$new("API server error", resp)
}
},
UpdateWorkspaceACL = function(workspace.namespace, workspace.name, invite.users.not.found, acl.updates, ...){
apiResponse <- self$UpdateWorkspaceACLWithHttpInfo(workspace.namespace, workspace.name, invite.users.not.found, acl.updates, ...)
resp <- apiResponse$response
if (httr::status_code(resp) >= 200 && httr::status_code(resp) <= 299) {
apiResponse$content
} else if (httr::status_code(resp) >= 300 && httr::status_code(resp) <= 399) {
apiResponse
} else if (httr::status_code(resp) >= 400 && httr::status_code(resp) <= 499) {
apiResponse
} else if (httr::status_code(resp) >= 500 && httr::status_code(resp) <= 599) {
apiResponse
}
},
UpdateWorkspaceACLWithHttpInfo = function(workspace.namespace, workspace.name, invite.users.not.found, acl.updates, ...){
args <- list(...)
queryParams <- list()
headerParams <- c()
if (missing(`workspace.namespace`)) {
stop("Missing required parameter `workspace.namespace`.")
}
if (missing(`workspace.name`)) {
stop("Missing required parameter `workspace.name`.")
}
if (missing(`invite.users.not.found`)) {
stop("Missing required parameter `invite.users.not.found`.")
}
if (missing(`acl.updates`)) {
stop("Missing required parameter `acl.updates`.")
}
queryParams['inviteUsersNotFound'] <- invite.users.not.found
if (!missing(`acl.updates`)) {
body.items = paste(unlist(lapply(acl.updates, function(param){param$toJSONString()})), collapse = ",")
body <- paste0('[', body.items, ']')
} else {
body <- NULL
}
urlPath <- "/api/workspaces/{workspaceNamespace}/{workspaceName}/acl"
if (!missing(`workspace.namespace`)) {
urlPath <- gsub(paste0("\\{", "workspaceNamespace", "\\}"), URLencode(as.character(`workspace.namespace`), reserved = TRUE), urlPath)
}
if (!missing(`workspace.name`)) {
urlPath <- gsub(paste0("\\{", "workspaceName", "\\}"), URLencode(as.character(`workspace.name`), reserved = TRUE), urlPath)
}
# OAuth token
headerParams['Authorization'] <- paste("Bearer", self$apiClient$accessToken, sep=" ")
resp <- self$apiClient$CallApi(url = paste0(self$apiClient$basePath, urlPath),
method = "PATCH",
queryParams = queryParams,
headerParams = headerParams,
body = body,
...)
if (httr::status_code(resp) >= 200 && httr::status_code(resp) <= 299) {
deserializedRespObj <- tryCatch(
self$apiClient$deserialize(resp, "WorkspaceACLUpdateResponseList", loadNamespace("openapi")),
error = function(e){
stop("Failed to deserialize response")
}
)
ApiResponse$new(deserializedRespObj, resp)
} else if (httr::status_code(resp) >= 300 && httr::status_code(resp) <= 399) {
ApiResponse$new(paste("Server returned " , httr::status_code(resp) , " response status code."), resp)
} else if (httr::status_code(resp) >= 400 && httr::status_code(resp) <= 499) {
ApiResponse$new("API client error", resp)
} else if (httr::status_code(resp) >= 500 && httr::status_code(resp) <= 599) {
ApiResponse$new("API server error", resp)
}
},
WorkspacePermissionReport = function(workspace.namespace, workspace.name, report.input, ...){
apiResponse <- self$WorkspacePermissionReportWithHttpInfo(workspace.namespace, workspace.name, report.input, ...)
resp <- apiResponse$response
if (httr::status_code(resp) >= 200 && httr::status_code(resp) <= 299) {
apiResponse$content
} else if (httr::status_code(resp) >= 300 && httr::status_code(resp) <= 399) {
apiResponse
} else if (httr::status_code(resp) >= 400 && httr::status_code(resp) <= 499) {
apiResponse
} else if (httr::status_code(resp) >= 500 && httr::status_code(resp) <= 599) {
apiResponse
}
},
WorkspacePermissionReportWithHttpInfo = function(workspace.namespace, workspace.name, report.input, ...){
args <- list(...)
queryParams <- list()
headerParams <- c()
if (missing(`workspace.namespace`)) {
stop("Missing required parameter `workspace.namespace`.")
}
if (missing(`workspace.name`)) {
stop("Missing required parameter `workspace.name`.")
}
if (missing(`report.input`)) {
stop("Missing required parameter `report.input`.")
}
if (!missing(`report.input`)) {
body <- `report.input`$toJSONString()
} else {
body <- NULL
}
urlPath <- "/api/workspaces/{workspaceNamespace}/{workspaceName}/permissionReport"
if (!missing(`workspace.namespace`)) {
urlPath <- gsub(paste0("\\{", "workspaceNamespace", "\\}"), URLencode(as.character(`workspace.namespace`), reserved = TRUE), urlPath)
}
if (!missing(`workspace.name`)) {
urlPath <- gsub(paste0("\\{", "workspaceName", "\\}"), URLencode(as.character(`workspace.name`), reserved = TRUE), urlPath)
}
# OAuth token
headerParams['Authorization'] <- paste("Bearer", self$apiClient$accessToken, sep=" ")
resp <- self$apiClient$CallApi(url = paste0(self$apiClient$basePath, urlPath),
method = "POST",
queryParams = queryParams,
headerParams = headerParams,
body = body,
...)
if (httr::status_code(resp) >= 200 && httr::status_code(resp) <= 299) {
deserializedRespObj <- tryCatch(
self$apiClient$deserialize(resp, "PermissionReport", loadNamespace("openapi")),
error = function(e){
stop("Failed to deserialize response")
}
)
ApiResponse$new(deserializedRespObj, resp)
} else if (httr::status_code(resp) >= 300 && httr::status_code(resp) <= 399) {
ApiResponse$new(paste("Server returned " , httr::status_code(resp) , " response status code."), resp)
} else if (httr::status_code(resp) >= 400 && httr::status_code(resp) <= 499) {
ApiResponse$new("API client error", resp)
} else if (httr::status_code(resp) >= 500 && httr::status_code(resp) <= 599) {
ApiResponse$new("API server error", resp)
}
}
)
)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.