feat(threads): paginate full history via summaries endpoint (#1022)

* feat(threads): add paginated summaries API and load full history

* fix(threads): address summaries review feedback

- validate summaries sort params and log gateway failures
- page frontend thread summaries without stale query keys or silent truncation
- export router modules and tighten thread list typing

Refs: 2901804166, 2901804176, 2901804179, 2901804180, 2901804183, 2901804187, 2901804191

---------

Co-authored-by: Willem Jiang <willem.jiang@gmail.com>
This commit is contained in:
aworki
2026-03-09 16:08:02 +08:00
committed by GitHub
parent 959b4f2b09
commit 2f47f1ced2
7 changed files with 361 additions and 24 deletions

View File

@@ -15,6 +15,7 @@ from src.gateway.routers import (
models,
skills,
suggestions,
threads,
uploads,
)
@@ -139,6 +140,10 @@ This gateway provides custom endpoints for models, MCP configuration, skills, an
"name": "channels",
"description": "Manage IM channel integrations (Feishu, Slack, Telegram)",
},
{
"name": "threads",
"description": "Thread summary and list endpoints for lightweight UI loading",
},
{
"name": "health",
"description": "Health check and system status endpoints",
@@ -176,6 +181,9 @@ This gateway provides custom endpoints for models, MCP configuration, skills, an
# Channels API is mounted at /api/channels
app.include_router(channels.router)
# Threads API is mounted at /api/threads
app.include_router(threads.router)
@app.get("/health", tags=["health"])
async def health_check() -> dict:
"""Health check endpoint.