GET /api/agents
List all active agent adapters with health and execution statistics.200
| Field | Type | Description |
|---|---|---|
type | string | Adapter type identifier |
name | string | Display name |
description | string | Human-readable description |
capabilities | string[] | List of capability tags |
configured | boolean | Adapter has required config |
healthy | boolean | Last health check passed |
lastActivity | ISO string | Timestamp of last task completion |
stats.completed | number | Total tasks completed |
stats.failed | number | Total tasks failed |
stats.avgDuration | number | Average execution time in ms |
GET /api/agents/types
List registered adapter type identifiers.200
Agent Adapter Interface
Adapters are registered viagetAgentRegistry() from src/adapters/registry.ts. Each adapter implements:
Health Checks
Agent health is checked on demand whenGET /api/agents is called. Each adapter runs its own healthCheck() which typically:
- Verifies API key is present
- Makes a lightweight probe request to the underlying AI service
- Returns
healthy: booleanandlatencyMs
degraded or unhealthy (visible at GET /api/health).
Registering Custom Adapters
Custom adapters are registered programmatically at startup:Related
- Agent Sessions API - Start and monitor execution sessions
- Tasks API - Create tasks that agents process
- Health API - System-wide health including agent status
- profclaw agent - Inspect agents from the CLI