Documents, extractions, jobs and schemas
These tools cover the day-to-day housekeeping of a workspace: listing documents, reading a document again, correcting values, running one saved schema over many documents as a job, and changing or removing saved schemas. Every call runs as the person behind the connection: a document that person cannot see answers 404, exactly like a missing one.
write scope. talonic_delete_document and talonic_delete_schema cannot be undone, and talonic_update_schema with a new field list removes every field you do not send again. Agents confirm with the user before calling them. Re-extracting a document and creating a job consume credits and are not deduplicated: after a timeout, check the first call's result before calling again.talonic_list_documents
List documents, newest first, one page at a time. Returns data[] (id, filename, pages, status, source, field count, created_at) and pagination { total, limit, has_more, next_cursor }.
| Parameter | Type | Description |
|---|---|---|
| status | string | Only documents with this status, e.g. `error`. |
| source_id | UUID | Only documents from this source. |
| source_type | string | Only documents from this kind of source. |
| search | string | Filename contains (case-insensitive). |
| parent_id | UUID | Only documents unpacked from this one (email attachments, archive members). |
| relation | string | Only nested documents of this kind. |
| top_level | boolean | `true` hides nested documents. |
| text_degraded | boolean | `true`: only documents whose text could not be read verbatim. |
| limit | integer | Items per page, 1-100. Default 20. |
| cursor | string | `pagination.next_cursor` of the previous page. |
| order | asc | desc | By creation time. Default desc (newest first). |
| after | ISO-8601 | Only items created after this time. |
| before | ISO-8601 | Only items created before this time. |
talonic_reextract_document
Read an existing document again and capture its values afresh, without uploading it again. Consumes credits like a new extraction. Answers at once with status: processing; poll talonic_get_document until it is completed.
| Parameter | Type | Description |
|---|---|---|
| document_id * | UUID | The document. |
talonic_delete_document
Delete one document with its captured values. Cannot be undone. Documents only shared with the user are read-only and answer 404. Returns { deleted: true, id }.
| Parameter | Type | Description |
|---|---|---|
| document_id * | UUID | The document. |
talonic_list_extractions
List extractions, one per document with captured values, newest first. An extraction's id is its document's id.
| Parameter | Type | Description |
|---|---|---|
| document_id | UUID | Only this document's extraction. |
| status | complete | failed | Only finished or failed ones. |
| limit | integer | Items per page, 1-100. Default 20. |
| cursor | string | `pagination.next_cursor` of the previous page. |
| order | asc | desc | By creation time. Default desc (newest first). |
| after | ISO-8601 | Only items created after this time. |
| before | ISO-8601 | Only items created before this time. |
talonic_get_extraction
One extraction in full: every field with its value, type and confidence.
| Parameter | Type | Description |
|---|---|---|
| extraction_id * | UUID | The extraction (document) id. |
talonic_get_extraction_data
One extraction's values as a flat field → value map, or as a one-row CSV ({ format: 'csv', csv }).
| Parameter | Type | Description |
|---|---|---|
| extraction_id * | UUID | The extraction (document) id. |
| format | json | csv | Default json. |
talonic_correct_extraction
Correct captured values. Each correction is kept as a new version of the value, attributed to the connection. A value a reviewer confirmed, or one waiting for approval, is not overwritten: it is reported in cells_skipped. Returns the extraction with cells_written and cells_skipped.
| Parameter | Type | Description |
|---|---|---|
| extraction_id * | UUID | The extraction (document) id. |
| values * | object | `{ <field_name>: corrected value }` for the fields to change. |
talonic_list_jobs
List jobs (one saved schema run over a set of documents), newest first.
| Parameter | Type | Description |
|---|---|---|
| status | string | Only jobs with this status. |
| limit | integer | Items per page, 1-100. Default 20. |
| cursor | string | `pagination.next_cursor` of the previous page. |
| order | asc | desc | By creation time. Default desc (newest first). |
| after | ISO-8601 | Only items created after this time. |
| before | ISO-8601 | Only items created before this time. |
talonic_get_job
One job's status, schema, document count, timestamps and error. Poll it after talonic_create_job.
| Parameter | Type | Description |
|---|---|---|
| job_id * | UUID | The job. |
talonic_get_job_results
A job's result rows: one per document with its values, confidence and validation flags. Readable while the job still runs.
| Parameter | Type | Description |
|---|---|---|
| job_id * | UUID | The job. |
talonic_create_job
Run a saved schema over many documents and collect one row of values per document. Consumes credits per document. Name the documents, or pass all_documents: true for every completed document of the workspace. Returns the job id; poll talonic_get_job.
| Parameter | Type | Description |
|---|---|---|
| schema_id * | UUID | The saved schema to run. |
| document_ids | UUID[] | The documents to process. |
| all_documents | boolean | `true`: every completed document, instead of `document_ids`. |
| name | string | A name for the job, up to 200 characters. |
talonic_cancel_job
Cancel a pending or running job; rows already produced stay. Safe to retry: a job that already ended answers 409 and is left as it is.
| Parameter | Type | Description |
|---|---|---|
| job_id * | UUID | The job. |
talonic_update_schema
Rename a saved schema, change its description, or replace its field list. A new definition or fields list replaces every field, so read the schema first with talonic_get_schema and send the whole list. A schema managed by a Spec answers 409; change the Spec in the app instead.
| Parameter | Type | Description |
|---|---|---|
| schema_id * | string | UUID or SCH-XXXXXXXX short id. |
| name | string | New name, up to 100 characters. |
| description | string | null | New description; null clears it. |
| definition | object | The full field list as JSON Schema: `{ properties, required }`. |
| fields | object[] | The full field list as rows: `field_name`, `display_name`, `data_type`, `description`, `is_required`. |
talonic_delete_schema
Delete a saved schema. Cannot be undone; documents already extracted with it keep their values. A schema managed by a Spec answers 409.
| Parameter | Type | Description |
|---|---|---|
| schema_id * | string | UUID or SCH-XXXXXXXX short id. |