---
title: "Remember"
method: POST
path: "/api/v1/memory/remember"
tags: ["memory"]
---

# Remember

`POST /api/v1/memory/remember`

## Request

- Base URL: `https://memory.kagura-ai.com` (the document declares no server; this is the origin it was published from)
- URL: `https://memory.kagura-ai.com/api/v1/memory/remember`
- Auth: none declared

Store new memory with 3-layer architecture.

Issue #1 specification:
- Layer 1: summary (Embedding化、検索用)
- Layer 2: context_summary (文脈説明)
- Layer 3: content + details (完全詳細)

Request:
    {
        "summary": "認証エラー修正。JWTトークン有効期限チェック追加。",
        "context_summary": "ユーザーからログイン失敗の報告があり...",
        "content": "auth.pyのverify_token関数にexpired_atの検証を追加",
        "details": {"code_diff": "...", "test_results": "..."},
        "type": "code",
        "importance": 0.8,
        "tags": ["python", "authentication"],
        "context": {"context_id": "my-context"}
    }

Response:
    {
        "status": "success",
        "memory_id": "uuid",
        "scope": "working",
        "persistence": {
            "scope": "working",
            "committed": true,
            "promotes_via": "sleep_consolidation",
            "consolidation_archive_min_age_days": 30,
            "detail": "..."
        }
    }

The memory is committed before this returns; ``scope`` selects the
consolidation lifecycle, not whether it was stored. ``persistence``
describes that lifecycle for this deployment and is null when the scope
cannot be classified. Its age floor is scoped to consolidation and is not a
retention guarantee — see ``services.persistence``.

Example:
    POST /api/v1/memory/remember
    Authorization: Bearer <session_token>

## Headers

- `authorization` string, nullable

## Request body

- RememberRequest: Request schema for remember() API. Example: { "summary": "認証エラー修正。JWTトークン有効期限チェック追加。", "context_summary": "ユーザーからログイン失敗の報告があり...", "content": "auth.pyのverify_token関数にexpired_atの検証を追加", "details": {"code_diff": "...", "test_results": "..."}, "type": "code", "importance": 0.8, "tags": ["python", "authentication"], "context": {"context_id": "my-context", "file_path": "auth.py"} }
  - `summary` string, required: 検索用サマリー
  - `context_summary` string, nullable: 背景・文脈説明
  - `content` string, required: 基本内容
  - `details` object, nullable: 完全詳細（JSONB）
  - `type` string, required: メモリタイプ
  - `importance` number: 重要度 (0.0-1.0)
  - `tags` string[]: タグ
  - `context` object, nullable: コンテキスト情報
  - `delivery_mode` 'always' | 'on_recall' | 'on_trigger': Delivery mode: always (pin, load every turn) | on_recall (default) | on_trigger
  - `source_uri` string, nullable: Origin URI: file://, http(s)://, vault://, obsidian://
  - `source_type` 'file' | 'url' | 'vault' | 'api' | 'manual', nullable: Origin type
  - `linked_memory_ids` string[], nullable: Explicit links to existing memories (creates declared_link edges)
  - `linked_source_uris` string[], nullable: Explicit links by source_uri (resolved at remember time, unresolved silently skipped)
  - `supersedes` string, uuid, nullable: Memory ID this new memory supersedes (old one is shadowed, not deleted)

## Response `200`

Successful Response

- RememberResponse: Response schema for remember() API.
  - `status` string
  - `memory_id` string, uuid, required
  - `scope` string, required
  - `version` integer
  - `persistence` PersistenceInfo: What a write's ``scope`` means for durability. ``scope="working"`` reads as "not saved yet", which is wrong: the row is committed before the write returns. This block says what the scope actually implies, so a caller does not have to guess whether a memory survives until consolidation promotes it. This is NOT a retention SLA. It describes the consolidation lifecycle only; other maintenance (notably near-duplicate merge) has its own rules — pinned memories (``delivery_mode='always'``) are exempt from it — and an explicit forget() removes a memory at any time.
    - `scope` 'working' | 'persistent', required
    - `committed` boolean: The memory row is committed to PostgreSQL before this response is returned. Always true — scope does not gate durability.
    - `promotes_via` string, nullable: The maintenance pass that can promote this memory to scope='persistent' on this deployment: 'sleep_consolidation', 'legacy_consolidation', or null when the memory is already persistent or no consolidation pass is enabled here.
    - `consolidation_archive_min_age_days` integer, nullable: Age floor CONSOLIDATION applies before it may archive this memory; it also requires zero adoption. Scoped to consolidation only — it is not a retention guarantee, and does not bind near-duplicate merge (which skips pinned memories) or an explicit forget(). Null when no consolidation pass is enabled, or when the memory is persistent (consolidation acts only on scope='working').
    - `detail` string, required: One-line summary of the above for the calling agent.
  - `lint` WriteLintHint[]
    - `code` string, required: Stable machine-readable hint id: summary_short, summary_long, summary_narrative, no_tags, tag_near_duplicate, tag_normalized.
    - `hint` string, required: What to do differently, in one sentence.
    - `subject` string, nullable: The specific value the hint is about (e.g. the tag), when applicable.
    - `replacement` string, nullable: tag_normalized only: the stored spelling that replaced ``subject`` (remember(tags_normalize=true), #1853).

## Other responses

- `422`: Validation Error

---

[API](https://skmtc.dev/kagura-ai/apis/kagura-memory-cloud.md) · [All operations](https://skmtc.dev/kagura-ai/apis/kagura-memory-cloud/llms.txt) · [OpenAPI document](https://skmtc.dev/kagura-ai/apis/kagura-memory-cloud/revisions/09f17f5ada29?raw)
