---
title: "Delete a chat"
method: DELETE
path: "/chats/{id}"
tags: ["Chats"]
---

# Delete a chat

`DELETE /chats/{id}`

## Request

- Base URL: `https://app.gc.ai/api/external/v1`
- URL: `https://app.gc.ai/api/external/v1/chats/{id}`
- Auth: API key in header `Authorization`
- TypeScript: <https://skmtc.dev/gc-ai/apis/gc-ai-external-api/docs/chats/:id/delete.ts> (a function with typed inputs; its response is checked against the schema)

Delete a chat and all its messages. Files attached to the chat are deleted too, unless something else uses them: another chat, My Files or a folder, a project, a skill, an automation, a task, or a vault. Public share links are invalidated.

## Path parameters

- `id` string, uuid, required: The chat ID

## Response `204`

Chat deleted

## Other responses

- `400`: Invalid chat ID
- `401`: Missing or malformed API key
- `403`: Invalid API key, or a user API key deleting a chat its user did not create
- `404`: Chat not found or access denied
- `429`: Rate limit exceeded. See [Rate Limits](https://docs.gc.ai/api-reference/concepts/rate-limits) for the tiers, limits, and how to back off.
- `500`: Internal server error
- `503`: Service temporarily unavailable

---

[API](https://skmtc.dev/gc-ai/apis/gc-ai-external-api.md) - [All operations](https://skmtc.dev/gc-ai/apis/gc-ai-external-api/llms.txt) - [OpenAPI document](https://skmtc.dev/gc-ai/apis/gc-ai-external-api/revisions/2bbdfddf7107?raw)
