---
title: "Modify AI memory entry"
method: PATCH
path: "/v1/ai/memory/{memory-id}"
tags: ["AI Memory"]
---

# Modify AI memory entry

`PATCH /v1/ai/memory/{memory-id}`

Change title, content, and/or locked flag of a memory entry. Only provided fields are changed. Locked entries cannot be changed or deleted by the model.

## Request body

- object
  - `title` string
  - `content` string
  - `locked` boolean

## Response `200`

Updated memory entry

- AiMemoryEntry
  - `id` integer — Unique entry identifier
  - `scope` 'environment' | 'user' | 'object' — Entry scope
  - `scopeId` integer — User ID for user scope, object ID for object scope, 0 for environment scope
  - `title` string — Entry title (unique within scope)
  - `content` string — Entry content
  - `createdBy` 'model' | 'human' — Who created the entry
  - `sourceUserId` integer — ID of the user on whose behalf the entry was created
  - `sourceType` 'chat' | 'task' | 'operator' | 'human' — Execution context that created the entry
  - `sourceId` integer — Chat ID, AI task ID, or AI operator instance ID depending on source type (0 for human)
  - `createdAt` integer — Creation time (UNIX timestamp)
  - `updatedAt` integer — Last modification time (UNIX timestamp)
  - `locked` boolean — True if the entry cannot be changed or deleted by the model

## Other responses

- `400` — Invalid request
- `403` — Insufficient access rights
- `404` — Entry not found
- `409` — Entry with this title already exists in the scope

## Changes

- **2026-10-01** `b4fc7bfd5bd3` — 1 info
  - endpoint added

[Change history](https://skmtc.dev/netxms/apis/netxms-api/changes/v1/ai/memory/:memory-id/patch.md)

---

[API](https://skmtc.dev/netxms/apis/netxms-api.md) · [All operations](https://skmtc.dev/netxms/apis/netxms-api/llms.txt) · [OpenAPI document](https://skmtc.dev/netxms/apis/netxms-api/revisions/129789f8868f?raw)
