Explainability headers (X-Darouter-*)
Ships Decision trail headers on chat/completions. Treat them as evidence of what the control plane decided — not as quality grades.
Common headers
| Header | Meaning | Maturity |
|---|---|---|
X-Darouter-Selected-Model | Concrete model after auto/virtual resolution | Ships |
X-Darouter-Route-Explanation | Why this route/offer won | Ships |
X-Darouter-Decision-ID | Opaque id for GET /v1/optimizer/decisions/{id} | Ships |
X-Darouter-Governance-Explanation | Hard governance outcome before ranking | Ships |
X-Darouter-Cache-Reason | Closed-enum cache-aware rank reason | Ships |
X-Request-ID | Correlation id for portal Logs browse | Ships |
Carbon-related observe headers (when present) do not change Select. No live carbon grams routing.
How to use them
- Log Selected-Model + Decision-ID on every production call.
- In portal Logs, browse recent traces keyboard-free; open a row for metadata-only detail.
- In portal Routing, paste Decision-ID to inspect attempts and outcomes.
OpenAPI + decision lookup
Headers are response metadata on compatible routes such as POST /v1/chat/completions. Persist X-Darouter-Decision-ID and resolve via OpenAPI:
GET /v1/optimizer/decisions/{decision_id}GET /v1/optimizer/decisions/{decision_id}/outcomes
Full field contracts live in /v1/openapi.json — not a cookbook tree.