Skip to main content

JSON Protocol

This page summarizes the main HTTP payload shapes currently used by the web UI.

Common Types

Node

{
"id": "method:...",
"kind": "method",
"label": "foo",
"fqname": "MyPkg.foo",
"location": {"file": "src/a.jl", "line": 42, "column": 1},
"metadata": {"external": true, "external_group": "external_package"}
}

metadata.external_group is optional for external method nodes:

  • base_stdlib
  • external_package

Other useful optional metadata fields include:

  • virtual
  • synthetic
  • overload_style

Edge

{
"id": "edge:...",
"kind": "call_possible",
"source": "method:...",
"target": "method:...",
"confidence": "possible",
"evidence": {
"kinds": ["call_possible"],
"engine": "da_source",
"file": "src/a.jl",
"line": 55
}
}

evidence contract:

  • evidence.kinds is required for every edge.
  • evidence.kinds is an array of edge-kind strings.
  • evidence.kinds always includes the current top-level kind.
  • Aggregated edges may include multiple values in evidence.kinds.
  • evidence.engine = "da_source" refers to the DepAtlasSource engine id.

confidence enum:

  • exact
  • inferred
  • possible
  • dynamic

confidence should be interpreted as evidence class, not certainty.

Endpoints

POST /api/v1/tasks

{
"analysis_path": "/abs/path/project",
"refresh_mode": "full",
"jet_auto_entrypoints": 12,
"entrypoints": [{"module": "Main", "function": "run", "signature": ["String"]}],
"analysis_profile": "default"
}

This endpoint creates a new analysis task.

GET /api/v1/tasks/{task_id}

This endpoint returns task lifecycle status, normalized config, progress, and any eventual snapshot id.

GET /api/v1/snapshots/{snapshot_id}/summary

This endpoint returns snapshot counts, supported layers, and diagnostics.

POST /api/v1/snapshots/{snapshot_id}/graph/query

This endpoint returns filtered nodes, edges, and pagination state for one graph layer.

The request body includes:

  • layer
  • filters
  • optional page

Common filter fields include:

  • edge_kinds
  • confidence_min
  • module_prefix
  • show_overloaded_functions
  • show_base_stdlib_calls
  • show_external_package_calls

POST /api/v1/snapshots/{snapshot_id}/reachability/query

This endpoint returns a bounded reachability subgraph for one seed node.

The request body includes:

  • layer
  • node_id
  • optional direction
  • optional depth
  • optional filters
  • optional limits

GET /api/v1/snapshots/{snapshot_id}/node?id=<node_id>

This endpoint returns the node plus incoming and outgoing neighborhood information.

GET /api/v1/source?file=<abs-or-rel>&line=<n>&snapshot_id=<optional>

This endpoint returns a source snippet centered around one line.

If snapshot_id is provided, the backend resolves relative paths against that snapshot's project root.

GET /api/v1/fs/list?path=<optional>

This endpoint returns directory entries for the path browser used by the web UI.

Notes

  • The web UI currently uses the /api/v1/... namespace throughout.
  • Graph export JSON is documented separately in Export JSON.