---
title: "Remove a knowledge pack from a brain"
description: "Remove a pack from a brain. The pack itself is untouched and stays\navailable on its own. Returns 204 with no body."
---

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

Path: AI Gateway API › Brains

`DELETE /brains/{brain_id}/knowledge-packs/{pack_id}`

Remove a pack from a brain. The pack itself is untouched and stays
available on its own. Returns 204 with no body.

## Authentication

- `HTTPBearer`, http, header `Authorization`

## Path parameters

- `brain_id` (`remove_knowledge_pack_from_brain.path.brain_id`; string, required)
  - format `uuid`
- `pack_id` (`remove_knowledge_pack_from_brain.path.pack_id`; string, required)
  - format `uuid`

## Header parameters

- `X-On-Behalf-Of` (`remove_knowledge_pack_from_brain.header.X-On-Behalf-Of`; any of, optional)
  - any of: `string`, `null`
- `X-External-User-Id` (`remove_knowledge_pack_from_brain.header.X-External-User-Id`; any of, optional)
  - any of: `string`, `null`
- `X-App-Id` (`remove_knowledge_pack_from_brain.header.X-App-Id`; any of, optional)
  - any of: `string`, `null`

## Code samples

### cURL

```bash
curl --request DELETE \
  --url 'https://truememory-api.mvstg.com/brains/<brain_id>/knowledge-packs/<pack_id>' \
  --header 'Authorization: Bearer <token>'
```

### TypeScript

```typescript
const url = 'https://truememory-api.mvstg.com/brains/<brain_id>/knowledge-packs/<pack_id>';
const options = {method: 'DELETE', headers: {Authorization: 'Bearer <token>'}};

fetch(url, options)
  .then(res => res.json())
  .then(json => console.log(json))
  .catch(err => console.error(err));
```

### Python

```python
import requests

url = "https://truememory-api.mvstg.com/brains/<brain_id>/knowledge-packs/<pack_id>"

headers = {"Authorization": "Bearer <token>"}

response = requests.delete(url, headers=headers)

print(response.text)
```

## Responses

### 204

Successful Response

### 422

Validation Error

#### Example

```json
{
  "detail": [
    {
      "loc": [
        "string"
      ],
      "msg": "string",
      "type": "string",
      "input": null,
      "ctx": {}
    }
  ]
}
```

- `detail` (`remove_knowledge_pack_from_brain.response.422.detail`; array<object>, optional)
  - `loc` (`remove_knowledge_pack_from_brain.response.422.detail.loc`; array<any of>, required)
    - any of: `string`, `integer`
  - `msg` (`remove_knowledge_pack_from_brain.response.422.detail.msg`; string, required)
  - `type` (`remove_knowledge_pack_from_brain.response.422.detail.type`; string, required)
  - `input` (`remove_knowledge_pack_from_brain.response.422.detail.input`; unknown, optional)
  - `ctx` (`remove_knowledge_pack_from_brain.response.422.detail.ctx`; object, optional)


Source: https://truememory-docs.mvstg.com/api/brains/knowledge-packs/delete/index.md
