Folder

create(vaultId, name, parentId)

  • vaultId (string, required)

  • name (string, required) - folder name

  • options (NodeCreateOptions, optional) - parent id, etc.

  • returns Promise<{ folderId, transactionId }> - Promise with new folder id & corresponding transaction id

example
const { folderId } = await akord.folder.create(vaultId, "my first folder");

rename(folderId, name)

  • folderId (string, required)

  • name (string, required) - new folder name

  • returns Promise<{ transactionId }> - Promise with corresponding transaction id

example
const { transactionId } = await akord.folder.rename(folderId, "my first folder");

move(folderId, parentId)

Move the given folder along with its content to a different folder (parent):

  • folderId (string, required)

  • parentId (string, required) - new parent folder id

  • returns Promise<{ transactionId }> - Promise with corresponding transaction id

example

revoke(folderId)

Revoke the given folder along with the sub-tree of stacks and folders:

  • folderId (string, required)

  • returns Promise<{ transactionId }> - Promise with corresponding transaction id

example

restore(folderId)

Restore the given folder along with the sub-tree of stacks and folders:

  • folderId (string, required)

  • returns Promise<{ transactionId }> - Promise with corresponding transaction id

example

delete(folderId)

Remove the folder along with the sub-tree of stacks and folders from the vault:

  • folderId (string, required)

  • returns Promise<{ transactionId }> - Promise with corresponding transaction id

example

get(folderId, options)

  • folderId (string, required)

  • options (GetOptions, optional)

  • returns Promise<Folder> - Promise with the folder object

example

listAll(vaultId, options)

  • vaultId (string, required)

  • options (ListOptions, optional)

  • returns Promise<Array<Folder>> - Promise with all folders within given vault

example

list(vaultId, options)

  • vaultId (string, required)

  • options (ListOptions, optional)

  • returns Promise<{ items, nextToken }> - Promise with paginated folders within given vault

example

Last updated

Was this helpful?