API Reference
D.A.M.I provides a comprehensive REST API for programmatic access.
Base URL: https://api.dami.dev/api/v1
Authentication
All API requests require authentication via one of:
# Bearer Token (Firebase JWT)
Authorization: Bearer YOUR_FIREBASE_JWT
# API Key
X-API-Key: dami_sk_your_api_keyEndpoints
Health
GET /healthReturns service health status. No authentication required.
Agents
GET /api/v1/agents # List all agents
GET /api/v1/agents/:id # Get agent details
POST /api/v1/agents/auto/route # Auto-route prompt to best agentAuto-route example:
curl -X POST https://api.dami.dev/api/v1/agents/auto/route \
-H "Authorization: Bearer TOKEN" \
-d '{"prompt": "What are my cloud costs?"}'
# Response: {"data": {"routed_to": "finops", "confidence": 0.95}}Connectors
GET /api/v1/connectors # List connectors
POST /api/v1/connectors/connect # Connect a new tool
DELETE /api/v1/connectors/:id # Disconnect
GET /api/v1/connectors/:id/discover # Discover tools
POST /api/v1/connectors/:id/test # Test connectionMetrics
GET /api/v1/metrics/dora # DORA metrics
GET /api/v1/metrics/health-score # Engineering health (0-100)
GET /api/v1/metrics/usage # Token & workflow usage
GET /api/v1/metrics/agents # Per-agent performanceIncidents
GET /api/v1/incidents # List incidents
POST /api/v1/incidents # Create incident
GET /api/v1/incidents/:id # Get incident
PUT /api/v1/incidents/:id # Update status
GET /api/v1/incidents/:id/timeline # Get timelineWebhooks
POST /api/v1/webhooks/github # GitHub events
POST /api/v1/webhooks/jenkins # Jenkins notifications
POST /api/v1/webhooks/jira # Jira events
POST /api/v1/webhooks/pagerduty # PagerDuty alerts
POST /api/v1/webhooks/datadog # Datadog alertsChat
POST /api/v1/chat # Send message (SSE streaming response)
GET /api/v1/chat/history # Get chat historyRate Limits
| Tier | Requests/min | Concurrent |
|---|---|---|
| Free | 10 | 2 |
| Pro | 60 | 10 |
| Enterprise | Unlimited | Unlimited |
Error Format
All errors follow a consistent format:
{
"success": false,
"error": "Human-readable error message",
"code": "ERROR_CODE",
"details": {}
}