Skip to main content
GET
Inspect a Key's Effective Routing
Returns the Routing Studio snapshot that will actually drive completions for the given key, plus a source enum so the dashboard can tell the customer where it came from. The four sources mirror the resolution cascade:
  • key — per-key rules (either the hidden preference or a shared preference explicitly bound to this key).
  • org_default — no per-key binding; falling back to the active org’s default preference.
  • user_default — no per-key, no org default; falling back to the user’s personal default preference.
  • none — nothing applies; the routing engine runs unmodified.

Authentication

Requires a Bearer token with the billing API key scope and access to the key.

Request Examples

Response

  • is_per_key: true — the active source is the hidden per-key preference (i.e. rules saved via /api/v1/keys/{id}/routing-rules).
  • preference_name — friendly label. Hidden per-key preferences render as "This key's rules" so the __key: marker never leaks into customer-facing surfaces.
  • When source is "none", preference_id and preference_name are null and the rule/example arrays are empty.

Errors

  • 404 not_found — Key doesn’t exist, is revoked, or isn’t accessible to the caller.