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

# Debug a pipeline

> The documents to be debugged are sent in the request body. The output shows the state of the document after each indexing stage. A debug request will index documents to the system, but you can prevent it from doing so by setting the query parameter 'simulate' to false.



## OpenAPI

````yaml /api-reference/4.2/service-index-pipelines.json post /index-pipelines/{id}/collections/{collection}/debug
openapi: 3.0.0
info:
  version: 4.2.6-rc1
  title: Fusion Service index-pipelines
servers:
  - url: /api/apollo/
security: []
tags:
  - name: index-pipelines
paths:
  /index-pipelines/{id}/collections/{collection}/debug:
    post:
      tags:
        - 4.2 Index Pipelines API
      summary: Debug a pipeline
      description: >-
        The documents to be debugged are sent in the request body. The output
        shows the state of the document after each indexing stage. A debug
        request will index documents to the system, but you can prevent it from
        doing so by setting the query parameter 'simulate' to false.
      operationId: debugPipelineDocument
      parameters:
        - name: id
          in: path
          description: The name of a specific pipeline
          required: true
          schema:
            type: string
        - name: collection
          in: path
          description: The name of a specific collection
          required: true
          schema:
            type: string
        - name: simulate
          in: query
          description: >-
            If true, documents won’t be sent to Solr for indexing; the
            solr-index stage is skipped
          required: false
          schema:
            type: boolean
            default: false
        - name: echo
          in: query
          description: >-
            If true, return the list of indexed documents; if false, no output
            is returned
          required: false
          schema:
            type: boolean
            default: true
        - name: echoMaxCount
          in: query
          description: The maximum number of documents to list in the output
          required: false
          schema:
            type: integer
            format: int32
            default: 100
        - name: bufferDocsForSolr
          in: query
          description: >-
            If true, documents will be buffered before sending to Solr; this is
            an asynchronous mode and may give faster performance when indexing a
            large number of documents
          required: false
          schema:
            type: boolean
        - name: throwOnError
          in: query
          required: false
          schema:
            type: boolean
            default: true
        - name: eventsCollection
          in: query
          required: false
          schema:
            type: string
        - name: eventsPipeline
          in: query
          description: >-
            A string containing the name of the index pipeline that processes
            the link events; required for event processing
          required: false
          schema:
            type: string
        - name: eventTypes
          in: query
          description: >-
            A comma-separated list of eventTypes to be processed by the
            specified index pipeline; the only supported event type is 'links'
          required: false
          schema:
            type: string
      requestBody:
        $ref: '#/components/requestBodies/debugPipelineDocumentBody'
      responses:
        '200':
          description: successful operation
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/IndexPipelineDebugResponse'
components:
  requestBodies:
    debugPipelineDocumentBody:
      content:
        application/vnd.lucidworks-document:
          schema: {}
        application/vnd.solr-document:
          schema: {}
  schemas:
    IndexPipelineDebugResponse:
      type: object
      properties:
        stages:
          type: array
          items:
            $ref: '#/components/schemas/StageConfig'
        output:
          type: object
          additionalProperties:
            type: array
            items:
              $ref: '#/components/schemas/ContextAndDoc'
        outputEncounteredCount:
          type: integer
          format: int64
    StageConfig:
      type: object
      properties:
        type:
          type: string
          readOnly: true
        id:
          type: string
          readOnly: true
        skip:
          type: boolean
          default: false
        label:
          type: string
        condition:
          type: string
    ContextAndDoc:
      type: object
      properties:
        context:
          type: object
          additionalProperties:
            type: object
        error:
          type: string
        doc:
          $ref: '#/components/schemas/PipelineDocument'
    PipelineDocument:
      type: object
      properties:
        id:
          type: string
        fields:
          type: array
          readOnly: true
          items:
            $ref: '#/components/schemas/PipelineField'
        metadata:
          type: object
          additionalProperties:
            type: string
        commands:
          type: array
          items:
            $ref: '#/components/schemas/Command'
        hints:
          type: object
          additionalProperties:
            type: array
            uniqueItems: true
            items:
              type: string
    PipelineField:
      type: object
      properties:
        name:
          type: string
        value:
          type: object
        metadata:
          type: object
          additionalProperties:
            type: string
        annotations:
          type: array
          items:
            $ref: '#/components/schemas/Annotation'
    Command:
      type: object
      properties:
        name:
          type: string
          readOnly: true
        params:
          type: object
          readOnly: true
          additionalProperties:
            type: string
    Annotation:
      type: object
      properties:
        type:
          type: string
        start:
          type: integer
          format: int64
        end:
          type: integer
          format: int64
        features:
          type: object
          readOnly: true
          additionalProperties:
            type: string
        label:
          type: string
          readOnly: true
        featureCount:
          type: integer
          format: int32

````