INNER CODE UNIT · Python

fetch_folders

Squarespace/datasheets · datasheets/client.py:303

    def fetch_folders(self, only_mine=False):
        """Fetch all folders shared with this account

        Args:
            only_mine (bool): If True, limit results to only those folders owned by this user

        Returns:
            pandas.DataFrame: One row per folder listing folder name, ID, most recent modified
            time, and webview link to the folder
        """
        fields = 'files(name,id,modifiedTime,webViewLink,owners(me))'
        raw_info = self._fetch_info_on_items(kind='folder', only_mine=only_mine, fields=fields)
        return pd.DataFrame(raw_info, columns=['name', 'id', 'modifiedTime', 'webViewLink'])

    def fetch_workbook(self, filename=None, file_id=None):
        """Fetch a workbook

        Either filename (i.e. title) or file_id should be provided. Providing file_id

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…