From 99c7c419115b79f0f4d0679c5565f5ecfdb9b6df Mon Sep 17 00:00:00 2001 From: cthomas Date: Tue, 21 Oct 2025 13:03:36 -0700 Subject: [PATCH] feat: add descriptive title to groups routes for docs search [LET-5760] (#5607) feat: add descriptive title to groups routes for docs search --- fern/openapi.json | 8 ++++---- letta/server/rest_api/routers/v1/agents.py | 6 +++--- 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/fern/openapi.json b/fern/openapi.json index 53a1f26a..5781b191 100644 --- a/fern/openapi.json +++ b/fern/openapi.json @@ -6860,9 +6860,9 @@ "/v1/agents/{agent_id}/groups": { "get": { "tags": ["agents"], - "summary": "List Agent Groups", - "description": "Lists the groups for an agent", - "operationId": "list_agent_groups", + "summary": "List Groups For Agent", + "description": "Lists the groups for an agent.", + "operationId": "list_groups_for_agent", "parameters": [ { "name": "agent_id", @@ -6989,7 +6989,7 @@ "items": { "$ref": "#/components/schemas/Group" }, - "title": "Response List Agent Groups" + "title": "Response List Groups For Agent" } } } diff --git a/letta/server/rest_api/routers/v1/agents.py b/letta/server/rest_api/routers/v1/agents.py index f490410e..c4c38b82 100644 --- a/letta/server/rest_api/routers/v1/agents.py +++ b/letta/server/rest_api/routers/v1/agents.py @@ -1603,8 +1603,8 @@ async def reset_messages( ) -@router.get("/{agent_id}/groups", response_model=list[Group], operation_id="list_agent_groups") -async def list_agent_groups( +@router.get("/{agent_id}/groups", response_model=list[Group], operation_id="list_groups_for_agent") +async def list_groups_for_agent( agent_id: str = PATH_VALIDATORS[AgentState.__id_prefix__], manager_type: str | None = Query(None, description="Manager type to filter groups by"), server: "SyncServer" = Depends(get_letta_server), @@ -1621,7 +1621,7 @@ async def list_agent_groups( ), order_by: Literal["created_at"] = Query("created_at", description="Field to sort by"), ): - """Lists the groups for an agent""" + """Lists the groups for an agent.""" actor = await server.user_manager.get_actor_or_default_async(actor_id=headers.actor_id) logger.info("in list agents with manager_type", manager_type) return await server.agent_manager.list_groups_async(