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

# Получаване на документи

> Получаване на всички документи в база знания

Този endpoint връща списък с всички документи в конкретна база знания.

### Параметри от пътя

<ParamField path="knowledgebaseId" type="integer" required>
  Уникалният идентификатор на базата знания
</ParamField>

### Отговор

<ResponseField name="data" type="array">
  Масив от обекти документи

  <Expandable title="свойства на документа">
    <ResponseField name="id" type="integer">
      Уникалният идентификатор на документа
    </ResponseField>

    <ResponseField name="name" type="string">
      Името на документа
    </ResponseField>

    <ResponseField name="description" type="string">
      Опционално описание на документа
    </ResponseField>

    <ResponseField name="type" type="string">
      Тип документ: `website`, `pdf`, `txt`, или `docx`
    </ResponseField>

    <ResponseField name="type_label" type="string">
      Четим етикет за типа
    </ResponseField>

    <ResponseField name="status" type="string">
      Статус на обработката: `processing`, `active`, или `failed`
    </ResponseField>

    <ResponseField name="status_label" type="string">
      Четим етикет за статуса
    </ResponseField>

    <ResponseField name="created_at" type="string">
      ISO 8601 времеви печат на създаването
    </ResponseField>

    <ResponseField name="updated_at" type="string">
      ISO 8601 времеви печат на последната актуализация
    </ResponseField>
  </Expandable>
</ResponseField>

<ResponseExample>
  ```json 200 Response theme={null}
  {
    "data": [
      {
        "id": 1,
        "name": "Product Manual",
        "description": "Complete product user manual",
        "type": "pdf",
        "type_label": "PDF",
        "status": "active",
        "status_label": "Active",
        "created_at": "2025-01-05T10:30:00.000000Z",
        "updated_at": "2025-01-05T10:35:00.000000Z"
      },
      {
        "id": 2,
        "name": "Company Website",
        "description": "Main website content",
        "type": "website",
        "type_label": "Website",
        "status": "processing",
        "status_label": "Processing",
        "created_at": "2025-01-08T09:00:00.000000Z",
        "updated_at": "2025-01-08T09:00:00.000000Z"
      }
    ]
  }
  ```

  ```json 404 Knowledgebase Not Found theme={null}
  {
    "error": "Knowledgebase not found."
  }
  ```
</ResponseExample>

### Статуси на документи

| Статус       | Описание                                                    |
| ------------ | ----------------------------------------------------------- |
| `processing` | Документът се обработва и вгражда във векторната база данни |
| `active`     | Документът е обработен и готов за използване                |
| `failed`     | Обработката на документа е неуспешна                        |

***
