---
title: "Update the modifiable fields (Spoiler, highlight slot, and comment) for an annotation"
method: POST
path: "/api/Annotation/update"
tags: ["Annotation"]
---

# Update the modifiable fields (Spoiler, highlight slot, and comment) for an annotation

`POST /api/Annotation/update`

## Request body

- AnnotationDto
  - `id` integer
  - `xPath` string, nullable, required
  - `endingXPath` string, nullable
  - `selectedText` string, nullable
  - `comment` string, nullable
  - `commentHtml` string, nullable
  - `commentPlainText` string, nullable
  - `chapterTitle` string, nullable
  - `context` string, nullable
  - `highlightCount` integer
  - `containsSpoiler` boolean
  - `pageNumber` integer
  - `selectedSlotIndex` integer
  - `likes` integer[], nullable
  - `seriesName` string, nullable
  - `libraryName` string, nullable
  - `chapterId` integer, required
  - `volumeId` integer, required
  - `seriesId` integer, required
  - `libraryId` integer, required
  - `ownerUserId` integer, required
  - `ownerUsername` string, nullable
  - `ageRating` 0 | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | -1 — Members: - `0` — Unknown - `1` — Rating Pending (RatingPending) - `2` — Early Childhood (EarlyChildhood) - `3` — Everyone - `4` — G - `5` — Everyone 10+ (Everyone10Plus) - `6` — PG - `7` — Kids to Adults (KidsToAdults) - `8` — Teen - `9` — MA15+ (Mature15Plus) - `10` — Mature 17+ (Mature17Plus) - `11` — M (Mature) - `12` — R18+ (R18Plus) - `13` — Adults Only 18+ (AdultsOnly) - `14` — X18+ (X18Plus) - `-1` — Not Applicable (NotApplicable)
  - `createdUtc` string, date-time
  - `lastModifiedUtc` string, date-time

## Response `200`

OK

- AnnotationDto
  - `id` integer
  - `xPath` string, nullable, required
  - `endingXPath` string, nullable
  - `selectedText` string, nullable
  - `comment` string, nullable
  - `commentHtml` string, nullable
  - `commentPlainText` string, nullable
  - `chapterTitle` string, nullable
  - `context` string, nullable
  - `highlightCount` integer
  - `containsSpoiler` boolean
  - `pageNumber` integer
  - `selectedSlotIndex` integer
  - `likes` integer[], nullable
  - `seriesName` string, nullable
  - `libraryName` string, nullable
  - `chapterId` integer, required
  - `volumeId` integer, required
  - `seriesId` integer, required
  - `libraryId` integer, required
  - `ownerUserId` integer, required
  - `ownerUsername` string, nullable
  - `ageRating` 0 | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | -1 — Members: - `0` — Unknown - `1` — Rating Pending (RatingPending) - `2` — Early Childhood (EarlyChildhood) - `3` — Everyone - `4` — G - `5` — Everyone 10+ (Everyone10Plus) - `6` — PG - `7` — Kids to Adults (KidsToAdults) - `8` — Teen - `9` — MA15+ (Mature15Plus) - `10` — Mature 17+ (Mature17Plus) - `11` — M (Mature) - `12` — R18+ (R18Plus) - `13` — Adults Only 18+ (AdultsOnly) - `14` — X18+ (X18Plus) - `-1` — Not Applicable (NotApplicable)
  - `createdUtc` string, date-time
  - `lastModifiedUtc` string, date-time

---

[API](https://skmtc.net/kareadita/apis/kavita.md) · [All operations](https://skmtc.net/kareadita/apis/kavita/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/kareadita/kavita/revisions/a092f0284f3e/schema)
