Agent Management
Agents are the top-level entity in Kurral. Every session, scan, and metric is tied to an agent. Register your agents, track their health, and manage configuration via the dashboard or API.
Agents are the top-level entity in Kurral. Every session, scan, and metric is tied to an agent. Register your agents, track their health, and manage configuration via the dashboard or API.
Registering an Agent
Dashboard
- Go to Agents in the sidebar
- Click Register Agent
- Fill in: - Agent key (required) — immutable slug, minimum 3 characters (e.g.,
support-bot). This is what you pass in thex-kurral-agentheader. - Description — what the agent does - Model — the LLM model (for labeling; does not affect proxy routing) - Environment —production,staging, ordevelopment - Click Register
Note: The agent key cannot be changed after creation. Choose a descriptive, stable slug.
API
curl -X POST https://kurral-api.onrender.com/api/web/agents \
-H "Authorization: Bearer YOUR_CLERK_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"agent_key": "support-bot",
"description": "Customer support agent",
"model": "claude-sonnet-4-5",
"environment": "production"
}'
Auto-Registration via Proxy
When you send an LLM call through the proxy with an x-kurral-agent header that doesn't match an existing agent, Kurral automatically creates the agent for you.
Agent Detail View
Each agent has four tabs:
Overview
- Health score (0-100) — calculated from success rate, latency, and error frequency
- Status — healthy, degraded, critical, offline, or inactive
- Sessions chart — 7-day session volume with real data
- Configuration — agent key, ID, model, environment
- Recent sessions — last 5 sessions with status and timing
Sessions
Full list of agent sessions with:
- Status (completed, running, failed, blocked)
- Duration
- Token count
- Tool calls
- Model used
- Timestamp
Click any session to open the Flight Recorder view.
Secure
Security scan history for this agent:
- Security score trend
- Finding counts by severity
- Run Scan button to trigger a new scan
- Click any scan to see detailed findings
Settings
- Edit display name and description
- Change model label and environment
- Copy agent ID and agent key
- Delete agent
Health Score
The health score (0-100) is calculated from the agent's recent performance:
| Factor | Weight | Description |
|---|---|---|
| Success rate | High | Percentage of sessions that completed without errors |
| Latency | Medium | Average response time relative to baseline |
| Error frequency | High | Rate of failed or blocked sessions |
| Score | Status | Meaning |
|---|---|---|
| 80-100 | Healthy | Agent is performing well |
| 60-79 | Degraded | Some issues, investigate |
| 40-59 | Critical | Significant problems |
| 1-39 | Offline | Agent is not functioning |
| 0 | Inactive | No recent activity |
Agent Metrics
Access metrics for any agent via the dashboard or API:
# Get 7-day metrics
curl https://kurral-api.onrender.com/api/web/agents/{agent_id}/metrics?days=7 \
-H "Authorization: Bearer YOUR_CLERK_TOKEN"
Response:
{
"period_days": 7,
"total_sessions": 142,
"total_tokens": 89420,
"total_cost": 1.2340,
"avg_latency_ms": 1250,
"p50_latency_ms": 980,
"p90_latency_ms": 2100,
"p99_latency_ms": 4500,
"avg_security_score": 78.5,
"total_scans": 3,
"daily_breakdown": {
"2025-01-08": {"count": 18, "tokens": 12400, "cost": 0.18},
"2025-01-09": {"count": 22, "tokens": 14200, "cost": 0.21}
}
}
API Reference
| Method | Endpoint | Description |
|---|---|---|
POST | /api/web/agents | Create agent |
GET | /api/web/agents | List agents |
GET | /api/web/agents/{id} | Get agent detail |
PUT | /api/web/agents/{id} | Update agent |
DELETE | /api/web/agents/{id} | Delete agent |
GET | /api/web/agents/{id}/sessions | Agent's sessions |
GET | /api/web/agents/{id}/scans | Agent's scans |
GET | /api/web/agents/{id}/metrics?days=7 | Agent metrics |
All /api/web/ endpoints require Clerk JWT authentication.