Operate with annotation

annotation(
  annotation_id,
  action = c("fetch", "update", "delete", "flag", "hide", "show"),
  ...,
  api_path = get_hs_host(),
  api_key = NULL
)

Arguments

annotation_id

Annotation ID

action

Action to process, Default: `fetch` Hide and show action needs moderator permissions.

...

Parameters for update annotation action, more information in hypothesis documentation

api_path

The hypothesis API path, can be specify by `hypothesis.api.api_path` option or `HYPOTHESIS_API_PATH` environment variable. Default: `https://hypothes.is/api/`.

api_key

User api key, generated on the platform.

Examples

if (FALSE) {
annotation("annotation_id")
annotation("annotation_id", action = "update", text = "updated text")
annotation("annotation_id", action = "flag")
annotation("annotation_id", action = "hide")
annotation("annotation_id", action = "show")
}