---
title: "Confirm named fields, or every unconfirmed one"
method: POST
path: "/v1/doc-gen/templates/{id}/confirm"
tags: ["Document Generation"]
---

# Confirm named fields, or every unconfirmed one

`POST /v1/doc-gen/templates/{id}/confirm`

## Request

- Base URL: `https://api.talonic.com`
- URL: `https://api.talonic.com/v1/doc-gen/templates/{id}/confirm`
- Auth: HTTP bearer

Marks suggested field sources as confirmed. With `keys`, those fields; without, every unconfirmed field, leaving out the fields entered per document when `include_entered` is false. With `dry_run`, the response lists what would be confirmed and nothing is stored. Requires a person at or above member behind the key.

## Path parameters

- `id` string, uuid, required

## Request body

- DocGenConfirmRequest
  - `keys` string[]: The fields to confirm; every unconfirmed field when omitted or empty.
  - `include_entered` boolean: Without `keys`, also confirm the fields entered per document.
  - `dry_run` boolean

## Response `201`

The fields confirmed, or that would be.

- DocGenConfirmResult
  - `dry_run` boolean
  - `confirmed` object[]
    - `key` string
    - `label` string
    - `source` DocGenFieldSource: Where a field's value comes from. `type` selects the shape: `product` (`field`), `reference` (`column`), `extract` (`from`, `pattern`, optional `group` 0-9, optional `mode` `capture` or `remove`), `first` (`sources`, a list of product, reference, extract or party sources), `case` (`caseKey`, optional `when` condition), `user` (`profile`), `rule` (`rule`), `today`, `party` (`role`, `attribute`), `variant` (`by`, `map`, `fallback`), `condition` (`when`, optional `text`), `fixed` (`text`), and `lookup` (`from`, `cases`, `fallback`). A source is validated when stored; one of no known shape is refused.
      - `type` 'product' | 'reference' | 'extract' | 'first' | 'case' | 'user' | 'rule' | 'today' | 'party' | 'variant' | 'condition' | 'fixed' | 'lookup', required

## Other responses

- `400`: The request is invalid.
- `403`: The API key does not have the required scope.
- `404`: The requested resource was not found.
- `422`: A named key is not a field of the template.

## Changes

- **2026-10-28** `0a485a46163e`: 1 info
  - endpoint added

[Operation history](https://skmtc.dev/talonic/apis/talonic-api/changes/v1/doc-gen/templates/:id/confirm/post.md)

---

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