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

# Create annotation

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

## Request

- Base URL: `https://demo.hitkeep.com`
- URL: `https://demo.hitkeep.com/api/sites/{id}/annotations`
- Auth: one of:
  - API key in cookie `hk_token`
  - HTTP bearer
  - API key in header `X-API-Key`

Adds a note at a point in time or across a range. Requires site.manage_annotations.

## Path parameters

- `id` string, uuid, required

## Request body

- AnnotationInput
  - `body` string, required
  - `ends_at` string, date-time: Set to mark a range; must not be before starts_at.
  - `starts_at` string, date-time, required

## Response `201`

Created annotation

- Annotation
  - `body` string
  - `created_at` string, date-time
  - `ends_at` string, date-time: Omitted for a single point in time.
  - `id` string, uuid
  - `site_id` string, uuid
  - `starts_at` string, date-time

## Other responses

- `400`: Invalid annotation

---

[API](https://skmtc.dev/hitkeep/apis/hitkeep-rest-api.md) · [All operations](https://skmtc.dev/hitkeep/apis/hitkeep-rest-api/llms.txt) · [OpenAPI document](https://skmtc.dev/hitkeep/apis/hitkeep-rest-api/revisions/bb2df36ab2a4?raw)
