Skip to main content
POST
Retrieve Subgraph

Headers

authorization
string | null

Path Parameters

org_id
string<uuid>
required

Body

application/json

Request body for POST /orgs/{org_id}/search/retrieve.

See docs/notes/features/rag/RETRIEVAL_API_PLAN.md for the full API design.

query
string
required

Natural-language query or keywords

top_k
integer | null
default:5

Number of entry-point matches before graph expansion

Required range: 1 <= x <= 50
expansion_depth
enum<string> | null
default:none

How aggressively Pass 2 walks the graph. 'none' (default) returns only the ranked matches with no graph expansion; 'shallow'/'standard'/'deep' progressively include children, parents, and connection endpoints.

Available options:
none,
shallow,
standard,
deep
scope
RetrievalScopeRequest · object | null

Optional scope filters

include_raw_text
boolean | null
default:false

Return the prose text_content per node (for debugging / eval)

Response

Successful Response

Response for POST /orgs/{org_id}/search/retrieve.

query
string
required
matches
SubgraphMatch · object[]
required
nodes
SubgraphNode · object[]
required
connections
SubgraphConnection · object[]
required