Do you need to schedule reports that contain charts or dashboards? Do you want to automate how you share dashboards? You can obtain your dashboards as PDF or PNG files programmatically with a GraphQL mutation. You can also export dashboards as PDF files using the UI.
For example, You can generate static, snapshot versions of your New Relic dashboards and send them to Slack or download as files. To learn how, watch this short YouTube video (approx. 4 minutes).
Export dashboard pages
Obtain the dashboard's GUID: Click the icon by the dashboard's name to access the See metadata and manage tags modal and see the dashboard's GUID.
Get the individual pages' GUIDs using the query below:
{ actor { entitySearch(query: "parentId ='YOUR_PAGE_GUID'") { results { entities { guid name ... on DashboardEntityOutline { guid name dashboardParentGuid } } } } } }
Run the dashboardCreateSnapshotURL mutation in the NerdGraphQL explorer as many times as dashboard pages you want to export. You just need to provide the desired dashboard page GUID as a parameter.
Get the link to retrieve your dashboard page as a PDF. The link looks similar to:
https://gorgon.nr-assets.net/image/e0c22263-2d88-40bc-940a-b885dbc1d98d?format=PDF&width=2000&height=2000
- Configure the exported file, if necessary.
Configure the file you retrieve
Edit the returned link to change the format of your export (PDF or PNG), or resize it.
For example, if you obtain the link:
https://gorgon.nr-assets.net/image/e0c22263-2d88-40bc-940a-b885dbc1d98d?format=PDF&width=2000&height=2000
You could:
- Substitute
PDF
forPNG
to get an image. - Modify the width and height fields to adjust the size to your needs. The maximum value is
2000
.