Knowledge Base
List Knowledge Base Documents
List knowledge base documents to verify an upload or inspect the non-deleted files in a knowledge base.
GET
List Knowledge Base Documents
Read only
List knowledge base documents to verify an upload or inspect the non-deleted files in a knowledge base. Results are paginated. Each document carries its
id, title, knowledge_base_id, description, source, document_type, file_size, file_path, the full extracted text in content, and its indexing state in ingest_status, ingest_error, ingest_updated_at and ingest_job_id. Document IDs and knowledge_base_id are raw, without a prefix.
Before you begin
- Use a knowledge base ID from List Knowledge Bases.
- Send a valid workspace API key.
List Knowledge Base Documents Request
Query parameters
Verify the result
Readdata.items and data.meta in the 200 response. Pagination metadata includes totalItems, itemsPerPage, totalPages, and currentPage. Match an uploaded document by ID and title. file_size is in KB, with 1024 bytes per KB.
Errors and recovery
401 means the API key is missing or invalid. 400 means knowledge_base_id is missing, or page or limit is a decimal. 404 means the knowledge base ID does not exist in your workspace or the knowledge base has been deleted. Because document listings carry the full text of every file, DialNexa does not confirm that a knowledge base belongs to another workspace, so a valid ID you do not own returns the same 404 as one that was never created. Check the ID against List Knowledge Bases. Send page and limit as whole numbers of at least 1: a value that is not a number is ignored and the default is used, a decimal returns 400, limit=0 returns an empty page, and page=0 fails with 500. Use a valid document field for sortBy; an unknown field also fails with 500. sortOrder accepts ASC or DESC in any case; any other value fails with 500. This read is safe to retry.
Related endpoints
Authorizations
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Query Parameters
Knowledge base ID.
Example:
"kb_abc123def45678"
Page number.
Documents per page.
Document field to sort by.
Sort direction: ASC or DESC, in any case. Default ASC. Any other value fails with 500.