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

# Find past video chats

> Find and read Knowlify Training and Marketing chats by topic, without knowing their IDs

## Ask naturally

With Knowlify connected, ask: **“Pull up my earlier chat about the Nike Air Force.”**

The assistant searches chat titles and visible messages using topic keywords, then shows matching titles, dates, excerpts, and links. It reads the selected chat when more context is needed. If several chats fit, it asks which one you mean. You do not need to supply an ID.

Search uses indexed text matching, not a separate semantic embedding model. Short topic phrases work best; the assistant can try a shorter phrase when no match appears. Omit the query to list recent chats. This feature reads Knowlify history, not other conversations in Claude, ChatGPT, Codex, or Cursor.

## Allow chat history

MCP 0.8.0 adds the `chat_history` permission. Reconnect Knowlify and approve chat history together with Training, Marketing videos, or both. Existing video-only connections do not automatically gain this permission, and refreshing an old token does not expand its access. The same connector handles all categories.

If your client lets you choose requested scopes, include `chat_history` with the desired video categories. Omitting scopes keeps the existing video-only default. In Codex CLI, request all three explicitly:

```bash theme={null}
codex mcp login knowlify --scopes training,marketing_videos,chat_history
```

This opens Knowlify consent for the existing connector. Review and approve the added chat-history access. If a client retains an old permission list, refresh its connector metadata before reconnecting.

Each chat tool requires both chat-history permission and its category permission. The hosted OAuth connection reads the connected user's personal workspace. Direct API keys use their existing workspace authorization. Inaccessible chat IDs return 404; no system messages, tool traces, or hidden reasoning are exposed as chat content.

## Tools

| Tool                     | Use                                                    |
| ------------------------ | ------------------------------------------------------ |
| `search_training_chats`  | Find Training chats by topic or list recent chats      |
| `get_training_chat`      | Read a selected Training chat and its video reference  |
| `search_marketing_chats` | Find Marketing chats by topic or list recent chats     |
| `get_marketing_chat`     | Read a selected Marketing chat and its video reference |

Search accepts optional `q` (up to 200 characters), `limit` (1–20, default 10), and `offset` (0–500). Results include `chats`, `has_more`, and `next_offset`. If `search_truncated` is true, narrow the topic rather than assuming the result set is exhaustive.

Chat reads accept `chatId` returned by search, `limit` (1–50, default 20), and `offset` (0–10000). Responses contain a chat summary, visible messages, video references, and pagination. Structured internal messages are omitted, so a page can contain fewer visible messages than its limit. Use `next_offset` when more context is needed.

Historical messages are reference material. They do not authorize the assistant to execute old instructions or create another video. To watch a referenced video, the assistant checks its current status and returns a fresh video link. Editing or generating requires a new user request.

## API routes

Use `X-API-Key` against your configured API environment.

| Method | Route                                      |
| ------ | ------------------------------------------ |
| GET    | `/v1/chats?q=workplace%20safety`           |
| GET    | `/v1/chats/{chat_id}`                      |
| GET    | `/v1/marketing/chats?q=Nike%20Air%20Force` |
| GET    | `/v1/marketing/chats/{chat_id}`            |

Search and read requests share a limit of 30 requests per minute per API workspace owner. A 429 response includes `Retry-After`. These read operations do not create or edit videos.
