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

# Get Enterprise Search Index Status

> ## 1️⃣ Overview

**Purpose:**  
Retrieves the current indexing status of the enterprise search connector for a specific workspace.

Use this endpoint to monitor whether indexing is in progress, completed, or failed.

---

## 2️⃣ Endpoint

``` bash
GET /ai/api/v2/enterprise-search/connector/dg-s3-workspace/{workspaceId}/status

 ```

---

## 3️⃣ Path Parameters

| Parameter | Type | Required | Description |
| --- | --- | --- | --- |
| workspaceId | string | ✅ Yes | The ID of the workspace to check the index status for |

---

## 4️⃣ Authentication

Requires authentication using:

``` bash
Authorization: Bearer <token>

 ```

---

## 5️⃣ Request Headers

| Header | Required |
| --- | --- |
| Authorization | ✅ Yes |

---

## 6️⃣ Example Request

``` bash
curl --location 'https://ai.datagol.ai/ai/api/v2/enterprise-search/connector/dg-s3-workspace/{workspaceId}/status' \
--header 'Authorization: Bearer <token>'

 ```

---

## 7️⃣ Behavior Summary

``` id="behes2"
Returns the current indexing status of the enterprise search connector for the specified workspace.
Typically used to poll the status after triggering a re-index via the Re-index Workspace Files endpoint.

 ```



## OpenAPI

````yaml /openapi/openapi.yaml get /ai/api/v2/enterprise-search/connector/dg-s3-workspace/{workspaceId}/status
openapi: 3.0.0
info:
  title: DataGOL APIs
  version: 1.0.0
  description: ''
servers:
  - url: https://be.datagol.ai
  - url: https://be.datagol.ai
  - url: https://kg.datagol.ai
  - url: https://ai.datagol.ai
security: []
tags:
  - name: Links & Joins
    description: >
      ## 🔗 Links & Joins


      LINK and LOOKUP are special workbook column types that enable relational
      data modeling across tables.


      | Column Type | Purpose |

      |---|---|

      | `LINK` | Defines a relationship between two tables |

      | `LOOKUP` | Projects columns from an associated table via a link |


      Both are configured through `ColumnDTO.colOptions`. A table can have
      multiple link columns, and each link can have multiple lookup columns.


      ---


      ## 📐 UI Data Types


      - **LINK** — Special column used to represent inter-table relations

      - **LOOKUP** — Special column used to project associated table fields via
      a link


      ---


      ## 🔗 LINK Semantics


      A LINK column stores metadata for:

      - `tableId` — Current table

      - `associatedTableId` — Associated (linked) table

      - `relationType` — Type of relationship

      - `linkColumnId` — Link column identifier


      **Supported relation patterns:**


      | Pattern | Description |

      |---|---|

      | `ONE_TO_ONE` | Each record in the source maps to one record in the
      destination |

      | `ONE_TO_MANY` | One source record maps to many destination records |

      | `MANY_TO_MANY` | Many source records map to many destination records |


      ---


      ## 🔍 LOOKUP Semantics


      - A LOOKUP column is tightly coupled with a specific LINK column

      - References a link using `linkColumnId`

      - Represents a selected column from the associated table

      - Multiple lookup columns can be defined for the same link


      ---


      ## 🗂️ Metadata in `ColumnDTO.colOptions`


      Use `colOptions` to persist link/lookup metadata.


      | Field | Description |

      |---|---|

      | `columnId` | Current column ID |

      | `tableId` | Current table ID |

      | `associatedTableId` | Associated table ID |

      | `linkColumnId` | Link column ID — used by LOOKUP; references the LINK
      column's `columnId` |

      | `relationType` | Relation semantics for LINK |


      ---


      ## 🔄 Manual Linking Record Flow


      To create manual record-level links:


      1. Fetch associated table schema/data

      2. User selects associated record(s) to link

      3. Send linking payload with:
          - `sourceRecordId` — PK of the current table row
          - `destinationRecordId` — PK of the associated table row
          - `linkColumnId` — LINK column identifier
      4. Backend resolves link metadata from `linkColumnId` (relation type,
      associated table, direction/constraints)

      5. Backend applies relation rules and stores the link relation


      ---


      ## 📋 Record Linking Contract


      | Field | Description |

      |---|---|

      | `sourceRecordId` | PK of the current table row |

      | `destinationRecordId` | PK of the associated table row |

      | `linkColumnId` | LINK column identifier |

      | `tableId` | Current table ID |


      > Backend derives all remaining relation metadata from the link
      configuration.


      ---


      ## ⚠️ Important Notes


      > - LINK and LOOKUP are **column-level constructs** first; record linking
      is a data-level operation built on top

      > - LOOKUP behavior depends on LINK existence and metadata integrity

      > - With multiple links to the same associated table, each LOOKUP must
      bind to the correct `linkColumnId`

      > - Always treat the associated row ID as the associated table PK for
      linking UI selection
paths:
  /ai/api/v2/enterprise-search/connector/dg-s3-workspace/{workspaceId}/status:
    get:
      tags:
        - Enterprise Search
      summary: Get Enterprise Search Index Status
      description: >-
        ## 1️⃣ Overview


        **Purpose:**  

        Retrieves the current indexing status of the enterprise search connector
        for a specific workspace.


        Use this endpoint to monitor whether indexing is in progress, completed,
        or failed.


        ---


        ## 2️⃣ Endpoint


        ``` bash

        GET
        /ai/api/v2/enterprise-search/connector/dg-s3-workspace/{workspaceId}/status

         ```

        ---


        ## 3️⃣ Path Parameters


        | Parameter | Type | Required | Description |

        | --- | --- | --- | --- |

        | workspaceId | string | ✅ Yes | The ID of the workspace to check the
        index status for |


        ---


        ## 4️⃣ Authentication


        Requires authentication using:


        ``` bash

        Authorization: Bearer <token>

         ```

        ---


        ## 5️⃣ Request Headers


        | Header | Required |

        | --- | --- |

        | Authorization | ✅ Yes |


        ---


        ## 6️⃣ Example Request


        ``` bash

        curl --location
        'https://ai.datagol.ai/ai/api/v2/enterprise-search/connector/dg-s3-workspace/{workspaceId}/status'
        \

        --header 'Authorization: Bearer <token>'

         ```

        ---


        ## 7️⃣ Behavior Summary


        ``` id="behes2"

        Returns the current indexing status of the enterprise search connector
        for the specified workspace.

        Typically used to poll the status after triggering a re-index via the
        Re-index Workspace Files endpoint.

         ```
      parameters:
        - name: workspaceId
          in: path
          required: true
          schema:
            type: string
          description: The ID of the workspace to check the index status for
          example: '{{workspaceId}}'
      responses:
        '200':
          description: Get Enterprise Search Index Status
          content:
            application/json:
              schema:
                type: object
                properties:
                  connector_status:
                    type: object
                    description: Overall status of the workspace file connector
                    properties:
                      cc_pair_id:
                        type: integer
                        description: Internal ID of the connector-credential pair
                        example: 125
                      name:
                        type: string
                        description: Name of the connector-credential pair
                        example: Datagol-Workspace_File_Connector-{workspaceId}
                      cc_pair_status:
                        type: string
                        description: >-
                          Current status of the connector pair (e.g. PAUSED,
                          ACTIVE)
                        example: PAUSED
                      access_type:
                        type: string
                        description: Access type for the connector (e.g. public, private)
                        example: public
                      last_finished_status:
                        type: string
                        description: >-
                          Result of the last completed indexing run (e.g.
                          success, failure)
                        example: success
                      last_status:
                        type: string
                        description: Status of the most recent indexing attempt
                        example: success
                      last_success:
                        type: string
                        format: date-time
                        description: Timestamp of the last successful indexing run
                        example: '2026-05-29T12:22:50.515871Z'
                      docs_indexed:
                        type: integer
                        description: >-
                          Total number of documents currently indexed for this
                          workspace
                        example: 2
                      in_progress:
                        type: boolean
                        description: Whether an indexing job is currently running
                        example: true
                      in_repeated_error_state:
                        type: boolean
                        description: >-
                          Whether the connector is stuck in a repeated error
                          state
                        example: false
                      latest_index_attempt:
                        type: object
                        description: Details of the most recent indexing attempt
                        properties:
                          id:
                            type: integer
                            description: Internal ID of the index attempt
                            example: 396
                          status:
                            type: string
                            description: >-
                              Result status of the index attempt (e.g. success,
                              failure, in_progress)
                            example: success
                          from_beginning:
                            type: boolean
                            description: >-
                              Whether this was a full re-index from the
                              beginning
                            example: true
                          new_docs_indexed:
                            type: integer
                            description: Number of new documents indexed in this attempt
                            example: 1
                          total_docs_indexed:
                            type: integer
                            description: Total documents indexed across all attempts
                            example: 2
                          docs_removed_from_index:
                            type: integer
                            description: >-
                              Number of documents removed from the index in this
                              attempt
                            example: 0
                          error_msg:
                            type: string
                            nullable: true
                            description: >-
                              Error message if the attempt failed, null
                              otherwise
                            example: null
                          error_count:
                            type: integer
                            description: Number of errors encountered during this attempt
                            example: 0
                          time_started:
                            type: string
                            format: date-time
                            description: Timestamp when the index attempt started
                            example: '2026-05-29T12:22:50.457155+00:00'
                          time_updated:
                            type: string
                            format: date-time
                            description: Timestamp of the last update to this attempt
                            example: '2026-05-29T12:22:57.745602+00:00'
                          poll_range_start:
                            type: string
                            format: date-time
                            description: Start of the time range polled in this attempt
                            example: '1970-01-01T00:00:00Z'
                          poll_range_end:
                            type: string
                            format: date-time
                            description: End of the time range polled in this attempt
                            example: '2026-05-29T12:22:50.515871Z'
                  file_level_indexing_status:
                    type: object
                    description: Per-file indexing status keyed by file ID
                    additionalProperties:
                      type: object
                      properties:
                        id:
                          type: string
                          description: File ID
                          example: de4765c5-7705-4544-aba6-6dfbdeb7b35a
                        status:
                          type: string
                          description: >-
                            Indexing status of the file (e.g. INDEXED, PENDING,
                            FAILED)
                          example: INDEXED
                        last_modified:
                          type: string
                          format: date-time
                          description: Timestamp when the file was last modified
                          example: '2026-05-29T11:40:34Z'
                        last_synced:
                          type: string
                          format: date-time
                          nullable: true
                          description: >-
                            Timestamp when the file was last synced, null if
                            never synced
                          example: null
                        has_been_indexed:
                          type: boolean
                          description: >-
                            Whether the file has been successfully indexed at
                            least once
                          example: true
      security:
        - bearerAuth: []
components:
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      bearerFormat: JWT
      description: |
        This API uses OAuth 2.0 with the authorization code grant flow.

````