# Table of Contents
Table of Contents
- FileServiceClient
- FilesImpl
- Parameters
- getByPath
- getByPath
- getByPath
- getByPath
- get
- get
- get
- get
- update
- updateWithOptions
- delete
- deleteWithOptions
- move
- moveWithOptions
- rename
- renameWithOptions
- copy
- copy
- copy
- copy
- copyWithOptions
- restore
- restore
- restore
- restore
- restoreWithOptions
- getVersion
- getVersion
- getVersion
- getVersion
- listVersions
- listVersions
- listVersions
- listVersions
- getVersionByPath
- getVersionByPath
- getVersionByPath
- getVersionByPath
- listVersionsByPath
- listVersionsByPath
- listVersionsByPath
- listVersionsByPath
- listResources
- listResources
- listResources
- listResources
- listResourcesByPath
- listResourcesByPath
- listResourcesByPath
- listResourcesByPath
- createFileUpload
- createFileUploadWithOptions
- createSupportFileUpload
- createSupportFileUploadWithOptions
- uploadFile
- upload
- createOrUpdateLinks
- getUploadDetails
- lock
- lock
- lock
- lock
- unlock
- checkout
- checkin
- defineProperty
- defineProperty
- byteLength
- validateFileUploadConfiguration
- SpacesImpl
- getQueryParametersFromObject
- FoldersImpl
- Parameters
- create
- create
- create
- create
- getByPath
- getByPath
- getByPath
- getByPath
- get
- get
- get
- get
- update
- updateWithOptions
- delete
- deleteWithOptions
- move
- moveWithOptions
- rename
- renameWithOptions
- copy
- copy
- copy
- copy
- copyWithOptions
- restore
- restore
- restore
- restore
- restoreWithOptions
- list
- list
- list
- list
- getVersion
- getVersion
- getVersion
- getVersion
- listVersions
- listVersions
- listVersions
- listVersions
- listByPath
- listByPath
- listByPath
- listByPath
- getVersionByPath
- getVersionByPath
- getVersionByPath
- getVersionByPath
- listVersionsByPath
- listVersionsByPath
- listVersionsByPath
- listVersionsByPath
- JobsImpl
- ExportsImpl
- EventType
- EventType
- EventsManager
- ResourcesImpl
- __awaiter
- transformDateKey
- transformLinksKey
- transformDefaultKey
- transformKey
- transformResponse
- isValidUrlDuration
- getJobIdFromPath
- getNextPageToken
- getClientId
- Acl
- Acl
- Acl
- Acl
- SpaceCreateOptionalParams
- SoftDeleteRetention
- Provider
- SpaceResponse
- MinimalSpaceResponse
- SpaceUpdateParams
- SpaceDeleteOptionalParams
- SpaceDeleteResponse
- SpaceRestoreResponse
- SpaceStatistics
- Status
- EntityType
- SpacePermissionsLocal
- SpaceUpdatePermissionsLocal
- SpaceUpdateAcl
- SpaceRemoveAcl
- SpaceListOptionalParams
- SpaceListResponse
- AclRole
- AclRole
- AclActor
- InheritedAcl
- PermissionsEvaluated
- PermissionsInherited
- FolderCreateOptionalParams
- FolderResponse
- MinimalFolderResponse
- FolderUpdateParams
- FolderDeleteOptionalParams
- FolderCopyOptionalParams
- FolderDeleteResponse
- FolderRestoreOptionalParams
- FolderListOptionalParams
- FileOrFolderListResponse
- FolderListResponse
- FolderRestoreResponse
- FolderJobResponse
- FolderCopyResponse
- FolderRenameResponse
- FolderMoveResponse
- FolderStatistics
- FolderPermissionsLocal
- FolderUpdatePermissionsLocal
- FolderUpdateAcl
- FileResponse
- createdAt
- createdByTrn
- updatedAt
- updatedByTrn
- deleted
- deletedAt
- name
- id
- resourceTrn
- type
- spaceId
- spaceTrn
- version
- metadata
- path
- parentId
- parentType
- parentTrn
- permissionsLocal
- permissionsEvaluated
- permissionsInherited
- restrictedAccess
- fileset
- expiresAt
- multipart
- responseHeaders
- response
- download
- malwareScanStatus
- malwareScanResult
- malwareType
- lastMalwareScanDate
- size
- links
- md5
- lock
- stats
- capabilities
- checkout
- MinimalFileResponse
- FilePermissionsLocal
- FileLockResponse
- Checkout
- FileStatistics
- SupportFileResponse
- FileGetOptionalParams
- MalwareScanStatus
- FileUpdateParams
- FileUpdatePermissionsLocal
- FileUpdateAcl
- SupportFileLinkParams
- SupportFileLinkDetails
- FileDeleteOptionalParams
- FileDeleteResponse
- FileRestoreOptionalParams
- FileJobResponse
- FileRestoreResponse
- FileCopyResponse
- FileListOptionalParams
- FileListResponse
- UploadOptions
- FileUploadOptionalParams
- multipart
- urlDuration
- restrictedAccess
- fileset
- expiresAt
- responseHeaders
- metadata
- multipart
- supportFileKey
- parentMajorVersion
- addToLinks
- SupportFileUploadResponse
- FileUploadResponse
- FileInputUploadDetails
- Upload
- FileUploadType
- UploadStatus
- FileChunkUploadResponse
- UploadResponse
- FileCopyOptionalParams
- UploadOptionalParams
- FileLockOptionalParams
- FileCheckoutOptionalParams
- FileContent
- JobResponse
- JobResponse
- JobType
- JobStatus
- EventResponse
- EventResponse
- Capabilities
- Capabilities
- ExportResponse
- ExportResponse
- ExportStatus
- Output
- ResourceGetOptionalParams
- ResourceBatchGetParams
- ResourceBatchResponse
- InvalidItems
FileServiceClient
Represents a client for interacting with the File Service API.
Parameters
tokenProviderITokenProvider The token provider.baseUrlstring The base URL of the File Service API.
httpClientProvider
Represents the HTTP client provider.
Type: BearerTokenHttpClientProvider
tokenProvider
Represents a token provider.
Type: ITokenProvider
spaces
Represents the implementation of the Spaces.
Type: SpacesImpl
folders
Represents the implementation of the Folders.
Type: FoldersImpl
files
Represents the implementation of the Files.
Type: FilesImpl
jobs
Represents the implementation of the Jobs.
Type: JobsImpl
exports
Represents the implementation of the Exports.
Type: ExportsImpl
resources
Represents the implementation of the
FilesImpl
Represents the implementation of the Files operations.
Parameters
clientFileServiceClient A FileServiceClient instance used to make API calls.
getByPath
Get file by path.
Parameters
- Throws Error If there was an error retrieving the file information.
Returns Promise<FileResponse> A promise that resolves to a complete file response.
getByPath
Get file by path.
Parameters
spaceIdstring Space identifierpathstring Path of the fileparamsFileGetOptionalParams Optional parameters used to get file.
- Throws Error If there was an error retrieving the file information.
Returns Promise<FileResponse> A promise that resolves to a complete file response.
getByPath
Get file by path.
Parameters
spaceIdstring Space identifierpathstring Path of the fileminimalResponseboolean Indicate if the response should be complete or minimal
- Throws Error If there was an error retrieving the file information.
Returns Promise<(FileResponse | MinimalFileResponse)> A promise that resolves to a file response.
getByPath
Get file by path.
Parameters
spaceIdstring Space identifierpathstring Path of the fileparamsFileGetOptionalParams Optional parameters used to get file.minimalResponseboolean Indicate if the response should be complete or minimal
- Throws Error If there was an error retrieving the file information.
Returns Promise<(FileResponse | MinimalFileResponse)> A promise that resolves to a file response.
get
Get file by ID.
Parameters
- Throws Error If there was an error retrieving the file information.
Returns Promise<FileResponse> A promise that resolves to complete file response.
get
Get file by ID.
Parameters
spaceIdstring Space identifierfileIdstring File identifierparamsFileGetOptionalParams Optional parameters used to get file.
- Throws Error If there was an error retrieving the file information.
Returns Promise<FileResponse> A promise that resolves to complete file response.
get
Get file by ID.
Parameters
spaceIdstring Space identifierfileIdstring File identifierminimalResponseboolean Indicate if the response should be complete or minimal
- Throws Error If there was an error retrieving the file information.
Returns Promise<(FileResponse | MinimalFileResponse)> A promise that resolves to file response.
get
Get file by ID.
Parameters
spaceIdstring Space identifierfileIdstring File identifierparamsFileGetOptionalParams Optional parameters used to get file.minimalResponseboolean Indicate if the response should be complete or minimal
- Throws Error If there was an error retrieving the file information.
Returns Promise<(FileResponse | MinimalFileResponse)> A promise that resolves to file response.
update
Updates the file metadata and ACL. Linking/unlinking operation can only be done on a parent file.
Parameters
spaceIdstring Space identifierfileIdstring File identifierparamsFileUpdateParams Parameters for the file update.minimalResponseboolean Indicate if the response should be complete or minimal (optional, defaultfalse)
- Throws Error If there was an error updating the file.
Returns Promise<(FileResponse | MinimalFileResponse)> A promise that resolves to a updated file object.
updateWithOptions
Updates file by ID.
Parameters
-
spaceIdstring Space identifier -
fileIdstring File identifier -
paramsFileUpdateParams Parameters for the file update. -
optionsobject Additional options for the update operation. (optional, default{minimalResponse:false})
Returns Promise<(FileResponse | MinimalFileResponse)> A promise that resolves to an updated file object.
delete
Deletes the file by ID. If the file is a parent file, then all the support files linked to the parent file are also deleted.
Parameters
spaceIdstring Space identifierfileIdstring File identifierparamsFileDeleteOptionalParams Optional parameters for the file delete.
- Throws Error If there was an error deleting the file.
Returns Promise<FileDeleteResponse> A promise that resolves to the result of the delete operation.
deleteWithOptions
Deletes the file by ID.
Parameters
-
spaceIdstring Space identifier -
fileIdstring File identifier -
optionsobject Additional options for the delete operation.options.paramsFileDeleteOptionalParams? Optional parameters for the file delete.options.requestHeadersRecord<string, (string | Array<string>)>? Optional request headers to include in the delete request. Supported headers: “If-Match”, “If-None-Match”.
- Throws Error If there was an error deleting the file.
Returns Promise<FileDeleteResponse> A promise that resolves to the result of the delete operation.
move
Move a file to a new location within the same space.
Parameters
spaceIdstring Space identifierfileIdstring File identifiertargetParentIdstring target where the source file need to be movedminimalResponseboolean Indicate if the response should be complete or minimal (optional, defaultfalse)
- Throws Error If there was an error moving the file.
Returns Promise<(FileResponse | MinimalFileResponse)> A promise that resolves the moved file response.
moveWithOptions
Move a file to a new location within the same space.
Parameters
-
spaceIdstring Space identifier -
fileIdstring File identifier -
targetParentIdstring Target where the source file needs to be moved. -
optionsobject Additional options for the move operation. (optional, default{minimalResponse:false})
- Throws Error If there was an error moving the file.
Returns Promise<(FileResponse | MinimalFileResponse)> A promise that resolves to the moved file response.
rename
Rename a file within the same space.
Parameters
spaceIdstring Space identifierfileIdstring File identifiernamestring New name for the fileminimalResponseboolean Indicate if the response should be complete or minimal (optional, defaultfalse)
- Throws Error If there was an error renaming the file.
Returns Promise<(FileResponse | MinimalFileResponse)> A promise that resolves to the renamed file response.
renameWithOptions
Rename a file within the same space.
Parameters
-
spaceIdstring Space identifier -
fileIdstring File identifier -
namestring New name for the file -
optionsobject Additional options for the rename operation. (optional, default{minimalResponse:false})
- Throws Error If there was an error renaming the file.
Returns Promise<(FileResponse | MinimalFileResponse)> A promise that resolves to the renamed file response.
copy
Copies a file from one folder to another within the given space. Support files can be copied and linked to parent file during the copy operation by using the copySupportFiles parameter.
Parameters
spaceIdstring Space identifier.fileIdstring File identifier.targetParentIdstring Target where the source file needs to be copied.
- Throws any If there was an error copying the file.
Returns Promise<FileCopyResponse> A Promise that resolves to the result of the copy operation with a complete response.
copy
Copies a file from one folder to another within the given space. Support files can be copied and linked to parent file during the copy operation by using the copySupportFiles parameter.
Parameters
spaceIdstring Space identifier.fileIdstring File identifier.targetParentIdstring Target where the source file needs to be copied.paramsFileCopyOptionalParams Optional parameters for copying the file.
- Throws any If there was an error copying the file.
Returns Promise<FileCopyResponse> A Promise that resolves to the result of the copy operation with a complete response.
copy
Copies a file from one folder to another within the given space. Support files can be copied and linked to parent file during the copy operation by using the copySupportFiles parameter.
Parameters
spaceIdstring Space identifier.fileIdstring File identifier.targetParentIdstring Target where the source file needs to be copied.minimalResponseboolean Indicate if the response should be complete or minimal.
- Throws any If there was an error copying the file.
Returns Promise<FileCopyResponse> A Promise that resolves to the result of the copy operation.
copy
Copies a file from one folder to another within the given space. Support files can be copied and linked to parent file during the copy operation by using the copySupportFiles parameter.
Parameters
spaceIdstring Space identifier.fileIdstring File identifier.targetParentIdstring Target where the source file needs to be copied.paramsFileCopyOptionalParams Optional parameters for copying the file.minimalResponseboolean Indicate if the response should be complete or minimal.
- Throws any If there was an error copying the file.
Returns Promise<FileCopyResponse> A Promise that resolves to the result of the copy operation.
copyWithOptions
Copies a file from one folder to another within the given space with additional options.
Parameters
-
spaceIdstring Space identifier. -
fileIdstring File identifier. -
targetParentIdstring Target where the source file needs to be copied. -
optionsobject Additional options for the copy operation. (optional, default{minimalResponse:false})options.paramsFileCopyOptionalParams? Optional parameters for copying the file.options.requestHeadersRecord<string, (string | Array<string>)>? Optional request headers to include in the copy request. Supported headers: “If-Match”, “If-None-Match”.options.minimalResponseboolean? Indicate if the response should be complete or minimal.
- Throws any If there was an error copying the file.
Returns Promise<FileCopyResponse> A Promise that resolves to the result of the copy operation.
restore
Restore a deleted file by ID.
Parameters
- Throws Error If there was an error restoring the file.
Returns Promise<FileRestoreResponse> A Promise that resolves to the result of the restore operation with a complete response.
restore
Restore a deleted file by ID.
Parameters
spaceIdstring Space identifierfileIdstring File identifierparams(FileRestoreOptionalParams | boolean) Optional parameters for the file restore.
- Throws Error If there was an error restoring the file.
Returns Promise<FileRestoreResponse> A Promise that resolves to the result of the restore operation with a complete response.
restore
Restore a deleted file by ID.
Parameters
spaceIdstring Space identifierfileIdstring File identifierminimalResponseboolean Indicate if the response should be complete or minimal
- Throws Error If there was an error restoring the file.
Returns Promise<FileRestoreResponse> A Promise that resolves to the result of the restore operation.
restore
Restore a deleted file by ID.
Parameters
spaceIdstring Space identifierfileIdstring File identifierparams(FileRestoreOptionalParams | boolean) Optional parameters for the file restore.minimalResponseboolean Indicate if the response should be complete or minimal
- Throws Error If there was an error restoring the file.
Returns Promise<FileRestoreResponse> A Promise that resolves to the result of the restore operation.
restoreWithOptions
Restore a deleted file by ID.
Parameters
-
spaceIdstring Space identifier -
fileIdstring File identifier -
optionsobject Additional options for the restore operation. (optional, default{minimalResponse:false})options.paramsFileRestoreOptionalParams? Optional parameters for the file restore.options.requestHeadersRecord<string, (string | Array<string>)>? Optional request headers to include in the restore request. Supported headers: “If-Match”, “If-None-Match”.options.minimalResponseboolean? Indicate if the response should be complete or minimal
- Throws Error If there was an error restoring the file.
Returns Promise<FileRestoreResponse> A Promise that resolves to the result of the restore operation.
getVersion
Get a specific version of a file by ID.
Parameters
spaceIdstring Space identifierfileIdstring File identifierversionIdstring Version identifier of the file. The version identifier follows the major and minor version format.
- Throws Error If there was an error retrieving the file information.
Returns Promise<FileResponse> A promise that resolves to a complete file response.
getVersion
Get a specific version of a file by ID.
Parameters
spaceIdstring Space identifierfileIdstring File identifierversionIdstring Version identifier of the file. The version identifier follows the major and minor version format.paramsFileGetOptionalParams Optional parameters used to get a file version.
- Throws Error If there was an error retrieving the file information.
Returns Promise<FileResponse> A promise that resolves to a complete file response.
getVersion
Get a specific version of a file by ID.
Parameters
spaceIdstring Space identifierfileIdstring File identifierversionIdstring Version identifier of the file. The version identifier follows the major and minor version format.minimalResponseboolean Indicate if the response should be complete or minimal
- Throws Error If there was an error retrieving the file information.
Returns Promise<(FileResponse | MinimalFileResponse)> A promise that resolves to a file response.
getVersion
Get a specific version of a file by ID.
Parameters
spaceIdstring Space identifierfileIdstring File identifierversionIdstring Version identifier of the file. The version identifier follows the major and minor version format.paramsFileGetOptionalParams Optional parameters used to get a file version.minimalResponseboolean Indicate if the response should be complete or minimal
- Throws Error If there was an error retrieving the file information.
Returns Promise<(FileResponse | MinimalFileResponse)> A promise that resolves to a file response.
listVersions
Get all versions of a file by ID. The operation is paginated and the response contains a token that can be used to get the next page of results.
Parameters
- Throws Error If there was an error retrieving the file versions.
Returns Promise<FileListResponse> A promise that resolves to a complete file list response.
listVersions
Get all versions of a file by ID. The operation is paginated and the response contains a token that can be used to get the next page of results.
Parameters
spaceIdstring Space identifierfileIdstring File identifierparamsFileListOptionalParams Optional parameters used to list file versions.
- Throws Error If there was an error retrieving the file versions.
Returns Promise<FileListResponse> A promise that resolves to a complete file list response.
listVersions
Get all versions of a file by ID. The operation is paginated and the response contains a token that can be used to get the next page of results.
Parameters
spaceIdstring Space identifierfileIdstring File identifierminimalResponseboolean Indicate if the response should be complete or minimal
- Throws Error If there was an error retrieving the file versions.
Returns Promise<FileListResponse> A promise that resolves to a file list response.
listVersions
Get all versions of a file by ID. The operation is paginated and the response contains a token that can be used to get the next page of results.
Parameters
spaceIdstring Space identifierfileIdstring File identifierparamsFileListOptionalParams Optional parameters used to list file versions.minimalResponseboolean Indicate if the response should be complete or minimal
- Throws Error If there was an error retrieving the file versions.
Returns Promise<FileListResponse> A promise that resolves to a file list response.
getVersionByPath
Get a specific version of a file by path.
Parameters
spaceIdstring Space identifierversionIdstring Version identifier of the file. The version identifier follows the major and minor version format.pathstring Path of the file.
- Throws Error If there was an error retrieving the file information.
Returns Promise<FileResponse> A promise that resolves to a complete file response.
getVersionByPath
Get a specific version of a file by path.
Parameters
spaceIdstring Space identifierversionIdstring Version identifier of the file. The version identifier follows the major and minor version format.pathstring Path of the file.paramsFileGetOptionalParams Optional parameters used to get file versions.
- Throws Error If there was an error retrieving the file information.
Returns Promise<FileResponse> -A promise that resolves to a complete file response.
getVersionByPath
Get a specific version of a file by path.
Parameters
spaceIdstring Space identifierversionIdstring Version identifier of the file. The version identifier follows the major and minor version format.pathstring Path of the file.minimalResponseboolean Indicate if the response should be complete or minimal
- Throws Error If there was an error retrieving the file information.
Returns Promise<(FileResponse | MinimalFileResponse)> A promise that resolves to a file response.
getVersionByPath
Get a specific version of a file by path.
Parameters
spaceIdstring Space identifierversionIdstring Version identifier of the file. The version identifier follows the major and minor version format.pathstring Path of the file.paramsFileGetOptionalParams Optional parameters used to get file versions.minimalResponseboolean Indicate if the response should be complete or minimal
- Throws Error If there was an error retrieving the file information.
Returns Promise<(FileResponse | MinimalFileResponse)> A promise that resolves to a file response.
listVersionsByPath
Get all versions of a file by path.
The operation is paginated and the response contains a token that can be used to get the next page of results.
Parameters
- Throws Error If there was an error retrieving the file versions.
Returns Promise<FileListResponse> A promise that resolves to a complete file list response.
listVersionsByPath
Get all versions of a file by path.
The operation is paginated and the response contains a token that can be used to get the next page of results.
Parameters
spaceIdstring Space identifierpathstringparamsFileListOptionalParams Optional parameters used to get file versions.
- Throws Error If there was an error retrieving the file versions.
Returns Promise<FileListResponse> A promise that resolves to a complete file list response.
listVersionsByPath
Get all versions of a file by path.
The operation is paginated and the response contains a token that can be used to get the next page of results.
Parameters
spaceIdstring Space identifierpathstringminimalResponseboolean Indicate if the response should be complete or minimal
- Throws Error If there was an error retrieving the file versions.
Returns Promise<FileListResponse> A promise that resolves to a file list response.
listVersionsByPath
Get all versions of a file by path.
The operation is paginated and the response contains a token that can be used to get the next page of results.
Parameters
spaceIdstring Space identifierpathstringparamsFileListOptionalParams Optional parameters used to get file versions.minimalResponseboolean Indicate if the response should be complete or minimal
- Throws Error If there was an error retrieving the file versions.
Returns Promise<FileListResponse> A promise that resolves to a file list response.
listResources
Lists all resources (support files) of a file by ID. The operation is paginated and the response contains a token that can be used to get the next page of results.
Parameters
- Throws Error If there was an error retrieving the file resources.
Returns Promise<FileListResponse> A promise that resolves to a complete resource list response.
listResources
Lists all resources (support files) of a file by ID. The operation is paginated and the response contains a token that can be used to get the next page of results.
Parameters
spaceIdstring Space identifierfileIdstring File identifierparamsFileListResourcesOptionalParams Optional parameters used to get resources.
- Throws Error If there was an error retrieving the file resources.
Returns Promise<FileListResponse> A promise that resolves to a complete resource list response.
listResources
Lists all resources (support files) of a file by ID. The operation is paginated and the response contains a token that can be used to get the next page of results.
Parameters
spaceIdstring Space identifierfileIdstring File identifierminimalResponseboolean Indicate if the response should be complete or minimal
- Throws Error If there was an error retrieving the file resources.
Returns Promise<FileListResponse> A promise that resolves to a resource list response.
listResources
Lists all resources (support files) of a file by ID. The operation is paginated and the response contains a token that can be used to get the next page of results.
Parameters
spaceIdstring Space identifierfileIdstring File identifierparamsFileListResourcesOptionalParams Optional parameters used to get resources.minimalResponseboolean Indicate if the response should be complete or minimal
- Throws Error If there was an error retrieving the file resources.
Returns Promise<FileListResponse> A promise that resolves to a resource list response.
listResourcesByPath
Lists all resources (support files) of a file by path. The operation is paginated and the response contains a token that can be used to get the next page of results.
Parameters
- Throws Error If there was an error retrieving the file resources.
Returns Promise<FileListResponse> A promise that resolves to a complete resource list response.
listResourcesByPath
Lists all resources (support files) of a file by path. The operation is paginated and the response contains a token that can be used to get the next page of results.
Parameters
spaceIdstring Space identifierpathstring Path of the fileparamsFileListResourcesOptionalParams Optional parameters used to get resources.
- Throws Error If there was an error retrieving the file resources.
Returns Promise<FileListResponse> A promise that resolves to a complete resource list response.
listResourcesByPath
Lists all resources (support files) of a file by path. The operation is paginated and the response contains a token that can be used to get the next page of results.
Parameters
spaceIdstring Space identifierpathstring Path of the fileminimalResponseboolean Indicate if the response should be complete or minimal
- Throws Error If there was an error retrieving the file resources.
Returns Promise<FileListResponse> A promise that resolves to a resource list response.
listResourcesByPath
Lists all resources (support files) of a file by path. The operation is paginated and the response contains a token that can be used to get the next page of results.
Parameters
spaceIdstring Space identifierpathstring Path of the fileparamsFileListResourcesOptionalParams Optional parameters used to get resources.minimalResponseboolean Indicate if the response should be complete or minimal
- Throws Error If there was an error retrieving the file resources.
Returns Promise<FileListResponse> A promise that resolves to a resource list response.
createFileUpload
Generates a pre-signed upload url for the given name and parentId.
Parameters
spaceIdstring Space identifiernamestring The name of the file.parentIdstring Parent folder identifier to which the file has to be uploaded.paramsFileUploadCreateOptionalParams Optional parameters for the file upload.
- Throws Error If there was an error creating the upload.
Returns Promise<FileUploadResponse> A promise that resolves to a file upload response.
createFileUploadWithOptions
Generates a pre-signed upload url for the given name and parentId with additional options.
Parameters
-
spaceIdstring Space identifier -
namestring The name of the file. -
parentIdstring Parent folder identifier to which the file has to be uploaded. -
optionsobject Additional options for the file upload.
- Throws Error If there was an error creating the upload.
Returns Promise<FileUploadResponse> A promise that resolves to a file upload response.
createSupportFileUpload
Generates a pre-signed upload url for the given name and parentId of support file.
Parameters
spaceIdstring Space identifiernamestring name of the fileparentIdstring ID of a file to which the support file has to be uploaded.paramsSupportFileUploadCreateOptionalParams Optional parameters for the file upload.
- Throws Error If there was an error creating the upload.
Returns Promise<SupportFileUploadResponse> A promise that resolves to a support file upload response.
createSupportFileUploadWithOptions
Generates a pre-signed upload url for the given name and parentId of support file.
Parameters
-
spaceIdstring Space identifier -
namestring name of the file -
parentIdstring ID of a file to which the support file has to be uploaded. -
optionsobject Additional options for the file upload.
- Throws Error If there was an error creating the upload.
Returns Promise<SupportFileUploadResponse> A promise that resolves to a support file upload response.
uploadFile
Uploads a file/support file to the given upload URL.
Parameters
spaceIdstring Space identifieruploadIdstring Upload identifierfileFileContent The file to upload.paramsUploadOptionalParams Optional parameters for the file upload.
- Throws Error If there was an error uploading the file.
Returns Promise<boolean> A promise that resolves to true if the upload was successful.
upload
Handles file uploads with support for both multipart and single part methods. Generates a pre-signed URL for the file based on its name and parentId and upload the file to the url.
Parameters
spaceIdstring Space identifiernamestring The name of the file.parentIdstring Parent folder identifier to which the file has to be uploaded.fileFileContent The file to upload.optionsUploadOptions Options for the file upload.
- Throws Error If there was an error uploading the file.
Returns Promise<UploadResponse> A promise that resolves to an upload response.
createOrUpdateLinks
Link support files to a specific version of a file. The support files will be linked to the target main file and main file minor version will be incremented.
Parameters
spaceIdstring Space identifierfileIdstring File identifierfileMajorVersionstring The major version of the parent file.paramsSupportFileLinkParams The support file link parameters.minimalResponseboolean Indicate if the response should be complete or minimal. (optional, defaultfalse)
- Throws Error If there was an error linking support files.
Returns Promise<(FileResponse | MinimalFileResponse)> A promise that resolves to a file response.
getUploadDetails
Retrieve the upload details by Id
Parameters
spaceIdstring Space identifieruploadIdstring upload identifierurlDurationstring The duration for which the pre-signed URL is valid. The duration is specified in the format of ‘1h’, ‘1d’, ‘1w’, ‘1m’, ‘1y’.
- Throws Error If there was an error getting the upload details.
Returns Promise<FileUploadResponse> A promise that resolves to a file upload response.
lock
Lock a file within a space.
Parameters
- Throws Error If there was an error locking the file.
Returns Promise<FileResponse> A promise that resolves to a locked file with a complete response.
lock
Lock a file within a space.
Parameters
spaceIdstring Space identifierfileIdstring File identifierparamsFileLockOptionalParams Optional parameters for the file lock.
- Throws Error If there was an error locking the file.
Returns Promise<FileResponse> A promise that resolves to a locked file with a complete response.
lock
Lock a file within a space.
Parameters
spaceIdstring Space identifierfileIdstring File identifierminimalResponseboolean Indicate if the response should be complete or minimal
- Throws Error If there was an error locking the file.
Returns Promise<(FileResponse | MinimalFileResponse)> A promise that resolves to a locked file response.
lock
Lock a file within a space.
Parameters
spaceIdstring Space identifierfileIdstring File identifierparamsFileLockOptionalParams Optional parameters for the file lock.minimalResponseboolean Indicate if the response should be complete or minimal
- Throws Error If there was an error locking the file.
Returns Promise<(FileResponse | MinimalFileResponse)> A promise that resolves to locked file response.
unlock
Unlock a file within a space.
Parameters
spaceIdstring Space identifierfileIdstring File identifierminimalResponseboolean Indicate if the response should be complete or minimal (optional, defaultfalse)
- Throws Error If there was an error unlocking the file.
Returns Promise<(FileResponse | MinimalFileResponse)> A promise that resolves to an unlocked file response.
checkout
Checking out a file will prevent other actors from creating a new version or other mutation operations.
Parameters
-
spaceIdstring Space identifier -
fileIdstring File identifier -
optionsobject Additional options for the checkout operation. (optional, default{minimalResponse:false})
- Throws Error If there was an error checking out the file.
Returns Promise<(FileResponse | MinimalFileResponse)> A promise that resolves to a checked out file response.
checkin
Checking in a file will allow other actors to create a new version or perform other mutation operations.
Parameters
spaceIdstring Space identifierfileIdstring File identifierminimalResponseboolean Indicate if the response should be complete or minimal (optional, defaultfalse)
- Throws Error If there was an error checking in the file.
Returns Promise<(FileResponse | MinimalFileResponse)> A promise that resolves to a checked in file response.
defineProperty
Copyright (c) Trimble Inc.
defineProperty
Copyright (c) Trimble Inc.
byteLength
Calculates the byte length of the input.
Parameters
inputThe input value to calculate the byte length of.
Returns any The byte length of the input.
validateFileUploadConfiguration
Validates the upload file configuration.
Parameters
chunkSizeconcurrentRequestuploadFileConfigurationThe upload file configuration to validate.
- Throws Error If the upload file configuration is invalid.
SpacesImpl
Represents the implementation of the Spaces operations.
Parameters
clientFileServiceClient A FileServiceClient instance used to make API calls.
create
Create a new space.
Parameters
- Throws Error If there was an error creating the space.
Returns Promise<SpaceResponse> A Promise that resolves to the created space with a complete response.
create
Create a new space.
Parameters
namestring The name of the space.accountIdstring The unique identifier of the CDH account.paramsSpaceCreateOptionalParams Optional parameters for creating the space.
- Throws Error If there was an error creating the space.
Returns Promise<SpaceResponse> A Promise that resolves to the created space with a complete response.
create
Create a new space.
Parameters
namestring The name of the space.accountIdstring The unique identifier of the CDH account.minimalResponseboolean Indicate if the response should be complete or minimal.
- Throws Error If there was an error creating the space.
Returns Promise<(SpaceResponse | MinimalSpaceResponse)> A Promise that resolves to the created space.
create
Create a new space.
Parameters
namestring The name of the space.accountIdstring The unique identifier of the CDH account.paramsSpaceCreateOptionalParams Optional parameters for creating the space.minimalResponseboolean Indicate if the response should be complete or minimal.
- Throws Error If there was an error creating the space.
Returns Promise<(SpaceResponse | MinimalSpaceResponse)> A Promise that resolves to the created space.
get
Get space by Id. Retrieves the complete space filtered by the active status.
Parameters
spaceIdstring Space identifier
- Throws any If there was an error retrieving the space information.
Returns Promise<SpaceResponse> A Promise that resolves to a complete space response.
get
Get space by Id. Retrieves the complete space response filtered by the specified status.
Parameters
- Throws any If there was an error retrieving the space information.
Returns Promise<SpaceResponse> A Promise that resolves to a complete space response.
get
Get space by Id.
Parameters
spaceIdstring Space identifierminimalResponseboolean Indicate if the response should be complete or minimal.
- Throws any If there was an error retrieving the space information.
Returns Promise<(SpaceResponse | MinimalSpaceResponse)> A Promise that resolves to space response.
get
Get space by Id.
Parameters
spaceIdstring Space identifierstatus(Status | boolean) Filter the space by status.minimalResponseboolean Indicate if the response should be complete or minimal.
- Throws any If there was an error retrieving the space information.
Returns Promise<(SpaceResponse | MinimalSpaceResponse)> A Promise that resolves to space response.
update
Update space by ID. Only the name and acl details can be updated for the given space.
Parameters
spaceIdstring Space identifier.paramsSpaceUpdateParams The parameters for updating the space.minimalResponseboolean Indicate if the response should be complete or minimal. (optional, defaultfalse)
- Throws any An error if the space update fails.
Returns Promise<(SpaceResponse | MinimalSpaceResponse)> A Promise that resolves to the updated space.
delete
Delete space by ID. By default, it is a soft delete operation.
Parameters
spaceIdstring Space identifierparamsSpaceDeleteOptionalParams Optional parameters for deleting the space.
- Throws any If there was an error deleting the space.
Returns Promise<SpaceDeleteResponse> A Promise that resolves to the space delete response.
restore
Restore a deleted space by ID.
Parameters
spaceIdstring Space identifierminimalResponseboolean Indicate if the response should be complete or minimal. (optional, defaultfalse)
- Throws any If there was an error restoring the space.
Returns Promise<(SpaceResponse | MinimalSpaceResponse)> A Promise that resolves to the space restore response.
list
List child resources of a space by ID with additional options. Returns the resources of the space including itself, the root folder, and its children (files and folders).
Parameters
-
spaceIdstring Space identifier -
optionsobject Options for listing space children (optional, default{minimalResponse:false})options.paramsSpaceListOptionalParams Optional parameters to filter the list of space childrenoptions.minimalResponseboolean Indicate if the response should be complete or minimal
- Throws any If there was an error listing the space children.
Returns Promise<SpaceListResponse> A Promise that resolves to the list of space children.
getQueryParametersFromObject
Constructs a query string from the given query parameters object.
Parameters
queryParametersThe query parameters object.
Returns string The generated query string. If no parameters are provided, it returns an empty string. *
FoldersImpl
Represents the implementation of the folders operations.
Parameters
clientFileServiceClient A FileServiceClient instance used to make API calls.
create
Create a new folder under the given parentId.
Parameters
spaceIdstring Space identifier.parentIdstring Parent folder identifier.namestring Name of the folder. The name must be unique within the parent folder.
- Throws any If there was an error creating the folder.
Returns Promise<FolderResponse> A Promise that resolves to the created folder with a complete response.
create
Create a new folder under the given parentId.
Parameters
spaceIdstring Space identifier.parentIdstring Parent folder identifier.namestring Name of the folder. The name must be unique within the parent folder.paramsFolderCreateOptionalParams Optional parameters for creating the folder.
- Throws any If there was an error creating the folder.
Returns Promise<FolderResponse> A Promise that resolves to the created folder with a complete response.
create
Create a new folder under the given parentId.
Parameters
spaceIdstring Space identifier.parentIdstring Parent folder identifier.namestring Name of the folder. The name must be unique within the parent folder.minimalResponseboolean Indicate if the response should be complete or minimal.
- Throws any If there was an error creating the folder.
Returns Promise<(FolderResponse | MinimalFolderResponse)> A Promise that resolves to the created folder.
create
Create a new folder under the given parentId.
Parameters
spaceIdstring Space identifier.parentIdstring Parent folder identifier.namestring Name of the folder. The name must be unique within the parent folder.paramsFolderCreateOptionalParams Optional parameters for creating the folder.minimalResponseboolean Indicate if the response should be complete or minimal.
- Throws any If there was an error creating the folder.
Returns Promise<(FolderResponse | MinimalFolderResponse)> A Promise that resolves to the created folder.
getByPath
Get Folder by Path. Retrieves the folder with status set to active.
Parameters
spaceIdstring Space identifierpathstring Full path of the folder including all parent folders. The path should start with the root folder.
- Throws any If there was an error retrieving the folder information.
Returns Promise<FolderResponse> A Promise that resolves to a complete folder response.
getByPath
Get Folder by Path.
Parameters
spaceIdstring Space identifierpathstring Full path of the folder including all parent folders. The path should start with the root folder.statusStatus Filter the folder by status.
- Throws any If there was an error retrieving the folder information.
Returns Promise<FolderResponse> A Promise that resolves to a complete folder response.
getByPath
Get Folder by Path. Retrieves the folder with status set to active.
Parameters
spaceIdstring Space identifierpathstring Full path of the folder including all parent folders. The path should start with the root folder.minimalResponseboolean Indicate if the response should be complete or minimal.
- Throws any If there was an error retrieving the folder information.
Returns Promise<(FolderResponse | MinimalFolderResponse)> A Promise that resolves to folder response.
getByPath
Get Folder by Path.
Parameters
spaceIdstring Space identifierpathstring Full path of the folder including all parent folders. The path should start with the root folder.statusStatus Filter the folder by status.minimalResponseboolean Indicate if the response should be complete or minimal.
- Throws any If there was an error retrieving the folder information.
Returns Promise<(FolderResponse | MinimalFolderResponse)> A Promise that resolves to folder response.
get
Get folder by ID. Retrieves the folder with status set to active.
Parameters
- Throws any If there was an error retrieving the folder information.
Returns Promise<FolderResponse> A Promise that resolves to a complete folder response.
get
Get folder by ID.
Parameters
spaceIdstring Space identifierfolderIdstring Folder identifierstatusStatus Filter the folder by status.
- Throws any If there was an error retrieving the folder information.
Returns Promise<FolderResponse> A Promise that resolves to a complete folder response.
get
Get folder by ID. Retrieves the folder with status set to active.
Parameters
spaceIdstring Space identifierfolderIdstring Folder identifierminimalResponseboolean Indicate if the response should be complete or minimal.
- Throws any If there was an error retrieving the folder information.
Returns Promise<(FolderResponse | MinimalFolderResponse)> A Promise that resolves to the folder response.
get
Get folder by ID.
Parameters
spaceIdstring Space identifierfolderIdstring Folder identifierstatusStatus Filter the folder by status.minimalResponseboolean Indicate if the response should be complete or minimal.
- Throws any If there was an error retrieving the folder information.
Returns Promise<(FolderResponse | MinimalFolderResponse)> A Promise that resolves to the folder response.
update
Update Folder by ID.
Parameters
spaceIdstring Space identifier.folderIdstring Folder identifier.paramsFolderUpdateParams The parameters for updating the folder.minimalResponseboolean Indicate if the response should be complete or minimal. (optional, defaultfalse)
- Throws any If there was an error updating the folder.
Returns Promise<(FolderResponse | MinimalFolderResponse)> A Promise that resolves to the updated folder response.
updateWithOptions
Update Folder by ID.
Parameters
spaceIdstring Space identifier.folderIdstring Folder identifier.paramsFolderUpdateParams The parameters for updating the folder.optionsobject Optional parameters for the folder update. (optional, default{minimalResponse:false})
Properties
requestHeadersRecord<string, (string | Array<string>)>? Optional request headers.minimalResponseboolean? Indicate if the response should be complete or minimal.
- Throws any If there was an error updating the folder.
Returns Promise<(FolderResponse | MinimalFolderResponse)> A Promise that resolves to the updated folder response.
delete
Delete Folder by ID. By default, it is a soft delete operation.
Parameters
spaceIdstring Space identifierfolderIdstring Folder identifierparamsFolderDeleteOptionalParams Optional parameters for deleting the folder.
- Throws any If there was an error deleting the folder.
Returns Promise<FolderDeleteResponse> A Promise that resolves to the result of the delete operation.
deleteWithOptions
Delete Folder by ID.
Parameters
spaceIdstring Space identifierfolderIdstring Folder identifieroptionsobject Optional parameters for the folder delete operation.
Properties
paramsFolderDeleteOptionalParams? Optional parameters for deleting the folder.requestHeadersRecord<string, (string | Array<string>)>? Optional request headers. Supported headers: “If-Match”, “If-None-Match”.
- Throws any If there was an error deleting the folder.
Returns Promise<FolderDeleteResponse> A Promise that resolves to the result of the delete operation.
move
Move a folder to a new location within the same space.
Parameters
spaceIdstring Space identifierfolderIdstring Folder identifier to operate on.targetParentIdstring target where the source folder need to be movedminimalResponseboolean Indicate if the response should be complete or minimal. (optional, defaultfalse)
- Throws any If there was an error moving the folder.
Returns Promise<FolderMoveResponse> A Promise that resolves to the result of the move operation.
moveWithOptions
Move a folder to a new location within the same space.
Parameters
spaceIdstring Space identifierfolderIdstring Folder identifier to operate on.targetParentIdstring Target where the source folder needs to be moved.optionsobject Optional parameters for the folder move operation. (optional, default{minimalResponse:false})
- Throws any If there was an error moving the folder.
Returns Promise<FolderMoveResponse> A Promise that resolves to the result of the move operation.
rename
Rename a folder with a new name.
Parameters
spaceIdstring Space identifierfolderIdstring Folder identifier to operate on.namestring new nameminimalResponseboolean Indicate if the response should be complete or minimal. (optional, defaultfalse)
- Throws any If there was an error renaming the folder.
Returns Promise<FolderRenameResponse> A Promise that resolves to the result of the rename operation.
renameWithOptions
Rename a folder with a new name.
Parameters
spaceIdstring Space identifierfolderIdstring Folder identifier to operate on.namestring new nameoptionsobject Optional parameters for the folder rename operation. (optional, default{minimalResponse:false})
- Throws any If there was an error renaming the folder.
Returns Promise<FolderRenameResponse> A Promise that resolves to the result of the rename operation.
copy
Copy a folder to a new location within the same space.
Parameters
spaceIdstring Space identifier.folderIdstring Folder identifier to operate on.targetParentIdstring Target where the source folder needs to be copied.
- Throws any If there was an error copying the folder.
Returns Promise<FolderCopyResponse> A Promise that resolves to the result of the copy operation with a complete response.
copy
Copy a folder to a new location within the same space.
Parameters
spaceIdstring Space identifier.folderIdstring Folder identifier to operate on.targetParentIdstring Target where the source folder needs to be copied.paramsFolderCopyOptionalParams Optional parameters for copying the folder.
- Throws any If there was an error copying the folder.
Returns Promise<FolderCopyResponse> A Promise that resolves to the result of the copy operation with a complete response.
copy
Copy a folder to a new location within the same space.
Parameters
spaceIdstring Space identifier.folderIdstring Folder identifier to operate on.targetParentIdstring Target where the source folder needs to be copied.minimalResponseboolean Indicate if the response should be complete or minimal.
- Throws any If there was an error copying the folder.
Returns Promise<FolderCopyResponse> A Promise that resolves to the result of the copy operation.
copy
Copy a folder to a new location within the same space.
Parameters
spaceIdstring Space identifier.folderIdstring Folder identifier to operate on.targetParentIdstring Target where the source folder needs to be copied.paramsFolderCopyOptionalParams Optional parameters for copying the folder.minimalResponseboolean Indicate if the response should be complete or minimal.
- Throws any If there was an error copying the folder.
Returns Promise<FolderCopyResponse> A Promise that resolves to the result of the copy operation.
copyWithOptions
Copy a folder to a new location within the same space.
Parameters
spaceIdstring Space identifier.folderIdstring Folder identifier to operate on.targetParentIdstring Target where the source folder needs to be copied.optionsobject Optional parameters for the folder copy operation. (optional, default{minimalResponse:false})
- Throws any If there was an error copying the folder.
Returns Promise<FolderCopyResponse> A Promise that resolves to the result of the copy operation.
restore
Restore a deleted folder by ID.
Parameters
- Throws any If there was an error restoring the folder.
Returns Promise<FolderRestoreResponse> A Promise that resolves to the result of the restore operation with a complete response.
restore
Restore a deleted folder by ID.
Parameters
spaceIdstring Space identifierfolderIdstring Folder identifier to operate on.paramsFolderRestoreOptionalParams Optional parameters for restoring the folder.
- Throws any If the restore operation fails, an error is thrown.
Returns Promise<FolderRestoreResponse> A Promise that resolves to the result of the restore operation with a complete response.
restore
Restore a deleted folder by ID.
Parameters
spaceIdstring Space identifierfolderIdstring Folder identifier to operate on.minimalResponseboolean Indicate if the response should be complete or minimal.
- Throws any If the restore operation fails, an error is thrown.
Returns Promise<FolderRestoreResponse> A Promise that resolves to the result of the restore operation.
restore
Restore a deleted folder by ID.
Parameters
spaceIdstring Space identifierfolderIdstring Folder identifier to operate on.paramsFolderRestoreOptionalParams Optional parameters for restoring the folder.minimalResponseboolean Indicate if the response should be complete or minimal.
- Throws any If the restore operation fails, an error is thrown.
Returns Promise<FolderRestoreResponse> A Promise that resolves to the result of the restore operation.
restoreWithOptions
Restore a deleted folder by ID.
Parameters
spaceIdstring Space identifierfolderIdstring Folder identifier to operate on.optionsobject Optional parameters for the folder restore operation. (optional, default{minimalResponse:false})
- Throws any If the restore operation fails, an error is thrown.
Returns Promise<FolderRestoreResponse> A Promise that resolves to the result of the restore operation.
list
Lists all children of a folder in a space by ID. The operation is paginated and the response contains a token that can be used to get the next page of results.
Parameters
- Throws any If there was an error listing the children of the folder.
Returns Promise<FileOrFolderListResponse> A Promise that resolves to the list of children of the folder with a complete response.
list
Lists all children of a folder in a space by ID. The operation is paginated and the response contains a token that can be used to get the next page of results.
Parameters
spaceIdstring Space identifierfolderIdstring Folder identifier to operate on.paramsFolderListOptionalParams Optional parameters to list the children of the folder.
- Throws any If there was an error listing the children of the folder.
Returns Promise<FileOrFolderListResponse> A Promise that resolves to the list of children of the folder with a complete response.
list
Lists all children of a folder in a space by ID. The operation is paginated and the response contains a token that can be used to get the next page of results.
Parameters
spaceIdstring Space identifierfolderIdstring Folder identifier to operate on.minimalResponseboolean Indicate if the response should be complete or minimal.
- Throws any If there was an error listing the children of the folder.
Returns Promise<FileOrFolderListResponse> A Promise that resolves to the list of children of the folder.
list
Lists all children of a folder in a space by ID. The operation is paginated and the response contains a token that can be used to get the next page of results.
Parameters
spaceIdstring Space identifierfolderIdstring Folder identifier to operate on.paramsFolderListOptionalParams Optional parameters to list the children of the folder.minimalResponseboolean Indicate if the response should be complete or minimal.
- Throws any If there was an error listing the children of the folder.
Returns Promise<FileOrFolderListResponse> A Promise that resolves to the list of children of the folder.
getVersion
Get details for the specified folder version. Retrieves the folder with status set to active.
Parameters
spaceIdstring Space identifierfolderIdstring folder identifier to operate on.versionIdstring Version identifier of the folder. The version identifier will be a whole number for folders.
- Throws any If there was an error retrieving the folder information.
Returns Promise<FolderResponse> A Promise that resolves to a complete folder response.
getVersion
Get details for the specified folder version.
Parameters
spaceIdstring Space identifierfolderIdstring Folder identifierversionIdstring Version identifier of the folder. The version identifier will be a whole number for folders.statusStatus Filter the folder by status.
- Throws any If there was an error retrieving the folder information.
Returns Promise<FolderResponse> A Promise that resolves to a complete folder response.
getVersion
Get details for the specified folder version. Retrieves the folder with status set to active.
Parameters
spaceIdstring Space identifierfolderIdstring Folder identifierversionIdstring Version identifier of the folder. The version identifier will be a whole number for folders.minimalResponseboolean Indicate if the response should be complete or minimal.
- Throws any If there was an error retrieving the folder information.
Returns Promise<(FolderResponse | MinimalFolderResponse)> A Promise that resolves to the folder response.
getVersion
Get details for the specified folder version.
Parameters
spaceIdstring Space identifierfolderIdstring Folder identifierversionIdstring Version identifier of the folder. The version identifier will be a whole number for folders.statusStatus Filter the folder by status.minimalResponseboolean Indicate if the response should be complete or minimal.
- Throws any If there was an error retrieving the folder information.
Returns Promise<(FolderResponse | MinimalFolderResponse)> A Promise that resolves to the folder response.
listVersions
List all versions for a folder in a space by ID. The operation is paginated and the response contains a token that can be used to get the next page of results.
Parameters
- Throws any If there was an error listing the versions of the folder.
Returns Promise<FolderListResponse> A Promise that resolves to the list of versions of the folder with a complete response.
listVersions
List all versions for a folder in a space by ID. The operation is paginated and the response contains a token that can be used to get the next page of results.
Parameters
spaceIdstring Space identifierfolderIdstring folder identifier to operate on.paramsFolderListOptionalParams Optional parameters to filter the list of versions of the folder.
- Throws any If there was an error listing the versions of the folder.
Returns Promise<FolderListResponse> A Promise that resolves to the list of versions of the folder with a complete response.
listVersions
List all versions for a folder in a space by ID. The operation is paginated and the response contains a token that can be used to get the next page of results.
Parameters
spaceIdstring Space identifierfolderIdstring folder identifier to operate on.minimalResponseboolean Indicate if the response should be complete or minimal.
- Throws any If there was an error listing the versions of the folder.
Returns Promise<FolderListResponse> A Promise that resolves to the list of versions of the folder.
listVersions
List all versions for a folder in a space by ID. The operation is paginated and the response contains a token that can be used to get the next page of results.
Parameters
spaceIdstring Space identifierfolderIdstring folder identifier to operate on.paramsFolderListOptionalParams Optional parameters to filter the list of versions of the folder.minimalResponseboolean Indicate if the response should be complete or minimal.
- Throws any If there was an error listing the versions of the folder.
Returns Promise<FolderListResponse> A Promise that resolves to the list of versions of the folder.
listByPath
Lists all children of a folder in a space by path. The operation is paginated and the response contains a token that can be used to get the next page of results.
Parameters
spaceIdstring Space identifierpathstring Full path of the folder including all parent folders. The path should start with the root folder.
- Throws any If there was an error listing the children of the folder.
Returns Promise<FileOrFolderListResponse> A Promise that resolves to the list of children of the folder with a complete response.
listByPath
Lists all children of a folder in a space by path. The operation is paginated and the response contains a token that can be used to get the next page of results.
Parameters
spaceIdstring Space identifierpathstring Full path of the folder including all parent folders. The path should start with the root folder.paramsFolderListOptionalParams Optional parameters to filter the list of children of the folder.
- Throws any If there was an error listing the children of the folder.
Returns Promise<FileOrFolderListResponse> A Promise that resolves to the list of children of the folder with a complete response.
listByPath
Lists all children of a folder in a space by path. The operation is paginated and the response contains a token that can be used to get the next page of results.
Parameters
spaceIdstring Space identifierpathstring Full path of the folder including all parent folders. The path should start with the root folder.minimalResponseboolean Indicate if the response should be complete or minimal.
- Throws any If there was an error listing the children of the folder.
Returns Promise<FileOrFolderListResponse> A Promise that resolves to the list of children of the folder.
listByPath
Lists all children of a folder in a space by path. The operation is paginated and the response contains a token that can be used to get the next page of results.
Parameters
spaceIdstring Space identifierpathstring Full path of the folder including all parent folders. The path should start with the root folder.paramsFolderListOptionalParams Optional parameters to filter the list of children of the folder.minimalResponseboolean Indicate if the response should be complete or minimal.
- Throws any If there was an error listing the children of the folder.
Returns Promise<FileOrFolderListResponse> A Promise that resolves to the list of children of the folder.
getVersionByPath
Get details for the specified folder version by path. Retrieves the folder with status set to active.
Parameters
spaceIdstring Space identifierversionIdstring Version identifier of the folder. The version identifier will be a whole number for folders.pathstring Full path of the folder including all parent folders. The path should start with the root folder.
- Throws any If there was an error retrieving the folder information.
Returns Promise<FolderResponse> A Promise that resolves to a complete folder response.
getVersionByPath
Get details for the specified folder version by path.
Parameters
spaceIdstring Space identifierversionIdstring Version identifier of the folder. The version identifier will be a whole number for folders.pathstring Full path of the folder including all parent folders. The path should start with the root folder.statusStatus Filter the folder by status.
- Throws any If there was an error retrieving the folder information.
Returns Promise<FolderResponse> A Promise that resolves to a complete folder response.
getVersionByPath
Get details for the specified folder version by path. Retrieves the folder with status set to active.
Parameters
spaceIdstring Space identifierversionIdstring Version identifier of the folder. The version identifier will be a whole number for folders.pathstring Full path of the folder including all parent folders. The path should start with the root folder.minimalResponseboolean Indicate if the response should be complete or minimal.
- Throws any If there was an error retrieving the folder information.
Returns Promise<(FolderResponse | MinimalFolderResponse)> A Promise that resolves to a folder response.
getVersionByPath
Get details for the specified folder version by path.
Parameters
spaceIdstring Space identifierversionIdstring Version identifier of the folder. The version identifier will be a whole number for folders.pathstring Full path of the folder including all parent folders. The path should start with the root folder.statusStatus Filter the folder by status.minimalResponseboolean Indicate if the response should be complete or minimal.
- Throws any If there was an error retrieving the folder information.
Returns Promise<(FolderResponse | MinimalFolderResponse)> A Promise that resolves to a folder response.
listVersionsByPath
List all versions for a folder in a space by path. The operation is paginated and the response contains a token that can be used to get the next page of results.
Parameters
spaceIdstring Space identifierpathstring Full path of the folder including all parent folders. The path should start with the root folder.
- Throws any If there was an error listing the versions of the folder.
Returns Promise<FolderListResponse> A Promise that resolves to the list of versions of the folder with a complete response.
listVersionsByPath
List all versions for a folder in a space by path. The operation is paginated and the response contains a token that can be used to get the next page of results.
Parameters
spaceIdstring Space identifierpathstring Full path of the folder including all parent folders. The path should start with the root folder.paramsFolderListOptionalParams Optional parameters to filter the list of versions of the folder.
- Throws any If there was an error listing the versions of the folder.
Returns Promise<FolderListResponse> A Promise that resolves to the list of versions of the folder with a complete response.
listVersionsByPath
List all versions for a folder in a space by path. The operation is paginated and the response contains a token that can be used to get the next page of results.
Parameters
spaceIdstring Space identifierpathstring Full path of the folder including all parent folders. The path should start with the root folder.minimalResponseboolean Indicate if the response should be complete or minimal.
- Throws any If there was an error listing the versions of the folder.
Returns Promise<FolderListResponse> A Promise that resolves to the list of versions of the folder.
listVersionsByPath
List all versions for a folder in a space by path. The operation is paginated and the response contains a token that can be used to get the next page of results.
Parameters
spaceIdstring Space identifierpathstring Full path of the folder including all parent folders. The path should start with the root folder.paramsFolderListOptionalParams Optional parameters to filter the list of versions of the folder.minimalResponseboolean Indicate if the response should be complete or minimal.
- Throws any If there was an error listing the versions of the folder.
Returns Promise<FolderListResponse> A Promise that resolves to the list of versions of the folder.
JobsImpl
Creating and managing jobs.
Parameters
clientFileServiceClient A FileServiceClient instance used to make API calls.
get
Get Job details for a given job identifier. By default, this operation returns 404 NotFound in case of job not present or if the resource is in deleted state.
Parameters
jobIdstring The job identifier.
- Throws Error If the request fails.
Returns Promise<JobResponse> A promise that resolves with the job details.
ExportsImpl
Creating and managing exports.
Parameters
clientFileServiceClient A FileServiceClient instance used to make API calls.
create
Create a new export.
Parameters
spaceIdstring Space identifier.folderIdstring Folder identifier.includeTopLevelboolean If true, the export will include the top level folder inside the export as the first subfolder. If false, the export will only include the children of the top level folder. Default is true. (optional, defaulttrue)
- Throws any An error if the export creation fails.
Returns Promise<string> A Promise that resolves to the export identifier.
get
Get Export details for a given export identifier.
Parameters
spaceIdstring Space identifierexportIdstring Export identifierurlDurationstring The duration for which the download URL is valid. The default is 1 hour. (optional, default"60m")
- Throws any If there was an error retrieving the export information.
Returns Promise<ExportResponse> A Promise that resolves to the retrieved export information.
EventType
Copyright (c) Trimble Inc.
EventType
Represents the type of event that can occur during file upload.
EventsManager
Manages event subscriptions and publishes events to subscribers.
publish
Publishes one or more events to their respective subscribers.
Parameters
events(Array<EventResponse> | EventResponse) An array of events or a single event object.
Returns void
subscribe
Subscribes to one or more event types with a callback function.
Parameters
eventTypes(Array<EventType> | EventType) An array of event types or a single event type string.callbackEventCallback The callback function to be invoked when the event is published.
Returns void
unsubscribe
Unsubscribes from one or more event types with a callback function.
Parameters
eventTypes(Array<EventType> | EventType) An array of event types or a single event type string.callbackEventCallback The callback function to be removed from the subscribers list.
Returns void
ResourcesImpl
Represents the resources operations in the Trimble Cloud File Service.
Parameters
clientFileServiceClient A FileServiceClient instance used to make API calls.
getByPath
Get resource by Path. Retrieves the resource with status set to active.
Parameters
spaceIdstring Space identifierpathstring Full path of the resource (folder/file) including all parent folders. The path should start with the root folder.
- Throws any If there was an error retrieving the folder information.
Returns Promise<(FileResponse | FolderResponse)> A Promise that resolves to a complete file or folder response.
getByPath
Get resource by Path.
Parameters
spaceIdstring Space identifierpathstring Full path of the resource (folder/file) including all parent folders. The path should start with the root folder.paramsResourceGetOptionalParams Optional parameters for retrieving the resource.
- Throws any If there was an error retrieving the folder information.
Returns Promise<(FileResponse | FolderResponse)> A Promise that resolves to a complete file or folder response.
getByPath
Get resource by Path. Retrieves the resource with status set to active.
Parameters
spaceIdstring Space identifierpathstring Full path of the resource (folder/file) including all parent folders. The path should start with the root folder.minimalResponseboolean Indicate if the response should be complete or minimal.
- Throws any If there was an error retrieving the folder information.
Returns Promise<(FileResponse | MinimalFileResponse | FolderResponse | MinimalFolderResponse)> A Promise that resolves to file or folder response.
getByPath
Get resource by Path.
Parameters
spaceIdstring Space identifierpathstring Full path of the resource (folder/file) including all parent folders. The path should start with the root folder.paramsResourceGetOptionalParams Optional parameters for retrieving the resource.minimalResponseboolean Indicate if the response should be complete or minimal.
- Throws any If there was an error retrieving the folder information.
Returns Promise<(FileResponse | MinimalFileResponse | FolderResponse | MinimalFolderResponse)> A Promise that resolves to file or folder response.
get
Get resource by ID. Retrieves the resource with status set to active.
Parameters
- Throws any If there was an error retrieving the folder information.
Returns Promise<(FileResponse | FolderResponse)> A Promise that resolves to a complete file or folder response.
get
Get resource by ID.
Parameters
spaceIdstring Space identifierresourceIdstring Resource identifier (file or folder ID).paramsResourceGetOptionalParams Optional parameters for retrieving the resource.
- Throws any If there was an error retrieving the folder information.
Returns Promise<(FileResponse | FolderResponse)> A Promise that resolves to a complete file or folder response.
get
Get resource by ID. Retrieves the resource with status set to active.
Parameters
spaceIdstring Space identifierresourceIdstring Resource identifier (file or folder ID).minimalResponseboolean Indicate if the response should be complete or minimal.
- Throws any If there was an error retrieving the folder information.
Returns Promise<(FileResponse | MinimalFileResponse | FolderResponse | MinimalFolderResponse)> A Promise that resolves to file or folder response.
get
Get resource by ID.
Parameters
spaceIdstring Space identifierresourceIdstring Resource identifier (file or folder ID).paramsResourceGetOptionalParams Optional parameters for retrieving the resource.minimalResponseboolean Indicate if the response should be complete or minimal.
- Throws any If there was an error retrieving the folder information.
Returns Promise<(FileResponse | MinimalFileResponse | FolderResponse | MinimalFolderResponse)> A Promise that resolves to file or folder response.
getBatch
Retrieve resources in batch.
Parameters
spaceIdstring Space identifierparamsResourceBatchGetParams Parameters for retrieving resources in batch.minimalResponseboolean Indicate if the response should be complete or minimal. (optional, defaultfalse)
- Throws any If there was an error retrieving the folder information.
Returns Promise<ResourceBatchResponse> A Promise that resolves to a resource batch response.
__awaiter
Copyright (c) Trimble Inc.
transformDateKey
Transforms the response object by applying specific transformations to certain keys. Recursively transforms nested objects and arrays.
Parameters
keyvalueaccitemThe item to be transformed.
Returns any The transformed item.
transformLinksKey
Transforms the links key in the response object.
Parameters
valueThe value of the links key.accThe accumulator object for transformed values.itemThe original item being transformed.
transformDefaultKey
Transforms the default key in the response object.
Parameters
keyThe key to be transformed.valueThe value associated with the key.accThe accumulator object for transformed values.
transformKey
Transforms the key in the response object.
Parameters
keyThe key to be transformed.valueThe value associated with the key.accThe accumulator object for transformed values.itemThe original item being transformed.
transformResponse
Transforms the response object by applying specific transformations to certain keys. Recursively transforms nested objects and arrays.
Parameters
itemThe item to be transformed.
Returns any The transformed item.
isValidUrlDuration
Checks if the given URL duration is valid.
Parameters
urlDurationThe URL duration to validate.
Returns any true if the URL duration is valid, false otherwise.
getJobIdFromPath
Retrieves the job ID from a given path.
Parameters
pathstring The path from which to extract the job ID.
Returns string The extracted job ID.
getNextPageToken
Retrieves the next page token from the given result object.
Parameters
resultany The result object from which to extract the next page token.
Returns string The extracted next page token.
getClientId
Gets the client ID from the token provider. Retrieves the client ID from the azp (authorized party) claim if present, otherwise falls back to the sub (subject) claim.
Parameters
tokenProvider
- Throws Error If the token cannot be retrieved or decoded, or if neither azp nor sub claims are present.
Returns Promise<string> The client ID extracted from the token.
Copyright (c) Trimble Inc.
Acl
Copyright (c) Trimble Inc.
role
The role assigned to the actor.
Type: AclRole
actor
The actor identifier. The actor could be a user or application or group or a device.
Type: string
Acl
Represents an access control list (ACL) identity.
role
The role assigned to the actor.
Type: AclRole
actor
The actor identifier. The actor could be a user or application or group or a device.
Type: string
Acl
Copyright (c) Trimble Inc.
role
The role assigned to the actor.
Type: AclRole
actor
The actor identifier. The actor could be a user or application or group or a device.
Type: string
Acl
Copyright (c) Trimble Inc.
role
The role assigned to the actor.
Type: AclRole
actor
The actor identifier. The actor could be a user or application or group or a device.
Type: string
SpaceCreateOptionalParams
Represents the optional parameters for creating a space.
provider
The cloud provider where the space will be created. Supported values are “aws” and “azure”.
Type: Provider
permissionsLocal
Permission request on the space.
Type: SpacePermissionsLocal
softDeleteRetention
Duration of soft deleted resources being retained before being permanently removed.
Type: SoftDeleteRetention
SoftDeleteRetention
Duration of soft deleted resources being retained before being permanently removed.
THIRTY_DAYS
The space will be deleted after 30 days.
Type: string
SIX_MONTHS
The space will be deleted after 180 days.
Type: string
ONE_YEAR
The space will be deleted after 1 year.
Type: string
NEVER_DELETE
The space will never be deleted.
Type: string
Provider
The cloud provider where the space will be created. Supported values are “aws” and “azure”.
SpaceResponse
Represents a space in the file service.
createdAt
A date time expressed in ISO 8601 format.
Type: Date
createdByTrn
The TRN (Tenant Resource Name) of the user, application, or device that created the space.
Type: string
updatedAt
A date time expressed in ISO 8601 format.
Type: Date
updatedByTrn
The TRN (Tenant Resource Name) of the user, application, or device that last updated the space.
Type: string
deleted
Indicates whether the space has been deleted.
Type: boolean
deletedAt
A date time expressed in ISO 8601 format.
Type: Date
id
The unique identifier of the space.
Type: string
resourceTrn
The TRN of the resource.
Type: string
name
The name of the space.
Type: string
rootId
The unique identifier of the root folder.
Type: string
rootTrn
The TRN of the root folder.
Type: string
permissionsLocal
Permission request on the space.
Type: SpacePermissionsLocal
permissionsEvaluated
Permissions that are evaluated for the user.
Type: PermissionsEvaluated
type
The type of the space.
Type: EntityType.SPACE
accountId
The unique identifier of the CDH account.
Type: string
provider
The cloud provider of the space. Allowed values are aws, azure
Type: Provider
softDeleteRetention
Duration of soft deleted resources being retained before being permanently removed.
Type: SoftDeleteRetention
stats
The statistics of the space.
Type: SpaceStatistics
capabilities
Describes the list of actions that can be performed on the resource by the current user.
Type: Capabilities
MinimalSpaceResponse
Represents a minimal space response.
createdAt
A date time expressed in ISO 8601 format.
Type: Date
createdByTrn
The TRN (Tenant Resource Name) of the user, application, or device that created the space.
Type: string
updatedAt
A date time expressed in ISO 8601 format.
Type: Date
updatedByTrn
The TRN (Tenant Resource Name) of the user, application, or device that last updated the space.
Type: string
deleted
Indicates whether the space has been deleted.
Type: boolean
id
The unique identifier of the space.
Type: string
resourceTrn
The TRN of the resource.
Type: string
name
The name of the space.
Type: string
rootId
The unique identifier of the root folder.
Type: string
type
The type of the space.
Type: EntityType.SPACE
rootTrn
The TRN of the root folder.
Type: string
SpaceUpdateParams
Space parameters that can updated.
name
The name of the space
Type: string
permissionsLocal
Update the permissions on the resource.
Type: SpaceUpdatePermissionsLocal
softDeleteRetention
Duration of soft deleted resources being retained before being permanently removed.
Type: SoftDeleteRetention
SpaceDeleteOptionalParams
Represents the optional parameters for deleting a space.
permanent
If true, the space and its content will be hard deleted. If false, the space and its content will be soft deleted.
Type: boolean
recursive
This needs to be set to true in order to delete a space that is not empty.
Type: boolean
SpaceDeleteResponse
Represents the response object for deleting a space.
jobId
The ID of the job associated with the space deletion for non-empty spaces. For empty spaces, the job ID will be null.
Type: string
SpaceRestoreResponse
Represents the response for restoring a space.
space
Restored space details.
Type: (SpaceResponse | MinimalSpaceResponse)
jobId
ID of the job associated with the restoration of non-empty spaces. For empty spaces, the job ID will not be present.
Type: string
SpaceStatistics
Represents the statistics of a space.
size
The sum of sizes of all the active resources in the space in bytes
Type: number
supportFilesSize
The sum of size of all the active support files in the space in bytes
Type: number
deletedSize
The sum of sizes of all the soft deleted resources in the space in bytes
Type: number
deletedSupportFilesSize
The sum of sizes of all the soft deleted support files in the space in bytes
Type: number
filesCount
The count of all active files in the space
Type: number
foldersCount
The count of all active folders in the space
Type: number
deletedFilesCount
The count of all soft deleted files in the space
Type: number
deletedFoldersCount
The count of all soft deleted folders in the space
Type: number
totalStorageUsed
The total storage used by the space and its contents, including versions, in bytes
Type: number
contentsUpdatedAt
The date and time when the contents of the space were last updated
Type: Date
Status
The status query parameter is used to filter the resources based on their status. It accepts a comma-separated list of statuses. The possible statuses are ‘active’ and ‘deleted’. If ‘active’ is specified, only active resources will be returned. If ‘deleted’ is specified, only deleted resources will be returned. If both ‘active’ and ‘deleted’ are specified (as ‘active,deleted’), the API will return both active and deleted files.
Type: ("active" | "deleted" | "active,deleted")
EntityType
Represents the type of an entity.
SpacePermissionsLocal
Permission request on the space.
acl
The list of actors and their roles.
SpaceUpdatePermissionsLocal
Represents a space permissions update request. Note: Both replaceAcl and updateAcl cannot be used in the same request.
acl
Completely replace the existing permissions on the resource. When this field is used, all previous permissions are overwritten by the new ones.
updateAcl
Modify the current permissions by adding or removing permissions, without fully replacing the existing permissions.
Type: SpaceUpdateAcl
SpaceUpdateAcl
Allow modifications to the current permissions by adding or removing permissions, without fully replacing the existing permissions.
add
Add new roles to the existing permissions on the resource. If an actor already has a permission on the resource and is included in the request again, their existing permissions will be replaced with the new ones specified.
remove
Represent acl to remove
Type: Array<SpaceRemoveAcl>
SpaceRemoveAcl
Remove access from the resource
actor
The actor id to be removed from the permissions.
Type: string
role
The role to be removed for the actor.
Type: AclRole
SpaceListOptionalParams
Represents the optional parameters for listing space children.
pageSize
Maximum number of results to return per page.
Type: number
nextPageToken
Token to retrieve the next page of results.
Type: string
status
Filter the children by status.
Type: Status
sinceTime
The date and time since when the resources were last updated.
Type: Date
resourceType
Filter the children by resource type.
Type: EntityType
supportFiles
Include support files in the response.
Type: boolean
urlDuration
Duration of the download URL in seconds.
Type: number
sortOrder
Sort order of the results.
Type: string
SpaceListResponse
Represents a list of resources in a space.
items
List of resources in the space.
Type: (Array<(FolderResponse | FileResponse | SpaceResponse)> | Array<(MinimalFolderResponse | MinimalFileResponse | MinimalSpaceResponse)>)
nextPageToken
Token used to get the next result set on subsequent calls. If this is not returned, then this is the final page.
Type: string
AclRole
Copyright (c) Trimble Inc.
SpaceManager
SpaceManager has the highest level of permissions in the file space. Can perform all operations on the file space.
Type: string
ContentManager
ContentManager has almost as many permissions as SpaceManager, but cannot update/delete the file space.
Type: string
ContentContributor
ContentContributor has all operations on the file and folder except for the ACL control.
Type: string
ContentViewer
ContentViewer has all read permissions on the file and folder.
Type: string
AclRole
The role assigned to the actor.
SpaceManager
SpaceManager has the highest level of permissions in the file space. Can perform all operations on the file space.
Type: string
ContentManager
ContentManager has almost as many permissions as SpaceManager, but cannot update/delete the file space.
Type: string
ContentContributor
ContentContributor has all operations on the file and folder except for the ACL control.
Type: string
ContentViewer
ContentViewer has all read permissions on the file and folder.
Type: string
AclActor
The actor identifier
actor
The actor identifier. The actor could be a user or application or group or a device.
Type: string
InheritedAcl
Represents the actor role mapping for the resources that are inherited.
actor
The actor identifier. The actor could be a user or application or group or a device.
Type: string
role
The role assigned to the actor.
Type: AclRole
inheritedFrom
The resource identifier from which the permissions are inherited.
Type: string
inheritedFromTrn
The TRN of the resource.
Type: string
PermissionsEvaluated
Represents the permissions evaluated for the actors on the resource. It shows the most permissible role applicable for the actor, considering both the direct and inherited permissions.
acl
The list of actors and their roles.
Type: Array<InheritedAcl>
PermissionsInherited
Lists the permissions inherited from the entire parent hierarchy applicable for the actor.
acl
The list of actors and their roles.
Type: Array<InheritedAcl>
FolderCreateOptionalParams
Represents the optional parameters required to create a folder.
permissionsLocal
Permission request on the folder.
Type: FolderPermissionsLocal
metadata
Clients may set additional information related to the folder here.
Type: Record<string, (object | string)>
FolderResponse
Represents a folder entity.
createdAt
A date time expressed in ISO 8601 format.
Type: Date
createdByTrn
userTrn (string) or applicationTrn (string) or deviceTrn (string) (ActorTrn)
Type: string
updatedAt
A date time expressed in ISO 8601 format.
Type: Date
updatedByTrn
userTrn (string) or applicationTrn (string) or deviceTrn (string) (ActorTrn)
Type: string
deleted
True if the entity has been deleted
Type: boolean
deletedAt
A date time expressed in ISO 8601 format.
Type: Date
id
The unique identifier of the entity
Type: string
resourceTrn
The TRN of the resource.
Type: string
name
The name of the entity
Type: string
type
The type of the entity. Possible values are SPACE, FOLDER, and FILE
Type: EntityType.FOLDER
spaceId
The unique identifier of the space where the entity is stored
Type: string
spaceTrn
TRN of the space where the entity is stored
Type: string
version
The version of the entity
Type: string
metadata
Clients may set additional information related to the folder here.
Type: Record<string, (object | string)>
path
Full path of the folder.
Type: string
parentId
Folder identifier of the parent folder. Not present for root folder or for files not attached to any folder
Type: string
parentTrn
The TRN of the parent resource.
Type: string
size
The size of the folder in bytes.
Type: number
stats
The statistics of the folder.
Type: FolderStatistics
capabilities
Describes the list of actions that can be performed on the resource by the current user.
Type: Capabilities
permissionsLocal
Permissions that are set directly for an actor on the resource itself.
Type: FolderPermissionsLocal
permissionsEvaluated
Permissions that are evaluated for the user.
Type: PermissionsEvaluated
permissionsInherited
Lists the permissions inherited from the entire parent hierarchy applicable for the actor.
Type: PermissionsInherited
MinimalFolderResponse
Represents a minimal folder entity.
createdAt
A date time expressed in ISO 8601 format.
Type: Date
createdByTrn
userTrn (string) or applicationTrn (string) or deviceTrn (string) (ActorTrn)
Type: string
updatedAt
A date time expressed in ISO 8601 format.
Type: Date
updatedByTrn
userTrn (string) or applicationTrn (string) or deviceTrn (string) (ActorTrn)
Type: string
deleted
True if the entity has been deleted
Type: boolean
id
The unique identifier of the entity
Type: string
resourceTrn
The TRN of the resource.
Type: string
name
The name of the entity
Type: string
type
The type of the entity. Possible values are SPACE, FOLDER, and FILE
Type: EntityType.FOLDER
spaceId
The unique identifier of the space where the entity is stored
Type: string
spaceTrn
TRN of the space where the entity is stored
Type: string
version
The version of the entity
Type: string
FolderUpdateParams
Folder parameters that can updated.
metadata
Clients may set additional information related to the file here.
Type: Record<string, (object | string)>
permissionsLocal
Update the permissions on the resource.
Type: FolderUpdatePermissionsLocal
FolderDeleteOptionalParams
Represents the optional parameters for deleting a folder.
permanent
If true, the folder and its content will be hard deleted. If false, the folder and its content will be soft deleted.
Type: boolean
recursive
This needs to be set to true in order to delete a folder that is not empty.
Type: boolean
FolderCopyOptionalParams
Represents the optional parameters for copying a folder.
name
Optionally provide a new name for the copied folder
Type: string
copySupportFiles
The copySupportFiles query parameter determines whether to copy the support files along with the main file. If specified and true, the support files are copied and links are created between the copied main file and the copied support files.
Type: boolean
overwriteExisting
The overwriteExisting query parameter determines whether to overwrite an existing resource. If specified and true, the existing resource will have a new version created with the copied content.
Type: boolean
copyAcl
The copyAcl query parameter determines whether to copy the ACL from the resource to the target resource.
Type: boolean
permissionsLocal
Permissions that are set directly for an actor on the resource itself.
Type: FolderPermissionsLocal
FolderDeleteResponse
Represents the response for deleting a folder.
jobId
The ID of the job associated with the folder deletion for non-empty folders. For empty folders, this will be null.
Type: string
FolderRestoreOptionalParams
Represents the parameters for restoring a folder.
targetParentId
The target parent ID where the source folder needs to be restored.
Type: string
name
The new name of the folder.
Type: string
FolderListOptionalParams
Represents the query parameters for listing folders.
pageSize
The largest quantity of items to be returned in a single response (in a single page).
Type: number
status
The status query parameter is used to filter the resources based on their status.
Type: Status
nextPageToken
Pagination token that can be used as input from a previous response to get the next page of results.
Type: string
urlDuration
The duration for which the upload URL is valid.
Type: string
sortBy
Field to sort the results by.
Type: string
sortOrder
Sort order of the results.
Type: string
recursive
Whether to recursively list all children of subfolders.
Type: boolean
FileOrFolderListResponse
Represents a list of folders and files in a space.
items
List of file and folder descriptors in the space. The response will contain the folder and its children (files and folders) descriptors and their metadata information.
Type: (Array<(FolderResponse | FileResponse)> | Array<(MinimalFolderResponse | MinimalFileResponse)>)
nextPageToken
Token used to get the next result set on subsequent calls. If this is not returned, then this is the final page.
Type: string
FolderListResponse
Represents a list of all versions of a folder.
items
List of folders in the space.
Type: (Array<FolderResponse> | Array<MinimalFolderResponse>)
nextPageToken
Token used to get the next result set on subsequent calls. If this is not returned, then this is the final page.
Type: string
FolderRestoreResponse
Extends FolderJobResponse
Represents the response for restoring a folder.
FolderJobResponse
Folder job response.
folder
Folder response.
Type: (FolderResponse | MinimalFolderResponse)
jobId
The ID of the job associated with the folder operation.
Type: string
FolderCopyResponse
Extends FolderJobResponse
Represents the response for copying a folder.
FolderRenameResponse
Extends FolderJobResponse
Represents the response for renaming a folder.
FolderMoveResponse
Extends FolderJobResponse
Represents the response for moving a folder.
FolderStatistics
Represents the statistics of a folder.
supportFilesSize
The sum of sizes of all the latest versions of the support files in the folder in bytes
Type: number
immediateFilesCount
The count of files directly under the folder
Type: number
immediateFoldersCount
The count of folders directly under the folder
Type: number
contentsUpdatedAt
The date and time when the contents of the folder were last updated
Type: Date
FolderPermissionsLocal
Permission request on the folder.
inherits
Specifies if permissions are inherited from the parent resources.
Type: boolean
acl
The list of actors and their roles.
FolderUpdatePermissionsLocal
Represents a folder permissions update request. Note: Both replaceAcl and updateAcl cannot be used in the same request.
inherits
Specifies if permissions are inherited from the parent resources.
Type: boolean
acl
Completely replace the existing permissions on the resource. When this field is used, all previous permissions are overwritten by the new ones.
updateAcl
Modify the current permissions by adding or removing permissions, without fully replacing the existing permissions.
Type: FolderUpdateAcl
FolderUpdateAcl
Allow modifications to the current permissions by adding or removing permissions, without fully replacing the existing permissions.
add
Add new roles to the existing permissions on the resource. If an actor already has a permission on the resource and is included in the request again, their existing permissions will be replaced with the new ones specified.
remove
Actors to be removed from the permissions.
FileResponse
Represents a file entity.
createdAt
A date time expressed in ISO 8601 format.
Type: Date
createdByTrn
userTrn (string) or applicationTrn (string) or deviceTrn (string) (ActorTrn)
Type: string
updatedAt
A date time expressed in ISO 8601 format.
Type: Date
updatedByTrn
userTrn (string) or applicationTrn (string) or deviceTrn (string) (ActorTrn)
Type: string
deleted
True if the entity has been deleted
Type: boolean
deletedAt
A date time expressed in ISO 8601 format.
Type: Date
name
The name of the entity
Type: string
id
The unique identifier of the entity. This is a UUID.
Type: string
resourceTrn
The TRN of the resource.
Type: string
type
The type of the file.
Type: EntityType.FILE
spaceId
The unique identifier of the space where the file is stored
Type: string
spaceTrn
TRN of the space where the entity is stored
Type: string
version
The version of the file
Type: string
metadata
Clients may set additional information related to the file here.
Type: Record<string, (object | string)>
path
Path where file is created.
Type: string
parentId
Parent Folder Id where the file was created.
Type: string
parentType
The type of the parent file. It can be either FOLDER or FILE and parentType should be FILE when the file is a support file.
Type: string
parentTrn
TRN of the parent resource.
Type: string
permissionsLocal
Permissions that are set directly for an actor on the resource itself.
Type: FilePermissionsLocal
permissionsEvaluated
Permissions that are evaluated for the user.
Type: PermissionsEvaluated
permissionsInherited
Lists the permissions inherited from the entire parent hierarchy applicable for the actor.
Type: PermissionsInherited
restrictedAccess
Set to false if the download url of the file shouldn’t be expired. Whereas when true download url expiration takes place according to the configured value
Type: boolean
fileset
Whether the object consists of a set of multiple files that should be treated as a single file, such as with shape files.
Type: boolean
expiresAt
Time period when the file object gets automatically removed. Must be at least 1 hour after the current time. Should not exceed 20 years from the current time.
Type: Date
multipart
Whether the object consists of multiple parts that should be treated as a single file, such as with multipart uploads.
Type: boolean
responseHeaders
Download HTTP response headers can be set here.
Type: Record<string, (object | string)>
response
The optional response attributes to use during creation. Whether the response should be full or brief. A brief response will only return upload URL. This is provided to support devices that may have a limited amount of memory.
Type: {brief: boolean}
download
The download URL for the file.
Type: {url: string}
malwareScanStatus
The status of the malware scan for the file.
Type: MalwareScanStatus
malwareScanResult
The result of the malware scan for the file. Only applicable when the MalwareScanStatus is INFECTED or CANNOT_SCAN.
Type: string
malwareType
The type of malware detected. Only applicable when the MalwareScanStatus is INFECTED. Format is threat type (virus, adware, spyware, pua etc):threat name. For suspicious files the threat type is ‘unknown’.
Type: string
lastMalwareScanDate
The date and time of the last malware scan for the file.
Type: Date
size
The size of the file in bytes.
Type: number
links
Links to support files
Type: Record<string, SupportFileResponse>
md5
MD5 hash of the file object.
Type: string
lock
Lock attached to the file.
Type: FileLockResponse
stats
The statistics of the file.
Type: FileStatistics
capabilities
Describes the list of actions that can be performed on the resource by the current user.
Type: Capabilities
checkout
Checkout attached to the file.
Type: Checkout
MinimalFileResponse
Represents a minimal file entity.
createdAt
A date time expressed in ISO 8601 format.
Type: Date
createdByTrn
userTrn (string) or applicationTrn (string) or deviceTrn (string) (ActorTrn)
Type: string
updatedAt
A date time expressed in ISO 8601 format.
Type: Date
updatedByTrn
userTrn (string) or applicationTrn (string) or deviceTrn (string) (ActorTrn)
Type: string
deleted
True if the entity has been deleted
Type: boolean
name
The name of the entity
Type: string
id
The unique identifier of the entity. This is a UUID.
Type: string
resourceTrn
The TRN of the resource.
Type: string
type
The type of the file.
Type: EntityType.FILE
spaceId
The unique identifier of the space where the file is stored
Type: string
spaceTrn
TRN of the space where the entity is stored
Type: string
version
The version of the file
Type: string
FilePermissionsLocal
Permission request on the file.
inherits
Specifies if permissions are inherited from the parent resources.
Type: boolean
acl
The list of actors and their roles.
FileLockResponse
Lock attached to the file.
lockedBy
TRN of the user, application, or device that locked the file.
Type: string
lockedAt
The date and time when the file was locked.
Type: Date
reason
The reason for locking the file.
Type: string
Checkout
Checkout attached to the file.
checkedOutBy
TRN of the user, application, or device that checked out the file.
Type: string
checkedOutAt
The date and time when the file was checked out.
Type: Date
reason
The reason for checking out the file.
Type: string
FileStatistics
Represents the statistics of a file.
supportFilesSize
The sum of sizes of all the latest versions of the support files in the file in bytes
Type: number
supportFilesCount
The count of support files under the main file
Type: number
decompressedSize
The size of decompressed file in bytes. This field is only applicable for file set.
Type: number
supportFilesUpdatedAt
The date and time when the support files were last updated
Type: Date
SupportFileResponse
Support file response object
id
The unique identifier of the support file
Type: string
version
The version of the support file
Type: string
downloadUrl
Download URL of the support file
Type: string
resourceTrn
TRN of the resource
Type: string
FileGetOptionalParams
Represents the parameters for retrieving a file.
The content type is used to determine the format of the response. It overrides the file settings for the response content type which is given when creating the file.
Type: string
status
Status of the file.
Type: Status
urlDuration
The duration for which the download URL is valid.
Type: string
MalwareScanStatus
The status of the malware scan for the file.
FileUpdateParams
Represents the parameters for updating a file.
metadata
Clients may set additional information related to the file here.
Type: Record<string, (object | string)>
permissionsLocal
Update the permissions on the resource.
Type: FileUpdatePermissionsLocal
links
Links to support files
Type: Record<string, SupportFileLinkDetails>
FileUpdatePermissionsLocal
Represents a file permissions update request. Note: Both replaceAcl and updateAcl cannot be used in the same request.
inherits
Specifies if permissions are inherited from the parent resources.
Type: boolean
acl
Completely replace the existing permissions on the resource. When this field is used, all previous permissions are overwritten by the new ones.
updateAcl
Modify the current permissions by adding or removing permissions, without fully replacing the existing permissions.
Type: FileUpdateAcl
FileUpdateAcl
Allow modifications to the current permissions by adding or removing permissions, without fully replacing the existing permissions.
add
Add new roles to the existing permissions on the resource. If an actor already has a permission on the resource and is included in the request again, their existing permissions will be replaced with the new ones specified.
remove
The actors to be removed from the permissions.
SupportFileLinkParams
Represents the list of support files to be linked.
links
The links to support files
Type: Record<string, SupportFileLinkDetails>
SupportFileLinkDetails
Support file link details
id
The unique identifier of the support file
Type: string
version
The version of the support file
Type: string
FileDeleteOptionalParams
Represents the optional parameters for deleting a file.
permanent
If true, the file is permanently deleted.
Type: boolean
FileDeleteResponse
Represents the response for deleting a file.
jobId
The ID of the job associated with deletion of the file.
Type: string
FileRestoreOptionalParams
Represents the parameters for restoring a file.
targetParentId
The target parent ID where the source file needs to be restored.
Type: string
name
The new name of the file.
Type: string
FileJobResponse
File job response
jobId
The ID of the job associated with the operation on the file.
Type: string
file
File response.
Type: (FileResponse | MinimalFileResponse)
FileRestoreResponse
Extends FileJobResponse
Represents the response for restoring a file.
FileCopyResponse
Extends FileJobResponse
Represents the parameters for copying a file.
FileListOptionalParams
Represents the query parameters for listing file versions.
pageSize
The largest quantity of items to be returned in a single response (in a single page).
Type: number
status
The status query parameter is used to filter the resources based on their status.
Type: Status
nextPageToken
Pagination token that can be used as input from a previous response to get the next page of results.
Type: string
urlDuration
The file download URL’s validity duration can be set in days (d), hours (h), or minutes (m). Minimum value is 5 minutes (5m), maximum value is 7 days (7d).
Type: string
FileListResponse
Represents the response for a list of files.
items
List of file objects.
Type: (Array<FileResponse> | Array<MinimalFileResponse>)
nextPageToken
Token used to get the next result set on subsequent calls. If this is not returned, then this is the final page.
Type: string
UploadOptions
Represents the configuration options for file uploads.
multipart
Specifies whether the client will split the upload into multiple parts. If set to true, the file service will respond with a templated URL that the client can use to perform each partial upload. After completing all partial uploads, the client must call the Update File Upload endpoint.
Type: boolean
chunkSize
The size of each chunk in bytes for multipart upload. Provide the value in bytes.
Type: number
maxConcurrentRequests
The number of concurrent requests to be made during the upload process. Valid only with multipart upload.
Type: number
requestHeaders
Optional headers to be included in the upload request. Supported headers: “If-Match”, “If-None-Match”.
Type: Record<string, (string | Array<string>)>
params
Optional parameters for uploading a file.
Type: FileUploadOptionalParams
FileUploadOptionalParams
Represents the parameters for uploading a file.
urlDuration
The duration for which the upload URL is valid. @default: “60m”
Type: string
copyLinks
Include the links from the last version during a parent file’s major version change. If specified and true, the links are carried over to the new major version and if there are no links in the last version, the new version will not have any links.
Type: boolean
restrictedAccess
Set to false if the download url of the file shouldn’t be expired. Whereas when true download url expiration takes place according to the configured value
Type: boolean
fileset
Type: boolean
expiresAt
Time period when the file object gets automatically removed. Must be at least 1 hour after the current time. Should not exceed 20 years from the current time.
Type: Date
responseHeaders
Download HTTP response headers can be set here.
Type: Record<string, (object | string)>
metadata
Type: Record<string, (object | string)>
permissionsLocal
Permission request on the file.
Type: FilePermissionsLocal
multipart
True if the client will split the upload into multiple parts.
Type: boolean
urlDuration
The duration for which the upload URL is valid. @default: “60m”
Type: string
restrictedAccess
Set to false if the download url of the file shouldn’t be expired. Whereas when true download url expiration takes place according to the configured value
Type: boolean
fileset
Type: boolean
expiresAt
Time period when the file object gets automatically removed. Must be at least 1 hour after the current time. Should not exceed 20 years from the current time.
Type: Date
responseHeaders
Download HTTP response headers can be set here.
Type: Record<string, (object | string)>
metadata
Type: Record<string, (object | string)>
multipart
True if the client will split the upload into multiple parts.
Type: boolean
supportFileKey
Key of the support file. This is an optional field and the name of the file will be used as a default. This field is case sensitive. That is, the key THUMB is different from thumb.
Type: string
parentMajorVersion
Major version of the parent file. This is an optional field and the parent file’s latest major version will be used as a default.
Type: number
addToLinks
Whether the support file should be linked to the parent file.
Type: boolean
SupportFileUploadResponse
Extends FileUploadResponse
Represents the response object for uploading a file.
FileUploadResponse
Represents the response object for uploading a file.
createdAt
The unique identifier for the file. This is a UUID.
Type: Date
createdByTrn
userTrn (string) or applicationTrn (string) or deviceTrn (string) (ActorTrn)
Type: string
updatedAt
A date time expressed in ISO 8601 format.
Type: Date
updatedByTrn
userTrn (string) or applicationTrn (string) or deviceTrn (string) (ActorTrn)
Type: string
id
The upload identifier of file
Type: string
result
The input file information message : The additional information about the upload job. If upload is failed for any reason, the message will contain the error message. status : The status of the upload operation
Type: {message: string, status: UploadStatus}
size
The size of the uploaded file in bytes.
Type: number
version
The version of the uploaded file.
Type: string
md5
The md5 hash of the uploaded file, only available in upload response for singlepart files.
Type: string
fileInputUploadDetails
The input file information
Type: FileInputUploadDetails
resourceTrn
The TRN of the resource.
Type: string
FileInputUploadDetails
Represents the details of a file input upload.
fileId
The unique identifier for the file. This is a UUID.
Type: string
fileTrn
TRN of the file.
Type: string
spaceId
The unique identifier for the space where the file is stored.
Type: string
spaceTrn
The TRN of the space where the file is stored.
Type: string
name
Name of the file that was created.
Type: string
parentId
Parent Folder Id where the file was created.
Type: string
parentTrn
TRN of the parent resource.
Type: string
path
Path where file is created
Type: string
restrictedAccess
Set to false if the download url of the file shouldn’t be expired. Whereas when true download url expiration takes place according to the configured value
Type: boolean
status
The status of the upload operation, ‘UPLOADED’ status signifies a successful file upload.
Type: string
fileset
Whether the object consists of a set of multiple files that should be treated as a single file, such as with shape files.
Type: boolean
expiresAt
Time period when the file object gets automatically removed. Must be at least 1 hour after the current time. Should not exceed 20 years from the current time.
Type: Date
multipart
True if the client will split the upload into multiple parts. File service will respond with a templated URL that the client can use to do each partial upload. When the client is done, they must call the Update File Upload endpoint.
Type: boolean
responseHeaders
Download HTTP response headers can be set here.
Type: Record<string, (object | string)>
metadata
Clients may set additional information related to the file here.
Type: Record<string, (object | string)>
response
The optional response attributes to use during creation. brief - Whether the response should be full or brief. A brief response will only return upload URL.
Type: {brief: boolean}
permissionsLocal
Permission request on the file.
Type: FilePermissionsLocal
upload
The upload URL and type of upload for the file.
Type: Upload
parentType
The type of the parent file. It can be either FOLDER or FILE and parentType should be FILE when the file is a support file.
Type: string
supportFileKey
An optional key for the support file, Defaults to the file name if not specified.
Type: string
parentMajorVersion
This optional field specifies the major version of the parent file.
Type: number
addToLinks
Indicates whether the support file should be linked to the parent file.
Type: boolean
Upload
Represents an upload object that contains the URL and type of the file upload.
url
The URL to upload the file to.
Type: string
type
The type of the file upload URL.
Type: FileUploadType
FileUploadType
Represents the type of file upload.
SINGLEPART
The file is uploaded in a single part.
Type: string
MULTIPART
The file is uploaded in multiple parts.
Type: string
UploadStatus
Represents the status of the upload operation.
FileChunkUploadResponse
Represents the response for uploading a chunk of a file.
partNumber
The part number of the uploaded chunk.
Type: number
etag
The entity tag (ETag) of the uploaded chunk.
Type: string
UploadResponse
Represents the response for uploading a file.
fileId
The unique identifier for the file. This is a UUID.
Type: string
uploadId
The upload identifier of file
Type: string
FileCopyOptionalParams
Represents the parameters for copying a file.
name
Optionally provide a new name for the copied file
Type: string
versionId
Version identifier of the file.
Type: string
copySupportFiles
The copySupportFiles query parameter determines whether to copy the support files along with the main file. If specified and true, the support files are copied and links are created between the copied main file and the copied support files.
Type: boolean
overwriteExisting
The overwriteExisting query parameter determines whether to overwrite an existing resource. If specified and true, the existing resource will have a new version created with the copied content.
Type: boolean
copyAcl
The copyAcl query parameter determines whether to copy the ACL from the resource to the target resource.
Type: boolean
permissionsLocal
Permissions that are set directly for an actor on the resource itself.
Type: FilePermissionsLocal
UploadOptionalParams
Represents the configuration options for uploads.
chunkSize
The size of each chunk in bytes for multipart upload. Provide the value in bytes.
Type: number
maxConcurrentRequests
The number of concurrent requests to be made during the upload process. Valid only with multipart upload.
Type: number
FileLockOptionalParams
Represents the parameters for locking a file.
reason
Reason to lock a file
Type: string
FileCheckoutOptionalParams
Optional parameters for checking out a file.
reason
Reason to checkout a file
Type: string
FileContent
Represents the content type of a file. It can be a string, Buffer, or Blob.
Type: (string | Buffer | Blob)
JobResponse
Copyright (c) Trimble Inc.
id
The unique identifier of the job.
Type: string
resourceTrn
TRN of the resource.
Type: string
type
The type of job.
Type: JobType
status
The status of the job.
Type: JobStatus
createdAt
The date and time when the job was created, expressed in ISO 8601 format.
Type: Date
createdByTrn
The unique identifier of the user, application, or device that created the job (ActorTrn).
Type: string
message
The message associated with the job.
Type: string
JobResponse
Represents a response object for a job.
id
The unique identifier of the job.
Type: string
resourceTrn
TRN of the resource.
Type: string
type
The type of job.
Type: JobType
status
The status of the job.
Type: JobStatus
createdAt
The date and time when the job was created, expressed in ISO 8601 format.
Type: Date
createdByTrn
The unique identifier of the user, application, or device that created the job (ActorTrn).
Type: string
message
The message associated with the job.
Type: string
JobType
The type of job
JobStatus
The status of the job
EventResponse
Copyright (c) Trimble Inc.
eventType
Type of event that occurred.
Type: EventType
spaceId
Space identifier.
Type: string
uploadId
The unique identifier of the upload.
Type: string
percentage
Percentage of the file uploaded.
Type: number
EventResponse
Events response model.
eventType
Type of event that occurred.
Type: EventType
spaceId
Space identifier.
Type: string
uploadId
The unique identifier of the upload.
Type: string
percentage
Percentage of the file uploaded.
Type: number
Capabilities
Copyright (c) Trimble Inc.
canCreate
Indicates if the user has the capability to create an upload or create a folder under the resource
Type: boolean
canRead
Indicates if the user has the capability to read the given resource
Type: boolean
canDelete
Indicates if the user has the capability to perform delete operation on the resource
Type: boolean
canUpdate
Indicates if the user has the capability to perform mutation operation on the resource
Type: boolean
canManageAccess
Indicates if the user has the capability to modify the resource permissions
Type: boolean
canLock
Indicates if the user has the capability to lock the file
Type: boolean
canUnlock
Indicates if the user has the capability to unlock the file
Type: boolean
canCheckout
Indicates if the user has the capability to checkout the file
Type: boolean
canCheckin
Indicates if the user has the capability to checkin the file
Type: boolean
Capabilities
Describes the list of actions that can be performed on the resource by the current user.
canCreate
Indicates if the user has the capability to create an upload or create a folder under the resource
Type: boolean
canRead
Indicates if the user has the capability to read the given resource
Type: boolean
canDelete
Indicates if the user has the capability to perform delete operation on the resource
Type: boolean
canUpdate
Indicates if the user has the capability to perform mutation operation on the resource
Type: boolean
canManageAccess
Indicates if the user has the capability to modify the resource permissions
Type: boolean
canLock
Indicates if the user has the capability to lock the file
Type: boolean
canUnlock
Indicates if the user has the capability to unlock the file
Type: boolean
canCheckout
Indicates if the user has the capability to checkout the file
Type: boolean
canCheckin
Indicates if the user has the capability to checkin the file
Type: boolean
ExportResponse
Copyright (c) Trimble Inc.
createdAt
A date time expressed in ISO 8601 format.
Type: Date
createdByTrn
userTrn (string) or applicationTrn (string) or deviceTrn (string) (ActorTrn)
Type: string
updatedAt
A date time expressed in ISO 8601 format.
Type: Date
updatedByTrn
userTrn (string) or applicationTrn (string) or deviceTrn (string) (ActorTrn)
Type: string
id
The unique identifier of the entity
Type: string
exportTrn
TRN of the resource
Type: string
spaceId
The unique identifier of the space
Type: string
spaceTrn
TRN of the resource
Type: string
resourceId
The unique identifier of the target folder
Type: string
resourceTrn
TRN of the resource
Type: string
output
The output of the export
Type: Output
status
The status of the export job
Type: ExportStatus
ExportResponse
Represents an export entity.
createdAt
A date time expressed in ISO 8601 format.
Type: Date
createdByTrn
userTrn (string) or applicationTrn (string) or deviceTrn (string) (ActorTrn)
Type: string
updatedAt
A date time expressed in ISO 8601 format.
Type: Date
updatedByTrn
userTrn (string) or applicationTrn (string) or deviceTrn (string) (ActorTrn)
Type: string
id
The unique identifier of the entity
Type: string
exportTrn
TRN of the resource
Type: string
spaceId
The unique identifier of the space
Type: string
spaceTrn
TRN of the resource
Type: string
resourceId
The unique identifier of the target folder
Type: string
resourceTrn
TRN of the resource
Type: string
output
The output of the export
Type: Output
status
The status of the export job
Type: ExportStatus
ExportStatus
The status of the export job.
Output
Represents an output of an export.
url
The download URL of the export
Type: string
ResourceGetOptionalParams
Represents the parameters for retrieving a resource.
The content type is used to determine the format of the response. It overrides the file settings for the response content type which is given when creating the file.
Type: string
status
Status of the resource.
Type: Status
urlDuration
The duration for which the download URL is valid.
Type: string
ResourceBatchGetParams
Extends ResourceGetOptionalParams
Represents the parameters for retrieving a resource in batch.
ids
List of IDs of the resources to be fetched
paths
List of paths of the resources to be fetched
ResourceBatchResponse
Represents the response for a batch of resources.
items
List of items in the batch response.
Type: (Array<(FolderResponse | FileResponse)> | Array<(MinimalFolderResponse | MinimalFileResponse)>)
invalidItems
List of invalid items in the batch response.
Type: Array<InvalidItems>
InvalidItems
Represents the invalid items in a batch response.
id
Unique identifier of the resource
Type: string
path
Path of the resource
Type: string
status
HTTP status code
Type: number
type
Type of the error
Type: string
title
Title of the error
Type: string
detail
Detailed description of the error
Type: string
code
Error code
Type: string