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

# Check knowledge-base indexing progress

> Per-document indexing state for one agent, plus a summary count by status. An agent cannot use a document during a call until its `sync_status` is `synced`.

`providers` shows which search backends have finished indexing that document — useful when one backend lags behind the others.



## OpenAPI

````yaml /openapi.json get /agent/{id}/documents/sync-status
openapi: 3.1.0
info:
  title: Vocobase API
  version: '2.0'
  description: >-
    API for managing voice AI agents, documents, and calls on the Vocobase
    platform.
servers:
  - url: https://api.vocobase.com/api/v2
    description: Production
security:
  - bearerAuth: []
tags:
  - name: Config
    description: >-
      Read and update account configuration, webhook settings, and telephony
      credentials.
  - name: Agents
    description: Create, read, update, and delete voice AI agents.
  - name: Voices
    description: >-
      List voice tiers, available voices, and stream preview audio for agent
      configuration.
  - name: Documents
    description: Upload, manage, and delete knowledge base documents.
  - name: Agent Documents
    description: Link and unlink documents to agents for knowledge base integration.
  - name: Calls
    description: Initiate outbound calls and view call history.
  - name: Phone Numbers
    description: >-
      Import DIDs, assign agents for inbound routing, and re-sync carrier
      Application bindings.
  - name: Inbound Routing Policies
    description: >-
      Define pre-answer routing decisions for inbound calls before AI sessions
      are created.
  - name: Telephony Connections
    description: Create, list, rename, and disconnect named V2 telephony connections.
  - name: VoiceLink Management
    description: Manage VoiceLink reseller clients, DID mapping, and readiness sync.
  - name: Projects
    description: Organize agents into projects. Every agent belongs to exactly one project.
  - name: Dictionaries
    description: Speech-recognition dictionary CRUD and agent attachment.
  - name: Sessions
    description: Browser-initiated WebRTC voice sessions for in-app voice agents.
  - name: Campaigns
    description: Batch outbound calling.
  - name: Billing
    description: Balance, transactions, and usage summaries.
  - name: Custom Functions
    description: HTTP endpoints the agent can call mid-conversation.
  - name: Extraction Sets
    description: Reusable sets of post-call extraction fields.
  - name: Lifecycle Hooks
    description: Automatic pre-call and post-call integration steps.
  - name: Messaging
    description: Bring-your-own WhatsApp sending.
  - name: Integration Logs
    description: Audit trail for integration calls.
  - name: Connectors
    description: Catalog of tools an agent can be connected to.
  - name: Customers
    description: B2B2B sub-tenants and their tool connections.
  - name: Agent Tools
    description: Binding connectors and connections to an agent.
paths:
  /agent/{id}/documents/sync-status:
    get:
      tags:
        - Agent Documents
      summary: Check knowledge-base indexing progress
      description: >-
        Per-document indexing state for one agent, plus a summary count by
        status. An agent cannot use a document during a call until its
        `sync_status` is `synced`.


        `providers` shows which search backends have finished indexing that
        document — useful when one backend lags behind the others.
      operationId: getAgentDocumentSyncStatus
      parameters:
        - name: id
          in: path
          required: true
          schema:
            type: string
            format: uuid
          description: Agent ID.
        - name: status
          in: query
          required: false
          schema:
            type: string
            enum:
              - pending
              - syncing
              - synced
              - failed
              - deleted
          description: >-
            Return only documents in this sync state. The summary always counts
            all of them.
      responses:
        '200':
          description: Success.
          content:
            application/json:
              schema:
                type: object
                properties:
                  success:
                    type: boolean
                    const: true
                  data:
                    type: object
                    properties:
                      agent_id:
                        type: string
                        format: uuid
                      summary:
                        type: object
                        properties:
                          total:
                            type: integer
                          pending:
                            type: integer
                          syncing:
                            type: integer
                          synced:
                            type: integer
                          failed:
                            type: integer
                          deleted:
                            type: integer
                      documents:
                        type: array
                        items:
                          type: object
                          properties:
                            document_id:
                              type: string
                              format: uuid
                            name:
                              type: string
                            type:
                              type: string
                              enum:
                                - file
                                - web_link
                                - paragraph
                            sync_status:
                              type: string
                              enum:
                                - pending
                                - syncing
                                - synced
                                - failed
                                - deleted
                            sync_error:
                              type: string
                              nullable: true
                            synced_at:
                              type: string
                              format: date-time
                              nullable: true
                            linked_at:
                              type: string
                              format: date-time
                            providers:
                              type: object
                              properties:
                                supermemory:
                                  type: boolean
                                gemini:
                                  type: boolean
                                vertex:
                                  type: boolean
                                azure:
                                  type: boolean
              example:
                success: true
                data:
                  agent_id: a1b2c3d4-e5f6-7890-abcd-ef1234567890
                  summary:
                    total: 3
                    pending: 0
                    syncing: 1
                    synced: 2
                    failed: 0
                    deleted: 0
                  documents:
                    - document_id: d1234567-abcd-1234-abcd-123456789012
                      name: Product FAQ.pdf
                      type: file
                      sync_status: synced
                      sync_error: null
                      synced_at: '2026-08-26T12:01:14.000Z'
                      linked_at: '2026-08-26T12:00:58.000Z'
                      providers:
                        supermemory: true
                        gemini: true
                        vertex: true
                        azure: false
                    - document_id: d3456789-abcd-1234-abcd-123456789012
                      name: Refund policy
                      type: paragraph
                      sync_status: syncing
                      sync_error: null
                      synced_at: null
                      linked_at: '2026-08-26T12:02:03.000Z'
                      providers:
                        supermemory: true
                        gemini: false
                        vertex: false
                        azure: false
        '400':
          description: '`status` is not one of the allowed values.'
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
              example:
                success: false
                error:
                  code: VALIDATION_ERROR
                  message: >-
                    status must be one of: pending, syncing, synced, failed,
                    deleted
        '401':
          $ref: '#/components/responses/Unauthorized'
        '404':
          $ref: '#/components/responses/NotFound'
        '429':
          $ref: '#/components/responses/RateLimitExceeded'
        '500':
          $ref: '#/components/responses/InternalError'
components:
  schemas:
    ErrorResponse:
      type: object
      properties:
        success:
          type: boolean
          const: false
        error:
          type: object
          properties:
            code:
              type: string
            message:
              type: string
          required:
            - code
            - message
      required:
        - success
        - error
  responses:
    Unauthorized:
      description: Missing or invalid API key.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorResponse'
          example:
            success: false
            error:
              code: UNAUTHORIZED
              message: Invalid or missing API key
    NotFound:
      description: Resource not found.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorResponse'
          example:
            success: false
            error:
              code: NOT_FOUND
              message: Resource not found
    RateLimitExceeded:
      description: Per-account rate limit exceeded. Retry after a short backoff.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorResponse'
          example:
            success: false
            error:
              code: RATE_LIMITED
              message: Rate limit exceeded. Retry after 60 seconds.
    InternalError:
      description: Unexpected server error.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorResponse'
          example:
            success: false
            error:
              code: INTERNAL_ERROR
              message: An unexpected error occurred
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      description: >-
        API key in format: `rg_live_xxxx`. Pass as a Bearer token in the
        Authorization header.

````