---
title: "Expand an uploaded .zip or .pst container"
method: POST
path: "/api/v0/documents/containers"
tags: ["Documents"]
---

# Expand an uploaded .zip or .pst container

`POST /api/v0/documents/containers`

## Request

- Base URL: `https://api.outerport.com` (the document declares no server; this is the origin it was published from)
- URL: `https://api.outerport.com/api/v0/documents/containers`
- Auth: HTTP bearer
- TypeScript: <https://skmtc.dev/outerport/apis/outerport-api/docs/api/v0/documents/containers/post.ts> (a function with typed inputs; its response is checked against the schema)

Queues the expansion of a container whose bytes were PUT to the URL from POST /documents/containers/upload-url into folders and documents. The response carries a job id and no document id. An upload is expanded once: a later request with the same upload_id and name, including one sent at the same moment, queues nothing and returns the first request's job in its current status, whatever collection or options it names. The folder it names must still be one the caller owns.

## Request body

- ContainerExpansionRequest
  - `upload_id` string, uuid, required: The upload_id POST /documents/containers/upload-url returned.
  - `name` string, required: The container's file name, as sent for the upload URL.
  - `folder_id` string, uuid, nullable: The folder the container's contents land in.
  - `knowledge_base_id` string, uuid, nullable: Collection every expanded document joins, and whose persisted processing settings apply.
  - `skip_page_processing` boolean, nullable: When True, every expanded document is stored without per-page visual processing.
  - `text_mode` 'auto' | 'extract': Per-upload text-source override accepted at the HTTP boundary.
  - `generate_content` boolean: Whether to generate structured content (e.g., HTML tables)
  - `generate_description` boolean: Whether to generate human-readable descriptions for visual components
  - `generate_summary` boolean: Whether to generate a document summary

## Response `200`

Successful Response

- DocumentPostResponse
  - `job_status_id` string, uuid, required: The ID of the job status.
  - `status` string, required: The status of the job. Options: `pending`, `done`, `error`.
  - `error_message` string, nullable, required: The error message if the job failed.
  - `document_id` string, uuid, nullable, required: The ID of the document that was uploaded.

## Other responses

- `422`: Validation Error

## Changes

- **2026-10-13** `7f81908bcdfe`: 1 info
  - endpoint added

[Operation history](https://skmtc.dev/outerport/apis/outerport-api/changes/api/v0/documents/containers/post.md)

---

[API](https://skmtc.dev/outerport/apis/outerport-api.md) - [All operations](https://skmtc.dev/outerport/apis/outerport-api/llms.txt) - [OpenAPI document](https://skmtc.dev/outerport/apis/outerport-api/revisions/08b5bf6f7f18?raw)
