---
title: "Create annotation"
method: POST
path: "/api/tasks/{id}/annotations/"
tags: ["Annotations"]
---

# Create annotation

`POST /api/tasks/{id}/annotations/`

Add annotations to a task like an annotator does. The content of the result field depends on your
        labeling configuration. For example, send the following data as part of your POST
        request to send an empty annotation with the ID of the user who completed the task:

        ```json
        {
        "result": {},
        "was_cancelled": true,
        "ground_truth": true,
        "lead_time": 0,
        "task": 0
        "completed_by": 123
        }
        ```

## Path parameters

- `id` integer, required

## Request body

- AnnotationRequest — Annotation Serializer with FSM state support. Note: The 'state' field will be populated from the queryset annotation if present, preventing N+1 queries. Use .with_state() on your queryset.
  - `bulk_created` boolean, nullable — Annotation was created in bulk mode
  - `completed_by` integer
  - `draft_created_at` string, date-time, nullable — Draft creation time
  - `ground_truth` boolean — This annotation is a Ground Truth (ground_truth)
  - `import_id` integer, nullable — Original annotation ID that was at the import step or NULL if this annotation wasn't imported
  - `last_action` 'prediction' | 'propagated_annotation' | 'imported' | 'submitted' | 'updated' | 'skipped' | 'accepted' | 'rejected' | 'fixed_and_accepted' | 'deleted_review' — * `prediction` - Created from prediction * `propagated_annotation` - Created from another annotation * `imported` - Imported * `submitted` - Submitted * `updated` - Updated * `skipped` - Skipped * `accepted` - Accepted * `rejected` - Rejected * `fixed_and_accepted` - Fixed and accepted * `deleted_review` - Deleted review
  - `last_created_by` integer, nullable — User who created the last annotation history item
  - `lead_time` number, double, nullable — How much time it took to annotate the task
  - `parent_annotation` integer, nullable — Points to the parent annotation from which this annotation was created
  - `parent_prediction` integer, nullable — Points to the prediction from which this annotation was created
  - `project` integer, nullable — Project ID for this annotation
  - `result` object[] — List of annotation results for the task
  - `task` integer, nullable — Corresponding task for this annotation
  - `unique_id` string
  - `updated_by` integer, nullable — Last user who updated this annotation
  - `was_cancelled` boolean — User skipped the task

## Response `201`

Created annotation

- Annotation — Annotation Serializer with FSM state support. Note: The 'state' field will be populated from the queryset annotation if present, preventing N+1 queries. Use .with_state() on your queryset.
  - `bulk_created` boolean, nullable — Annotation was created in bulk mode
  - `completed_by` integer
  - `created_ago` string, required — Time delta from creation time
  - `created_at` string, date-time, required — Creation time
  - `created_username` string, required — Username string
  - `draft_created_at` string, date-time, nullable — Draft creation time
  - `ground_truth` boolean — This annotation is a Ground Truth (ground_truth)
  - `id` integer, required
  - `import_id` integer, nullable — Original annotation ID that was at the import step or NULL if this annotation wasn't imported
  - `last_action` 'prediction' | 'propagated_annotation' | 'imported' | 'submitted' | 'updated' | 'skipped' | 'accepted' | 'rejected' | 'fixed_and_accepted' | 'deleted_review' — * `prediction` - Created from prediction * `propagated_annotation` - Created from another annotation * `imported` - Imported * `submitted` - Submitted * `updated` - Updated * `skipped` - Skipped * `accepted` - Accepted * `rejected` - Rejected * `fixed_and_accepted` - Fixed and accepted * `deleted_review` - Deleted review
  - `last_created_by` integer, nullable — User who created the last annotation history item
  - `lead_time` number, double, nullable — How much time it took to annotate the task
  - `parent_annotation` integer, nullable — Points to the parent annotation from which this annotation was created
  - `parent_prediction` integer, nullable — Points to the prediction from which this annotation was created
  - `project` integer, nullable — Project ID for this annotation
  - `result` object[] — List of annotation results for the task
  - `state` string, required
  - `task` integer, nullable — Corresponding task for this annotation
  - `updated_at` string, date-time, required — Last updated time
  - `updated_by` integer, nullable — Last user who updated this annotation
  - `was_cancelled` boolean — User skipped the task

---

[API](https://skmtc.net/humansignal/apis/label-studio-api.md) · [All operations](https://skmtc.net/humansignal/apis/label-studio-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/humansignal/label-studio-api/versions/1b113b8df950/schema)
