Skip to content

cms/cmis

Documentation

Overview

Classes

Cmis

getSession()

Gets a new CMIS session instance to interact with the repository.

ts
static getSession(): Session;

Returns

  • Type: Session
  • Description: A new Session instance.

getAccessDefinitions()

Retrieves access control definitions for a specific path and method.

ts
static getAccessDefinitions(path: string, method: string): void;
ParameterTypeDescription
pathstringThe path of the CMIS object.
methodstringThe operation method (e.g., Cmis.METHOD_READ, Cmis.METHOD_WRITE).

Returns

  • Type: void
  • Description: A list of access definitions.

Folder

getId()

Gets the unique identifier of the folder.

ts
getId(): string;

Returns

  • Type: string
  • Description: The folder ID.

getName()

Gets the name of the folder.

ts
getName(): string;

Returns

  • Type: string
  • Description: The folder name.

createFolder()

Creates a new folder within this folder.

ts
createFolder(properties: any): Folder;
ParameterTypeDescription
propertiesanyA map of CMIS properties for the new folder (must include Cmis.NAME).

Returns

  • Type: Folder
  • Description: The newly created Folder object.

createDocument()

Creates a new document within this folder.

ts
createDocument(properties: any, contentStream: ContentStream, versioningState: string): Document;
ParameterTypeDescription
propertiesanyA map of CMIS properties for the new document (must include Cmis.NAME).
contentStreamContentStreamThe content stream containing the document's binary data.
versioningStatestringThe versioning state (e.g., Cmis.VERSIONING_STATE_MAJOR).

Returns

  • Type: Document
  • Description: The newly created Document object.

getChildren()

Retrieves the children of this folder.

ts
getChildren(): void;

Returns

  • Type: void
  • Description: A list of generic CmisObject wrappers for the children.

getPath()

Gets the path of the folder.

ts
getPath(): string;

Returns

  • Type: string
  • Description: The folder path.

isRootFolder()

Checks if this folder is the root folder of the repository.

ts
isRootFolder(): boolean;

Returns

  • Type: boolean
  • Description: True if it is the root folder, false otherwise.

getFolderParent()

Gets the parent folder of this folder.

ts
getFolderParent(): Folder;

Returns

  • Type: Folder
  • Description: The parent Folder object.

delete()

Deletes this folder (must be empty to succeed).

ts
delete(): void;

Returns

  • Type: void
  • Description:

rename()

Renames this folder.

ts
rename(newName: string): void;
ParameterTypeDescription
newNamestringThe new name for the folder.

Returns

  • Type: void
  • Description:

deleteTree()

Deletes this folder and all its contents recursively.

ts
deleteTree(): void;

Returns

  • Type: void
  • Description:

getType()

Gets the type definition of the folder.

ts
getType(): TypeDefinition;

Returns

  • Type: TypeDefinition
  • Description: The folder's TypeDefinition.

Document

getId()

Gets the unique identifier of the document.

ts
getId(): string;

Returns

  • Type: string
  • Description: The document ID.

getName()

Gets the name of the document.

ts
getName(): string;

Returns

  • Type: string
  • Description: The document name.

getType()

Gets the type definition of the document.

ts
getType(): TypeDefinition;

Returns

  • Type: TypeDefinition
  • Description: The document's TypeDefinition.

getPath()

Gets the path of the document.

ts
getPath(): string;

Returns

  • Type: string
  • Description: The document path.

delete()

Deletes this document.

ts
delete(): void;

Returns

  • Type: void
  • Description:

getContentStream()

Gets the binary content stream of the document.

ts
getContentStream(): ContentStream;

Returns

  • Type: ContentStream
  • Description: The ContentStream object, or `null` if the document has no content.

getSize()

Gets the size of the document's content stream in bytes.

ts
getSize(): number;

Returns

  • Type: number
  • Description: The size in bytes.

rename()

Renames this document.

ts
rename(newName: string): void;
ParameterTypeDescription
newNamestringThe new name for the document.

Returns

  • Type: void
  • Description: