---
title: "The charts and diagrams of one PDF"
method: GET
path: "/v1/chart-to-data/pdfs/{documentId}/charts"
tags: ["Chart Extraction"]
---

# The charts and diagrams of one PDF

`GET /v1/chart-to-data/pdfs/{documentId}/charts`

## Request

- Base URL: `https://api.talonic.com`
- URL: `https://api.talonic.com/v1/chart-to-data/pdfs/{documentId}/charts`
- Auth: HTTP bearer

Charts with stored inputs (`ready`) are returned at once. The first request for a file queues a scan on a worker; while it runs, `status` is `queued` or `running` and only the ready charts are listed. When the scan is `done`, `charts` also lists every chart frame the scan found (`found`) and `diagrams` lists the process diagrams read on the scanned pages. Poll until `status` is `done` or `failed`. A scan by an older engine, or one that failed for a transient reason, is queued again on request.

## Path parameters

- `documentId` string, uuid, required

## Response `200`

The charts of the PDF.

- ChartToDataCharts
  - `document_id` string, uuid
  - `status` 'queued' | 'running' | 'done' | 'failed': The state of the file's scan.
  - `error_code` string, nullable
  - `error_message` string, nullable
  - `page_count` integer, nullable: Null until the scan is done.
  - `pages_scanned` integer: 0 until the scan is done.
  - `charts` ChartToDataFoundChart[]
    - `page_number` integer
    - `box` ChartToDataBox: A box in PDF points with a top-left origin.
      - `x` number
      - `y` number
      - `width` number
      - `height` number
    - `state` 'ready' | 'found': `ready` charts have stored inputs and open by `chart_key`; `found` ones were only seen by the scan.
    - `chart_key` string, nullable
    - `id` string: Stable across rescans: the chart key when one is stored, else page and frame corner.
    - `title` string, nullable: The title from the chart's latest reading; absent or null for a chart never read.
    - `reason` string: Optional engineering text explaining why a found chart is not ready, from its scan or latest reading that returned no values. Absent for ready charts and when no reason was stored. Clients map recognized codes to localized sentences and use a generic fallback for unknown codes; raw text is not display copy.
  - `pictures` object[]: Optional unread figure-sized picture diagnostics, grouped by page. Omitted when the scan has none or an older scan stored no picture diagnostics. These are not chart assets or claims.
    - `page_number` integer, required
    - `reasons` string[], required: One engineering reason per unread picture, including the refusal code and explanation when available. Clients map recognized codes to localized sentences and fall back generically for unknown codes.
  - `diagrams` object[]
    - `page_number` integer
    - `view` ChartToDataDiagramView: The process diagram read from one page. `reader` is null when the page holds no diagram.
      - `reader` 'pipe' | 'station', nullable
      - `page` object
        - `width` number
        - `height` number
      - `nodes` object[]
        - `id` string
        - `label` string
        - `kind` string
        - `lane` string, nullable
        - `bbox` number[]
        - `symbol` number[]
        - `at` number[]
        - `items` string[]
        - `evidence` string
      - `edges` object[]
        - `id` string
        - `from` string
        - `to` string
        - `kind` string
        - `directed` boolean: True only when an arrowhead or the line order says which way the connection runs.
        - `evidence` string
        - `path` array[]: Pipe diagrams only: the drawn line segments as polylines of [x, y] points in PDF points.
          - array[]
            - number[]
      - `lanes` object[]
        - `name` string
        - `nodes` string[]

## Other responses

- `400`: The request is invalid.
- `404`: The requested resource was not found.
- `413`: The uploaded file exceeds the size limit.

## Changes

- **2026-11-06** `eb01b697e3e3`: 2 info
  - added the optional property `charts/items/reason` to the response with the `200` status
  - added the optional property `pictures` to the response with the `200` status
- **2026-10-28** `0a485a46163e`: 1 info
  - endpoint added

[Operation history](https://skmtc.dev/talonic/apis/talonic-api/changes/v1/chart-to-data/pdfs/:documentId/charts/get.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)
