---
title: "Link an AI Assistant thread to the one it continues in"
method: POST
path: "/assistant/threads/{origin}/{thread_id}/link/"
tags: ["assistant"]
---

# Link an AI Assistant thread to the one it continues in

`POST /assistant/threads/{origin}/{thread_id}/link/`

## Request

- Base URL: `https://api.getoneprofile.ai` (the document declares no server; this is the origin it was published from)
- URL: `https://api.getoneprofile.ai/assistant/threads/{origin}/{thread_id}/link/`
- Auth: one of:
  - API key in header `X-API-Key`
  - HTTP bearer

Record that this thread continues in another: the lead search that produced a table, and the table's thread it carried on in. Written on both ends, so each thread's row shows the link. Both threads must be yours; either one that is not answers 404.

## Path parameters

- `origin` 'chat', required: Which store a thread lives in. ONE MEMBER, on purpose. There were four assistants and four transcript tables; three were retired and there is one assistant now. The enum stays rather than collapsing to nothing, because `origin` is still half of how a meta row names a thread and is still on the wire, and because a second store arriving is a change to this list rather than to every signature that carries it. ``table``, ``find_leads`` and ``agent`` were the other three. Their rows are deleted by a release task in the same release that drops their tables: every read here coerces the column back into this enum, so a row naming a member that no longer exists raises rather than being skipped.
- `thread_id` string, uuid, required

## Request body

- AssistantThreadLinkSchema: Record that this thread continues in another: a search, and the table it produced.
  - `continued_in` AssistantThreadRefSchema, required: One thread, named by its store and its id in that store.
    - `origin` 'chat', required: Which store a thread lives in. ONE MEMBER, on purpose. There were four assistants and four transcript tables; three were retired and there is one assistant now. The enum stays rather than collapsing to nothing, because `origin` is still half of how a meta row names a thread and is still on the wire, and because a second store arriving is a change to this list rather than to every signature that carries it. ``table``, ``find_leads`` and ``agent`` were the other three. Their rows are deleted by a release task in the same release that drops their tables: every read here coerces the column back into this enum, so a row naming a member that no longer exists raises rather than being skipped.
    - `thread_id` string, uuid, required

## Response `200`

Successful Response

- AssistantThreadLinkResponseSchema: The link as recorded, both ends.
  - `continued_from` AssistantThreadRefSchema, required: One thread, named by its store and its id in that store.
    - `origin` 'chat', required: Which store a thread lives in. ONE MEMBER, on purpose. There were four assistants and four transcript tables; three were retired and there is one assistant now. The enum stays rather than collapsing to nothing, because `origin` is still half of how a meta row names a thread and is still on the wire, and because a second store arriving is a change to this list rather than to every signature that carries it. ``table``, ``find_leads`` and ``agent`` were the other three. Their rows are deleted by a release task in the same release that drops their tables: every read here coerces the column back into this enum, so a row naming a member that no longer exists raises rather than being skipped.
    - `thread_id` string, uuid, required
  - `continued_in` AssistantThreadRefSchema, required: One thread, named by its store and its id in that store.
    - `origin` 'chat', required: Which store a thread lives in. ONE MEMBER, on purpose. There were four assistants and four transcript tables; three were retired and there is one assistant now. The enum stays rather than collapsing to nothing, because `origin` is still half of how a meta row names a thread and is still on the wire, and because a second store arriving is a change to this list rather than to every signature that carries it. ``table``, ``find_leads`` and ``agent`` were the other three. Their rows are deleted by a release task in the same release that drops their tables: every read here coerces the column back into this enum, so a row naming a member that no longer exists raises rather than being skipped.
    - `thread_id` string, uuid, required

## Other responses

- `401`: Unauthorized
- `403`: Forbidden
- `404`: Thread not found, or not the caller's
- `422`: Invalid request made to the API.
- `500`: Internal server error.
- `502`: Bad gateway error.
- `503`: Service unavailable.

---

[API](https://skmtc.dev/getoneprofile/apis/api-reference-oneprofile.md) · [All operations](https://skmtc.dev/getoneprofile/apis/api-reference-oneprofile/llms.txt) · [OpenAPI document](https://skmtc.dev/getoneprofile/apis/api-reference-oneprofile/revisions/4a6bd71e3f02?raw)
