?
CLIAPI-37
feature api
Created: 2026-01-04 Updated: 2026-01-04
Relationships Loading...
Attachments
Loading...
Comments (2)
qa-agent · 2026-01-04
[QA] ✅ VERIFICATION PASSED All requirements verified and implementation is production-ready: **Testing Results:** - ✅ 742 unit tests passing (including 37 new tests) - ✅ Manual API testing successful - ✅ All query parameters working correctly - ✅ Built-in agents (Explore, Plan) properly returned - ✅ User/project/plugin agent discovery working - ✅ Source filtering functioning as expected **Code Quality:** - ✅ Follows SkillReader/SkillInfo patterns - ✅ Comprehensive error handling - ✅ Proper type annotations and docstrings - ✅ No regressions introduced **Files Added/Modified:** - AgentInfo model: src/cli_agent_api/models/config.py:363-390 - AgentReader service: src/cli_agent_api/services/agent_reader.py (375 lines) - GET /v1/config/agents: src/cli_agent_api/routers/config.py:341-381 - Test coverage: 31 AgentReader tests + 6 router tests See full QA report: /tmp/qa-CLIAPI-37.md **Recommendation:** Ready for merge to main.
agent · 2026-01-04
Fixed by implementing GET /v1/config/agents endpoint: **What was implemented:** 1. Added `AgentInfo` model in `src/cli_agent_api/models/config.py:363-390` with fields: - name, description, type (builtin/custom), source, prompt, model, allowed_tools 2. Created `AgentReader` service in `src/cli_agent_api/services/agent_reader.py`: - Discovers built-in agents (Explore, Plan) - Scans ~/.claude/agents/, .claude/agents/, and plugin agents directories - Supports both markdown (.md with YAML frontmatter) and JSON agent definitions 3. Added GET /v1/config/agents endpoint in `src/cli_agent_api/routers/config.py:341-381`: - Query params: working_dir, plugin_dirs, source (builtin/user/project/plugin/all), include_builtin - Returns list of AgentInfo objects **Tests added:** - 31 unit tests in `tests/unit/test_agent_reader.py` - 6 router tests in `tests/unit/test_config_router.py::TestGetAgents` **Verification:** - All 742 tests pass - Lint check passes for new code