@cpod/sdk - v0.2.7
    Preparing search index...

    Function getFoldersAndFiles

    • Get folders and files in a hierarchical structure

      Parameters

      Returns Promise<FoldersAndFilesResponse>

      Folders and files in the requested location

      401 - Not authenticated

      import { getFoldersAndFiles } from "@cpod/sdk";

      // Get root level folders and files
      const root = await getFoldersAndFiles();

      // Get contents of a specific folder
      const contents = await getFoldersAndFiles({ folder_id: "folder-123" });
      console.log(`${contents.folders.length} folders, ${contents.files.length} files`);