Skip to content

feat(folders): add new properties to support sub-folders - #81

Merged
Pedro Kehl (pedrokehl) merged 3 commits into
mainfrom
sub-folders
Aug 18, 2026
Merged

feat(folders): add new properties to support sub-folders#81
Pedro Kehl (pedrokehl) merged 3 commits into
mainfrom
sub-folders

Conversation

@pedrokehl

Copy link
Copy Markdown
Collaborator

No description provided.

Copilot AI lite review requested due to automatic review settings August 17, 2026 13:28
@pedrokehl
Pedro Kehl (pedrokehl) requested a review from a team as a code owner August 17, 2026 13:28

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR extends the Scenario Folders endpoint model to support nested folder trees (sub-folders) by adding new folder properties, new listing filters for parent/descendant expansion, and corresponding tool + test updates.

Changes:

  • Extend Folder to include hierarchy/tree fields (path, parentId, hasChildren, children, and subtree totals).
  • Add parentId / childrenDepth support to folders.list(), plus parentId support for create() and update().
  • Update MCP/CLI tool schemas and Jest mocks/tests to cover nested folders.

Reviewed changes

Copilot reviewed 8 out of 8 changed files in this pull request and generated 1 comment.

Show a summary per file
File Description
test/mocks/folders/update.json Expands the mocked update response with new hierarchy fields.
test/mocks/folders/list.json Updates list mock to include hierarchy fields and a children array for nested folders.
test/mocks/folders/list-children.json Adds a new mock for listing children of a specific parent folder.
test/mocks/folders/create.json Expands top-level create mock with hierarchy fields and subtree totals.
test/mocks/folders/create-nested.json Adds a new mock for creating a nested (child) folder.
test/folders.spec.ts Adds/updates unit tests for listing children/descendants and creating/moving nested folders.
src/endpoints/folders.ts Adds new Folder fields and new list/create/update inputs to support sub-folders.
src/endpoints/folders.tools.ts Extends tool input schemas/examples for parentId and childrenDepth.
Suppressed comments (1)

test/folders.spec.ts:101

  • This test validates the request body for moving a folder to the top level, but it doesn't assert the response reflects the move. Returning a response with parentId=null and asserting it would make the test more realistic and cover the SDK’s returned value.
            let requestBody: unknown;
            mockFetch('PATCH https://make.local/api/v2/scenarios-folders/1576', foldersUpdateMock, req => {
                requestBody = req.body;
            });


💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

Comment thread test/folders.spec.ts
@pedrokehl
Pedro Kehl (pedrokehl) merged commit da59330 into main Aug 18, 2026
4 checks passed
@pedrokehl
Pedro Kehl (pedrokehl) deleted the sub-folders branch August 18, 2026 08:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants