---
title: Agents
full: true
_openapi:
  toc:
    - depth: 2
      title: '`GET /v1/agents`. Returns all registered profiles. Bypasses the'
      url: '#get-v1agents-returns-all-registered-profiles-bypasses-the'
    - depth: 2
      title: '`POST /v1/agents` — upsert a profile. Body is YAML (when'
      url: '#post-v1agents--upsert-a-profile-body-is-yaml-when'
    - depth: 2
      title: '`GET /v1/agents/:id`.'
      url: '#get-v1agentsid'
    - depth: 2
      title: '`DELETE /v1/agents/:id`. Soft-delete via the store.'
      url: '#delete-v1agentsid-soft-delete-via-the-store'
    - depth: 2
      title: '`GET /v1/agents/{id}/guardrails` — list active policies owned by an'
      url: '#get-v1agentsidguardrails--list-active-policies-owned-by-an'
    - depth: 2
      title: '`POST /v1/agents/{id}/guardrails/generate` — derive a set of'
      url: '#post-v1agentsidguardrailsgenerate--derive-a-set-of'
  structuredData:
    headings:
      - content: '`GET /v1/agents`. Returns all registered profiles. Bypasses the'
        id: get-v1agents-returns-all-registered-profiles-bypasses-the
      - content: '`POST /v1/agents` — upsert a profile. Body is YAML (when'
        id: post-v1agents--upsert-a-profile-body-is-yaml-when
      - content: '`GET /v1/agents/:id`.'
        id: get-v1agentsid
      - content: '`DELETE /v1/agents/:id`. Soft-delete via the store.'
        id: delete-v1agentsid-soft-delete-via-the-store
      - content: '`GET /v1/agents/{id}/guardrails` — list active policies owned by an'
        id: get-v1agentsidguardrails--list-active-policies-owned-by-an
      - content: '`POST /v1/agents/{id}/guardrails/generate` — derive a set of'
        id: post-v1agentsidguardrailsgenerate--derive-a-set-of
    contents:
      - content: store's read cache because admin-list isn't on the hot path.
        heading: get-v1agents-returns-all-registered-profiles-bypasses-the
      - content: '`Content-Type` is `*yaml*`) or JSON.'
        heading: post-v1agents--upsert-a-profile-body-is-yaml-when
      - content: >-
          agent. Does not require the agent to exist; missing agent → empty
          list.
        heading: get-v1agentsidguardrails--list-active-policies-owned-by-an
      - content: |-
          guardrail policies tailored to an agent's stored `system_prompt`,
          auto-persist them with `enabled=false`, and return what was saved.

          Callers review the set and flip individual policies on via
          `PATCH /v1/policies/{id}/enabled`. Runtime checks never see these
          policies until that happens (because `/v1/check` filters by enabled).
        heading: post-v1agentsidguardrailsgenerate--derive-a-set-of
---

{/* This file was generated by Fumadocs. Do not edit this file directly. Any changes should be made by running the generation command again. */}

<APIPage document={"../../docs/openapi.yaml"} webhooks={[]} operations={[{"path":"/v1/agents","method":"get"},{"path":"/v1/agents","method":"post"},{"path":"/v1/agents/{id}","method":"get"},{"path":"/v1/agents/{id}","method":"delete"},{"path":"/v1/agents/{id}/guardrails","method":"get"},{"path":"/v1/agents/{id}/guardrails/generate","method":"post"}]} showTitle showDescription />