Status & Issues
Check templates, field confirmation, proposals and recent batches in one call, and read the worklist of what looks wrong in Document Generation (/v1/doc-gen).
Two read-only routes give an operator the state of the app without walking every template and batch. GET /v1/doc-gen/status is the cheap overview: how many templates exist, how many fields are confirmed, how many proposals are running, failed or never started, and what the last 30 days of batches look like. It is also the route the talonic_doc_gen_* MCP tools use to probe whether the app is available. GET /v1/doc-gen/issues is the worklist behind those numbers, one entry per thing that looks wrong, each naming the template or batch concerned.
Batches are counted and judged as the key's minting user may read them under Sources IAM, over a window of the last 30 days. An empty data list from the issues route means nothing needs attention. Every entry has a code and a human-readable detail; entries about templates carry template_id and template_name, entries about batches carry job_id, and fields lists the field keys concerned where that applies.
/v1/doc-gen/statusResponse fields
Response: Status
{
"templates": 9,
"fields": { "total": 104, "confirmed": 96, "unconfirmed": 8, "entered_per_document": 14 },
"proposals": { "running": 0, "failed": 1, "never_proposed": 2 },
"jobs": {
"last_30_days": 17,
"documents_last_30_days": 212,
"failed_last_30_days": 0,
"last": {
"id": "e61a0c97-2b4f-4d38-a5c1-7f90d3b8e426",
"created_at": "2026-10-21T09:31:07.000Z",
"status": "completed",
"templates": ["contract-letter"],
"documents": 1
}
}
}/v1/doc-gen/issuesEntry fields and codes
Response: Issues
{
"data": [
{
"code": "fields_unconfirmed",
"template_id": "3b1f6a52-8c0e-4f0a-9d5e-2a7c1e4b9d10",
"template_name": "contract-letter",
"detail": "3 of 12 field(s) are suggestions nobody has confirmed.",
"fields": ["addressee", "reference_line", "closing_remark"]
},
{
"code": "pdf_missing",
"job_id": "e61a0c97-2b4f-4d38-a5c1-7f90d3b8e426",
"detail": "1 document(s) have no PDF; POST /v1/doc-gen/jobs/e61a0c97-2b4f-4d38-a5c1-7f90d3b8e426/pdf makes them again."
}
]
}never_proposed and proposal_pending at the proposal routes, fields_unconfirmed at the confirm route, and pdf_missing at the PDF retry. Poll issues after a batch to learn whether anything needs a person.