---
type: api
title: Add events to a conversation
description: Append custom events to a conversation's timeline. The caller must be the owner, a member, or the conversation must be public. Server assigns id, created_at, and actor for each event; the body provides type and data. Only registered custom event types are accepted — built-in lifecycle types are rejected. To learn more about agent conversations, refer to the [agent chat documentation](https://www.elastic.co/docs/explore-analyze/ai-features/agent-builder/chat).<br/><br/>[Required authorization] Route required privileges: agentBuilder:read.
url: https://www.elastic.co/elastic/docs-builder/docs/4371/api/doc/kibana/v0/operation/operation-post-agent-builder-conversations-conversation-id-add-events
resource: https://www.elastic.co/elastic/docs-builder/docs/4371/api/doc/kibana/v0/operation/operation-post-agent-builder-conversations-conversation-id-add-events
products:
  - Kibana
---

# Add events to a conversation

Availability: Planned

- Server: `https://{kibana_url}`

## Paths

- `POST` `/api/agent_builder/conversations/{conversation_id}/_add_events`

- [Api key auth](/elastic/docs-builder/docs/4371/api/doc/kibana/v0/authentication#apikeyauth)
- [Basic auth](/elastic/docs-builder/docs/4371/api/doc/kibana/v0/authentication#basicauth)

#### Path Parameters

- `conversation_id` (string · max: 256)
  The unique identifier of the conversation.

## Description

Append custom events to a conversation's timeline. The caller must be the owner, a member, or the conversation must be public. Server assigns id, created_at, and actor for each event; the body provides type and data. Only registered custom event types are accepted — built-in lifecycle types are rejected. To learn more about agent conversations, refer to the [agent chat documentation](https://www.elastic.co/docs/explore-analyze/ai-features/agent-builder/chat).<br/><br/>[Required authorization] Route required privileges: agentBuilder:read.

## Request Body

`application/json`

- `events` ([] object · min: 1 · max: 10) — required
  Events to append. Between 1 and 10.
  - `data` (object) — required
    The event payload. Its shape is defined by the event type.
  - `type` (string · min: 1 · max: 256) — required
    The registered custom event type.

## Response

Indicates a successful response

## Code Examples

#### Console

```console
POST kbn://api/agent_builder/conversations/${CONVERSATION_ID}/_add_events
{
  "events": [
    { "type": "text_note", "data": { "text": "A note on this conversation" } }
  ]
}
```

#### curl

```curl
curl \
  -X POST "${KIBANA_URL}/api/agent_builder/conversations/${CONVERSATION_ID}/_add_events" \
  -H "Authorization: ApiKey ${API_KEY}" \
  -H "kbn-xsrf: true" \
  -H "elastic-api-version: 2023-10-31" \
  -H "Content-Type: application/json" \
  -d '{
    "events": [
      { "type": "text_note", "data": { "text": "A note on this conversation" } }
    ]
  }'
```

## Response Examples

#### Add events response

Example response returning the materialized events with server-assigned fields

```json
{
  "events": [
    {
      "actor": {
        "id": "u_abc123_uid",
        "type": "user",
        "username": "elastic"
      },
      "created_at": "2026-09-14T10:00:00.000Z",
      "data": {
        "text": "First note on this conversation"
      },
      "id": "7d3f1a2b-4c5e-6f7a-8b9c-0d1e2f3a4b5c",
      "type": "text_note"
    },
    {
      "actor": {
        "id": "u_abc123_uid",
        "type": "user",
        "username": "elastic"
      },
      "created_at": "2026-09-14T10:00:00.000Z",
      "data": {
        "text": "Second note on this conversation"
      },
      "id": "8e4f2b3c-5d6f-7a8b-9c0d-1e2f3a4b5c6d",
      "type": "text_note"
    }
  ]
}
```

