Создание примечания

Создает примечание.

Request

POST

https://api-metrika.yandex.net/management/v1/counter/{counterId}/chart_annotations

Path parameters

Name

Description

counterId

Type: integer

Идентификатор счетчика, для которого вы хотите создать примечание.

Body

application/json
{
  "chart_annotation": {
    "id": 0,
    "date": "2025-01-01",
    "time": "12:00:00",
    "title": "example",
    "message": "example",
    "group": "example"
  }
}

Name

Description

chart_annotation

Type: MetrikaChartAnnotation

Примечание на графике.

Example
{
  "id": 0,
  "date": "2025-01-01",
  "time": "12:00:00",
  "title": "example",
  "message": "example",
  "group": "example"
}

MetrikaChartAnnotation

Примечание на графике.

Name

Description

date

Type: string<date>

Дата.

Example: 2025-01-01

group

Type: string

Группа. Возможные значения:

  • A — группа A.
  • B — группа B.
  • C — группа C.
  • D — группа D.
  • E — группа E.

Example: example

title

Type: string

Заголовок.

Min length: 0

Max length: 255

Example: example

id

Type: integer

Идентификатор примечания.

message

Type: string

Описание.

Min length: 0

Max length: 1023

Example: example

time

Type: string<time>

Время.

Example: 12:00:00

Example
{
  "id": 0,
  "date": "2025-01-01",
  "time": "12:00:00",
  "title": "example",
  "message": "example",
  "group": "example"
}

Responses

200 OK

OK

Body

application/json
{
  "chart_annotation": {
    "id": 0,
    "date": "2025-01-01",
    "time": "12:00:00",
    "title": "example",
    "message": "example",
    "group": "example"
  }
}

Name

Description

chart_annotation

Type: MetrikaChartAnnotation

Примечание на графике.

Example
{
  "id": 0,
  "date": "2025-01-01",
  "time": "12:00:00",
  "title": "example",
  "message": "example",
  "group": "example"
}