---
title: "List Documents"
method: POST
path: "/documents"
tags: ["Documents"]
---

# List Documents

`POST /documents`

List accessible documents with metadata filtering.

**Supported operators**: `$and`, `$or`, `$nor`, `$not`, `$eq`, `$ne`, `$gt`, `$gte`, `$lt`, `$lte`,
`$in`, `$nin`, `$exists`, `$type`, `$regex`, `$contains`.

**Implicit equality** (backwards compatible):
```json
{"status": "active"}
```
Uses JSONB containment, matches scalars inside arrays, JSON-serializable types only.

**Explicit operators** (typed comparisons):
```json
{"priority": {"$eq": 42}, "created_date": {"$gte": "2024-01-01T00:00:00Z"}}
```
Supports typed metadata (number, decimal, datetime, date) with safe casting.

## Query parameters

- `folder_name` union
  - string
  - string[]
- `folder_depth` integer, nullable — Folder scope depth: 0/None = exact, -1 = all descendants, n > 0 = include descendants up to n levels.
- `end_user_id` string, nullable

## Headers

- `authorization` string

## Request body

- ListDocumentsRequest — Request model for listing documents
  - `document_filters` object, nullable — Metadata filters with operator support: $and, $or, $nor, $not, $eq, $ne, $gt, $gte, $lt, $lte, $in, $nin, $exists, $type, $regex, $contains. Implicit equality uses JSONB containment; explicit operators support typed comparisons.
  - `skip` integer — Number of documents to skip before returning results.
  - `limit` integer — Maximum number of documents to return.

## Response `200`

Successful Response

- Document[]
  - `external_id` string
  - `content_type` string, required
  - `filename` string, nullable
  - `metadata` object
  - `metadata_types` object
  - `storage_info` object
  - `system_metadata` object
  - `additional_metadata` object
  - `chunk_ids` string[]
  - `summary_storage_key` string, nullable
  - `summary_version` integer, nullable
  - `summary_bucket` string, nullable
  - `summary_updated_at` string, nullable
  - `folder_name` string, nullable
  - `end_user_id` string, nullable
  - `app_id` string, nullable
  - `folder_path` string, nullable
  - `folder_id` string, nullable

## Other responses

- `422` — Validation Error

## Changes

- **2025-12-18** `4b79c3821a17` — 1 warning, 5 info
  - removed the optional property `items/storage_files` from the response with the `200` status
  - added the optional property `items/folder_id` to the response with the `200` status
  - added the optional property `items/summary_bucket` to the response with the `200` status
  - added the optional property `items/summary_storage_key` to the response with the `200` status
  - …2 more
- **2025-12-06** `e185c542e939` — 2 info
  - added the new optional `query` request parameter `folder_depth`
  - added the optional property `items/folder_path` to the response with the `200` status
- **2025-11-27** `4ce03d9b0f27` — 1 info
  - the `limit` request property default value changed from `10000` to `1000`
- **2025-11-13** `b9ae748cb938` — 1 info
  - added the optional property `items/metadata_types` to the response with the `200` status
- **2025-11-05** `9ade02dd7b1d` — 1 breaking, 1 info
  - api path removed without deprecation
  - endpoint added

[Change history](https://skmtc.dev/morphik-org/apis/fastapi/changes/documents/post.md)

---

[API](https://skmtc.dev/morphik-org/apis/fastapi.md) · [All operations](https://skmtc.dev/morphik-org/apis/fastapi/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/morphik-org/fastapi/revisions/40c31e73d375/schema)
