# Update conversations

URL: https://docs.hanzo.ai/docs/openapi/agent/patch-agent-chat-conversations-by-id

> Takes `{title?, pinned?, archived?}` and changes what it names, leaving the rest; a body naming none is refused 400, and so is an empty title.

`PATCH /v1/agent/chat/conversations/{id}`

> [Agent →](https://docs.hanzo.ai/docs/openapi/agent) · [All API references →](https://docs.hanzo.ai/docs/openapi) · [Get started →](https://docs.hanzo.ai/docs/guides)

|               |                                                         |
| ------------- | ------------------------------------------------------- |
| **Address**   | `https://api.hanzo.ai/v1/agent/chat/conversations/{id}` |
| **Method**    | `PATCH`                                                 |
| **Operation** | `patch_agent_chat_conversations_by_id`                  |
| **Auth**      | `Authorization: Bearer $HANZO_API_KEY`                  |

Takes `{title?, pinned?, archived?}` and changes what it names, leaving the rest; a body naming none is refused 400, and so is an empty title. A title is cut to one line of at most 80 characters. Answers the conversation as the list does — id, title, updatedAt, pinned, archived — and the change does not move `updatedAt`, which stays when it was last spoken in.

The list puts pinned conversations first and leaves archived ones out; `?archived=true` lists those alone. Only the member who opened the conversation may change it; another member's, another org's, and one recorded with no member answer 404. Every change is written to the audit trail.

## Request

1 field.

| Field | In   | Type   | Required | Description |
| ----- | ---- | ------ | -------- | ----------- |
| `id`  | path | string | yes      |             |

## Response

The document declares no response body for this operation. It answers `200` on success and the platform error shape on failure — see [Errors](https://docs.hanzo.ai/docs/errors).

## Examples

**CLI**

```bash
hanzo agent chat conversations update <id>
```

**SDK**

**.ts**

```ts
import { Configuration, AgentApi } from 'hanzoai';

const api = new AgentApi(new Configuration({ accessToken: process.env.HANZO_API_KEY }));
const { data } = await api.patchAgentChatConversationsById({ id: 'id' });
```

**.py**

```python
from hanzoai.cloud import ApiClient, Configuration
from hanzoai.cloud.api import AgentApi

client = ApiClient(Configuration(access_token=os.environ["HANZO_API_KEY"]))
result = AgentApi(client).patch_agent_chat_conversations_by_id(id='id')
```

**.go**

```go
cfg := hanzoai.NewConfiguration()
cfg.AddDefaultHeader("Authorization", "Bearer "+os.Getenv("HANZO_API_KEY"))
client := hanzoai.NewAPIClient(cfg)

resp, _, err := client.AgentAPI.PatchAgentChatConversationsById(context.Background()).Execute()
if err != nil {
	return err
}
```

**.rs**

```rust
use hanzo_client::apis::{configuration::Configuration, agent_api};

let mut cfg = Configuration::new();
cfg.bearer_access_token = std::env::var("HANZO_API_KEY").ok();

let result = agent_api::patch_agent_chat_conversations_by_id(&cfg, Default::default()).await?;
```

**.java**

```java
import ai.hanzo.cloud.ApiClient;
import ai.hanzo.cloud.api.AgentApi;

ApiClient client = new ApiClient();
client.setBearerToken(System.getenv("HANZO_API_KEY"));

var result = new AgentApi(client).patchAgentChatConversationsById();
```

**HTTP**

```bash
curl -X PATCH https://api.hanzo.ai/v1/agent/chat/conversations/<id> \
  -H "Authorization: Bearer $HANZO_API_KEY"
```

**MCP**

MCP reaches **agent** through the `agent` tool, which names its 51 operations with its own verbs — this one among them, under a name only MCP declares. `describe` explains any of them:

```bash
curl -X POST https://api.hanzo.ai/v1/mcp \
  -H "Content-Type: application/json" \
  -d '{
       "jsonrpc": "2.0",
       "id": 1,
       "method": "tools/call",
       "params": {
         "name": "describe",
         "arguments": {
           "op": "list_agents"
         }
       }
     }'
```

---

[Agent API](https://docs.hanzo.ai/docs/openapi/agent) · [All Hanzo APIs](https://docs.hanzo.ai/docs/openapi) · [Interactive reference](https://docs.hanzo.ai/docs/openapi/reference)
