From d1bcae69b91906540ab5ac71cf2db9be22dbd6e6 Mon Sep 17 00:00:00 2001 From: rayhpeng Date: Sun, 12 Apr 2026 16:17:09 +0800 Subject: [PATCH] docs: add run-level API endpoints to CLAUDE.md routers table --- backend/CLAUDE.md | 3 +++ 1 file changed, 3 insertions(+) diff --git a/backend/CLAUDE.md b/backend/CLAUDE.md index 563034c2f..6ff7ea258 100644 --- a/backend/CLAUDE.md +++ b/backend/CLAUDE.md @@ -216,6 +216,9 @@ FastAPI application on port 8001 with health check at `GET /health`. | **Threads** (`/api/threads/{id}`) | `DELETE /` - remove DeerFlow-managed local thread data after LangGraph thread deletion; unexpected failures are logged server-side and return a generic 500 detail | | **Artifacts** (`/api/threads/{id}/artifacts`) | `GET /{path}` - serve artifacts; active content types (`text/html`, `application/xhtml+xml`, `image/svg+xml`) are always forced as download attachments to reduce XSS risk; `?download=true` still forces download for other file types | | **Suggestions** (`/api/threads/{id}/suggestions`) | `POST /` - generate follow-up questions; rich list/block model content is normalized before JSON parsing | +| **Thread Runs** (`/api/threads/{id}/runs`) | `POST /` - create background run; `POST /stream` - create + SSE stream; `POST /wait` - create + block; `GET /` - list runs; `GET /{rid}` - run details; `POST /{rid}/cancel` - cancel; `GET /{rid}/join` - join SSE; `GET /{rid}/messages` - paginated messages `{data, has_more}`; `GET /{rid}/events` - full event stream; `GET /../messages` - thread messages with feedback; `GET /../token-usage` - aggregate tokens | +| **Feedback** (`/api/threads/{id}/runs/{rid}/feedback`) | `PUT /` - upsert feedback; `DELETE /` - delete user feedback; `POST /` - create feedback; `GET /` - list feedback; `GET /stats` - aggregate stats; `DELETE /{fid}` - delete specific | +| **Runs** (`/api/runs`) | `POST /stream` - stateless run + SSE; `POST /wait` - stateless run + block; `GET /{rid}/messages` - paginated messages by run_id `{data, has_more}` (cursor: `after_seq`/`before_seq`); `GET /{rid}/feedback` - list feedback by run_id | Proxied through nginx: `/api/langgraph/*` → LangGraph, all other `/api/*` → Gateway.