Self-Awareness

Full agent self-awareness in a single call — identity, health, budget, memory, config, and suggestions.

Get self-awareness

/v1/self

Returns everything an agent needs to know about itself and the system state. One call replaces 6+ individual endpoint calls. Cached for 30 seconds per tenant.

Response

{
  "identity": {
    "tenant_id": "d360e933-...",
    "auth_method": "api_key",
    "key_id": "key_abc123",
    "agent_id": null,
    "roles": ["developer"],
    "scopes": []
  },
  "capabilities": {
    "granted": [
      "audit.read",
      "config.read",
      "memory.read",
      "memory.write",
      "router.read",
      "router.write"
    ],
    "role_hierarchy": ["developer"]
  },
  "health": {
    "providers": {
      "anthropic": { "status": "healthy", "latency_ms": 234, "last_probe_at": "2026-03-15T..." },
      "openai": { "status": "healthy", "latency_ms": 189, "last_probe_at": "2026-03-15T..." }
    },
    "circuit_breakers": { "total": 45, "open": 2, "closed": 43 }
  },
  "budget": {
    "daily": { "spent_usd": 1.23, "limit_usd": 10, "remaining_usd": 8.77 },
    "monthly": { "spent_usd": 15.5, "limit_usd": 100, "remaining_usd": 84.5 }
  },
  "memory": {
    "total_entries": 42,
    "blocks": { "semantic": 20, "episodic": 15, "procedural": 5, "system": 2 },
    "pinned": 3
  },
  "configuration": {
    "guardrails": { "enabled": true, "mode": "warn" },
    "guardian": { "mode": "active" },
    "kill_switch": { "active": false, "reason": null },
    "privacy_mode": "standard"
  },
  "suggestions": [
    {
      "action": "store_memory",
      "reason": "Memory is empty — store facts to persist context across sessions",
      "endpoint": "POST /v1/memory/entries"
    }
  ],
  "recent_errors": [],
  "models_available": 308,
  "endpoints": {
    "completions": "POST /v1/chat/completions",
    "models": "GET /v1/models",
    "runnable": "GET /v1/catalog/runnable",
    "self": "GET /v1/self",
    "health": "GET /v1/health/providers",
    "providers": "GET /v1/providers",
    "memory": "GET /v1/memory/entries",
    "budget": "GET /v1/budget/status",
    "killswitch": "GET /v1/killswitch/status"
  }
}

Suggestions

The suggestions array dynamically recommends what to configure next:

ConditionActionEndpoint
No provider keysregister_providerPOST /v1/providers
Guardrails disabledenable_guardrailsPUT /v1/guardrails/config
No agent identitybootstrap_agentPOST /v1/agent/bootstrap
Empty memorystore_memoryPOST /v1/memory/entries
Circuit breakers opencheck_healthGET /v1/health/providers
Kill switch activedeactivate_killswitchPOST /v1/killswitch/deactivate
Budget <10% remainingincrease_budgetPATCH /v1/agent-limits
No model aliasesconfigure_aliasesPUT /v1/aliases

Authentication

Requires API key: Authorization: Bearer br_live_...

Works with both API key auth and agent JWT.

SDK Usage

const self = await client.self.get();
console.log(self.models_available);
console.log(self.suggestions);
self = client.self_awareness.get()
print(self["models_available"])
print(self["suggestions"])
curl https://api.brainstormrouter.com/v1/self \
  -H "Authorization: Bearer br_live_..."