Get Shortest Path
Find all shortest paths between two nodes using KuzuDB ALL SHORTEST.
Note: KuzuDB does not support parameter binding in recursive relationship bounds, so max_depth is interpolated as a validated literal (ge=2, le=20).
Returns all shortest paths (same hop count, different routes) so the frontend can render every connection between the two nodes. The overview graph may not contain all intermediate nodes, so paths are drawn between visible positions.
Query Parameters
from_id*From Id
Source node ID
to_id*To Id
Target node ID
max_depth?Max Depth
Default
10Range
2 <= value <= 20Response Body
application/json
application/json
curl -X GET "http://127.0.0.1:14242/graph/shortest-path?from_id=string&to_id=string"null{
"detail": [
{
"loc": [
"string"
],
"msg": "string",
"type": "string",
"input": null,
"ctx": {}
}
]
}