PMM Annotations API with time


Is it posible to make an annotation from the command line for a time in the past?
We had an event over night and I’ll like to make an annotation for all nodes/services at that time, but I cant find any ‘time’ argument for the command.
e.g. some thing like this

pmm-admin annotate “DB crashed” --time “20210818 010506”


Hi Rune,

You may use the API for adding an annotation with additional parameters.


curl 'http://admin:admin@localhost/graph/api/annotations' -H 'Content-Type: application/json;charset=UTF-8' --data-binary '{"tags": ["pmm-server"], "time":1629237906000, "text":"DB crashed"}'

1 Like

sorry, it doesn’t work for me. I end up with the annotation at the time I call curl not the time provided as an argument.

I tried both the swagger interface and your ‘/graph/api/annotations’, no luck.

1 Like

You may update time for already created annotations.

1629237906000 → 1629237906666

1 Like