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

# Form Fields Result Check

> Poll this endpoint to check the status of a Form Fields request and retrieve the fields found.



## OpenAPI

````yaml https://www.datalab.to/openapi.json get /api/v1/form-fields/{request_id}
openapi: 3.1.0
info:
  title: Datalab API
  version: 0.0.1
servers:
  - url: https://www.datalab.to
    description: Datalab API
security: []
paths:
  /api/v1/form-fields/{request_id}:
    get:
      summary: Form Fields Result Check
      description: >-
        Poll this endpoint to check the status of a Form Fields request and
        retrieve the fields found.
      operationId: result_response_api_v1_form_fields__request_id__get
      parameters:
        - name: request_id
          in: path
          required: true
          schema:
            type: string
            title: Request Id
        - name: wos-session
          in: cookie
          required: false
          schema:
            type: string
            title: Wos-Session
        - name: datalab_active_team
          in: cookie
          required: false
          schema:
            type: string
            title: Datalab Active Team
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/FormFieldsFinalResponse'
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
      security:
        - APIKeyHeader: []
components:
  schemas:
    FormFieldsFinalResponse:
      properties:
        status:
          type: string
          title: Status
          description: >-
            The status of the request. Should be 'complete' when the request is
            done.
        result_url:
          anyOf:
            - type: string
            - type: 'null'
          title: Result Url
          description: >-
            Signed URL for downloading the completed result JSON when direct
            result download is required.
        expires_in:
          anyOf:
            - type: integer
            - type: 'null'
          title: Expires In
          description: Number of seconds until result_url expires.
        success:
          anyOf:
            - type: boolean
            - type: 'null'
          title: Success
          description: Whether form field detection was successful.
        error:
          anyOf:
            - type: string
            - type: 'null'
          title: Error
          description: Error message if form field detection failed.
        pages:
          anyOf:
            - items:
                $ref: '#/components/schemas/FormFieldsPage'
              type: array
            - type: 'null'
          title: Pages
          description: The fields found on each processed page.
        page_count:
          anyOf:
            - type: integer
            - type: 'null'
          title: Page Count
          description: Number of pages processed.
        total_cost:
          anyOf:
            - type: number
            - type: 'null'
          title: Total Cost
        cost_breakdown:
          anyOf:
            - additionalProperties: true
              type: object
            - type: 'null'
          title: Cost Breakdown
          description: A dictionary of the cost breakdown of this request.
        runtime:
          anyOf:
            - type: number
            - type: 'null'
          title: Runtime
          description: Processing time in seconds.
        versions:
          anyOf:
            - additionalProperties: true
              type: object
            - type: string
            - type: 'null'
          title: Versions
          description: A dictionary of the versions of the libraries used in the request.
      type: object
      required:
        - status
      title: FormFieldsFinalResponse
      description: Response model for the form fields endpoint.
    HTTPValidationError:
      properties:
        detail:
          items:
            $ref: '#/components/schemas/ValidationError'
          type: array
          title: Detail
      type: object
      title: HTTPValidationError
    FormFieldsPage:
      properties:
        page:
          type: integer
          title: Page
          description: The page index, starting at 0.
        fields:
          items:
            $ref: '#/components/schemas/FormField'
          type: array
          title: Fields
          description: The fields on the page, in reading order.
        error:
          type: string
          title: Error
          description: Set when the model could not read this page.
          default: ''
      type: object
      required:
        - page
      title: FormFieldsPage
    ValidationError:
      properties:
        loc:
          items:
            anyOf:
              - type: string
              - type: integer
          type: array
          title: Location
        msg:
          type: string
          title: Message
        type:
          type: string
          title: Error Type
        input:
          title: Input
        ctx:
          type: object
          title: Context
      type: object
      required:
        - loc
        - msg
        - type
      title: ValidationError
    FormField:
      properties:
        field_type:
          type: string
          title: Field Type
          description: >-
            The kind of field: signature, initials, email, name, firstName,
            lastName, company, title, date, text, checkbox or radio.
        bbox:
          items:
            type: number
          type: array
          title: Bbox
          description: >-
            The field box as [x0, y0, x1, y1], in fractions of the page width
            and height, with the origin at the top left.
        label:
          type: string
          title: Label
          description: The printed label that tells a person what to enter in the field.
          default: ''
      type: object
      required:
        - field_type
        - bbox
      title: FormField
  securitySchemes:
    APIKeyHeader:
      type: apiKey
      in: header
      name: X-API-Key

````

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