INNER CODE UNIT · Python

list_documents_in_index

kaito-project/kaito · presets/ragengine/main.py:522

async def list_documents_in_index(
    index_name: str,
    limit: int = Query(
        10, ge=1, le=100, description="Maximum number of documents to return"
    ),
    offset: int = Query(0, ge=0, description="Starting point for the document list"),
    max_text_length: int | None = Query(
        1000,
        ge=1,
        description="Maximum text length to return **per document**. This does not impose a limit on the total length of all documents returned.",
    ),
    metadata_filter: str | None | None = Query(
        None,
        description="Optional metadata filter to apply when listing documents. This should be a dictionary with key-value pairs to match against document metadata.",
    ),
):
    """
    Handles URL-encoded index names sent by the client.

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…