---
title: "Upload Pdf Template"
method: POST
path: "/api/pdf/templates/upload"
tags: ["PDF Form Processing"]
---

# Upload Pdf Template

`POST /api/pdf/templates/upload`

Upload and save a PDF form template for future use.
Extracts form fields and stores file in S3.

Args:
    file: PDF file
    description: Optional description
    current_user: Authenticated user (optional for guest mode)

Returns:
    {
        "template_id": "uuid",
        "name": "filename.pdf",
        "detected_fields": [...],
        "page_count": int,
        "s3_key": "pdf_templates/..."
    }

## Query parameters

- `description` string, 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/revisions/b6c76b02a94a/schema)
