> ## Documentation Index
> Fetch the complete documentation index at: https://docs.thrindex.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Get a memory

> GET /v1/memories/{id} — fetch a single memory by ID, including its content.

## `GET /v1/memories/{id}`

Fetch a single memory by its UUID. This is the only endpoint that returns the `content` field in a non-search context — the list endpoint excludes content for payload efficiency.

**Required scope:** `memory:read`

***

## Request

```bash theme={null}
curl https://api.thrindex.com/v1/memories/3f2e1d0c-1234-5678-abcd-ef0123456789 \
  -H "Authorization: Bearer th_live_..."
```

### Path parameters

| Parameter | Type          | Required | Description                                                         |
| --------- | ------------- | -------- | ------------------------------------------------------------------- |
| `id`      | string (UUID) | yes      | The memory's unique identifier, as returned by `POST /v1/memories`. |

***

## Response

### `200 OK`

```json theme={null}
{
  "id": "3f2e1d0c-1234-5678-abcd-ef0123456789",
  "org_id": "org_abc...",
  "agent_id": "support-agent",
  "user_id": "user-42",
  "content": "User prefers weekly email digests over push notifications.",
  "level": 0,
  "status": "active",
  "importance": 0.82,
  "confidence": 1.0,
  "source": "agent",
  "created_at": "2026-05-24T17:00:00.000Z",
  "updated_at": "2026-05-24T17:00:00.000Z"
}
```

### Fields

| Field        | Type            | Description                                             |
| ------------ | --------------- | ------------------------------------------------------- |
| `id`         | string (UUID)   | Memory identifier                                       |
| `org_id`     | string          | Your organization identifier                            |
| `agent_id`   | string          | Agent that owns the memory                              |
| `user_id`    | string          | User the memory belongs to                              |
| `content`    | string          | The full memory text                                    |
| `level`      | integer         | `0` = raw, `1` = abstraction                            |
| `status`     | string          | `"active"` or `"deprecated"` (soft-deleted)             |
| `importance` | float (0–1)     | Importance score assigned by the cognition worker       |
| `confidence` | float (0–1)     | Confidence score (provided on write, defaults to `1.0`) |
| `source`     | string          | Origin of the memory (e.g. `"agent"`)                   |
| `created_at` | ISO 8601 string | When the memory was created                             |
| `updated_at` | ISO 8601 string | When the memory was last updated                        |

***

## Examples

<Tabs>
  <Tab title="Python">
    ```python theme={null}
    from thrindex import Thrindex, NotFoundError, MemoryDetail

    client = Thrindex(api_key="th_live_...")

    try:
        memory: MemoryDetail = client.get("3f2e1d0c-1234-5678-abcd-ef0123456789")
        print(memory.content)
        print(f"Level: {memory.level}, Importance: {memory.importance:.2f}")
    except NotFoundError:
        print("Memory not found.")
    ```
  </Tab>

  <Tab title="TypeScript">
    ```typescript theme={null}
    import { ThrindexClient, NotFoundError } from 'thrindex';
    import type { MemoryDetail } from 'thrindex';

    const client = new ThrindexClient({ apiKey: 'th_live_...' });

    try {
      const memory: MemoryDetail = await client.get('3f2e1d0c-1234-5678-abcd-ef0123456789');
      console.log(memory.content);
      console.log(`Level: ${memory.level}, Importance: ${memory.importance.toFixed(2)}`);
    } catch (err) {
      if (err instanceof NotFoundError) {
        console.error('Memory not found.');
      }
    }
    ```
  </Tab>
</Tabs>

***

## Errors

| Status | Code             | Description                                                                          |
| ------ | ---------------- | ------------------------------------------------------------------------------------ |
| `401`  | `unauthorized`   | Missing or invalid API key                                                           |
| `401`  | `forbidden`      | API key lacks `memory:read` scope                                                    |
| `404`  | `not_found`      | Memory does not exist, has been hard-deleted, or belongs to a different organization |
| `429`  | `rate_limited`   | Rate limit exceeded                                                                  |
| `500`  | `internal_error` | Server error                                                                         |

<Note>
  A `404` is returned both when the memory does not exist and when it exists but belongs to a different organization. These cases are intentionally indistinguishable.
</Note>
