From 2e5425f7f385257f5a8c517e1b73456122466ccd Mon Sep 17 00:00:00 2001 From: Sam Catlow Date: Wed, 29 Jul 2026 07:31:35 +1000 Subject: [PATCH] fix: add missing AgentInfo type and AgentReader interface --- internal/gateway/gateway.go | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/internal/gateway/gateway.go b/internal/gateway/gateway.go index 514d583f2..e1fa39cdd 100644 --- a/internal/gateway/gateway.go +++ b/internal/gateway/gateway.go @@ -114,6 +114,19 @@ type TaskCreator interface { // valid state transitions; see gateway.tasks.go's StoreTaskController // for the reference implementation. When nil on a Router, /approve and // /cancel return "not configured". +// AgentInfo is a lightweight agent summary for /agents. +type AgentInfo struct { + ID int64 + Title string + Status string + Identity string +} + +// AgentReader is the read surface /agents uses. +type AgentReader interface { + AgentList(ctx context.Context) ([]AgentInfo, error) +} + type TaskController interface { // Approve moves a waiting_human task back to queued. Returns an // error (surfaced to the user, not the LLM) if the task doesn't