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

# Configure Annotation Reply

> **Available for**: Chatflow, Chatbot, Agent apps.

Enables or disables the annotation reply feature. The request body is validated before the action runs, so `embedding_provider_name`, `embedding_model_name`, and `score_threshold` are required for both `enable` and `disable`. Executes asynchronously; use [Get Annotation Reply Job Status](/en/api-reference/annotations/get-annotation-reply-job-status) to track progress.



## OpenAPI

````yaml /en/api-reference/openapi_service.json post /apps/annotation-reply/{action}
openapi: 3.0.1
info:
  title: Dify Service API
  description: >-
    REST API for Dify applications and knowledge bases. Application endpoints
    authenticate with an app API key; knowledge endpoints authenticate with a
    dataset API key.
  version: 1.0.0
servers:
  - url: https://{api_base_url}
    description: >-
      Base URL of the Dify Service API. For self-hosted deployments, replace it
      with your own API base URL.
    variables:
      api_base_url:
        default: api.dify.ai/v1
        description: Host and path of the API base URL, without the `https://` prefix.
security:
  - ApiKeyAuth: []
tags:
  - name: Chat Messages
    description: Operations related to chat messages and interactions.
  - name: Files
    description: File upload and preview operations.
  - name: End Users
    description: Operations related to end user information.
  - name: Feedback
    description: User feedback operations.
  - name: Conversations
    description: Operations related to managing conversations.
  - name: Audio
    description: Text-to-Speech and Speech-to-Text operations.
  - name: Applications
    description: Operations to retrieve application settings and information.
  - name: Annotations
    description: Operations related to managing annotations for direct replies.
  - name: Human Input
    description: Endpoints for resuming paused workflows that require human input.
  - name: Workflow Runs
    description: Operations for executing and managing workflows.
  - name: Completion Messages
    description: Operations related to text generation and completion.
  - name: Knowledge Bases
    description: >-
      Operations for managing knowledge bases, including creation,
      configuration, and retrieval.
  - name: Documents
    description: >-
      Operations for creating, updating, and managing documents within a
      knowledge base.
  - name: Chunks
    description: Operations for managing document chunks and child chunks.
  - name: Metadata
    description: >-
      Operations for managing knowledge base metadata fields and document
      metadata values.
  - name: Tags
    description: Operations for managing knowledge base tags and tag bindings.
  - name: Models
    description: Operations for retrieving available models.
  - name: Knowledge Pipeline
    description: >-
      Operations for managing and running knowledge pipelines, including
      datasource plugins and pipeline execution.
paths:
  /apps/annotation-reply/{action}:
    post:
      tags:
        - Annotations
      summary: Configure Annotation Reply
      description: >-
        **Available for**: Chatflow, Chatbot, Agent apps.


        Enables or disables the annotation reply feature. The request body is
        validated before the action runs, so `embedding_provider_name`,
        `embedding_model_name`, and `score_threshold` are required for both
        `enable` and `disable`. Executes asynchronously; use [Get Annotation
        Reply Job
        Status](/en/api-reference/annotations/get-annotation-reply-job-status)
        to track progress.
      operationId: initialAnnotationReplySettings
      parameters:
        - name: action
          in: path
          required: true
          description: Action to perform.
          schema:
            type: string
            enum:
              - enable
              - disable
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/InitialAnnotationReplySettingsRequest'
            examples:
              enableAnnotationReply:
                summary: Request Example
                value:
                  score_threshold: 0.9
                  embedding_provider_name: openai
                  embedding_model_name: text-embedding-3-small
      responses:
        '200':
          description: Annotation reply settings task initiated.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/InitialAnnotationReplySettingsResponse'
              examples:
                annotationReplyResponse:
                  summary: Response Example
                  value:
                    job_id: a1b2c3d4-5678-90ab-cdef-1234567890ab
                    job_status: waiting
components:
  schemas:
    InitialAnnotationReplySettingsRequest:
      type: object
      description: Request body for configuring annotation reply settings.
      required:
        - score_threshold
        - embedding_provider_name
        - embedding_model_name
      properties:
        embedding_provider_name:
          type: string
          description: Name of the embedding model provider (e.g., `openai`, `cohere`).
        embedding_model_name:
          type: string
          description: >-
            Name of the embedding model to use for annotation matching (e.g.,
            `text-embedding-3-small`).
        score_threshold:
          type: number
          format: float
          description: >-
            Minimum similarity score for an annotation to be considered a match.
            Higher values require closer matches.
    InitialAnnotationReplySettingsResponse:
      type: object
      properties:
        job_id:
          type: string
          format: uuid
          description: >-
            Asynchronous job ID. Use with [Get Annotation Reply Job
            Status](/en/api-reference/annotations/get-annotation-reply-job-status)
            to track progress.
        job_status:
          type: string
          description: >-
            Current job status: `waiting` (queued) or `processing` (in
            progress). `completed` and `error` are returned only by [Get
            Annotation Reply Job
            Status](/en/api-reference/annotations/get-annotation-reply-job-status).
  securitySchemes:
    ApiKeyAuth:
      type: http
      scheme: bearer
      bearerFormat: API_KEY
      description: >-
        API Key authentication. For all API requests, include your API Key in
        the `Authorization` HTTP Header, prefixed with `Bearer `. Example:
        `Authorization: Bearer {API_KEY}`. **Strongly recommend storing your API
        Key on the server-side, not shared or stored on the client-side, to
        avoid possible API-Key leakage that can lead to serious consequences.**
        Requests with a missing or invalid API key fail with HTTP `401` and
        error code `unauthorized`.

````