---
title: "Make a batch's missing PDFs again"
method: POST
path: "/v1/doc-gen/jobs/{id}/pdf"
tags: ["Document Generation"]
---

# Make a batch's missing PDFs again

`POST /v1/doc-gen/jobs/{id}/pdf`

## Request

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

Converts the stored Word files of ready documents that have no PDF; nothing is filled or generated twice. Only documents the key's minting user may read are converted, and only while the batch's files are kept. Requires a person at or above member behind the key.

## Path parameters

- `id` string, uuid, required

## Response `201`

The batch after the conversion.

- DocGenJob
  - `id` string, uuid
  - `templateIds` string[]
  - `templateNames` string[]
  - `createdAt` string, date-time
  - `by` string
  - `status` 'running' | 'completed' | 'failed'
  - `error` string, nullable
  - `savedToWorkspace` boolean
  - `pdfAvailable` boolean
  - `filesExpireAt` string, date-time, nullable: When the files of a batch not kept in the workspace are deleted.
  - `filesExpired` boolean: True once the files are gone; the values and history stay.
  - `documents` DocGenJobDocument[]
    - `id` string, uuid
    - `templateId` string, uuid
    - `templateName` string
    - `recordId` string
    - `recordLabel` string
    - `values` object
    - `events` DocGenAuditEvent[]
      - `id` string
      - `at` string, date-time
      - `by` string
      - `kind` 'filled' | 'entered' | 'edited' | 'reverted' | 'generated' | 'exported' | 'saved' | 'template_uploaded' | 'field_confirmed' | 'parties_chosen'
      - `field` string
      - `fieldLabel` string
      - `from` string, nullable
      - `to` string, nullable
      - `detail` string
      - `documentId` string
    - `status` 'pending' | 'ready' | 'failed'
    - `files` DocGenGeneratedFile[]: Empty once the batch's files have expired.
      - `kind` 'docx' | 'pdf'
      - `name` string
      - `size` integer: Bytes.
    - `error` string, nullable
    - `pdfError` string, nullable: Why the PDF is missing although the Word file was made.
  - `events` DocGenAuditEvent[]: Always empty; each document carries its own events.
    - `id` string
    - `at` string, date-time
    - `by` string
    - `kind` 'filled' | 'entered' | 'edited' | 'reverted' | 'generated' | 'exported' | 'saved' | 'template_uploaded' | 'field_confirmed' | 'parties_chosen'
    - `field` string
    - `fieldLabel` string
    - `from` string, nullable
    - `to` string, nullable
    - `detail` string
    - `documentId` string

## Other responses

- `400`: The request is invalid.
- `403`: The API key does not have the required scope.
- `404`: The requested resource was not found.
- `410`: The batch's files were not kept and the 24-hour download window has passed.
- `503`: PDF conversion is not available at the moment; retryable.

## Changes

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

[Operation history](https://skmtc.dev/talonic/apis/talonic-api/changes/v1/doc-gen/jobs/:id/pdf/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)
