Annotations

Create Annotation

Available for: Chatflow, Chatbot, Legacy Agent apps.

Creates an annotation. Annotations are predefined question-answer pairs the app returns directly on a match, instead of generating a fresh response.

post/apps/annotations

Request

  • Base URL
    https://api.dify.ai/v1
  • URL
    https://api.dify.ai/v1/apps/annotations
  • Auth
    HTTP bearer

Request body

answerstring required

Answer returned when this annotation is matched.

questionstring required

Question text the app matches incoming user input against.

Response

Annotation created successfully.

answerstring nullable

Predefined answer returned when the annotation is matched.

created_atinteger nullable

Creation timestamp (Unix epoch seconds).

hit_countinteger nullable

Number of times this annotation has been matched and returned as a reply.

idstring uuid

Unique annotation identifier.

questionstring nullable

Question text that triggers this annotation.

Changes

No recorded changes to this operation across all 17 revisions of this API.