Smartsheet.Api.Internal.FolderResourcesImpl.ListFolders C# (CSharp) Method

ListFolders() public method

Gets a list of the top-level child Folders within the specified Folder.

This operation supports pagination of results. For more information, see Paging.

It mirrors To the following Smartsheet REST API method:
GET /folders/{folderId}/folders

if any argument is null or empty string if there is any problem with the REST API request if there is any problem with the REST API authorization (access token) if the resource cannot be found if the REST API service is not available (possibly due To rate limiting) if there is any other error during the operation
public ListFolders ( long folderId, PaginationParameters paging ) : PaginatedResult
folderId long the folderId
paging PaginationParameters the pagination information
return PaginatedResult
        public virtual PaginatedResult<Folder> ListFolders(long folderId, PaginationParameters paging)
        {
            StringBuilder path = new StringBuilder("folders/" + folderId + "/folders");
            if (paging != null)
            {
                path.Append(paging.ToQueryString());
            }
            return this.ListResourcesWithWrapper<Folder>(path.ToString());
        }

Usage Example

Example #1
0
        public virtual void TestListFolders()
        {
            server.setResponseBody("../../../TestSDK/resources/listFolders.json");

            IList <Folder> folders = folderResource.ListFolders(12345L);

            Assert.AreEqual(2, folders.Count);
        }
All Usage Examples Of Smartsheet.Api.Internal.FolderResourcesImpl::ListFolders