Files
DB-GPT/packages
alan.cl 0868c23988 fix(connector): route order + frontend list URL trailing slash
Two backend integration bugs surfaced when /construct/connectors loaded:

1. GET /pending-confirms returned {Connector 'pending-confirms' not found}
   because the route was defined AFTER GET /{connector_id}, so FastAPI
   matched the catch-all first and treated 'pending-confirms' as a
   connector_id. HITL polling never reached the queue endpoint.

   Move /pending-confirms, /confirm, and ConfirmRequest BEFORE the
   /{connector_id} routes so FastAPI matches the fixed paths first.

2. GET /api/v2/serve/connectors (no trailing slash) hit DB-GPT's static
   Next-export fallback (404 HTML), because FastAPI registers the list
   route as GET / under api_prefix and the auto-redirect was intercepted.
   Frontend useConnectors() used the bare base URL.

   Add API_BASE_LIST = `${API_BASE}/` constant and use it for the list
   (GET /) and create (POST /) calls. Single-resource calls keep the
   bare base + "/{id}" form.
2026-05-27 11:31:47 +08:00
..