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

# List Message Threads



## OpenAPI

````yaml get /v1/threads
openapi: 3.1.0
info:
  title: WxO Server API
  summary: API for the next gen watsonx Orchestrate stack
  description: >+

    The watsonx Orchestrate Server provides a set of APIs to power the watsonx
    Orchestrate AI assistant. This includes the following core services:


    * Orchestrate Assistant - a built-in AI assistant that powers the
    Orchestrate end-user experience.

    * Custom Assistants - a service layer for interacting with existing AI
    assistatns (such as those in watsonx Assistant).

    * Message Threads - a chat history and async message tracking store.

    * Document Store - manage collections of documents in nearly any format
    including text, pdf, html and many more.

    * Information Extraction - automatically extract clean text and images from
    any document in the Document Store.  Also extract other useful metadata like
    questions answered, keywords, and named entities.

    * Embedding - generate vector embeddings for text and images in the Document
    Store.

    * Vector Index and Retrieval - automatically index documents with rich
    metadata for vector search or hybrid search.

    * Search Engine - create a Gen AI powered search engine that works like Bing
    or Google.

    * Query Engine - configure your own RAG (Retrieval Augmented Generation)
    engine supporting advanced retrieval patterns and automated data management.

    * Model Proxy - create your own LLM model endpoints for chat completions and
    embeddings.  Supports IBM watsonx.ai, IBM BAM, OpenAI, MistralAI, or Ollama
    for local models.


    WxO API Server utilizes the following open source projects:


    * [PostgreSQL](https://www.postgresql.org/)

    * [PGVector](https://github.com/pgvector/pgvector)

    * [LlamaIndex](https://docs.llamaindex.ai/en/stable/)

    * [LangChain](https://python.langchain.com/docs/get_started/introduction)

    * [FastAPI](https://fastapi.tiangolo.com/)

    * [Unstructured](https://unstructured.io/)

    * [Celery](https://docs.celeryproject.org/en/stable/)

  version: 0.1.0
servers:
  - url: https://{api_endpoint}
    description: version
security: []
paths:
  /v1/threads:
    get:
      tags:
        - Message Threads
      summary: List Message Threads
      operationId: List_Message_Threads_v1_threads_get
      parameters:
        - name: limit
          in: query
          required: false
          schema:
            anyOf:
              - type: integer
                minimum: 1
              - type: 'null'
            description: Limit the number of results returned
            title: Limit
          description: Limit the number of results returned
        - name: offset
          in: query
          required: false
          schema:
            anyOf:
              - type: integer
                minimum: 0
              - type: 'null'
            description: Skip the first N results
            title: Offset
          description: Skip the first N results
        - name: agent_id
          in: query
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            description: Filter threads by agent ID
            title: Agent Id
          description: Filter threads by agent ID
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                anyOf:
                  - $ref: '#/components/schemas/ThreadResponseWithPagination'
                  - type: array
                    items:
                      $ref: '#/components/schemas/Thread'
                title: Response List Message Threads V1 Threads Get
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
      security:
        - HTTPBearer: []
components:
  schemas:
    ThreadResponseWithPagination:
      properties:
        data:
          items:
            $ref: '#/components/schemas/Thread'
          type: array
          title: Data
        total:
          type: integer
          title: Total
        limit:
          type: integer
          title: Limit
        offset:
          type: integer
          title: Offset
      type: object
      required:
        - data
        - total
        - limit
        - offset
      title: ThreadResponseWithPagination
    Thread:
      properties:
        id:
          type: string
          format: uuid
          title: Id
        tenant_id:
          type: string
          title: Tenant Id
        status:
          anyOf:
            - $ref: '#/components/schemas/ThreadStatus'
            - type: 'null'
          default: ready
        tenant_name:
          anyOf:
            - type: string
            - type: 'null'
          title: Tenant Name
        title:
          anyOf:
            - type: string
            - type: 'null'
          title: Title
        assistant_id:
          anyOf:
            - type: string
              format: uuid
            - type: 'null'
          title: Assistant Id
        agent_id:
          anyOf:
            - type: string
              format: uuid
            - type: 'null'
          title: Agent Id
        knowledge_base_id:
          anyOf:
            - type: string
              format: uuid
            - type: 'null'
          title: Knowledge Base Id
        created_by:
          type: string
          title: Created By
        created_by_username:
          anyOf:
            - type: string
            - type: 'null'
          title: Created By Username
        created_on:
          anyOf:
            - type: string
              format: date-time
            - type: 'null'
          title: Created On
        updated_at:
          anyOf:
            - type: string
              format: date-time
            - type: 'null'
          title: Updated At
        deleted_at:
          anyOf:
            - type: string
              format: date-time
            - type: 'null'
          title: Deleted At
        deleted_by:
          anyOf:
            - type: string
            - type: 'null'
          title: Deleted By
        last_read_at:
          anyOf:
            - type: string
              format: date-time
            - type: 'null'
          title: Last Read At
        last_agent_message_at:
          anyOf:
            - type: string
              format: date-time
            - type: 'null'
          title: Last Agent Message At
      type: object
      required:
        - id
        - tenant_id
        - created_by
        - deleted_at
      title: Thread
    HTTPValidationError:
      properties:
        detail:
          items:
            $ref: '#/components/schemas/ValidationError'
          type: array
          title: Detail
      type: object
      title: HTTPValidationError
    ThreadStatus:
      type: string
      enum:
        - async_wait
        - ready
        - async_slot_request
        - async_a2a_slot_request
      title: ThreadStatus
    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
  securitySchemes:
    HTTPBearer:
      type: http
      scheme: bearer

````