Skip to main content
The Box AI API runs on files stored in Box. This page collects the limits, supported file types, and AI Units pricing that decide whether a document workload fits, from a single 300-page agreement to millions of archived forms.

Limits at a glance

Exceeding most limits does not return an error. Box truncates the input to the limit and processes what it can. For details, see . Box AI uses large language models, so the page guidance on this page is an estimate. Results vary with the density and content of each document.

Can Box AI extract from a 300-page document without splitting it?

Sometimes. Whether an extraction completes depends on the token limit for processing, not the page count. A sparse 300-page document can complete in one call, while a dense 48-page brochure might not. For reliable results, split long documents into segments of about 50 pages. Box offers two agents for POST /ai/extract_structured:
  • Standard Extract Agent: recommended for high-volume, structured or semi-structured documents with 50 pages or fewer and fewer than 20 extraction fields.
  • Enhanced Extract Agent: recommended for complex, large, or unstructured documents with 50 pages or more and more than 20 extraction fields, such as contracts or clinical reports.
To use the Enhanced Extract Agent, add the ai_agent object to your request:
See and the .

Scanned documents and the page limit

extract_structured applies additional processing to scanned documents, including automatic OCR and layout parsing, before extraction. For long scanned documents, see Recommended approach for long agreements. For a long scanned document, such as a 300-page credit agreement:
  1. Split the document into segments of about 50 pages, and upload each segment to Box as a separate file.
  2. Call extract_structured on each segment with the Enhanced Extract Agent.
  3. Combine the results from each segment in your application.

One API for scanned PDFs, photos, and Word files

POST /ai/extract_structured accepts images, scanned documents, Office and Google files, PDFs, spreadsheets, and code or text files. You pass each file by its Box file ID in the items array. Box applies optical character recognition (OCR) automatically to images and scanned documents, so you do not need to convert photos to PDF or run a separate OCR step. For the full list, see .

Documents that mix text and scanned pages

The Enhanced Extract Agent supports PDFs that mix text pages and scanned pages. Extraction quality is typically lower than for documents where every page contains text.

OCR by endpoint

Not every endpoint applies OCR. Use extract_structured for scanned documents and photos. extract_structured has explicit multilingual support for English, Japanese, Chinese, Korean, and Cyrillic-based languages.

Pricing and AI Units

Box AI API usage consumes AI Units. Each Box plan includes a monthly AI Unit allocation, and you can buy more. What consumes AI Units:
  • Box AI APIs: All calls to the Box AI API, including Ask, text generation, and extraction, are chargeable.
  • Extraction through the Box MCP server: Extraction tasks that an MCP tool runs use the API and consume AI Units.
  • Confidence scores and references: Turning on confidence levels or bounding boxes consumes additional AI Units.
  • Premium models: Choosing a premium model increases the rate of AI Unit consumption.
When your organization uses all of its AI Units, chargeable features, including the Box AI API, are blocked until the next entitlement period or until you buy more units. Admins can monitor consumption in the Admin Console. For plan details and chargeability rules, see Understanding AI Units in Box.

Cost per request

AI Unit consumption per request depends on the endpoint, the agent and model tier, and whether you request confidence scores or references. For rates, see the Box AI Units consumption table.

Extraction across millions of documents

There is no batch extract endpoint. Requests with several files return one combined answer, so for per-file results you call extract_structured once per file and run the requests concurrently:
  1. Find the files with a , by listing folder items, or from a workflow.
  2. Call extract_structured for each file ID with an identity that can access the file.
  3. If the API returns 429 Too Many Requests, wait for the time in the Retry-After header and retry. See .
  4. Save each result on the file as a .
Each call consumes AI Units, so the total cost of a backfill depends on the number of files, the agent, and whether you request confidence scores. See Cost per request and .
Last modified on November 23, 2026