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

# Unstructured

> Partition documents (PDF, DOCX, PPTX, HTML, images, and more) into structured JSON elements for RAG ingestion via the Unstructured Partition API

## At a glance

* **Availability**: Experimental ([how to enable](/cloud/integrations)).
* **Auth**: API key.
* **Connection**: The key from `UNSTRUCTURED_API_KEY` is sent as the `unstructured-api-key` header.
* **Docs**: [https://docs.unstructured.io/api-reference/partition/overview](https://docs.unstructured.io/api-reference/partition/overview)

## Credentials

Set these per environment. See [Connect an integration](/cloud/integrations).

| Variable               | Required | Description                                                                                                                                  |
| ---------------------- | -------- | -------------------------------------------------------------------------------------------------------------------------------------------- |
| `UNSTRUCTURED_API_KEY` | Yes      | Unstructured API key, sent as the unstructured-api-key request header [Docs](https://docs.unstructured.io/api-reference/partition/overview). |

## Setup

1. **Create an Unstructured account**: Sign up at [https://platform.unstructured.io](https://platform.unstructured.io) - new accounts include a free trial of the serverless API, enough for testing without billing.
2. **Get an API key**: In the Unstructured UI, open the API Keys section, create a key, and copy it.
3. **Store the key**: Add UNSTRUCTURED\_API\_KEY=.... to your .env file. Requests authenticate with the unstructured-api-key header (no Bearer prefix).
4. **Verify access**: Run the Partition Document tool with a small text or PDF file and strategy auto. A 401 means the key is wrong; a 422 usually means the files field is missing or unreadable.

* The Partition endpoint processes one local file per request and does not fetch remote URLs - download the file first and pass its content
* Your account may be issued a dedicated API URL; the default [https://api.unstructuredapp.io/general/v0/general](https://api.unstructuredapp.io/general/v0/general) works for standard serverless accounts
* hi\_res and vlm strategies are slower and cost more per page than fast/auto but handle complex layouts and tables much better
* Use chunking\_strategy by\_title with max\_characters tuned to your embedding model for RAG-ready chunks

Provider API reference: [https://docs.unstructured.io/api-reference/partition/overview](https://docs.unstructured.io/api-reference/partition/overview)

## Tools

| Tool               | Access | Description                                                                                                                                                                                                                                                                                                   |
| ------------------ | ------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| Partition Document | Read   | Parse one local document into structured JSON elements (titles, narrative text, tables, lists) with optional chunking for RAG. The file content is uploaded as the multipart/form-data 'files' field together with the other fields; remote URLs are not accepted - fetch the file first and pass its content |

## Example prompts

* Partition the document I provide with Unstructured using by\_title chunking and summarize the resulting elements.
* Partition my document with the hi\_res strategy and extract the tables it contains.
