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

# Get Knowledgebase

> A knowledge base with its totals and a page of its datasources.

API key permission: Knowledge Base (Admin also opens it).



## OpenAPI

````yaml /api-reference/openapi.json get /knowledgebase/{entry_id}
openapi: 3.1.0
info:
  title: Neural Factory API
  version: 0.1.0
  description: >-
    The endpoints a program can call with an API key. Exchange the key's secret
    for a token at POST /apikeys/token and send it as a Bearer token.
servers:
  - url: https://api.neuralfactory.ai
    description: SaaS
  - url: https://{apiHost}
    description: 'Enterprise: the API address of your own deployment'
    variables:
      apiHost:
        default: api.example.com
        description: Your deployment's API host
security:
  - bearerAuth: []
tags:
  - name: API keys
  - name: Chat
  - name: Runs
  - name: Agents
  - name: Workflows
  - name: Schedules
  - name: Knowledge bases
  - name: Documents
  - name: Search
  - name: Skills
  - name: Toolkits
  - name: Files
  - name: Interactions
  - name: Usage and billing
  - name: Catalogue
  - name: Browser
  - name: Users
  - name: Groups
  - name: Builds
paths:
  /knowledgebase/{entry_id}:
    get:
      tags:
        - Knowledge bases
      summary: Get Knowledgebase
      description: |-
        A knowledge base with its totals and a page of its datasources.

        API key permission: Knowledge Base (Admin also opens it).
      operationId: get_knowledgebase_knowledgebase__entry_id__get
      parameters:
        - name: entry_id
          in: path
          required: true
          schema:
            type: string
            title: Entry Id
        - name: page
          in: query
          required: false
          schema:
            type: integer
            minimum: 1
            description: Page number for datasources, starting from 1
            default: 1
            title: Page
          description: Page number for datasources, starting from 1
        - name: page_size
          in: query
          required: false
          schema:
            type: integer
            maximum: 100
            minimum: 1
            description: Number of datasources per page
            default: 20
            title: Page Size
          description: Number of datasources per page
        - name: search
          in: query
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            description: Search datasources by name
            title: Search
          description: Search datasources by name
        - name: env
          in: query
          required: false
          schema:
            title: Env
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: >-
                  #/components/schemas/api__knowledgebase__models__KnowledgeBaseDetail
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
components:
  schemas:
    api__knowledgebase__models__KnowledgeBaseDetail:
      properties:
        knowledgebase:
          $ref: '#/components/schemas/KnowledgeBaseEntry'
        summary:
          $ref: '#/components/schemas/KnowledgeBaseSummary'
        datasources:
          $ref: '#/components/schemas/DatasourceList'
      type: object
      required:
        - knowledgebase
        - summary
        - datasources
      title: KnowledgeBaseDetail
      description: Enhanced knowledge base detail response with datasources and summary
    HTTPValidationError:
      properties:
        detail:
          items:
            $ref: '#/components/schemas/ValidationError'
          type: array
          title: Detail
      type: object
      title: HTTPValidationError
    KnowledgeBaseEntry:
      properties:
        id:
          type: string
          title: Id
        title:
          type: string
          title: Title
        title_slug:
          type: string
          title: Title Slug
        description:
          type: string
          title: Description
        deleting:
          type: boolean
          title: Deleting
        organization_id:
          anyOf:
            - type: string
            - type: 'null'
          title: Organization Id
        created_by:
          anyOf:
            - type: string
            - type: 'null'
          title: Created By
        visibility:
          type: string
          title: Visibility
          default: private
        allowed_user_ids:
          items:
            type: string
          type: array
          title: Allowed User Ids
          default: []
        allowed_group_ids:
          items:
            type: string
          type: array
          title: Allowed Group Ids
          default: []
        languages:
          items:
            type: string
          type: array
          title: Languages
          default: []
        sources_count:
          type: integer
          title: Sources Count
          default: 0
        total_documents:
          type: integer
          title: Total Documents
          default: 0
        indexing_progress:
          type: number
          title: Indexing Progress
          default: 0
        last_updated:
          anyOf:
            - type: string
              format: date-time
            - type: 'null'
          title: Last Updated
        status:
          type: string
          title: Status
          default: active
        availability:
          type: string
          title: Availability
          default: active
        created_at:
          anyOf:
            - type: string
              format: date-time
            - type: 'null'
          title: Created At
        updated_at:
          anyOf:
            - type: string
              format: date-time
            - type: 'null'
          title: Updated At
      type: object
      required:
        - id
        - title
        - title_slug
        - description
        - deleting
      title: KnowledgeBaseEntry
    KnowledgeBaseSummary:
      properties:
        total_documents:
          type: integer
          title: Total Documents
        data_sources_count:
          type: integer
          title: Data Sources Count
        indexing_progress:
          type: number
          title: Indexing Progress
        last_updated:
          anyOf:
            - type: string
              format: date-time
            - type: 'null'
          title: Last Updated
      type: object
      required:
        - total_documents
        - data_sources_count
        - indexing_progress
        - last_updated
      title: KnowledgeBaseSummary
      description: Summary statistics for knowledge base detail view
    DatasourceList:
      properties:
        items:
          items:
            $ref: '#/components/schemas/DatasourceEntry'
          type: array
          title: Items
        meta:
          $ref: '#/components/schemas/PaginationMeta'
      type: object
      required:
        - items
        - meta
      title: DatasourceList
      description: Paginated datasources list
    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
    DatasourceEntry:
      properties:
        id:
          type: string
          title: Id
        name:
          type: string
          title: Name
        type:
          type: string
          title: Type
        documents_count:
          type: integer
          title: Documents Count
        last_modified:
          anyOf:
            - type: string
              format: date-time
            - type: 'null'
          title: Last Modified
        status:
          type: string
          title: Status
        description:
          anyOf:
            - type: string
            - type: 'null'
          title: Description
        created_by_email:
          anyOf:
            - type: string
            - type: 'null'
          title: Created By Email
        created_by_name:
          anyOf:
            - type: string
            - type: 'null'
          title: Created By Name
        sync_enabled:
          anyOf:
            - type: boolean
            - type: 'null'
          title: Sync Enabled
        sync_interval:
          anyOf:
            - type: integer
            - type: 'null'
          title: Sync Interval
        cron_expression:
          anyOf:
            - type: string
            - type: 'null'
          title: Cron Expression
        sync_config:
          anyOf:
            - additionalProperties: true
              type: object
            - type: 'null'
          title: Sync Config
        last_sync_error:
          anyOf:
            - type: string
            - type: 'null'
          title: Last Sync Error
        last_sync_warning:
          anyOf:
            - type: string
            - type: 'null'
          title: Last Sync Warning
        sync_in_progress:
          anyOf:
            - type: boolean
            - type: 'null'
          title: Sync In Progress
        last_sync:
          anyOf:
            - type: string
            - type: 'null'
          title: Last Sync
      type: object
      required:
        - id
        - name
        - type
        - documents_count
        - last_modified
        - status
      title: DatasourceEntry
      description: Model for datasource entries in the knowledge base detail view
    PaginationMeta:
      properties:
        total:
          type: integer
          title: Total
        page:
          type: integer
          title: Page
        page_size:
          type: integer
          title: Page Size
        total_pages:
          type: integer
          title: Total Pages
      type: object
      required:
        - total
        - page
        - page_size
        - total_pages
      title: PaginationMeta
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      bearerFormat: JWT
      description: >-
        The access_token returned by POST /apikeys/token for an API key's
        secret.

````

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