feat: add descriptive title to groups routes for docs search [LET-5760] (#5607)

feat: add descriptive title to groups routes for docs search
This commit is contained in:
cthomas
2025-10-21 13:03:36 -07:00
committed by Caren Thomas
parent 3cf17359a9
commit 99c7c41911
2 changed files with 7 additions and 7 deletions

View File

@@ -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"
}
}
}

View File

@@ -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(