get_document_pdf_text
Extract embedded text from PDF documents directly from their content bytes, bypassing the need for text extract annotations. Returns page-separated text for documents without existing extraction metadata.
Instructions
Extracts the embedded text of a PDF document directly from its content bytes.
Unlike get_document_text_extract (which depends on text extract annotations created by the repository's text extraction service), this tool downloads the PDF content in memory and extracts its embedded text layer directly. It is read-only: no reservation/lock is placed and nothing is written to disk. Use it when a PDF's text is needed but no text extract annotation exists.
Note: scanned PDFs with no embedded text layer will return empty pages — those require OCR or a vision model instead.
:param identifier: The document id or path (required). This can be either the document's ID (GUID) or its path in the repository (e.g., "/Folder1/document.pdf").
:returns: If successful, returns a dictionary containing: - document_id (str): The document's ID. - page_count (int): Number of pages in the PDF. - characters (int): Total characters extracted. - text (str): The extracted text, with pages separated by form-feed markers. If unsuccessful, returns a ToolError with details about the failure.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| identifier | Yes |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |