> ## Documentation Index
> Fetch the complete documentation index at: https://docs.usenexio.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Start a table extraction from a conversation document

> Starts one job, as the acting seat, that reads every page of a document the conversation holds in parallel chunks and files one spreadsheet draft with one row per item and a Source page column. A value a page does not show stays blank; rows keep page order and are never deduplicated. With summary, the job groups, counts and adds up the items itself into summary rows and a total row, and checks them against the document's printed grand totals. The draft is filed on the account when one is named, else as the seat's own. Read the job's status at its id until its state is done, partial or failed.



## OpenAPI

````yaml /openapi.generated.json post /documents/table-extractions
openapi: 3.1.0
info:
  description: >-
    Public API reference. Generated from apps/engine/openapi.yaml by make
    docs-openapi-write. Do not edit.
  title: Nexio platform API
  version: '1'
servers:
  - url: https://api.usenexio.com
security: []
tags:
  - name: Access
  - name: Catalog
  - name: Conversations
  - name: Documents
  - name: Engines
  - name: Events
  - name: Feedback
  - name: Graph
  - name: Records
  - name: Roadmap
  - name: Runs
  - name: Webhooks
  - name: accounts
  - name: actions
  - name: activities
  - name: activity-feed
  - name: attachments
  - name: audit
  - name: benefit-plans
  - name: billing-transactions
  - name: carrier_documents
  - name: certificate-holders
  - name: certificate_drafts
  - name: certificates
  - name: change_feed
  - name: claims
  - name: classes
  - name: codes
  - name: commission_facts
  - name: connections
  - name: contacts
  - name: contingencies
  - name: conversations
  - name: customer
  - name: customer_contacts
  - name: deals
  - name: dependents
  - name: document_extractions
  - name: documents
  - name: drivers
  - name: eforms
  - name: employees
  - name: events
  - name: feature_requests
  - name: form-templates
  - name: invoices
  - name: leads
  - name: line_schedules_other
  - name: loss_history
  - name: machines
  - name: markets
  - name: motor-carriers
  - name: notes
  - name: opportunities
  - name: opportunity-signals
  - name: pages
  - name: personal_lines_detail
  - name: placement_choices
  - name: placement_feedback
  - name: placements
  - name: policies
  - name: policy_parties
  - name: policy_personnel
  - name: policy_transactions
  - name: premium_rows
  - name: procedures
  - name: proposals
  - name: quote_comparisons
  - name: quotes
  - name: records
  - name: register-views
  - name: renewal-entries
  - name: risk_review_choices
  - name: rollups
  - name: seats
  - name: sec-filings
  - name: service_agreements
  - name: submissions
  - name: suspenses
  - name: tasks
  - name: umbrella_underlying
  - name: underwriting_questions
  - name: uploaded_documents
  - name: vehicles
  - name: workflows
paths:
  /documents/table-extractions:
    post:
      tags:
        - Documents
      summary: Start a table extraction from a conversation document
      description: >-
        Starts one job, as the acting seat, that reads every page of a document
        the conversation holds in parallel chunks and files one spreadsheet
        draft with one row per item and a Source page column. A value a page
        does not show stays blank; rows keep page order and are never
        deduplicated. With summary, the job groups, counts and adds up the items
        itself into summary rows and a total row, and checks them against the
        document's printed grand totals. The draft is filed on the account when
        one is named, else as the seat's own. Read the job's status at its id
        until its state is done, partial or failed.
      operationId: startDocumentTableExtraction
      parameters:
        - description: >-
            The member the read is made for (a WorkOS user id). Unset keeps the
            org-wide posture the key alone grants.
          in: header
          name: Nexio-Act-As
          schema:
            description: >-
              The member the read is made for (a WorkOS user id). Unset keeps
              the org-wide posture the key alone grants.
            type: string
        - description: >-
            The acting member's verified email, lowercased. Ignored without
            Nexio-Act-As.
          in: header
          name: Nexio-Act-As-Email
          schema:
            description: >-
              The acting member's verified email, lowercased. Ignored without
              Nexio-Act-As.
            type: string
        - description: The calling application (workbench).
          in: header
          name: Nexio-Consumer
          schema:
            description: The calling application (workbench).
            type: string
        - description: The calling application's build.
          in: header
          name: Nexio-Consumer-Build
          schema:
            description: The calling application's build.
            type: string
        - description: The access vocabulary hash the calling build was generated against.
          in: header
          name: Nexio-Consumer-Vocabulary
          schema:
            description: >-
              The access vocabulary hash the calling build was generated
              against.
            type: string
        - description: >-
            A caller-chosen request id, echoed in the Nexio-Request-Id response
            header.
          in: header
          name: Nexio-Request-Id
          schema:
            description: >-
              A caller-chosen request id, echoed in the Nexio-Request-Id
              response header.
            type: string
        - description: >-
            The caller's remaining budget for this request, in whole
            milliseconds (1 to 10 digits, greater than zero), relative to
            receipt. The engine stops work at the shorter of this and the
            route's own budget, and answers 504 request_timeout when it expires.
            A value above the route budget is capped to it; a malformed value is
            ignored.
          in: header
          name: Nexio-Timeout
          schema:
            description: >-
              The caller's remaining budget for this request, in whole
              milliseconds (1 to 10 digits, greater than zero), relative to
              receipt. The engine stops work at the shorter of this and the
              route's own budget, and answers 504 request_timeout when it
              expires. A value above the route budget is capped to it; a
              malformed value is ignored.
            type: string
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/DocumentTableExtractionRequest'
        required: true
      responses:
        '202':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/DocumentTableExtractionAnswer'
          description: Accepted
        '400':
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/Problem'
          description: Bad Request
        '401':
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/Problem'
          description: Unauthorized
        '403':
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/Problem'
          description: Forbidden
        '404':
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/Problem'
          description: Not Found
        '409':
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/Problem'
          description: Conflict
        '413':
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/Problem'
          description: Request Entity Too Large
        '422':
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/Problem'
          description: Unprocessable Entity
        '500':
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/Problem'
          description: Internal Server Error
        '503':
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/Problem'
          description: Service Unavailable
      security:
        - bearer: []
components:
  schemas:
    DocumentTableExtractionRequest:
      additionalProperties: false
      properties:
        account:
          description: >-
            An account to file the draft on, admitted under the seat's scope.
            Absent: the draft is the seat's own.
          type: string
        attachment_id:
          description: >-
            The document's id in the conversation, or its doc: address on the
            current version.
          type: string
        columns:
          description: >-
            1 to 11 distinct column names, each 1 to 80 characters, used
            verbatim as headers. The job adds Source page as the last column.
          items:
            type: string
          type:
            - array
            - 'null'
        conversation_id:
          description: The conversation that holds the document (a UUID).
          type: string
        row_rule:
          description: >-
            What one row is, at most 300 characters; with summary, what one item
            is. Absent: one row per item the columns describe.
          type: string
        summary:
          $ref: '#/components/schemas/DocumentTableExtractionSummary'
          description: >-
            Summary rows instead of one row per item: every item is read, then
            grouped, counted and added up by the job and checked against the
            document's printed grand totals. Absent: one row per item.
        title:
          description: >-
            The spreadsheet's table title, at most 120 characters. Absent: the
            file name.
          type: string
      required:
        - conversation_id
        - attachment_id
        - columns
      type: object
    DocumentTableExtractionAnswer:
      additionalProperties: false
      properties:
        data:
          $ref: '#/components/schemas/DocumentTableExtraction'
      required:
        - data
      type: object
    Problem:
      additionalProperties: false
      properties:
        code:
          description: >-
            The stable machine-readable error code, UPPER_SNAKE_CASE, one
            meaning forever.
          enum:
            - INVALID_ARGUMENT
            - UNAUTHENTICATED
            - CAPABILITY_DENIED
            - NOT_VISIBLE_OR_ABSENT
            - IDEMPOTENT_REQUEST_IN_FLIGHT
            - ETAG_MISMATCH
            - VALIDATION_FAILED
            - IDEMPOTENCY_KEY_PAYLOAD_MISMATCH
            - SOURCE_UNAVAILABLE
            - RATE_LIMITED
            - INTERNAL
            - DEADLINE_EXCEEDED
            - UNAVAILABLE
            - CLIENT_CLOSED_REQUEST
          type: string
        detail:
          description: A human-readable sentence about this occurrence.
          type: string
        details:
          description: >-
            Structured detail for the reason (for example which owner selection
            rule failed). A Records refusal names its reason code in
            details.reason; a projection refusal (SOURCE_UNAVAILABLE) also names
            its closed subtype in details.subtype (admission_pending, no_build,
            binding_changed, agency_admission_unbounded,
            authority_coordinates_changed, guard_absent, derivation_unaccepted),
            and only admission_pending, which clears by itself, also carries
            details.retry_after_ms, equal to retry_after_ms and the Retry-After
            header.
        errors:
          description: Each invalid parameter, for INVALID_ARGUMENT.
          items:
            $ref: '#/components/schemas/ProblemError'
          type:
            - array
            - 'null'
        instance:
          description: The request path this occurrence answered.
          type: string
        reason:
          description: >-
            The finer cause within the code, UPPER_SNAKE_CASE (for example
            SCOPE_UNAVAILABLE under CAPABILITY_DENIED).
          type: string
        request_id:
          description: The request id, as echoed in the Nexio-Request-Id response header.
          type: string
        retry_after_ms:
          description: When a retry may succeed, the wait before it.
          format: int64
          type: integer
        status:
          description: The HTTP status code.
          format: int64
          type: integer
        title:
          description: The HTTP status phrase.
          type: string
        type:
          description: A URI naming the problem type, derived from the code.
          type: string
      required:
        - type
        - title
        - status
        - code
        - request_id
      type: object
    DocumentTableExtractionSummary:
      additionalProperties: false
      properties:
        count:
          description: The column that holds each row's number of items.
          type: string
        group_by:
          description: >-
            The columns whose values key one summary row (a policy effective and
            expiration date). Empty: one row for the whole document.
          items:
            type: string
          type:
            - array
            - 'null'
        period:
          description: >-
            An item date the columns do not show (a date of loss). An item whose
            group-by values are blank is grouped into the 12-month period of
            this date that holds it, counted from the first date of the
            document's printed range, and the row's group-by columns name the
            period's start and end.
          type: string
        sum:
          description: The columns added up over each row's items.
          items:
            type: string
          type:
            - array
            - 'null'
      required:
        - group_by
        - sum
      type: object
    DocumentTableExtraction:
      additionalProperties: false
      properties:
        attachment_id:
          type: string
        columns:
          description: 'The headers: the asked columns, then Source page.'
          items:
            type: string
          type:
            - array
            - 'null'
        conversation_id:
          type: string
        created_at:
          format: date-time
          type: string
        draft:
          description: >-
            Null until filed; then the template fill's draft (draftId,
            templateId, format and the rest).
        error:
          anyOf:
            - $ref: '#/components/schemas/DocumentTableExtractionError'
              description: Why a job failed, or on a partial summary which totals differ.
            - type: 'null'
        failed_pages:
          items:
            $ref: '#/components/schemas/DocumentTableExtractionFailedPages'
          type:
            - array
            - 'null'
        filename:
          type: string
        finished_at:
          format: date-time
          type:
            - string
            - 'null'
        id:
          type: string
        pages_done:
          description: Pages in chunks that ended, read or failed.
          format: int64
          type: integer
        pages_total:
          format: int64
          type: integer
        row_rule:
          type: string
        rows:
          description: Rows found so far.
          format: int64
          type: integer
        settled:
          description: >-
            True once the job is done, partial or failed: its state never
            changes again.
          type: boolean
        state:
          description: >-
            running: chunks reading. filing: every chunk ended and the draft is
            being filed. done: every page read and the draft filed. partial: the
            draft filed, and failed_pages lists pages no attempt could read or
            error (totals_mismatch) says which summary totals differ from the
            document's printed ones. failed: no draft; error says why.
          enum:
            - running
            - filing
            - done
            - partial
            - failed
          type: string
        title:
          type: string
        updated_at:
          format: date-time
          type: string
      required:
        - id
        - state
        - settled
        - conversation_id
        - attachment_id
        - filename
        - title
        - columns
        - row_rule
        - pages_total
        - pages_done
        - rows
        - failed_pages
        - draft
        - error
        - created_at
        - updated_at
        - finished_at
      type: object
    ProblemError:
      additionalProperties: false
      properties:
        location:
          description: Where the input was, for example query.limit.
          type: string
        message:
          type: string
        value: {}
      required:
        - message
      type: object
    DocumentTableExtractionError:
      additionalProperties: false
      properties:
        code:
          type: string
        message:
          type: string
      required:
        - code
        - message
      type: object
    DocumentTableExtractionFailedPages:
      additionalProperties: false
      properties:
        from:
          format: int64
          type: integer
        reason:
          enum:
            - model_error
            - invalid_answer
            - page_unreadable
          type: string
        to:
          format: int64
          type: integer
      required:
        - from
        - to
        - reason
      type: object
  securitySchemes:
    bearer:
      description: The org's platform API key.
      scheme: bearer
      type: http

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.