---
title: "POST /memories/{memoryId}/events"
method: POST
path: "/memories/{memoryId}/events"
---

# POST /memories/{memoryId}/events

`POST /memories/{memoryId}/events`

Creates an event in an AgentCore Memory resource. Events represent interactions or activities that occur within a session and are associated with specific actors.

To use this operation, you must have the `bedrock-agentcore:CreateEvent` permission.

This operation is subject to request rate limiting.

## Path parameters

- `memoryId` string, required

## Request body

- object
  - `actorId` string, required — The identifier of the actor associated with this event. An actor represents an entity that participates in sessions and generates events.
  - `sessionId` string — The identifier of the session in which this event occurs. A session represents a sequence of related events.
  - `eventTimestamp` string, date-time, required — The timestamp when the event occurred. If not specified, the current time is used.
  - `payload` PayloadType[], required — The content payload of the event. This can include conversational data or binary content.
    - `conversational` object — The conversational content of the payload.
      - `content` object, required — The content of the conversation message.
        - `text` string, password — The text content of the memory item.
      - `role` 'ASSISTANT' | 'USER' | 'TOOL' | 'OTHER', required — The role of the participant in the conversation (for example, "user" or "assistant").
    - `blob` object — The binary content of the payload.
  - `branch` object — Contains information about a branch in an AgentCore Memory resource. Branches allow for organizing events into different conversation threads or paths.
    - `rootEventId` string — The identifier of the root event for this branch.
    - `name` string — The name of the branch.
  - `clientToken` string — A unique, case-sensitive identifier to ensure that the operation completes no more than one time. If this token matches a previous request, AgentCore ignores the request, but does not return an error.
  - `metadata` object — The key-value metadata to attach to the event.
  - `extractionMode` 'SKIP' — Controls long-term memory extraction for this event. When set to <code>SKIP</code>, the event is stored in short-term memory but is excluded from long-term memory extraction. If not specified, the event is processed for extraction as usual.

## Response `201`

Success

- CreateEventOutput
  - `event` object, required — The event that was created.
    - `memoryId` string, required — The identifier of the AgentCore Memory resource containing the event.
    - `actorId` string, required — The identifier of the actor associated with the event.
    - `sessionId` string, required — The identifier of the session containing the event.
    - `eventId` string, required — The unique identifier of the event.
    - `eventTimestamp` string, date-time, required — The timestamp when the event occurred.
    - `payload` PayloadType[], required — The content payload of the event.
      - `conversational` object — The conversational content of the payload.
        - `content` object, required — The content of the conversation message.
          - `text` string, password — The text content of the memory item.
        - `role` 'ASSISTANT' | 'USER' | 'TOOL' | 'OTHER', required — The role of the participant in the conversation (for example, "user" or "assistant").
      - `blob` object — The binary content of the payload.
    - `branch` object — The branch information for the event.
      - `rootEventId` string — The identifier of the root event for this branch.
      - `name` string, required — The name of the branch.
    - `metadata` object — Metadata associated with an event.

## Other responses

- `480` — ServiceQuotaExceededException
- `481` — ThrottledException
- `482` — ServiceException
- `483` — RetryableConflictException
- `484` — AccessDeniedException
- `485` — ValidationException
- `486` — InvalidInputException
- `487` — ResourceNotFoundException

---

[API](https://skmtc.net/aws/apis/bedrock-agentcore.md) · [All operations](https://skmtc.net/aws/apis/bedrock-agentcore/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/aws/bedrock-agentcore/versions/79623b33d495/schema)
