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

# Preview what a commit with this mapping would write

> Streams the parsed document with the given mapping and returns one page of a clause's rows, each marked as creating or updating an item on the starting branch, plus optional per-clause counts. Writes nothing.



## OpenAPI

````yaml /openapi/customer-api.json post /project/{projectId}/reqif-import/{jobId}/preview
openapi: 3.0.0
info:
  contact: {}
  description: >-
    Flow customer API reference. Start with the [quickstart](/api/quickstart)
    and [authentication guide](/api/authentication).
  title: Customer API
  version: 1.0.0
servers:
  - description: Flow API
    url: '{baseUrl}'
    variables:
      baseUrl:
        default: https://backend.branch.flowengineering.com
security: []
tags:
  - name: Audit
  - name: Automations
  - name: Branches
  - name: Comments
  - name: Convert
  - name: Data Model
  - name: Diagrams
  - name: Entities
  - name: Events
  - name: Files
  - name: Import
  - name: Notifications
  - name: Persistent agents
  - name: Projects
  - name: ReqIF
  - name: ReqIF Import
  - name: Review policy
  - name: Shared Access Grants
  - name: User Groups
  - name: Users
  - name: Views
paths:
  /project/{projectId}/reqif-import/{jobId}/preview:
    post:
      tags:
        - ReqIF Import
      summary: Preview what a commit with this mapping would write
      description: >-
        Streams the parsed document with the given mapping and returns one page
        of a clause's rows, each marked as creating or updating an item on the
        starting branch, plus optional per-clause counts. Writes nothing.
      operationId: ReqifImportController_preview
      parameters:
        - in: path
          name: projectId
          required: true
          schema:
            type: string
        - in: path
          name: jobId
          required: true
          schema:
            type: string
        - description: Workspace identifier
          in: header
          name: customer
          required: true
          schema:
            type: string
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/PreviewReqifImportDto'
        required: true
      responses:
        '200':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ReqifImportPreviewResponseDto'
          description: ''
      security:
        - api-key: []
        - bearer: []
components:
  schemas:
    PreviewReqifImportDto:
      properties:
        base_branch_id:
          description: >-
            The branch the import would start from, which decides whether a row
            creates or updates an item. Omit or "master" for the base branch.
          type: string
        clause_id:
          description: The clause whose rows to return. Omit to return no rows.
          type: string
        clauses:
          description: >-
            The mapping clauses to preview, in precedence order, as the commit
            takes them.
          items:
            type: object
          type: array
        include_counts:
          description: >-
            Also count, for every clause, the rows that would create and update
            items.
          type: boolean
        limit:
          default: 50
          description: Rows to return.
          maximum: 100
          type: number
        offset:
          default: 0
          description: Rows of the clause to skip, in document order.
          type: number
      required:
        - clauses
      type: object
    ReqifImportPreviewResponseDto:
      properties:
        counts:
          description: Per-clause counts, when requested.
          items:
            $ref: '#/components/schemas/ReqifImportPreviewCountDto'
          type: array
        counts_complete:
          description: >-
            False when the counts stopped short of the whole document, so they
            are lower bounds.
          type: boolean
        has_more:
          description: Whether the clause has rows past this page.
          type: boolean
        rows:
          items:
            $ref: '#/components/schemas/ReqifImportPreviewRowDto'
          type: array
      required:
        - rows
        - has_more
      type: object
    ReqifImportPreviewCountDto:
      properties:
        clause_id:
          type: string
        created:
          type: number
        updated:
          type: number
      required:
        - clause_id
        - created
        - updated
      type: object
    ReqifImportPreviewRowDto:
      properties:
        id_value:
          description: The value the row is identified by (its Source ID).
          type: string
        identifier:
          description: The ReqIF object identifier.
          type: string
        outcome:
          description: >-
            Whether the commit would create a new item or update an existing
            one.
          enum:
            - created
            - updated
          type: string
        values:
          description: >-
            The Flow field values the commit would write, by field key, in
            stored form.
          type: object
      required:
        - identifier
        - outcome
        - id_value
        - values
      type: object
  securitySchemes:
    api-key:
      in: header
      name: X-API-Key
      type: apiKey
    bearer:
      bearerFormat: JWT
      scheme: bearer
      type: http

````

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