Agents · updateAgent
Change an agent's notification level
PATCH /v1/agents/{id}
Sets what the agent's events do to people, for the whole workspace: asks_and_events (every event is delivered), asks_only (events are stored and shown in the app, only asks are delivered) or silent (events are stored and shown, never delivered). Asks are always delivered, whatever the level. Agents connected as claude-code or codex start at asks_only, every other agent at asks_and_events. Owners and Deciders; recorded in the activity log as agent.updated.
- Who may call it
- humans: Deciders and up
- Server
- https://api.logu.dev
Parameters#
| Name | In | Type | Required | Description |
|---|---|---|---|---|
id | path | string | required | The agent's id (agt_…). · e.g. agt_01K7D8F2H4K6M8P0R2T4V6X8Z0 |
Logu-Workspace | header | string | optional | Humans only: the workspace to act in (default: your personal workspace). Agents always act in their API key's workspace. · e.g. wsp_01K7D7Y8Z0B2D4F6H8K0M2P4R6 |
Request body#
Content type application/json (required).
| Field | Type | Required | Notes |
|---|---|---|---|
notificationLevel | "asks_and_events" | "asks_only" | "silent" | required |
{
"notificationLevel": "asks_only"
}
Example#
curl -s -X PATCH "https://api.logu.dev/v1/agents/agt_01K7D8F2H4K6M8P0R2T4V6X8Z0" \
-H "Authorization: Bearer $LOGU_SESSION_TOKEN" \
-H "Content-Type: application/json" \
-d '{"notificationLevel":"asks_only"}'
Responses#
200
The agent, with its active API keys (never their secrets).
{
"id": "agt_01K7D8F2H4K6M8P0R2T4V6X8Z0",
"name": "deploy-bot",
"notificationLevel": "asks_only",
"createdAt": "2026-10-01T09:00:00.000Z",
"apiKeys": [
{
"id": "key_01K7DB1A3C5E7G9J1L3N5Q7S9U",
"name": "Claude",
"prefix": "lga_",
"test": false,
"createdAt": "2026-10-02T09:00:00.000Z",
"lastUsedAt": "2026-10-12T14:03:11.000Z",
"connector": {
"clientId": "oac_01K7DB3C5E7G9J1L3N5Q7S9U1W",
"name": "Claude"
}
},
{
"id": "key_01K7D8F2J5N7Q9S1U3W5Y7A9C1",
"name": "deploy-bot",
"prefix": "lg_8fK2xQp",
"test": false,
"createdAt": "2026-10-01T09:00:00.000Z",
"lastUsedAt": "2026-10-12T14:03:11.000Z",
"connector": null
}
],
"asks30d": 14,
"events30d": 62
}
Response fields
| Field | Type | Required | Notes |
|---|---|---|---|
id | string | required | |
name | string | required | |
notificationLevel | "asks_and_events" | "asks_only" | "silent" | required | |
createdAt | string | required | date-time |
apiKeys | ApiKey[] | required | |
apiKeys[].id | string | required | |
apiKeys[].name | string | required | |
apiKeys[].prefix | string | required | |
apiKeys[].test | boolean | required | |
apiKeys[].createdAt | string | required | date-time |
apiKeys[].lastUsedAt | string | null | required | date-time |
apiKeys[].connector | object | null | required | |
apiKeys[].connector.clientId | string | required | |
apiKeys[].connector.name | string | required | |
asks30d | integer | required | |
events30d | integer | required |
Errors#
Every error is {"error":{"code","message","hint","docUrl","requestId"}}: branch on code. See Errors.
| Status | Code | Meaning |
|---|---|---|
| 400 | bad_request | The request is malformed or a field is invalid (see issues). |
| 400 | unknown_field | The body has a field the endpoint doesn't know (often a typo or snake_case). |
| 401 | unauthorized | No credentials, or the API key or session is invalid or revoked. |
| 403 | forbidden | The caller is authenticated but may not do this (wrong role, or an API key on a human-only endpoint). |
| 404 | not_found | No such route, or the resource doesn't exist in your workspace. |
| 500 | internal_error | Something went wrong on Logu's side. |