---
title: "Retry With Precision"
method: POST
path: "/api/precision/retry"
tags: ["Precision Retry"]
---

# Retry With Precision

`POST /api/precision/retry`

Retry document processing with enhanced Gemini vision

This endpoint:
1. Accepts a list of document IDs to retry
2. Fetches original images from S3
3. Processes with Gemini 2.5 Flash for best accuracy
4. Updates database with improved structured data
5. Returns updated results

Example request:
```
POST /api/precision/retry
{
    "document_ids": ["doc-id-1", "doc-id-2"],
    "batch_id": "batch-id-123",
    "apply_to_all_pages": false
}
```

Returns:
    List of results for each document processed

## Request body

- PrecisionRetryRoutesRetryRequest
  - `document_ids` string[], required
  - `batch_id` string, required
  - `apply_to_all_pages` boolean
  - `page_numbers` integer[], nullable
  - `schema_fields` object[], nullable

## Response `200`

Successful Response

- unknown

## Other responses

- `422` — Validation Error

---

[API](https://skmtc.net/qomplement/apis/fastapi.md) · [All operations](https://skmtc.net/qomplement/apis/fastapi/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/qomplement/fastapi/versions/718de1c0d866/schema)
