---
title: "Retrieve the text content of a specific document."
method: GET
path: "/v1/libraries/{library_id}/documents/{document_id}/text_content"
tags: ["beta.libraries.documents"]
---

# Retrieve the text content of a specific document.

`GET /v1/libraries/{library_id}/documents/{document_id}/text_content`

Given a library and a document in that library, you can retrieve the text content of that document if it exists. For documents like pdf, docx and pptx the text content results from our processing using Mistral OCR.

## Path parameters

- `library_id` string, uuid, required
- `document_id` string, uuid, required

## Query parameters

- `page_start` integer, nullable
- `page_end` integer, nullable

## Response `200`

Successful Response

- DocumentTextContent
  - `text` string, required

## Other responses

- `422` — Validation Error

---

[API](https://skmtc.dev/mistral/apis/mistral-ai-api.md) · [All operations](https://skmtc.dev/mistral/apis/mistral-ai-api/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/mistral/mistral-ai-api/revisions/61436a496404/schema)
