---
title: "Check whether a node is a descendant of another"
method: GET
path: "/api/v1/nodes/{nodeId}/is-descendant"
tags: ["Nodes"]
---

# Check whether a node is a descendant of another

`GET /api/v1/nodes/{nodeId}/is-descendant`

## Request

- Base URL: `https://api-docs.busabase.com`
- URL: `https://api-docs.busabase.com/api/v1/nodes/{nodeId}/is-descendant`
- Auth: none declared

## Path parameters

- `nodeId` string, required: The node walked UPWARDS from — the possible descendant.

## Query parameters

- `potentialAncestorId` string, required: The node looked for on the way up. Answers "is `nodeId` inside this one?", not the reverse — swapping the two silently returns the wrong answer rather than an error.

## Response `200`

Server-authoritative parentId-chain walk from nodeId up to potentialAncestorId. Used to gate cross-branch drag-and-drop drops in the sidebar, since the full tree is no longer guaranteed to be loaded client-side (depth-bounded lazy load) — a purely local walk could wrongly allow dropping a folder into its own unloaded descendant.

- object
  - `isDescendant` boolean, required

---

[API](https://skmtc.dev/busabase/apis/busabase-api.md) · [All operations](https://skmtc.dev/busabase/apis/busabase-api/llms.txt) · [OpenAPI document](https://skmtc.dev/busabase/apis/busabase-api/revisions/bc6a7d5ff4c1?raw)
