After your extension starts sending data to Dynatrace, you can create a custom dashboard and then export its definition to a JSON file and add it to your extension archive. You can export a dashboard definition through the Dynatrace web UI or Dynatrace API.
id
parameter (for example, id=d996b25e-593c-4213-8ad3-c87319a8830a
) and save the parameter value.curl -X GET "https://{env-id}.live.dynatrace.com/api/config/v1/dashboards/{dashboard-id}" \-H "accept: application/json; charset=utf-8" \-H "Authorization: Api-Token `{api-token}"
{env-id}
with your Environment ID.{api-token}
with an API token that has the required permissions.{dashboard-id}
with the dashboard identifier you determined in the previous step.Add your dashboard JSON file to your extension package and reference it in your extension YAML file.
For the following package structure:
extension.zip│ extension.yaml│└───alerts│ | alert.json│└───dashboards│ dashboard.json
Use the following reference in the top level of your YAML file:
dashboards:- path: dashboards/dashboard.jsonalerts:- path: alerts/alert.json