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

# Create annotation for single trace

> Create an annotation for a single trace



## OpenAPI

````yaml POST /api/annotations/trace/{id}
openapi: 3.1.0
info:
  title: LangWatch API
  version: 1.0.0
  description: LangWatch openapi spec
servers:
  - url: https://app.langwatch.ai
security:
  - api_key: []
paths:
  /api/annotations/trace/{id}:
    post:
      description: Create an annotation for a single trace
      parameters:
        - name: id
          in: path
          description: ID of the trace to annotate
          required: true
          schema:
            type: string
      requestBody:
        description: Annotation data
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                comment:
                  type: string
                isThumbsUp:
                  type: boolean
                email:
                  type: string
      responses:
        '200':
          description: Annotation created
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Annotation'
        '400':
          description: Invalid input
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
components:
  schemas:
    Annotation:
      required:
        - name
      type: object
      properties:
        id:
          description: The ID of the annotation
          type: string
        projectId:
          description: The ID of the project
          type: string
        traceId:
          description: The ID of the trace
          type: string
        comment:
          description: The comment of the annotation
          type: string
        isThumbsUp:
          description: The thumbs up status of the annotation
          type: boolean
        userId:
          description: The ID of the user
          type: string
        createdAt:
          description: The created at of the annotation
          type: string
        updatedAt:
          description: The updated at of the annotation
          type: string
        email:
          description: The email of the user
          type: string
    Error:
      required:
        - error
        - message
      type: object
      properties:
        error:
          type: integer
          format: int32
        message:
          type: string
  securitySchemes:
    api_key:
      type: apiKey
      in: header
      name: X-Auth-Token

````