---
title: "List Policy Attachments"
method: GET
path: "/policies/attachments/list"
tags: ["policy_engine"]
---

# List Policy Attachments

`GET /policies/attachments/list`

List all policy attachments from the database and config.yaml.

Config-defined attachments are returned with definition_location "config" and a
synthetic attachment_id ("config-<index>").

Example Request:
```bash
curl -X GET "http://localhost:4000/policies/attachments/list" \
    -H "Authorization: Bearer <your_api_key>"
```

Example Response:
```json
{
    "attachments": [
        {
            "attachment_id": "123e4567-e89b-12d3-a456-426614174000",
            "policy_name": "global-baseline",
            "scope": "*",
            "teams": [],
            "keys": [],
            "models": [],
            "created_at": "2024-01-01T00:00:00Z",
            "updated_at": "2024-01-01T00:00:00Z"
        }
    ],
    "total_count": 1
}
```

## Response `200`

Successful Response

- PolicyAttachmentListResponse — Response for listing policy attachments.
  - `attachments` PolicyAttachmentDBResponse[] — List of policy attachments.
    - `attachment_id` string, required — Unique ID of the attachment.
    - `created_at` string, date-time, nullable — When the attachment was created.
    - `created_by` string, nullable — Who created the attachment.
    - `definition_location` 'db' | 'config' — Where this attachment is defined: 'db' (database) or 'config' (config.yaml).
    - `keys` string[] — Key patterns.
    - `models` string[] — Model patterns.
    - `policy_name` string, required — Name of the attached policy.
    - `scope` string, nullable — Scope of the attachment.
    - `tags` string[] — Tag patterns.
    - `teams` string[] — Team patterns.
    - `updated_at` string, date-time, nullable — When the attachment was last updated.
    - `updated_by` string, nullable — Who last updated the attachment.
  - `total_count` integer — Total number of attachments.

## Changes

- **2026-09-19** `c357baf422ab` — 2 info
  - api tag `policy_engine` added
  - api tag `Policies` removed
- **2026-09-18** `082b5fabd909` — 3 info
  - api tag `Policies` added
  - api tag `policy_engine` removed
  - added the optional property `attachments/items/definition_location` to the response with the `200` status
- **2026-09-17** `e2f308355e2d` — 2 info
  - api tag `policy_engine` added
  - api tag `Policies` removed
- **2026-09-01** `89805a9f84ad` — 2 info
  - api tag `Policies` added
  - api tag `policy_engine` removed
- **2026-09-01** `5c00a227eebf` — 2 info
  - api tag `policy_engine` added
  - api tag `Policies` removed

[Full history](https://skmtc.dev/flock/apis/litellm-api/changes/policies/attachments/list/get.md)

---

[API](https://skmtc.dev/flock/apis/litellm-api.md) · [All operations](https://skmtc.dev/flock/apis/litellm-api/llms.txt) · [OpenAPI document](https://skmtc.dev/flock/apis/litellm-api/revisions/3b2b241e4b0b?raw)
