Annotations query results for custom plugin

hi,
the only panels that are able to visualize annotations are times series , graph and candlestick.
However, I’d like to use results of annotations query (configured in the dashboard settings, applying dashboard variables) in my custom plugin .
The problem is that ‘annotations’ array in the ‘data’ object passed to my panel plugin is always empty.

Where can I find the place in grafana’s code where it prevents annotations from being passed to any other viz but times-series?
Is there a workaround to get annotation query results in custom plugin?

@vaduga You need to add data support in the module.ts:

.setDataSupport({
    annotations: true,
    alertStates: true,
  });
1 Like