# AgentProtocolEventMap

**Kind:** Interface

**Source:** [`atloria-monorepo/libs/agent-core/src/protocol/agent-protocol.ts`](https://github.com/sherkety/atloria/blob/main/atloria-monorepo/libs/agent-core/src/protocol/agent-protocol.ts#L36)

## Properties

| Property | Type |
|---|---|
| `'agent:thinking'` | `{ agentName: string }` |
| `'agent:tool_start'` | `{ toolName: string; input: string }` |
| `'agent:tool_end'` | `{ toolName: string; outputPreview: string; durationMs: number }` |
| `'agent:message'` | `{ text: string; agentName: string; delta: boolean }` |
| `'agent:turn_done'` | `{ turnNumber: number; usage: TokenUsage }` |
| `'agent:error'` | `{ message: string; recoverable: boolean }` |
| `'agent:status_update'` | `{ code: string; message: string }` |
| `'agent:input_queued'` | `{ message: string; position: number }` |
| `'agent:verbose'` | `{ category: string; message: string; data?: Record<string, unknown>; timestamp: number }` |
| `'agent:ended'` | `{ totalUsage: TokenUsage; turnCount: number }` |
| `'agent:todo'` | `{ items: ReadonlyArray<TodoItem>; stats: TodoStats }` |
| `'agent:plan_ready'` | `{ plan: string }` |
| `'agent:plan_approved'` | `Record<string, never>` |
| `'agent:model_switched'` | `{ from: string; to: string; reason: string }` |
| `'agent:session_start'` | `{ model: string; workspace?: string }` |
| `'agent:session_end'` | `{ totalUsage: TokenUsage; turnCount: number; reason: 'completed' | 'error' | 'cancelled' }` |
| `'agent:pre_compact'` | `{ turnNumber: number; tokenCount: number; recentFiles: string[] }` |
| `'agent:post_compact'` | `{ turnNumber: number; summaryInjected: boolean }` |
| `'agent:subagent_start'` | `{ agentName: string; task: string }` |
| `'agent:subagent_end'` | `{ agentName: string; output: string; durationMs: number }` |
| `'agent:user_prompt_submit'` | `{ message: string }` |
