# Get an update result

`GET /memory_stores/{name}/updates/{update_id}`

Retrieves the status and result of a memory store update operation.

## Parameters

### Path parameters

| Name | Type | Required | Description |
|------|------|----------|-------------|
| `name` | `string` | Yes | The name of the memory store. |
| `update_id` | `string` | Yes | The ID of the memory update operation. |

### Query parameters

| Name | Type | Required | Description |
|------|------|----------|-------------|
| `api-version` | `string` | Yes | The API version to use for this operation. |

### Header parameters

| Name | Type | Required | Description |
|------|------|----------|-------------|
| `Foundry-Features` | `enum` | Yes | A feature flag opt-in required when using preview operations or modifying persisted preview resources. _Constant:_ `MemoryStores=V1Preview` |

## Responses

### 200 — The request has succeeded.

Content-Type: `application/json`

Provides the status of a memory store update operation.

| Property | Type | Required | Description |
|----------|------|----------|-------------|
| `update_id` | `string` | Yes | The unique ID of this update request. Use this value as previous_update_id in subsequent requests to perform incremental updates. |
| `status` | `enum` | Yes | The status of the memory update operation. One of "queued", "in_progress", "completed", "failed", or "superseded". _Enum:_ `queued`, `in_progress`, `completed`, `failed`, `superseded` |
| `superseded_by` | `string` | No | The update_id the operation was superseded by when status is "superseded". |
| `result` | `MemoryStoreUpdateCompletedResult` | No | The result of memory store update operation when status is "completed". |
| `error` | `OpenAI.Error` | No | Error object that describes the error when status is "failed". |

#### `result` — `MemoryStoreUpdateCompletedResult`

The result of memory store update operation when status is "completed".

| Property | Type | Required | Description |
|----------|------|----------|-------------|
| `memory_operations` | `MemoryOperation[]` | Yes | A list of individual memory operations that were performed during the update. |
| `usage` | `MemoryStoreOperationUsage` | Yes | Usage statistics associated with the memory update operation. |

##### `memory_operations` — `MemoryOperation[]`

A list of individual memory operations that were performed during the update.

**Array of** `MemoryOperation`**:**

Represents a single memory operation (create, update, or delete) performed on a memory item.

| Property | Type | Required | Description |
|----------|------|----------|-------------|
| `kind` | `enum` | Yes | The type of memory operation being performed. _Enum:_ `create`, `update`, `delete` |
| `memory_item` | `UserProfileMemoryItem \| ChatSummaryMemoryItem \| ProceduralMemoryItem` | Yes | The memory item to create, update, or delete. |

###### `memory_item` — `UserProfileMemoryItem | ChatSummaryMemoryItem | ProceduralMemoryItem`

The memory item to create, update, or delete.

**One of the following:**

- **`user_profile`** — `user_profile (UserProfileMemoryItem)`

A memory item specifically containing user profile information extracted from conversations, such as preferences, interests, and personal details.

| Property | Type | Required | Description |
|----------|------|----------|-------------|
| `memory_id` | `string` | Yes | The unique ID of the memory item. |
| `updated_at` | `FoundryTimestamp` | Yes | The last update time of the memory item. _Format:_ `unixtime` |
| `scope` | `string` | Yes | The namespace that logically groups and isolates memories, such as a user ID. |
| `content` | `string` | Yes | The content of the memory. |
| `kind` | `enum` | Yes | The kind of the memory item. _Constant:_ `user_profile` |

- **`chat_summary`** — `chat_summary (ChatSummaryMemoryItem)`

A memory item containing a summary extracted from conversations.

| Property | Type | Required | Description |
|----------|------|----------|-------------|
| `memory_id` | `string` | Yes | The unique ID of the memory item. |
| `updated_at` | `FoundryTimestamp` | Yes | The last update time of the memory item. _Format:_ `unixtime` |
| `scope` | `string` | Yes | The namespace that logically groups and isolates memories, such as a user ID. |
| `content` | `string` | Yes | The content of the memory. |
| `kind` | `enum` | Yes | The kind of the memory item. _Constant:_ `chat_summary` |

- **`procedural`** — `procedural (ProceduralMemoryItem)`

A memory item containing a procedure extracted from conversations.

| Property | Type | Required | Description |
|----------|------|----------|-------------|
| `memory_id` | `string` | Yes | The unique ID of the memory item. |
| `updated_at` | `FoundryTimestamp` | Yes | The last update time of the memory item. _Format:_ `unixtime` |
| `scope` | `string` | Yes | The namespace that logically groups and isolates memories, such as a user ID. |
| `content` | `string` | Yes | The content of the memory. |
| `kind` | `enum` | Yes | The kind of the memory item. _Constant:_ `procedural` |

##### `usage` — `MemoryStoreOperationUsage`

Usage statistics associated with the memory update operation.

| Property | Type | Required | Description |
|----------|------|----------|-------------|
| `embedding_tokens` | `integer` | Yes | The number of embedding tokens. _Format:_ `int32` |
| `input_tokens` | `OpenAI.integer` | Yes | The number of input tokens. _Format:_ `int64` |
| `input_tokens_details` | `OpenAI.ResponseUsageInputTokensDetails` | Yes | A detailed breakdown of the input tokens. |
| `output_tokens` | `OpenAI.integer` | Yes | The number of output tokens. _Format:_ `int64` |
| `output_tokens_details` | `OpenAI.ResponseUsageOutputTokensDetails` | Yes | A detailed breakdown of the output tokens. |
| `total_tokens` | `OpenAI.integer` | Yes | The total number of tokens used. _Format:_ `int64` |

###### `input_tokens_details` — `OpenAI.ResponseUsageInputTokensDetails`

A detailed breakdown of the input tokens.

| Property | Type | Required | Description |
|----------|------|----------|-------------|
| `cached_tokens` | `OpenAI.integer` | Yes | _Format:_ `int64` |

###### `output_tokens_details` — `OpenAI.ResponseUsageOutputTokensDetails`

A detailed breakdown of the output tokens.

| Property | Type | Required | Description |
|----------|------|----------|-------------|
| `reasoning_tokens` | `OpenAI.integer` | Yes | _Format:_ `int64` |

#### `error` — `OpenAI.Error`

Error object that describes the error when status is "failed".

| Property | Type | Required | Description |
|----------|------|----------|-------------|
| `code` | `string \| null` | Yes |  |
| `message` | `string` | Yes |  |
| `param` | `string \| null` | No |  |
| `type` | `string` | No |  |
| `details` | `OpenAI.Error[]` | No |  |
| `additionalInfo` | `object` | No |  |
| `debugInfo` | `object` | No |  |

### 4XX — Client error

Content-Type: `application/json`

Error response for API failures.

| Property | Type | Required | Description |
|----------|------|----------|-------------|
| `error` | `OpenAI.Error` | Yes |  |

#### `error` — `OpenAI.Error`

| Property | Type | Required | Description |
|----------|------|----------|-------------|
| `code` | `string \| null` | Yes |  |
| `message` | `string` | Yes |  |
| `param` | `string \| null` | No |  |
| `type` | `string` | No |  |
| `details` | `OpenAI.Error[]` | No |  |
| `additionalInfo` | `object` | No |  |
| `debugInfo` | `object` | No |  |

### 5XX — Server error

Content-Type: `application/json`

Error response for API failures.

| Property | Type | Required | Description |
|----------|------|----------|-------------|
| `error` | `OpenAI.Error` | Yes |  |

#### `error` — `OpenAI.Error`

| Property | Type | Required | Description |
|----------|------|----------|-------------|
| `code` | `string \| null` | Yes |  |
| `message` | `string` | Yes |  |
| `param` | `string \| null` | No |  |
| `type` | `string` | No |  |
| `details` | `OpenAI.Error[]` | No |  |
| `additionalInfo` | `object` | No |  |
| `debugInfo` | `object` | No |  |
