How to get datasource list and datasource form from another datasource?

Hi!
Sorry, I do not speak English very well.

I want to write a data source plugin, which proxy the request to another data source and apply transformations on the result (at first step WMA or EMA).
Is there a way to get the list of data sources from QueryController and show another data source query form as a part of my data source query?

Yes. You can inject backendSrv and fetch a list of datasources like this (and then filter on name or type):

Thanks. It works.
And I found how to show the query editor from another data source as part of my datasource query - similarly to https://github.com/grafana/grafana/blob/master/public/app/features/plugins/plugin_loader.ts .

1 Like