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

# Get a saved document's detail, structure outline, and the chats that used it.

> One saved document's metadata plus a STRUCTURE outline and the chat sessions that have it
open (prior-chats-per-file). Owner-scoped — 404 if the document isn't yours.

`structure` (WP8-f, always included, token-light, NON-BILLABLE) is the cheap verify step after
any edit: `headings` (level + text + position), `section_count` (heading-anchored), `block_count`
(editable chunks), `media` (image/diagram counts). The C6 blind-test agent burned ~15-20% of its
entire op budget exporting markdown after every edit purely to check structure — this read
answers the same question for free. Pass include_html=true only when you need the body.



## OpenAPI

````yaml /openapi.json get /v1/documents/{document_id}
openapi: 3.1.0
info:
  title: Universal Document AI API
  description: AI-powered document editing with multi-tenant organization support
  version: 2.0.0
servers: []
security: []
paths:
  /v1/documents/{document_id}:
    get:
      tags:
        - v1
        - mcp
      summary: >-
        Get a saved document's detail, structure outline, and the chats that
        used it.
      description: >-
        One saved document's metadata plus a STRUCTURE outline and the chat
        sessions that have it

        open (prior-chats-per-file). Owner-scoped — 404 if the document isn't
        yours.


        `structure` (WP8-f, always included, token-light, NON-BILLABLE) is the
        cheap verify step after

        any edit: `headings` (level + text + position), `section_count`
        (heading-anchored), `block_count`

        (editable chunks), `media` (image/diagram counts). The C6 blind-test
        agent burned ~15-20% of its

        entire op budget exporting markdown after every edit purely to check
        structure — this read

        answers the same question for free. Pass include_html=true only when you
        need the body.
      operationId: get_document_detail
      parameters:
        - name: document_id
          in: path
          required: true
          schema:
            type: string
            title: Document Id
        - name: include_html
          in: query
          required: false
          schema:
            type: boolean
            description: >-
              When true, also returns the document's full reassembled HTML body
              (`html`), plus its `page_setup` and `version_id`. Default false
              returns metadata + structure + prior-chats only, keeping the
              response token-light. This is the by-id way to read a saved
              document's body without opening it into a session.
            default: false
            title: Include Html
          description: >-
            When true, also returns the document's full reassembled HTML body
            (`html`), plus its `page_setup` and `version_id`. Default false
            returns metadata + structure + prior-chats only, keeping the
            response token-light. This is the by-id way to read a saved
            document's body without opening it into a session.
        - name: authorization
          in: header
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            title: Authorization
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema: {}
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
      security:
        - HTTPBearer: []
components:
  schemas:
    HTTPValidationError:
      properties:
        detail:
          items:
            $ref: '#/components/schemas/ValidationError'
          type: array
          title: Detail
      type: object
      title: HTTPValidationError
    ValidationError:
      properties:
        loc:
          items:
            anyOf:
              - type: string
              - type: integer
          type: array
          title: Location
        msg:
          type: string
          title: Message
        type:
          type: string
          title: Error Type
      type: object
      required:
        - loc
        - msg
        - type
      title: ValidationError
  securitySchemes:
    HTTPBearer:
      type: http
      scheme: bearer

````