> ## Documentation Index
> Fetch the complete documentation index at: https://ionet-cca8037f-confidential-compute.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# Retrieve a document

> Retrieves detailed information about a specific document by its ID.

This endpoint returns the document’s metadata, status, and system information. It does not return the document’s content - use the `/documents/{id}/download` endpoint for that.

Users can only retrieve documents they own or have access to through collections. Superusers can retrieve any document.


## OpenAPI

````yaml openapi/rag-documents/get-document-by-id.json get /api/r2r/v3/documents/{id}
openapi: 3.1.0
info:
  title: IO Intelligence
  version: '1.0'
servers:
  - url: https://api.intelligence.io.solutions
security:
  - sec0: []
paths:
  /api/r2r/v3/documents/{id}:
    get:
      summary: Retrieve a Document
      description: Retrieves detailed information about a specific document by its ID.
      operationId: reverse_proxy_auth_r2r_v3_documents__id__get
      parameters:
        - name: token
          in: header
          required: false
          schema:
            type: string
            description: JWT token
            title: Token
          description: JWT token
        - name: Authorization
          in: header
          required: false
          schema:
            type: string
            description: io.net provided API Key
            title: Authorization
          description: io.net provided API Key
        - name: x-api-key
          in: header
          required: false
          schema:
            type: string
            description: API key set by an SDK client
            title: X-Api-Key
          description: API key set by an SDK client
        - name: id
          in: path
          description: Document ID
          required: true
          schema:
            type: string
      responses:
        '200':
          description: '200'
          content:
            application/json:
              examples:
                Result:
                  value:
                    results:
                      id: 123e4567-e89b-12d3-a456-426614174000
                      collection_ids:
                        - 123e4567-e89b-12d3-a456-426614174000
                      owner_id: 123e4567-e89b-12d3-a456-426614174000
                      document_type: pdf
                      metadata:
                        title: Sample Document
                      version: '1.0'
                      title: Sample Document
                      size_in_bytes: 123456
                      ingestion_status: pending
                      extraction_status: pending
                      created_at: '2021-01-01T00:00:00Z'
                      updated_at: '2021-01-01T00:00:00Z'
                      ingestion_attempt_number: 0
                      summary: A summary of the document
                      summary_embedding:
                        - 0.1
                        - 0.2
                        - 0.3
                      total_tokens: 1000
                      chunks:
                        - key: value
              schema:
                type: object
                properties:
                  results:
                    type: object
                    properties:
                      id:
                        type: string
                        example: 123e4567-e89b-12d3-a456-426614174000
                      collection_ids:
                        type: array
                        items:
                          type: string
                          example: 123e4567-e89b-12d3-a456-426614174000
                      owner_id:
                        type: string
                        example: 123e4567-e89b-12d3-a456-426614174000
                      document_type:
                        type: string
                        example: pdf
                      metadata:
                        type: object
                        properties:
                          title:
                            type: string
                            example: Sample Document
                      version:
                        type: string
                        example: '1.0'
                      title:
                        type: string
                        example: Sample Document
                      size_in_bytes:
                        type: integer
                        example: 123456
                        default: 0
                      ingestion_status:
                        type: string
                        example: pending
                      extraction_status:
                        type: string
                        example: pending
                      created_at:
                        type: string
                        example: '2021-01-01T00:00:00Z'
                      updated_at:
                        type: string
                        example: '2021-01-01T00:00:00Z'
                      ingestion_attempt_number:
                        type: integer
                        example: 0
                        default: 0
                      summary:
                        type: string
                        example: A summary of the document
                      summary_embedding:
                        type: array
                        items:
                          type: number
                          example: 0.1
                          default: 0
                      total_tokens:
                        type: integer
                        example: 1000
                        default: 0
                      chunks:
                        type: array
                        items:
                          type: object
                          properties:
                            key:
                              type: string
                              example: value
        '404':
          description: '404'
          content:
            application/json:
              examples:
                Result:
                  value: {}
              schema:
                type: object
                properties: {}
        '422':
          description: '422'
          content:
            text/plain:
              examples:
                Result:
                  value: ''
      deprecated: false
components:
  securitySchemes:
    sec0:
      type: oauth2
      flows: {}

````