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

# Read Collections

> Retrieve collections with pagination.

Returns a paginated list of collections with filtering options.

Args:
    skip: Number of records to skip (for pagination)
    limit: Maximum number of records to return
    status: Filter by collection status (e.g., 'active', 'archived')
    visibility: Filter by visibility ('public' or 'private')
    search: Search term for name or description
    tags: Comma-separated list of tags to filter by
    
Returns:
    PaginatedResponse with collections and total count
    
Examples:
    Get first page:
        GET /collections?skip=0&limit=20
    
    Get second page:
        GET /collections?skip=20&limit=20
    
    Filter by status:
        GET /collections?status=active&limit=50
        
    Search collections:
        GET /collections?search=documents&limit=20
        
    Filter by tags:
        GET /collections?tags=important,work&limit=50



## OpenAPI

````yaml api-reference/openapi.json get /api/v1/collections
openapi: 3.1.0
info:
  title: FastAPI app
  version: 0.1.0
servers: []
security: []
paths:
  /api/v1/collections:
    get:
      tags:
        - Collections
      summary: Read Collections
      description: |-
        Retrieve collections with pagination.

        Returns a paginated list of collections with filtering options.

        Args:
            skip: Number of records to skip (for pagination)
            limit: Maximum number of records to return
            status: Filter by collection status (e.g., 'active', 'archived')
            visibility: Filter by visibility ('public' or 'private')
            search: Search term for name or description
            tags: Comma-separated list of tags to filter by
            
        Returns:
            PaginatedResponse with collections and total count
            
        Examples:
            Get first page:
                GET /collections?skip=0&limit=20
            
            Get second page:
                GET /collections?skip=20&limit=20
            
            Filter by status:
                GET /collections?status=active&limit=50
                
            Search collections:
                GET /collections?search=documents&limit=20
                
            Filter by tags:
                GET /collections?tags=important,work&limit=50
      operationId: read_collections_api_v1_collections_get
      parameters:
        - name: skip
          in: query
          required: false
          schema:
            type: integer
            minimum: 0
            description: Number of collections to skip
            default: 0
            title: Skip
          description: Number of collections to skip
        - name: limit
          in: query
          required: false
          schema:
            type: integer
            maximum: 1000
            minimum: 1
            description: Number of collections to return
            default: 100
            title: Limit
          description: Number of collections to return
        - name: status
          in: query
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            description: Filter by collection status
            title: Status
          description: Filter by collection status
        - name: visibility
          in: query
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            description: Filter by visibility (public/private)
            title: Visibility
          description: Filter by visibility (public/private)
        - name: search
          in: query
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            description: Search collections by name or description
            title: Search
          description: Search collections by name or description
        - name: tags
          in: query
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            description: Filter by tags (comma-separated)
            title: Tags
          description: Filter by tags (comma-separated)
        - name: X-Workspace-Id
          in: header
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            description: The workspace ID
            title: X-Workspace-Id
          description: The workspace ID
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/PaginatedResponse_CollectionRead_'
        '404':
          description: Collection not found
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
      security:
        - DualAuthScheme: []
components:
  schemas:
    PaginatedResponse_CollectionRead_:
      properties:
        data:
          items:
            $ref: '#/components/schemas/CollectionRead'
          type: array
          title: Data
        total_count:
          type: integer
          title: Total Count
        page:
          anyOf:
            - type: integer
            - type: 'null'
          title: Page
        limit:
          anyOf:
            - type: integer
            - type: 'null'
          title: Limit
        next_page:
          anyOf:
            - type: integer
            - type: 'null'
          title: Next Page
        next_cursor:
          anyOf:
            - type: string
            - type: 'null'
          title: Next Cursor
        has_more:
          anyOf:
            - type: boolean
            - type: 'null'
          title: Has More
      type: object
      required:
        - data
        - total_count
      title: PaginatedResponse[CollectionRead]
    HTTPValidationError:
      properties:
        detail:
          items:
            $ref: '#/components/schemas/ValidationError'
          type: array
          title: Detail
      type: object
      title: HTTPValidationError
    CollectionRead:
      properties:
        id:
          type: string
          title: Id
          description: Collection ID
        created_at:
          anyOf:
            - type: string
            - type: 'null'
          title: Created At
        updated_at:
          anyOf:
            - type: string
            - type: 'null'
          title: Updated At
        name:
          type: string
          maxLength: 100
          minLength: 1
          title: Name
          description: Collection name
        description:
          anyOf:
            - type: string
              maxLength: 255
            - type: 'null'
          title: Description
          description: Collection description
        store_type:
          anyOf:
            - type: string
            - $ref: '#/components/schemas/CollectionStoreType'
            - type: 'null'
          title: Store Type
          description: Storage type for the collection
        visibility:
          type: string
          title: Visibility
          description: Collection visibility (private/public)
          default: private
        status:
          type: string
          title: Status
          description: Collection status
          default: active
        tags:
          anyOf:
            - items:
                type: string
              type: array
            - type: 'null'
          title: Tags
          description: Collection tags for organization
        parent_id:
          anyOf:
            - type: string
            - type: 'null'
          title: Parent Id
          description: Reference to parent collection
        stats:
          additionalProperties: true
          type: object
          title: Stats
          description: Collection statistics
          default: {}
        meta_data:
          additionalProperties: true
          type: object
          title: Meta Data
          description: Collection metadata
          default: {}
        settings:
          additionalProperties: true
          type: object
          title: Settings
          description: Collection configuration settings
          default: {}
        embedding:
          anyOf:
            - $ref: '#/components/schemas/EmbeddingModelSettings'
            - type: 'null'
          description: Embedding configuration
          default: {}
        source_type:
          anyOf:
            - type: string
            - type: 'null'
          title: Source Type
          description: Collection source type
          default: document
        source_id:
          anyOf:
            - type: string
            - type: 'null'
          title: Source Id
          description: Collection source ID
        workspace_id:
          type: string
          title: Workspace Id
          description: Reference to workspace
        created_by:
          anyOf:
            - type: string
            - type: 'null'
          title: Created By
          description: User who created the collection
      type: object
      required:
        - id
        - name
        - workspace_id
      title: CollectionRead
      description: Schema for reading collection data.
    ValidationError:
      properties:
        loc:
          items:
            anyOf:
              - type: string
              - type: integer
          type: array
          title: Location
        msg:
          type: string
          title: Message
        type:
          type: string
          title: Error Type
      type: object
      required:
        - loc
        - msg
        - type
      title: ValidationError
    CollectionStoreType:
      type: string
      enum:
        - pgvector
        - langchain_pgvector
        - chroma
        - pinecone
        - milvus
        - qdrant
        - mongodb
        - upstash
      title: CollectionStoreType
    EmbeddingModelSettings:
      properties:
        provider:
          anyOf:
            - $ref: '#/components/schemas/EmbeddingProvider'
            - type: string
            - type: 'null'
          title: Provider
        model:
          anyOf:
            - type: string
            - type: 'null'
          title: Model
        dimensions:
          anyOf:
            - type: integer
            - type: 'null'
          title: Dimensions
        use_default_cred:
          anyOf:
            - type: boolean
            - type: 'null'
          title: Use Default Cred
          default: true
        credentials:
          anyOf:
            - $ref: '#/components/schemas/EmbeddingModelCustomCredentials'
            - type: 'null'
      type: object
      title: EmbeddingModelSettings
    EmbeddingProvider:
      type: string
      enum:
        - openai
        - azure_openai
        - aws_bedrock
        - sentence_transformer
        - voyageai
        - google
        - ollama
        - mistral
        - cohere
        - jina
        - huggingface
        - together
      title: EmbeddingProvider
    EmbeddingModelCustomCredentials:
      properties:
        api_key:
          anyOf:
            - type: string
            - type: 'null'
          title: Api Key
        credential_id:
          anyOf:
            - type: string
            - type: 'null'
          title: Credential Id
        organization:
          anyOf:
            - type: string
            - type: 'null'
          title: Organization
        base_url:
          anyOf:
            - type: string
            - type: 'null'
          title: Base Url
        batch_size:
          anyOf:
            - type: integer
            - type: 'null'
          title: Batch Size
        max_retries:
          anyOf:
            - type: integer
            - type: 'null'
          title: Max Retries
        timeout:
          anyOf:
            - type: integer
            - type: 'null'
          title: Timeout
      type: object
      title: EmbeddingModelCustomCredentials
  securitySchemes:
    DualAuthScheme:
      type: http
      scheme: bearer

````