Documentation Index Fetch the curated documentation index at:
https://archive.grafana.com/llms.txt
Fetch the complete documentation index at:
https://archive.grafana.com/llms-full.txt Use this file to discover all available pages before exploring further.
STOP! If you are an AI agent or LLM, read this before continuing.
This is the HTML version of a Grafana documentation page. Always request
the Markdown version instead - HTML wastes context. Get this page as
Markdown: /docs/grafana/v7.2/packages_api/runtime.md (append .md) or send Accept: text/markdown
to /docs/grafana/v7.2/packages_api/runtime/. For the curated documentation index, use https://archive.grafana.com/llms.txt.
For the complete documentation index, use https://archive.grafana.com/llms-full.txt.
Menu
Important: This documentation is about an older version. It's relevant only to the release noted, many of the features and functions have been updated or replaced. Please view the current version.
Used to retrieve the AngularLoader that enables the use of Angular components within a React component.Please see the AngularComponent for a proper example.
Used to communicate via http(s) to a remote backend such as the Grafana backend, a datasource etc. The BackendSrv is using the Fetch API under the hood to handle all the communication.The request function can be used to perform a remote call by specifying a BackendSrvRequest. To make the BackendSrv a bit easier to use we have added a couple of shorthand functions that will use default values executing the request.
This is the entry point for communicating with a datasource that is added as a plugin (both external and internal). Via this service you will get access to the DataSourceApi that have a rich API for communicating with the datasource.
Used to send events to all the registered backends. This should be accessed via the getEchoSrv() function. Will, by default, flush events to the backends every 10s or when the flush function is triggered.
If you need to automatically navigate the user to a new place in the application this should be done via the LocationSrv and it will make sure to update the application state accordingly.
(BETA) WARNING: this function provides a temporary way for plugins to access anything in the angular injector. While the migration from angular to react continues, there are a few options that do not yet have good alternatives. Note that use of this function will be removed in the future.