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

# Get Product Preview

> Get a preview of products extracted from a document (Phase 7 HITL).

Returns the first 5 products using the current column mapping,
useful for reviewing mapping accuracy before confirming.

Requires: document:read permission



## OpenAPI

````yaml /openapi/merchantops-public.json get /api/lakehouse/documents/{document_id}/preview
openapi: 3.1.0
info:
  description: >-
    Public API for the MerchantOps product catalog, pricing, and publishing
    surface.
  title: MerchantOps API
  version: 1.0.0
servers:
  - description: Production
    url: https://api.merchantops.ai
security: []
paths:
  /api/lakehouse/documents/{document_id}/preview:
    get:
      tags:
        - Product Lakehouse
      summary: Get Product Preview
      description: |-
        Get a preview of products extracted from a document (Phase 7 HITL).

        Returns the first 5 products using the current column mapping,
        useful for reviewing mapping accuracy before confirming.

        Requires: document:read permission
      operationId: get_product_preview
      parameters:
        - in: path
          name: document_id
          required: true
          schema:
            title: Document Id
            type: string
        - in: header
          name: authorization
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            title: Authorization
        - in: header
          name: X-Organization-ID
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            title: X-Organization-Id
        - in: cookie
          name: stytch_session
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            title: Stytch Session
      responses:
        '200':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ProductPreviewResponse'
          description: Successful Response
        '422':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
          description: Validation Error
components:
  schemas:
    ProductPreviewResponse:
      description: Response with preview of products using current mapping.
      properties:
        column_mapping:
          additionalProperties:
            anyOf:
              - type: string
              - type: 'null'
          title: Column Mapping
          type: object
        document_id:
          title: Document Id
          type: string
        preview_products:
          items:
            $ref: '#/components/schemas/ProductPreview'
          title: Preview Products
          type: array
        total_rows:
          title: Total Rows
          type: integer
      required:
        - document_id
        - total_rows
        - preview_products
        - column_mapping
      title: ProductPreviewResponse
      type: object
    HTTPValidationError:
      properties:
        detail:
          items:
            $ref: '#/components/schemas/ValidationError'
          title: Detail
          type: array
      title: HTTPValidationError
      type: object
    ProductPreview:
      description: Preview of a single product extracted from spreadsheet.
      properties:
        brand:
          anyOf:
            - type: string
            - type: 'null'
          title: Brand
        confidence:
          title: Confidence
          type: number
        description:
          anyOf:
            - type: string
            - type: 'null'
          title: Description
        mapped_fields:
          additionalProperties: true
          title: Mapped Fields
          type: object
        product_name:
          anyOf:
            - type: string
            - type: 'null'
          title: Product Name
        row_number:
          title: Row Number
          type: integer
        vendor_style_id:
          anyOf:
            - type: string
            - type: 'null'
          title: Vendor Style Id
      required:
        - row_number
        - product_name
        - brand
        - vendor_style_id
        - description
        - confidence
        - mapped_fields
      title: ProductPreview
      type: object
    ValidationError:
      properties:
        ctx:
          title: Context
          type: object
        input:
          title: Input
        loc:
          items:
            anyOf:
              - type: string
              - type: integer
          title: Location
          type: array
        msg:
          title: Message
          type: string
        type:
          title: Error Type
          type: string
      required:
        - loc
        - msg
        - type
      title: ValidationError
      type: object

````