Skip to main content

Agents

Register the agents you govern and toggle whether they are told they are monitored.

MethodPathScopeSummary
GET/agents/readList Agents
POST/agents/events:writeRegister Agent
GET/agents/{agent_id}readGet Agent
PATCH/agents/{agent_id}/monitoringevents:writeSet Monitoring State

Try it​

curl -sf -X POST "$VIGIL_URL/agents/" -H "Authorization: Bearer $VIGIL_KEY" -H "Content-Type: application/json" \
-d '{"agent_id":"docs-api","name":"Docs API"}' > /dev/null || true
curl -sf -H "Authorization: Bearer $VIGIL_KEY" "$VIGIL_URL/agents/docs-api"

Routes​

GET /agents/​

List Agents. Scope: read.

Active agents in the org. kind narrows to one kind; include_inactive=true (admin) adds retired agents.

ParameterInRequiredTypeNotes
kindquerynoproduction, sandbox, system | null
include_inactivequerynoboolean

Response 200:

[
{
"id": 0,
"org_id": 0,
"agent_id": "string",
"name": "string",
"description": "string | null",
"registered_at": "2026-09-08T00:00:00Z",
"is_active": true,
"kind": "string",
"public": true,
"public_links": "string | null",
"currently_monitored": true,
"monitoring_toggled_at": "2026-09-08T00:00:00Z | null"
}
]

POST /agents/​

Register Agent. Scope: events:write.

Request body:

{
"agent_id": "string",
"name": "string",
"description": "string | null",
"kind": "production | sandbox | system"
}
FieldTypeRequiredNotes
agent_idstringyes
namestringyes
descriptionstring | nullno
kindproduction, sandbox, systemno

Response 200:

{
"id": 0,
"org_id": 0,
"agent_id": "string",
"name": "string",
"description": "string | null",
"registered_at": "2026-09-08T00:00:00Z",
"is_active": true,
"kind": "string",
"public": true,
"public_links": "string | null",
"currently_monitored": true,
"monitoring_toggled_at": "2026-09-08T00:00:00Z | null"
}

GET /agents/{agent_id}​

Get Agent. Scope: read.

ParameterInRequiredTypeNotes
agent_idpathyesstring

Response 200:

{
"id": 0,
"org_id": 0,
"agent_id": "string",
"name": "string",
"description": "string | null",
"registered_at": "2026-09-08T00:00:00Z",
"is_active": true,
"kind": "string",
"public": true,
"public_links": "string | null",
"currently_monitored": true,
"monitoring_toggled_at": "2026-09-08T00:00:00Z | null"
}

PATCH /agents/{agent_id}/monitoring​

Set Monitoring State. Scope: events:write.

Toggle monitoring state. Used by alignment faking detector.

ParameterInRequiredTypeNotes
agent_idpathyesstring

Request body:

{
"monitored": true
}
FieldTypeRequiredNotes
monitoredbooleanyes

Response 200:

{
"id": 0,
"org_id": 0,
"agent_id": "string",
"name": "string",
"description": "string | null",
"registered_at": "2026-09-08T00:00:00Z",
"is_active": true,
"kind": "string",
"public": true,
"public_links": "string | null",
"currently_monitored": true,
"monitoring_toggled_at": "2026-09-08T00:00:00Z | null"
}

Generated from openapi.json (VIGIL 0.2.0). Scopes follow the router dependencies in VIGIL_SPEC.md section 4.2.